Skip to content

chore(eval): promote the live A/B token-economics harness into the repo - #449

Merged
justrach merged 1 commit into
release/0.0.242from
chore/eval-live-ab-harness
Aug 6, 2026
Merged

chore(eval): promote the live A/B token-economics harness into the repo#449
justrach merged 1 commit into
release/0.0.242from
chore/eval-live-ab-harness

Conversation

@justrach

@justrach justrach commented Aug 6, 2026

Copy link
Copy Markdown
Owner

The instrument behind the recent token-economics findings (the +240 tok/call system-prompt delta, and the three-cap-stack observation that motivated #440) lived only in a session scratchpad. Every number it produced became unreproducible the moment that session ended. This makes it durable.

The harness moves to scripts/eval/live-ab/ largely intact, with the changes needed to survive a clone:

  • Binaries are configurable. GRAFF_EVAL_BEFORE / GRAFF_EVAL_AFTER replace hardcoded worktree paths, resolved lazily so running a single arm needs only that arm's variable, and failing with an actionable message rather than a traceback.
  • Model and timeout are overridable (GRAFF_EVAL_MODEL, GRAFF_EVAL_TIMEOUT), with one model per invocation so the two arms cannot silently diverge.
  • The MCP-off invariant moved into code. one_run now writes .harness/settings.json into each run copy instead of relying on a committed dotfile. Disabling the companion MCP server is a measurement invariant, since its schemas move the input-token number, and the repo .gitignore excludes .harness/, so a shipped copy would not have survived a clone at all. This was caught by the staging step, not assumed.
  • Run residue stripped. .git, __pycache__ and .pytest_cache are gone from the fixtures; runs/ and results.json are ignored as outputs, not instrument.

RESULTS-2026-08-05-prime-batch.md is kept verbatim as the measured baseline the findings came from, and README.md documents the four conditions that have to hold for a comparison to mean anything (same model, both ReleaseSafe, companion MCP off, fresh fixture per run) plus how to read the reports without overclaiming at n=3.

Verified: all three Python entry points byte-compile; the unset-environment path produces the intended message rather than a traceback; the fixture's single-FAILED-line invariant still holds (line 1036 of 1151).

Not verified: no live A/B was re-run against this copy, since that costs model spend. The next change that needs a number is the natural place to exercise it end to end.

The instrument that produced the +240 tok/call prompt-delta finding and the
three-cap-stack finding lived only in a session scratchpad, which made every
number it produced unreproducible the moment that session ended. It moves to
scripts/eval/live-ab/ largely intact, with the changes needed to survive a
clone:

- the two arms' binaries come from GRAFF_EVAL_BEFORE / GRAFF_EVAL_AFTER
  instead of hardcoded worktree paths, resolved lazily so running a single
  arm needs only that arm's variable, and failing with an actionable message
  rather than a traceback;
- model and timeout are overridable (GRAFF_EVAL_MODEL, GRAFF_EVAL_TIMEOUT),
  with one model per invocation so the two arms cannot silently diverge;
- one_run now WRITES .harness/settings.json into each run copy rather than
  relying on a committed dotfile. Disabling the companion MCP server is a
  measurement invariant (its schemas move the input-token number), and the
  repo .gitignore excludes .harness/, so a shipped copy would not have
  survived a clone at all;
- run residue (.git, __pycache__, .pytest_cache) is stripped from the
  fixtures, and runs/ + results.json are ignored as outputs.

RESULTS-2026-08-05-prime-batch.md is kept verbatim as the measured baseline
those findings came from.

Co-Authored-By: Codegraff <blackfloofie@codegraff.com>
@justrach
justrach changed the base branch from main to release/0.0.242 August 6, 2026 12:31
@justrach
justrach merged commit 28e3627 into release/0.0.242 Aug 6, 2026
6 checks passed
@justrach
justrach deleted the chore/eval-live-ab-harness branch August 6, 2026 12:32
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