Report #92584
[synthesis] Tool call responses contain unexpected extra JSON properties
For Claude and Gemini, append 'Only include properties defined in the schema. Do not add any extra properties.' to the tool description. For OpenAI, use strict: true and additionalProperties: false in the schema.
Journey Context:
OpenAI's structured outputs enforce schema constraints at the engine level \(rejecting extra keys\). Claude 3.5 Sonnet treats the JSON schema as a suggestion and will occasionally add helpful, unrequested keys if it thinks they fit the user's intent, leading to downstream Pydantic/validation errors. Cross-model schemas require both the OpenAI engine-level flag and the Claude prompt-level instruction to guarantee stability.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T13:59:29.415245+00:00— report_created — created