Skip to content

feat(evals): weekly capped evals, golden cases as data, a local viewer - #11

Open
Prashant-Surya wants to merge 9 commits into
mainfrom
feat/harness-improvements
Open

Prashant-Surya wants to merge 9 commits into
mainfrom
feat/harness-improvements

Conversation

@Prashant-Surya

@Prashant-Surya Prashant-Surya commented Nov 26, 2026 •

Copy link
Copy Markdown
Member

What

  • Was: the golden hundred ran nightly at the deployment's default budget (up to ~$200 a night), the cases lived in ~1,000 lines of Python, and browsing datasets and reports meant reading JSONL by hand. The frame-browser image failed to build because Debian dropped the pinned Chromium build.
  • Now: evals run weekly on a capped sample and skip an unchanged tree; golden cases are one JSON line each in golden.jsonl; just evals-view opens a local read-only page over datasets, reports and golden cases; Chromium is pinned to today's bookworm-security build.
  • Golden takes --sample N --seed S and --budget USD; a task parked on its budget is cancelled and reported "over budget" instead of timing out after 15 min.
  • Weekly run: Mondays, 20 golden cases at $0.50 each plus 15 trivial50 rows (~$25 at most); skipped when the prompts, skills, model catalog seed, eval cases, uv.lock and the workflow are unchanged since the last green run. A manual dispatch never skips and can run all 104.
  • A PR that changes prismoid/ai or skills decides a seeded sample of 50 outcome rows in process (advisory).
  • Fix: both workflows now hand the key to the worker as PRISMOID_WORKER_ANTHROPIC_API_KEY (and PRISMOID_WORKER_OPENAI_API_KEY). The worker never reads the bare name, so every CI case failed in seconds at $0. main's nightly has the same bug. The secret names are unchanged.
  • Every golden case states its deliverable (document, spreadsheet, code, deck, collection; the browser rows leave it to the Lead), so a short ask publishes a file to verify, not a chat reply.
  • Golden gates on a floor (FLOOR, 0.5) and, given the last green run's report, fails when more than 2 more of the shared cases fail than did then. It no longer gates on a fixed 90%.
  • The weekly run checks the key with Anthropic before it brings up the stack, and prints the worker's errors when a case fails. A case that delivered nothing now gives a reason: the escalation's diagnosis, or "answered in a reply".

Where to look

  1. 🔴 backend/evals/run.py - --budget, golden --sample, the over-budget cancel
  2. 🔴 .github/workflows/evals.yml - weekly cadence, fingerprint, skip, previous-report carry
  3. 🟡 backend/evals/cases/golden.py - the loader and its rules
  4. 🟡 .github/workflows/evals-pr.yml - the PR routing sample
  5. 🟡 backend/tools/evals_view.py - the local viewer (not shipped)
  6. 🟡 backend/prismoid/ai/frames/image_browser/Dockerfile - the Chromium pin
  7. ⚪ backend/evals/cases/golden.jsonl - the cases, moved verbatim (a test pins equality)
  8. ⚪ docs/adr/, STATE.md, READMEs, ci.yml comment - cadence wording

Watch out for: uv.lock in the fingerprint means dependency bumps trigger a run. A run that loses 2 cases still passes and becomes the next baseline, so the floor is what stops a slow slide.

Blast Radius

  • Weekly evals (CI) - fingerprint, skip, the previous report download and the summary diff
  • PR routing evals (CI) - runs on this PR, since it adds the workflow file
  • python -m evals.run --suite golden (local) - same cases, new flags optional
  • Dataset suites' --budget default (1 USD) - unchanged
  • Frame-browser image build (worker) - the new Chromium pin
  • just evals-view (local) - only the person who runs it

Proof

Important

