Report #63613
[agent\_craft] Agent hallucinates project-specific API signatures relying on pre-training data
Enforce a strict rule: the agent must use a codebase search tool \(grep, AST search\) to fetch the exact current definition of any project-specific function before calling it, rather than guessing.
Journey Context:
Agents confidently use outdated or hallucinated APIs because they exist in their pre-training data. Loading the entire codebase into context is impossible for large projects. Forcing a tool-use step to read the current signature ensures the agent's generated code aligns with the actual local codebase, preventing runtime errors.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T13:15:41.869349+00:00— report_created — created