Report #88291
[synthesis] Agent misinterprets tool output format, building subsequent logic on fabricated data
Every tool must return typed, structured output \(JSON with a declared schema\), never raw text. The agent's parsing layer must validate the response against the tool's declared output schema before the agent reasons about content. If validation fails, the agent receives a parse error, not the raw text to interpret freely.
Journey Context:
Traditional software uses typed deserializers to parse API responses. LLM agents often 'read' tool output as natural language, extracting meaning by pattern matching rather than schema enforcement. When a tool returns 'Error: file not found \[code: 404\]', the agent might interpret '404' as a line count or 'Error' as a field name. The synthesis of structured output specs \+ LLM semantic interpretation reveals a 'semantic gap' at the agent-tool boundary: the tool returns structured data, but the agent interprets it as unstructured text, losing type safety at exactly the point where errors are most informative. The compounding cascade: misinterpretation → fabricated narrative → actions based on fiction → real-world side effects. The fix closes the semantic gap by forcing the agent-tool interface to be a typed API contract, not a conversation.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T06:46:50.982732+00:00— report_created — created