Evals
How Shipyard evals work: cases, trials, the LLM judge, pass-rate intervals and flaky results, and what they cost.
An eval checks that a real model, given a user prompt and your server, calls the right tool and gives a correct answer. It catches regressions that fixtures cannot, such as a description edit that makes a model skip your tool.
Cases
A case has an id, a prompt and expectTools. An empty expectTools means the model should call no tool (a negative case). Optional fields: expectFacts (strings the answer must contain) and forbid (strings it must not contain).
{
"id": "goalie-save-pct",
"prompt": "What was the starting goalie's save percentage in last night's Bruins game?",
"expectTools": ["get_game_detail"],
"expectFacts": [".925"],
"forbid": ["I cannot access"]
}
shipyard eval <url> --draft drafts cases from your tool list: positive cases a real user would type and negative cases. Draft names must match real tools. Edit them and pass the file with --cases.
Trials
Models cannot be seeded, so one run is noise. Each case runs 3 times per provider by default (--trials). The report shows passes out of trials, the pass rate and a 95% Wilson interval, for example 2 of 3 with an interval of roughly 21% to 94%. A small number of trials gives a wide interval. Do not read a single result as a fact.
A case is flaky when it passed in some trials and failed in others. Flaky is different from broken: a broken case fails every time. Flaky cases usually mean an ambiguous description or a prompt with two valid answers. Fix those first.
Grading
- Right tool: every tool in
expectToolswas called, or no tool was called if the list is empty. A wrong tool fails the trial. - Facts: a case passes the fast path if all
expectFactsappear in the answer (case-insensitive) and noforbidstring does. Aforbidhit always fails. - Judge: when the right tool was called but facts are missing, or the case lists no facts, an LLM judge (Claude Haiku 5.5) grades the answer. It matches by meaning, so ".925" equals "0.925", and it fails answers that refuse, contradict themselves or say they made things up. The answer is passed as data, and the judge is told to ignore instructions inside it. If the judge call fails, the substring result stands.
Each trial records whether it was graded by substring or judge, with the judge's one-line reason. Use --no-judge for substring checks only.
Cost
Every trial is a real model call, and judge calls are billed too. --max-cost (default 0.5 USD per run) is a ceiling. Trials after the ceiling are marked skipped and are not counted in pass rates. Evals need ANTHROPIC_API_KEY and/or OPENAI_API_KEY.
In Monitor, evals run daily and alert when a model's pass rate falls 15 points or more against the last run. See also selection gate and Grow.