Skip to content

Add a readable summary of the published results, and check it for staleness - #58

Merged
wshlavacek merged 7 commits into
mainfrom
summary-guard
Nov 25, 2026
Merged

wshlavacek merged 7 commits into
mainfrom
summary-guard

Conversation

@wshlavacek

Copy link
Copy Markdown
Collaborator

Adds a readable summary of the published results, generated from the committed data and guarded against going stale.

What a reader sees

  • published/README.md lists every suite (all 12) with its latest snapshot, its correctness tally and a status: CURRENT, OUT OF DATE (with the reason), or not published.
  • Each snapshot gets a README.md with:
    • a header naming the BNGsim version and build, every engine's version, the harness commit and the timing node;
    • a correctness table, with each reference's verdict and a one-line reason for every check that failed;
    • a timing table in absolute seconds, with 95% CIs;
    • speedups as a derived view only.

How it stays honest

  • Generated, never hand-written. bench publish writes the summaries, and bench publish --index rewrites the index. tests/test_summary.py rebuilds every summary from the committed data and fails on any difference.

  • bench staleness marks a snapshot OUT OF DATE in any of these cases:

    • a newer BNGsim release is on PyPI;
    • the suite's members changed;
    • a job's definition changed (model sha256, PEtab tables, protocol, verdict, harness version, setting);
    • a pinned engine version changed.

    Except for the PyPI lookup, everything is read from committed files.

  • Weekly workflow. .github/workflows/staleness.yml runs on Mondays, on every push to main and on demand. It keeps one issue, "Published results are out of date", open and up to date, and closes it when everything is current. It uses only GITHUB_TOKEN with issues: write.

  • Skipped releases. published/skipped-releases.json records releases skipped on purpose. 0.17.3 is skipped; the next measured release is 0.17.4.

Changes to the published data

  • CSV setting column. correctness.csv and timing.csv gain a setting column after problem. A member measured in two settings could otherwise be told apart only by row order: nf_exact and nf_reject, or sens-net's auto and fitted.
  • Fuller manifests. Each manifest now lists every engine a suite uses, adding NFsim, RuleMonkey, Antimony and PEtab where used. The schema stays at 1, because keys are only added.

The unit suite passes: 1006 tests.

A member has one job per setting where a capability runs several: the
network-free suites run nf_exact and nf_reject for every member, and
sens-net runs auto and, for five members, fitted. correctness.csv and
timing.csv had no setting column, so the two rows a member's engine gets
could only be told apart by their order in the file. Both files now carry
the job's setting after the problem.

The eight committed snapshots are migrated, not re-measured: their rows
were rebuilt from each snapshot's own jobs/*.json with publish's row
functions, and the rebuilt rows equal the committed ones byte for byte
apart from the new column. The manifest schema stays 1: the column is
added, none is removed or changed.
bench.staleness.reasons() lists every way a committed snapshot no longer
says what the repository would measure now: a newer bngsim release on
PyPI or another bngsim pinned in pixi.toml; members added, dropped or
moved; a member's job ids changed (an engine added, a setting changed);
a job definition that differs from the one its record was keyed on
(model sha256, PEtab tables, protocol, verdict, harness, timing
protocol, input conversion); the harness identity (bench version,
vendored verdict code, forced environment); and reference engine
versions that differ from the environment's pins.

Everything but the PyPI release comes from committed files, so every
machine gives the same answer. A job reads its engines' versions from
the environment it runs in; here those fields are replaced by the
pixi.toml pins (and bench.fetch's for BioNetGen and RuleMonkey), and an
engine with no pin is refused rather than silently ignored. The newest
release skips pre-releases and fully yanked ones.
…data

bench publish now writes a README.md into every snapshot, generated from
that snapshot's manifest.json, correctness.csv and timing.csv alone: a
header naming the bngsim version and build, the engine versions, the
harness version and commits, the timing node and the date; a correctness
table with each member's outcome and every reference's verdict, then one
line per check that did not pass naming the engine and why; and a timing
table of absolute pre-sim and solve medians with their 95% CI per
engine. A speedup appears only as a view derived from that table.

It also writes the index, published/README.md and index.json: all twelve
suites of specs.SUITES, each one's latest snapshot, the tally of its
correctness outcomes, and CURRENT, OUT OF DATE (with every reason from
bench.staleness) or NOT PUBLISHED. index.json records the newest bngsim
release seen on PyPI and the day it was looked up, so the index is a
function of committed files.

bench publish --index regenerates the summaries without publishing
(--offline: keep the recorded release). bench staleness prints each
suite's status and reasons, exits 1 when a published suite is out of
date and 2 when PyPI cannot be read, and can write the out-of-date
suites as an issue body. tests/test_summary.py regenerates every
summary from the committed data and fails on any difference, so a spec,
snapshot or code change that would change what they say cannot land
without them.

The summaries of the eight published suites are generated here. bngsim
0.17.3 is on PyPI, so all eight show OUT OF DATE.
A workflow runs bench staleness every Monday, on every push to main and
on demand, regenerating the index with that day's status. While any
published suite is out of date it keeps one issue, "Published results
are out of date", open with a table of the suites and every reason, and
updates its body on each run; it closes the issue when every published
suite is current again. A PyPI lookup that fails, or any other error,
fails the run instead of reporting the suites current. The regenerated
index and the issue body are kept as the run's artifact; nothing is
pushed, and the only credential is the workflow's GITHUB_TOKEN with
issues: write.
A snapshot README's failure line for an ODE DIFF repeated the table's
"DIFF (both)" and then "failed both checks". It now says "DIFF" and
names the half that failed: bngsim's vendored verdict, the per-species
check, or both. ode-sbml's README is regenerated.
The user decided (2026-11-25) to skip bngsim 0.17.3 and measure again
at 0.17.4. published/skipped-releases.json now lists each release
skipped on purpose with the reason and date of the decision, and
staleness does not count a skipped release as newer: a snapshot stays
CURRENT, and the index says so beside its status ("CURRENT (bngsim
0.17.3 skipped: ...)"). The next release that is not skipped makes it
out of date, as does one between the snapshot and a skipped release, so
the PyPI lookup now records every final release (index.json
bngsim_release.releases), not only the newest. A malformed skip list is
refused.

The index is regenerated: the eight published snapshots are CURRENT,
so the staleness workflow's first run on main finds nothing to report.
A manifest's engines named only BioNetGen, libRoadRunner, COPASI and
AMICI, so a network-free snapshot did not say which NFsim or RuleMonkey
it measured. engines now adds, after those four, NFsim (the binary
BioNetGen bundles, at the version env.NFSIM_VERSION reports), RuleMonkey
(rm_driver), Antimony (the converter an ode-antimony job used) and
PEtab, each only where the suite's jobs use it. The keys are added,
none removed or changed, so the schema stays 1.

The eight committed manifests are extended from their own records with
the same function, the four existing engine lists checked unchanged,
and nothing else in them or their CSVs changes: the two network-free
suites gain NFsim 1.14.3 and RuleMonkey 3.13.0, sens-sbml PEtab 0.10.0.
Their READMEs are regenerated.
@wshlavacek
wshlavacek merged commit e56ef4e into main Nov 25, 2026
2 checks passed
@wshlavacek
wshlavacek deleted the summary-guard branch November 29, 2026 00:12
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.

1 participant