Skip to content

Add Claude Sonnet 5 as a built-in juror #11

Description

@cderinbogaz

Contribution type

Model integration using an existing harness. Follow the model/preset contributor guide introduced in #58.

Exact model id and version

claude-sonnet-5. Confirm Anthropic's exact request id and whether an immutable revision is available at implementation time; do not substitute a moving alias without documenting it.

Serving provider and route

Anthropic through the existing claude-code harness. src/cost/pricing.json already contains a dated claude-sonnet-5 row, but the built-in catalog currently has no model that uses it.

Existing harness

claude-code, using the same measured invocation and parser contract as claude-opus-5.

Authentication shape

Juror reads JUROR_ANTHROPIC_API_KEY (with the documented legacy fallback) and passes it to Claude Code as ANTHROPIC_API_KEY only inside the isolated harness invocation. No credential value belongs in config, argv, fixtures, logs, or this issue.

Pricing evidence

  • Source: https://www.anthropic.com/pricing#api
  • Checked-in rates: $3 input / $0.30 cache read / $3.75 cache write / $15 output per million tokens
  • Checked-in context window: 1,000,000 tokens
  • Evidence date currently recorded in src/cost/pricing.json: 2026-08-06

Recheck the source and date when implementing. Preserve unknown behavior if Claude output omits both reported USD and usable token data.

Preset placement and value

Add a BUILTIN_MODELS entry modeled on claude-opus-5 and place the id in at least one PRESET_DEFINITIONS[*].modelIds list. A built-in in no preset is dead configuration and now fails the generated compatibility check. Explain the selected preset in terms of Anthropic-only affordability, model-family/provider diversity, and incremental review cost; update its consensus/referee choice only if evidence supports that change.

Reproducible fixtures

Use synthetic/redacted Claude Code JSON fixtures for:

  • successful claude-sonnet-5 identity and reported total_cost_usd;
  • missing/unavailable model;
  • authentication failure;
  • malformed or missing usage/cost; and
  • timeout/partial output where existing Claude fixtures do not already cover the shape.

No paid credential is required for the deterministic test suite.

Security and failure behavior

Reuse Claude Code's private runtime, --bare startup isolation, read/search-only tool list, sealed checkout, per-invocation credential allowlist, and cleanup. A missing key, missing executable, or unavailable Sonnet route must produce an explicit skipped/failed receipt row. If fewer than two model families finish, the summary must say cross-model consensus is unavailable.

Acceptance checklist

  • Add the built-in entry and reachable preset membership.
  • Recheck and retain dated official pricing evidence.
  • Add/update config membership, auth readiness, cost, failure, and receipt tests.
  • Add redacted parser fixtures if Sonnet produces a distinct output shape.
  • Run npm run docs:compatibility and inspect model id, route, secret, preset, cost mode, and pricing source.
  • Run the full validation sequence from CONTRIBUTING.md.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestgood first issueGood for newcomersharnessModel harnesses and adding jurors

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions