Skip to content

feat(metric-benchmark): compute paired mutant scores for fixed subsets - #95

Merged
mstaats-nvidia merged 7 commits into
mainfrom
feat/metric-benchmark-mutant-scores
Oct 31, 2026
Merged

mstaats-nvidia merged 7 commits into
mainfrom
feat/metric-benchmark-mutant-scores

Conversation

@mstaats-nvidia

@mstaats-nvidia mstaats-nvidia commented Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

Compute equally weighted mean signed baseline-to-mutant degradation for each fixed task subset. Negative effects remain valid and receive inspection diagnostics; missing required pairs produce unavailable scores with missing_score_reason rather than zero or a reduced task set.

compute_mutant_scores.py owns the CLI and calls the scoring library for one case. It takes --cases, --analysis, --case, --results-root, and --output, checks the saved case identity, and selects recorded attempts by execution number. With signed case inputs, scoring needs only metadata, subsets, and results indexes. Unsigned sources must remain available to establish content identity; sign before removing them. Native validation is a separate tool.

The command guide documents arguments, the library API, and a worked JSON-output example. Public scoring functions have short docstrings. The shared score schema uses missing_score_reason throughout code, examples, validation reports, and synthetic fixtures.

Validation at f7a71eb:

  • Full local suite with the Docker smoke enabled: 3,413 passed, 35 skipped, 290 warnings. Skips cover unavailable optional runtimes, Node-dependent rendering checks, Windows-only behavior, and explicitly gated live-model execution.
  • Nine real local Harbor trials passed, followed by completed-job reuse and relocation. Scoring the saved native results produced the expected three subset scores; CLI/library output was byte-identical and execution evidence stayed unchanged.
  • Downstream benchmark suite at feat(metric-benchmark): orchestrate configured experiments through stage libraries #99 f81f82a: 180 passed, 1 skipped (the Docker opt-in test, exercised separately above). This covers coverage/correlation consumption, coordinator replay, and standalone CLI parity.
  • Ruff, formatting, type checks for Python 3.12/3.13, copyright, license, DCO, and whitespace checks passed.
  • Hosted CI passed on this exact head, including Python 3.12/3.13 and all three native Gym compatibility routes.

Both inline review comments are addressed and resolved. The new regression cases cover rejection of a different cases_sha256 and aggregation across three tasks and two mutants. No scoring algorithm changes were needed during final validation.

Stack: main → #95 mutant scores → #96 coverage → #97 correlation → #99 coordinator. Merge preparation is complete; this PR remains open and has not been merged.

@mstaats-nvidia
mstaats-nvidia force-pushed the feat/metric-benchmark-mutant-scores branch from 1475e24 to 2a5f513 Compare October 21, 2026 20:22
@mstaats-nvidia
mstaats-nvidia force-pushed the feat/metric-benchmark-mutant-scores branch from 2a5f513 to 9ba3336 Compare October 21, 2026 20:28
@mstaats-nvidia
mstaats-nvidia force-pushed the feat/metric-benchmark-mutant-scores branch from 9ba3336 to c5b22ce Compare October 21, 2026 21:08
@mstaats-nvidia mstaats-nvidia changed the title feat(metric-benchmark): compute paired mutant scores feat(metric-benchmark): compute paired mutant scores for fixed subsets Oct 21, 2026
@mstaats-nvidia
mstaats-nvidia changed the base branch from feat/metric-benchmark-subsets to feat/metric-benchmark-execution October 21, 2026 21:10
@mstaats-nvidia
mstaats-nvidia added this pull request to stack #107 October 21, 2026 21:10
@mstaats-nvidia
mstaats-nvidia force-pushed the feat/metric-benchmark-mutant-scores branch from c5b22ce to 442aff9 Compare October 23, 2026 14:33
mstaats-nvidia added a commit that referenced this pull request Oct 23, 2026
Defines an experimental benchmark for evaluating how well our coverage
metric predicts evaluation effectiveness through mutation testing.

