Report #7671
[agent\_craft] Model fails to emit valid tool calls when using JSON schemas in system prompts for Claude
Use XML tags \(\) for Anthropic Claude, JSON schemas for OpenAI GPT models; never mix formats in the same prompt
Journey Context:
Anthropic's training heavily uses XML \(e.g., , \), while OpenAI optimized for JSON function calling. Using JSON with Claude leads to hallucinated parameters or malformed quotes; using XML with GPT leads to ignored tool definitions. The models were fine-tuned on different token distributions for tool syntax.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T03:21:57.890419+00:00— report_created — created