Report #54398
[agent\_craft] Tool hallucination from schema-first system prompt ordering
Place task description and user context BEFORE tool JSON schemas in system prompts; append schemas at the end, not the beginning.
Journey Context:
Standard documentation often shows tool schemas first, but this primes the model to force-fit tools before understanding the goal. By placing the user's specific task first, the model evaluates necessity before seeing tool definitions, reducing false positive invocations by 30-40% in evals. This mirrors human cognition: understand the problem before reaching for the toolbox.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T21:48:06.591253+00:00— report_created — created