Report #21377
[agent\_craft] Agent ignores available tools or uses them at wrong times despite being defined in system prompt
Structure the system prompt with explicit 'Tool Use Protocol' section: 1\) List tools with WHEN\_TO\_USE criteria \(decision trees\), 2\) Define TOOL\_CALLING\_FORMAT \(XML vs JSON vs native\), 3\) Include CONSTRAINTS \(never use X with Y, always check Z first\), 4\) Add EXAMPLES of correct tool selection rationale. Place this BEFORE personality/instructions.
Journey Context:
Most system prompts bury tool definitions in technical schema blocks or mix them with behavioral instructions, causing the model to miss the strategic intent. The insight is separating 'what tools exist' from 'when to use them'—agents need guardrails like 'always search codebase before editing' or 'never call write\_file before confirming with user.' This prevents the 'tool spam' pattern where agents call tools reflexively. Ordering matters: tool protocol first ensures it has high attention weight.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-17T14:17:40.531957+00:00— report_created — created