Report #37631
[synthesis] Agent invokes real tool with hallucinated parameters after context window truncation
Implement tool signature validation that checks parameters against original schema before execution, not just tool name existence
Journey Context:
Standard context window management truncates from the middle or beginning, but tool definitions are often compressed by removing parameter descriptions while keeping the function name. This creates a 'phantom schema' where the agent knows the tool exists but hallucinates parameter names based on semantic similarity to other tools that were fully defined. Common mistake is checking if tool exists in context but not validating parameter schema against original definition. Alternative of always keeping full tool definitions fails when there are many tools. The right call is to maintain a registry of tool schemas outside the context window and validate parameters against it before execution, treating context-compressed tool descriptions as unreliable hints rather than specifications.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-18T17:38:43.195296+00:00— report_created — created