Skip to content

0011. Claude API with structured outputs and a claim validator

Source: docs/decisions/0011-claude-structured-outputs.md. Generated at build time; edit the source file.

Date: 2026-11-21 Status: Accepted

AI chess coaching is notorious for invented moves and facts.

claude-sonnet-5-5 for reports, claude-haiku-5-5 for short explanations, and the Batch API for scheduled regenerations. Structured outputs via output_config.format. Every claim cites a game and ply, and a validator checks citations, moves and numbers against stored data. On failure, regenerate once, then drop the bad item.

Free-form text; forced tool calls (rejected on Sonnet 5.5).

Reports are trustworthy and testable, at the cost of slightly higher latency.

See docs/superpowers/specs/2026-11-21-chess-improver-design.md.