Repository navigation
Description
Summary
release_audit.py benchmark --run A B already accepts several run directories
and aggregates them per case, but it treats them as unrelated evidence:
- different candidate builds are averaged together without a warning;
- the only stability signal is
pass_rate, so a scenario that passes 2 of 3
times is reported as an average instead of as a 0%pass^kfailure; - nothing distinguishes a deterministic pass from a scenario that intermittently
fails and will therefore bite a release.
Please report pass@k, pass^k and an explicit flaky list when several runs of
the same build are supplied, and refuse to aggregate runs that do not share
one candidate.
Current behavior
aggregate_multi_run_benchmarks() (scripts/release_audit.py) collects
runs, passes and pass_rate per case, and summary.candidates lists every
candidate it saw. A two-run synthetic ledger reproduces it:
"candidates": ["aaaaaaa", "bbbbbbb"],
"summary": { "runs_count": 2, "full_pass_runs": 1, "mean_success_rate": 0.8334 },
"cases": [
{ "id": "ARENA-JOINT-FORMS", "runs": 2, "passes": 2, "pass_rate": 1.0 },
{ "id": "LIVE-V2EX", "runs": 2, "passes": 1, "pass_rate": 0.5 },
{ "id": "PLAN-BATCH-FORM", "runs": 2, "passes": 2, "pass_rate": 1.0 }
]Two different candidates are averaged into one mean_success_rate, and the
intermittent LIVE-V2EX failure has no dedicated field.
Why it matters
gate requires every planned scenario to pass in a single authoritative round,
which is the right release bar. But when the same build is exercised more than
once, a single boolean per scenario cannot answer the question a release
actually asks: does this pass every time?
pass@k(at least one success in k trials) always improves with k and is the
wrong headline for a release gate.pass^k(all k trials succeed) is the release-relevant number: a scenario
with 75% single-run success has only ~42% pass^3.- The flaky list is the entry point for the transcript review that currently
has to be done by hand fromcommands/*/meta.json.
Reporting only pass_rate also hides a genuine integrity problem: nine clean
runs plus one unrelated build produce plausible-looking numbers that mean
nothing.
Proposal
Extend the existing multi-run path rather than adding a parallel command:
- Fail closed on mixed candidates. Require every supplied run to share
candidate,entry_sha256,binary_sha256, and theplan.jsondigest.
Otherwise error out and name the run that differs. - Report stability per case. Add
pass_at_k(passes > 0),pass_all_k
(passes == runs), andflaky(0 < passes < runs) tocases, plus
pass_at_k_overall,pass_all_k_overallandflaky_idstosummary.
kis the number of runs supplied; treat fewer than two runs as a plain
benchmark and do not emit stability fields. - Render it. Add a stability table to
render_multi_run_markdown(): case id, runs, passes,pass_rate,
pass@k,pass^k, flaky marker. - Leave
gatealone. Trials are additional evidence. The release verdict
keeps requiring every planned scenario to pass in the authoritative round,
so this change cannot lower the bar.
Non-goals
- The helper does not execute browser work; trials are still produced by the
agent running freshinitrounds. Each run must be an independent round with
its own fixtures, port and sessions, which is what makes the trial meaningful. - No change to
result,results.jsonor thegatecontract. - No probabilistic extrapolation:
pass@k/pass^khere are empirical over the
supplied runs, not estimates over unseen trials.
Scope
Roughly 80 lines in release_audit.py (aggregation, summary, markdown) plus
unit tests in test_release_audit.py using synthetic run directories. No
browser execution, no CLI schema change.
Open questions
- Should the same-build check be unconditional in
benchmark --run ..., or
opt-in via a flag so mixed-build comparisons still have an escape hatch? - If a caller supplies trials, should
gategain an optional
--require-pass-allmode, or stay strictly single-round? - Are
pass_at_k/pass_all_kthe field names you want in
benchmark-multi.json, or should the report usepass@k/pass^kliterally?
Activity