mirror of
https://github.com/fabro-sh/fabro.git
synced 2026-10-09 03:20:56 +00:00
`Claude5QuestionToolArgs`/`Claude5Question`/`Claude5Option` differed from the Anthropic trio only in required-ness -- `header: String` rather than `Option<String>`, same for each option's `description`. The JSON Schema already enforces that at the model boundary, so the lenient structs deserialize the strict payload unchanged. `normalize_claude5_questions` then reproduced `normalize_anthropic_questions` plus an inlined copy of `options_from_anthropic`, so `option_key`, `display_text`, and `bounded_display_field` were each applied in two places and could drift. Replace both with one normalizer taking a `QuestionLimits`. The genuine Claude 5 deltas -- at most four questions, two to four options, a twelve-character header cap, required header and option descriptions, and no previews on multi-select -- become data rather than a second code path. Two rules serde used to enforce are now the normalizer's: a missing header and a missing option description. Both are still rejected, with a clearer message than serde's "missing field". `multiSelect` now defaults to false instead of being a deserialization error; the schema still marks it required, which is where that contract belongs. Adds tests pinning the strict rules against the shared normalizer, and one asserting the lenient contract still accepts optional headers and descriptions. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| fabro-acp | ||
| fabro-agent | ||
| fabro-automation | ||
| fabro-checkpoint | ||
| fabro-dump | ||
| fabro-environment | ||
| fabro-github | ||
| fabro-graphviz | ||
| fabro-hooks | ||
| fabro-install | ||
| fabro-interview | ||
| fabro-llm | ||
| fabro-manifest | ||
| fabro-mcp | ||
| fabro-mcp-store | ||
| fabro-sandbox | ||
| fabro-slack | ||
| fabro-store | ||
| fabro-tool | ||
| fabro-tracker | ||
| fabro-validate | ||
| fabro-variable | ||
| fabro-workflow | ||