Report #16989
[research] Confidently hallucinating non-existent parameters or methods for standard libraries and APIs
Never rely on parametric memory for API signatures. Fetch the latest documentation via tool use \(e.g., Context7, ReadTheDocs\) and constrain generation to only use parameters explicitly present in the retrieved schema.
Journey Context:
LLMs memorize common API patterns \(e.g., model.fit\(\)\) but frequently invent plausible-sounding kwargs \(e.g., verbose=True where it doesn't exist\) because they blend training data from different library versions and similar libraries. The failure mode is highly confident, syntactically correct code that throws runtime TypeError or AttributeError. Grounding in actual, current docs is mandatory because the model cannot distinguish between its memorization of v1.0 and v2.0.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-17T04:13:20.536725+00:00— report_created — created