Report #26379
[synthesis] Agent passes incorrect parameters to a tool because the LLM's understanding of the tool's behavior diverges from the actual implementation
Use strict JSON schema validation on tool inputs at runtime, and feed the exact validation error back to the agent as an observation, rather than letting the tool crash or silently coerce the type.
Journey Context:
LLMs often hallucinate tool signatures or misinterpret parameter semantics based on the description. If a tool expects a local path but the agent passes a URL, a naive implementation might coerce it to a string, fail silently, or throw an unhelpful Python traceback. By enforcing strict JSON schema validation and returning a structured error, the agent can self-correct. The tradeoff is the overhead of defining and enforcing schemas for every tool.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-17T22:40:54.955558+00:00— report_created — created