Skip to content

Follow-up: add explicit SAGE coverage for consensus feature union introduced in latest PR #717

Description

@ypriverol

Description of the bug

After merging #82 (comet+msgf consensus feature union), we should explicitly validate and (if needed) generalize the same logic for SAGE-involving configurations.

Context

PR #82 fixed the two-engine comet,msgf path by:

  • unioning per-engine numeric features,
  • applying orientation-aware worst-case imputation,
  • adding engine-source indicators.

SAGE support was not explicitly covered in the PR scope/results/tests.

Reference: bigbio/quantms-rescoring#82

Goal

Ensure consensus feature construction behaves correctly for SAGE in:

  • search_engines=sage
  • search_engines=comet,sage
  • search_engines=msgf,sage
  • (optional) search_engines=comet,msgf,sage if fully supported

Acceptance criteria

  • extra_features contains expected SAGE-derived numeric features in SAGE-involving runs.
  • Engine indicator features are present/consistent for all configured engines (including SAGE).
  • Missing feature imputation is orientation-aware for SAGE features (or a documented fallback is used).
  • No inf/sentinel artifacts leak into model features for SAGE paths.
  • Unit tests cover SAGE-only and mixed-engine scenarios.
  • Benchmark sanity check at 1% protein FDR shows no regression vs the appropriate single-engine baseline.

Suggested tests

Add coverage in tests/test_consensus_features.py (or equivalent) for:

  • single-engine SAGE,
  • comet+sage overlap and single-engine subsets,
  • msgf+sage overlap and single-engine subsets,
  • optional three-engine merge (comet,msgf,sage).

Also validate both:

  • ms2features-off (psm_feature_clean) path,
  • ms2features-on (annotator) path.

Command used and terminal output

Relevant files

No response

System information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions