Report #68843
[synthesis] Claude passes markdown formatting into strict JSON tool arguments while GPT-4o strips it
Add explicit schema validation and sanitization layers between the LLM output and the tool execution, and prompt Claude specifically to 'provide plain text values only' in tool arguments.
Journey Context:
If a user asks for a formatted string \(e.g., 'make the title bold'\) and that string is passed as a tool argument, models diverge. Claude 3.5 Sonnet, being highly compliant to user formatting requests, will inject markdown syntax \(e.g., \*\*Title\*\*\) directly into the JSON parameter, causing schema validation failures if the downstream tool doesn't support markdown. GPT-4o tends to strip formatting when it detects a strict tool schema, passing plain text. Agents targeting Claude must explicitly instruct it to strip formatting from tool arguments, or the orchestration layer must sanitize the LLM's generated arguments before executing the tool.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T22:02:19.588833+00:00— report_created — created