| name | library-docs |
| description | Use when a project depends on third-party libraries and the agent needs project-specific usage rules — and must check for an MCP server or current docs — before coding against a library it only half-remembers. |
library-docs
Overview
Not generic documentation — how THIS project uses each library, plus the rule to ground in current docs before writing code. Stops the agent from coding against an API it half-remembers from training data.
Lives at context/library-docs.md.
When to use
- When the project adopts a library.
- Before the agent writes code against any third-party tool.
The core rule
Before using any library: check if an MCP server is configured for it; if so, read the live schema/docs first. If not, fetch current docs. Only then write code. Training data goes stale; the live source doesn't.
What goes in it
Per library:
- How we use it here — the specific patterns this project relies on.
- Rules — dos/don'ts for this codebase.
- Examples — one real usage snippet.
- MCP / docs source — the MCP server name or doc URL to check first.
How to maintain
Add an entry when you adopt a library; update the example when usage changes.
Common mistakes
- Pasting generic docs → the agent already half-knows those. Capture the project-specific usage.
- Skipping the MCP/current-docs check → version drift bugs. Check the live source first.