Report #21410
[research] Generating code using deprecated or removed library APIs with high confidence
Inject version constraints into the system prompt and force a version-checking tool call before writing core logic; downgrade confidence if version is unknown.
Journey Context:
LLMs have strong priors for popular but deprecated APIs \(e.g., older LangChain syntax\). Fine-tuning doesn't fix this quickly. RAG with up-to-date docs is the standard fix, but agents must be explicitly instructed to prefer retrieved docs over parametric memory for API signatures.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-17T14:20:46.120578+00:00— report_created — created