eval
Measure how a skill, prompt, system-prompt, or agent-file change affects agent behavior before promoting it: blinded candidates on an organic task, a hidden rubric, one blinded judge, and a check of each candidate's transcript. Use for 'eval this change', or before merging a change whose only test is how agents behave.
- License 许可
- MIT
- 最近更新
- 2026-11-03
- Stars
- ★ 10
- Forks
- 2
01 前言 Front Matter
- name
- eval
- description
- Measure how a skill, prompt, system-prompt, or agent-file change affects agent behavior before promoting it: blinded candidates on an organic task, a hidden rubric, one blinded judge, and a check of each candidate's transcript. Use for 'eval this change', or before merging a change whose only test is how agents behave.
- user-invokable
- true
- disable-model-invocation
- false
03 SKILL.md 正文
Eval
You own the experiment design. Plan, blind, run, synthesize. Keep the run in the state folder under a project-shaped slug, never one of the words the blinding list bans, since a candidate can read its own session path. Keep its decision log there per the show-me-your-work skill.
Non-negotiables for blinding:
- No
eval,test,judge,experiment,rubric,score,compare,benchmark,candidate, orarenain any directory, file, or prompt the candidate sees. - The candidate prompt looks like an organic user request. State the goal, not the meta.
- No chain-eliciting cues. Don't ask the candidate to list which skills, principles, or files they applied. Ask for design notes generally and grade chain-following from code shape, not self-report.
- Sanitize directory and slug names. Use project-shaped names a user might pick.
- Don't tell the candidate other candidates exist.
- The judge can know it's judging but sees outputs by sanitized label only, never by model name.
- Comparing two variants: one judge scores both sets in a single pass on one scale, blind to which set each came from.
Steps:
- Frame. State what variant is under test and what behavior counts as success. Write the rubric (3-6 concrete criteria) for the judge only. Hold it back from candidates. Name the baseline arm: the change's base commit.
- Set up the arms. Each arm is a worktree of the repository at that arm's commit, with its install run, so the variant is the only difference. For a change to this Pi setup, a candidate runs with
PI_CODING_AGENT_DIR=<arm worktree>/agent, which loads that arm'sSYSTEM.md, skills, prompts, and extensions. That directory has no credentials, so first refresh each OAuth token in the live directory for longer than the run will take,pi auth print-bearer-token --provider <provider> --min-expiry <run length>for eachoauthentry in~/.pi/agent/auth.json, theninstall -m 600the liveauth.jsoninto each arm'sagent/. A token that refreshes inside a copy rotates the live one and logs the live session out. Delete each copy when the run ends. - Set up sanitized environments. Per-candidate working dir, each its own copy of one seed. Plant any context an organic task would have: a project skeleton, the skills the candidate would naturally read.
- Author one organic prompt. What a user would type. No leakage of what's being measured.
- Run the candidates. Same prompt to each, each in its own sanitized dir, as a plain Pi session through
bg_start:PI_CODING_AGENT_DIR=<arm>/agent pi --print --model <model> --thinking high --session-dir <run folder>/sessions/<label> "<prompt>". Api-subagentlaunch appends text that tells the candidate it works for another agent, so use it only when the variant under test is subagent behavior. Run every candidate on one model, the one the variant will run on in practice, so the arms differ only in the variant. Run at least three candidates per arm, interleaving the arms, because one run per arm cannot separate the variant from run-to-run variation. - Spawn one blinded judge on the other model family per the arena skill's Phase C. Judge sees outputs by sanitized label and the rubric, never a model name.
- Verify the chain from transcripts, not self-report. Read each candidate's session file under its
--session-dir, and only those. List what it actually did withjq -r 'select(.type=="message" and .message.role=="assistant") | .message.content[]? | select(.type=="toolCall") | "\(.name)\t\(.arguments.path // .arguments.command // .arguments.code | tostring | .[0:200])"' <session>.jsonl, and read the codemode and bash entries for the files they opened. Grade chain-following from the files it really read plus the shape of the code, never from the candidate's own claims. - Read every candidate output yourself end to end. Compare to the judge's verdict. Disagreement means a model is biased or the rubric is ambiguous. Synthesize. A variant that does not beat the baseline arm is not promoted, since an unmeasured neutral change still costs every later reader (the principle-laziness-protocol skill).
- Close the decision log per the show-me-your-work skill.
Reply: variant under test, rubric, per-candidate notes, judge's verdict, your synthesis, a recommendation for whether to promote the variant, and the Attention section.
04 同仓库更多 Skills
changelog
Write the changelog entry for a pull request. Use when a PR changes behavior that users, operators, or integrators can notice.
writing-good-tickets
Write, file, or update an issue or ticket that an agent or a developer can take to one PR. Use when filing a bug or feature, updating an issue, or breaking a plan into tickets.
writing-good-prs
Write or update a pull request title and body that a reviewer can trust and own. Use when opening a PR or editing its description.
writing-good-commits
Write or reword a git commit message and size the commit it describes. Use when committing, or when reshaping commits during a rebase.
writing-for-agents
Writing documents for agents. Use when creating or editing skills, or modifying AGENTS.md or CLAUDE.md.
wizard
Generate an interactive bash wizard that walks a human through steps only they can perform. Use when provisioning infrastructure, setting up credentials or CI secrets, walking an unfamiliar third-party dashboard, or running a one-off migration or cutover. Don't invoke this for steps the agent can perform itself.