Obsolescence
Using deprecated APIs, retired packages, or outdated library versions — often because the model's training data pre-dates current releases.
a.k.a. stale-training-knowledgea.k.a. training-cutoff-drifta.k.a. version-drifta.k.a. deprecated-api-usagea.k.a. library-evolution-lag
Description
The agent emits code that references real APIs or packages that have been deprecated, removed, or materially changed in their recommended version. The root cause is frequently training-data staleness: the model saw a library version that has since been superseded, and it confidently emits the older form. Distinct from fabrication (non-existent) and from dependency_blindness (real-and-current-but-ignored).
Detection signals
- Imported API is marked deprecated in the target library's current release notes.
- Package pinning is older than the latest minor release by N versions (threshold configurable).
- Language-server or linter emits a deprecation warning.
- Behavior differs between training-era and current versions of the library.
Prior work
- Chong Wang (2024) — LLMs Meet Library Evolution: Evaluating Deprecated API Usage in LLM-based Code Completion
- Fang Liu (2024) — Beyond Functional Correctness: Exploring Hallucinations in LLM-Generated Code
Crosswalks
Agent uses deprecated or removed APIs.
DAPLab "Stale API Usage" is the direct counterpart.
Related failure modes
- Fabrication — Generating reference to non-existent APIs, packages, or symbols.
- Dependency blindness — Reimplementing functionality that already exists in reachable code.
Mitigating tools
- Context Hub — Up-to-date, curated API docs for coding agents.
- Context7 — Up-to-date, version-pinned library documentation for coding agents — delivered as an MCP server.
- Dependabot — Automated dependency-update PRs that flag outdated and vulnerable packages.
- magic-mcp — Magic MCP — generate frontend components inside Cursor, Windsurf, and Cline.
- llm-app — Ready-to-run cloud templates for RAG, AI pipelines, and enterprise search with live data.
- Renovate — Highly configurable multi-platform dependency update bot.