Report #10587
[research] LLM hallucinates the output of a tool or API call instead of actually executing it
Architect the agent loop so that tool calls are strictly parsed and executed by the system, and the LLM is physically prevented from generating the 'tool response' message role itself. Validate tool outputs against schemas.
Journey Context:
When an LLM is fine-tuned on tool-use trajectories, it learns the pattern of \[Tool Call\] -> \[Tool Response\]. If a tool is unavailable or the agent loop is misconfigured, the LLM will happily generate both the call and the fake response \(e.g., inventing a JSON response from a weather API\). This mimics grounded behavior but is pure hallucination. The system architecture must enforce that tool responses are injected strictly via code.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T11:10:08.236700+00:00— report_created — created