One pass of my board eval bills $9.14 on the Anthropic API. Through Claude Code it bills $0. Same model, claude-opus-4-8.
That is 27 calls, and it is not an estimate. The CLI prints a total_cost_usd in its envelope: what the run would have cost on the API. It bills the subscription instead, so the number is a receipt for money nobody spent.
The switch fixed something better than the bill
Running with --output-format json and --json-schema rides the same structured-output machinery the API does, an internal forced tool call. Before that, my runner parsed the model's free-text reply, and the suite showed what that costs.
The suite is 15 fixed briefs for a board generator, each built around one trap: opposing undertones, an absolute no, a colorblind partner, a couple who gave almost no signal. On the free-text path, 7 of the 15 came back as a usable board. Pulling the longest JSON span out of the reply raised that to 10. With --json-schema, 12 of 15 came back and none failed in transport; the $9.14 pass above is that run. It took 27 calls for 15 briefs because a board the quality guard rejects is generated again, so a hard brief costs more than one call. The three it still missed were refused by the generator's own schema and quality guards, and my report counts those two together, so I cannot tell you all three were content and none was format.
The schema needs relaxing first: strip pattern, minLength, maxLength, minItems, maxItems, format and the $schema meta-ref, because the CLI validator rejects draft-2020-12. The strict version stays in Zod on the caller side, so nothing is actually loosened, the validation just moves to where it can run.
One trap is worth the whole post
If ANTHROPIC_API_KEY sits in the child process environment, the CLI quietly bills the API account rather than the subscription. Nothing errors. Nothing warns. The invoice arrives. It gets stripped explicitly at spawn.
This is the failure mode I would look for first in anyone else's runner: the money leak is silent, and the only symptom is a bill at the end of the month for a run you believed was free.
And the limit, which matters more than the savings
This is a dev-loop tool. Anthropic's consumer terms prohibit automated access "except when you are accessing our Services via an Anthropic API Key or where we otherwise explicitly permit it", and the commercial terms governing API use do not cover consumer subscriptions. An eval runner on my own machine is the CLI used as designed. A shipped service is not.
Iterate on the CLI, ship on the API, and read the total_cost_usd of every pass: it is the one place the CLI tells you what the same run would cost in production.
The same habit, a pass measured with its misses written down, runs through the rest of my work: the evals of fintech-roast keep their misses in the repo, and a detector I calibrated to a perfect recall shows what that number hid.
Originally published at dylan.merigaud.com.
Top comments (0)