Skip to content

bench: answer keys and outcome scorer for four rival rows - #1966

Closed
remigiusz-antczak wants to merge 1 commit into
mainfrom
feat/bench-answer-keys
Closed

remigiusz-antczak wants to merge 1 commit into
mainfrom
feat/bench-answer-keys

Conversation

@remigiusz-antczak

Copy link
Copy Markdown
Collaborator

Adds answer keys and a deterministic hit-rate scorer for four rival-bench rows (business-ops, growth-analytics, idea-critic, contribution). These rows can then be scored on outcomes instead of judge preference.

  • 40 scenarios keyed, 10 per row. Each has must-hit items (named risk, correct figure, required gate) and must-not items (leaks in a drafted message, unsafe commands).
  • rival_eval.py keys scores each arm's outputs. It reports per-scenario hits, the must-not violations, and no_draft where no drafted message was found. It fails if an arm directory is missing.

Fairness guards, after the independent review:

  • Keys use concept-level wording, not Perun's own verdict vocabulary.
  • Numbers accept the figures the scenario states, in k and percent forms.
  • Keys that only checked for words echoed from the prompt are replaced with outcomes the answer must add.
  • Must-not checks scan only the drafted message and skip negated advice ("never run git push --force").
  • Tests pin these guards:
    • each scenario's own prompt text scores at most 0.25, against a <0.5 bar;
    • a plain-words answer scores the same as one in Perun's vocabulary;
    • paraphrase and negation cases.

Not yet done: calibrating the keys against real arm outputs (no cached outputs match the current ids). The first paid run should spot-check keys before any row verdict counts.

Tests: 61/61 (answer keys 14, rival_eval 47), run on the commit's own tree. Independent review: 0🔴; the 8🟡 and 1🔵 are fixed here.

🤖 Generated with Claude Code

https://claude.ai/code/session_014QNFFPWVcPUbeuvwM5fk2Z

…rows

Add keys.json (3-6 must-hit and 1-3 must-not regex items per scenario) for the 40 held-out scenarios of business-ops, growth-analytics, idea-critic and contribution. Keys test what an answer adds beyond its prompt (echo baseline max 0.25), accept number forms and paraphrases, and carry no Perun verdict tokens.

rival_eval.py gains key_score (per-arm hit rate and violation rate, no judge), an answer_key block in results.json, a keys subcommand that rescores cached outputs offline and fails on a missing arm directory, and key hygiene in check. Must-nots are negation-aware and skip placeholders; contribution leak and force-push checks scan only the drafted message, and a missing draft is flagged no_draft. No paid call.

Tests: 61/61 (test_rival_answer_keys 14, test_rival_eval 47)

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014QNFFPWVcPUbeuvwM5fk2Z
@remigiusz-antczak

Copy link
Copy Markdown
Collaborator Author

Superseded by #1983.

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