Confidence: Medium - the Python is unit-tested, just check is green, and the key fix is reproduced locally; the weekly workflow has not yet run green end to end

  • Ran: just check (backend suite, import contracts, quality, web); tests pin golden.jsonl == the old cases, bad-row errors, the seeded sample, the budget payload and the over-budget cancel against a scripted API; the viewer in a browser; Debian's bookworm-security index lists chromium 156.0.8078.108-1~deb12u1.
  • Local stack, the weekly sample with the dial (--sample 20 --seed 1 --budget 0.5): 11/20 pass (55%), $1.40 in all, $0.09 at most per case. Of the 9 failures, 5 are the verifier failing correct work (units, citation labels, the sign of a gap), 2 are collections published with empty rows, 1 is a spreadsheet total, and 1 is a small rounding error.
  • Local stack, the CI sample before the dial (--sample 5 --seed 1 --budget 0.5, ~$0.40 total): 3 cases answered in a reply, 2 published and failed verification (organize-metrics-gallery missing figures, model-pnl cross-foot). No case came near the $0.50 cap. Starting the worker with only the bare ANTHROPIC_API_KEY reproduced CI's 3-attempts-at-$0 failure exactly.
  • Try it: Actions → Weekly evals → Run workflow on this branch with cases = 5; just evals-view locally.
  • Not verified: the weekly workflow end to end with the key fix; a real task hitting its $0.50 cap; the frame-browser image build (nightly integration-frames.yml).

Rollout

  • Needs ANTHROPIC_API_KEY (and optionally OPENAI_API_KEY for the cross-family judge) as repo secrets; without them the weekly run fails fast and spends nothing, and the PR job reports "not run".
  • The weekly schedule starts once this is on main.

Media

N/A

Links

  • Issue: None
  • Decision record / design: docs/adr/008-continuous-operation.md (amended), docs/adr/052-the-problem-book.md
  • Stack / follow-ups: fix the grounding:claims false failures (units, citation labels, gap sign); collections published with empty rows; raise FLOOR as those land
  • Author notes: written with Claude Code

🤖 Generated with Claude Code

…olden cases

`just evals-view` serves one page on 127.0.0.1 over backend/evals: the JSONL datasets
(filter by outcome, category, group, variant, check type; a row's full definition in a
side panel), the saved run reports (results per row across trials, infra errors, rows
not run, a baseline beside them) and the golden cases.

Standard library only, so no new dependency. It never writes a file and computes no
score: the numbers and the broke/fixed rows against a baseline come from running
`python -m evals.report`, and the golden tab imports evals.cases.golden. Dataset text
is rendered with textContent only, since rows hold adversarial asks.
…1~deb12u1

Debian dropped 156.0.8078.79-1~deb12u1 from bookworm-security when the
.108 security build replaced it, so the frame-browser apt step failed.
The nightly ran the whole golden hundred at the deployment's default budget
and mostly re-measured an unchanged tree. Now:

- golden cases move from code to evals/cases/golden.jsonl; golden.py loads
  them and rejects a bad row by file and line
- --sample/--seed draw a seeded golden sample; --budget caps each golden
  task, and a task parked on its budget is cancelled and reported
  "over budget" instead of timing out
- evals.yml runs Mondays on 20 golden cases at 0.50 USD and 15 trivial50
  rows, skipping when the prompts, skills, model catalog seed, eval cases,
  lockfile and the workflow are unchanged since the last green run; a
  manual dispatch never skips and can run the whole hundred
- evals-pr.yml decides a sample of 50 outcome rows on a PR that changes
  prismoid/ai or skills (advisory)
- ADR-008 amended; ADR-052, STATE.md and the eval READMEs follow
@Prashant-Surya Prashant-Surya changed the title feat(evals): a local eval viewer, plus the browser frame's Chromium pin bump feat(evals): weekly capped evals, golden cases as data, a local viewer Nov 27, 2026
The worker reads PRISMOID_WORKER_ANTHROPIC_API_KEY, never the bare
ANTHROPIC_API_KEY the workflows set, so every eval task ran keyless and
failed in seconds at no cost. Both workflows now pass the secret under the
worker's prefix. The catalog-models check is removed: it rested on a wrong
guess and flagged an alias the provider serves only by its dated id. A golden
case that was answered in a reply now says so.
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