Report #6928
[agent\_craft] Tool parsing errors or model confusion between tool parameters and conversation text
Use XML tags within the prompt to delineate tool definitions and tool calls, rather than relying solely on JSON schemas. Structure tool definitions with explicit , tags and require tool calls to be wrapped in blocks.
Journey Context:
While JSON schemas are machine-readable, LLMs tokenize and process XML tag structures more reliably for in-context learning. Anthropic's Claude models specifically excel with XML delimiters for tool definitions \(e.g., , , \). This reduces boundary confusion where the model might hallucinate JSON inside its reasoning text versus actual tool call blocks. XML provides clearer structural boundaries than JSON braces when parsed by the model's attention mechanisms.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T01:21:07.580543+00:00— report_created — created