The concise [root
README](https://github.com/NVIDIA-NeMo/eval-author/blob/docs/metric-benchmark-design/labs/metric-benchmark/README.md)
describes the project, its work-in-progress status, and the expectation
that case examples will grow, change, or be dropped as we build in plain
sight. Prep is external to this repository; runs consume prepared case
examples, fixed subset manifests, and a YAML benchmark definition.

The [stage
descriptions](https://github.com/NVIDIA-NeMo/eval-author/blob/docs/metric-benchmark-design/labs/metric-benchmark/docs/stages.md)
focus on four executable stages: run mutants × eval tasks, compute
mutant scores, compute coverage, and correlate the score pairs. The
first execution script will be a basic local Harbor loop; NeMo Helix
support is planned afterward. The [architecture and both SVG
figures](https://github.com/NVIDIA-NeMo/eval-author/blob/docs/metric-benchmark-design/labs/metric-benchmark/docs/architecture.md)
explain the inputs, component boundaries, shared results directory, and
statistical comparison.

This is the documentation-only base of the stack. Implementation PRs #94
→ #105 → #106 → #95 → #96 → #97 → #99 inherit the overview and design
unchanged. Their detailed CLI guide lives separately in `docs/tools.md`.

Validation: the five files in this PR are Markdown/SVG only. Local links
and anchors, Markdown fences, headers, SVG XML, and whitespace checks
pass; the updated figure was rendered and visually inspected. Restacking
preserves all source and test files byte-for-byte. No live evaluations
or model calls were made.
@mstaats-nvidia
mstaats-nvidia force-pushed the feat/metric-benchmark-mutant-scores branch from 442aff9 to 91ac3a9 Compare October 23, 2026 14:42
@mstaats-nvidia
mstaats-nvidia force-pushed the feat/metric-benchmark-mutant-scores branch from 91ac3a9 to ca1acfd Compare October 26, 2026 12:32
@mstaats-nvidia
mstaats-nvidia force-pushed the feat/metric-benchmark-mutant-scores branch 2 times, most recently from 86f0de5 to a0f0a5a Compare October 26, 2026 15:21
@mstaats-nvidia
mstaats-nvidia force-pushed the feat/metric-benchmark-mutant-scores branch from a0f0a5a to 5ec53b2 Compare October 26, 2026 19:19
@mstaats-nvidia
mstaats-nvidia force-pushed the feat/metric-benchmark-mutant-scores branch 2 times, most recently from 5e70825 to 054838e Compare October 28, 2026 13:01
Base automatically changed from feat/metric-benchmark-execution to main October 29, 2026 10:28
@mstaats-nvidia
mstaats-nvidia force-pushed the feat/metric-benchmark-mutant-scores branch from 054838e to 97d0e07 Compare October 29, 2026 10:30
@mstaats-nvidia
mstaats-nvidia force-pushed the feat/metric-benchmark-mutant-scores branch from 5c9825d to 4e07b36 Compare October 29, 2026 14:27
@mstaats-nvidia
mstaats-nvidia removed this pull request from stack #107 October 29, 2026 14:28
@mstaats-nvidia
mstaats-nvidia changed the base branch from main to feat/metric-benchmark-stage-config October 29, 2026 14:28
@mstaats-nvidia
mstaats-nvidia added this pull request to stack #158 October 29, 2026 14:28
@mstaats-nvidia
mstaats-nvidia force-pushed the feat/metric-benchmark-mutant-scores branch from 4e07b36 to b9ceae8 Compare October 29, 2026 14:40
@mstaats-nvidia
mstaats-nvidia force-pushed the feat/metric-benchmark-mutant-scores branch from b9ceae8 to 68f55f3 Compare October 29, 2026 15:26
@mstaats-nvidia
mstaats-nvidia marked this pull request as ready for review October 29, 2026 15:33
@mstaats-nvidia
mstaats-nvidia requested a review from a team as a code owner October 29, 2026 15:33

@aleckhoury aleckhoury left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The scoring math checks out. Each subset's score is the equal-weight mean over mutants of the mean paired task degradation, sign * (baseline - mutant). Negative values are kept and flagged in diagnostics. A missing, incomplete or metric-absent pair makes that mutant effect and the subset score null with a reason; nothing turns into zero or is silently dropped. Attempts are selected by execution number, never by outcome.

Edge cases probed:

  • With latest, a failed first attempt followed by a later success scores correctly.
  • lower_is_better produces the right sign.
  • A wrong metric name makes every subset unavailable.
  • With signed inputs, scoring works after task dirs, bundles and native trial dirs are removed.

At this head: 139 passed, 1 skipped. Two small notes inline.

Base automatically changed from feat/metric-benchmark-stage-config to main October 30, 2026 21:36
@mstaats-nvidia
mstaats-nvidia force-pushed the feat/metric-benchmark-mutant-scores branch from 68f55f3 to 8ebc003 Compare October 30, 2026 21:36
Clarify when scoring can omit executable inputs and document unsigned iteration.

Signed-off-by: mstaats <mstaats@nvidia.com>
Signed-off-by: mstaats <mstaats@nvidia.com>
Signed-off-by: mstaats <mstaats@nvidia.com>
Signed-off-by: mstaats <mstaats@nvidia.com>
@mstaats-nvidia
mstaats-nvidia merged commit 4543876 into main Oct 31, 2026
20 checks passed
@mstaats-nvidia
mstaats-nvidia deleted the feat/metric-benchmark-mutant-scores branch October 31, 2026 11:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants