Mar 22, 2026
AI Agents without Outdated APIs
AI coding assistants can automate your development work. They can write code, fix bugs, and explain complex topics. But these agents often use outdated APIs or make up parameters that do not exist. This happens because they learn from static training data that does not update. Stanford professor Andrew Ng's team launched Context Hub to solve this problem. It gives AI agents access to curated, up-to-date API documentation so they always work with current information.
What is Context Hub?
Context Hub is an open-source tool that provides AI coding agents with reliable API documentation. The project addresses a common problem called "agent drift." Agent drift happens when AI agents use outdated API parameters or hallucinate information that does not exist. This leads to broken code and wasted debugging time.
The tool includes a command-line interface called chub. Developers and AI agents can use chub to search for API documentation, fetch specific docs, and keep information up to date. The project was created by Andrew Ng's team and launched in March 2026. It is designed to work with popular AI coding assistants like Claude Code and Cursor.
Key Features
Curated Documentation Registry: Context Hub hosts versioned documentation from over 68 API providers. This includes major services like OpenAI, Stripe, AWS, and many others. Each document exists in multiple language variants like Python and JavaScript.
Skill Repository: Beyond simple documentation, Context Hub includes skills. Skills are behavioral instructions that teach agents how to handle coding patterns. This helps agents not just know APIs but understand how to use them correctly.
Local Annotation System: Agents can attach private notes to documentation they use. These notes persist across sessions. The next time the agent works on a similar task, it sees those notes first. This solves the forgetting problem that many AI assistants face.
Community Feedback Loop: Users can vote on documentation quality using up and down votes. Good votes signal to authors that content is helpful. This feedback helps authors improve documentation for everyone over time.
MCP Server Integration: Context Hub includes a Model Context Protocol server called chub-mcp. This allows the tool to integrate with Claude Desktop, Cursor, and other AI assistants that support MCP.
How It Works
Context Hub stores documentation as markdown files with YAML frontmatter. Each document includes metadata like name, description, supported languages, and version information. When documentation is updated, the system creates a new version while keeping old versions available.
The build process converts markdown files into a registry.json file. This registry is then served via CDN. When you run chub update, the tool downloads the latest registry to your local cache at ~/.chub/.
You can merge remote CDN content with your own local documentation. This means companies can create private registries for internal APIs and skills. Your team gets the benefits of Context Hub while keeping sensitive information private.
Getting Started
- Install the CLI tool globally using npm:
npm install -g @aisuite/chub - Update your local registry:
chub update - Search for API documentation:
chub search openai - Fetch specific documentation:
chub get openai/chat --lang py - Add personal notes:
chub annotate stripe/api "Use this endpoint for subscriptions" - Send feedback to authors:
chub feedback stripe/api up
For AI assistants that support MCP, configure the chub-mcp server in your client settings. This gives the assistant direct access to all chub commands as tools.
Conclusion
Context Hub solves a real problem in AI-assisted development. When agents have access to current, curated documentation, they produce better code. The annotation system helps agents learn from past mistakes. The feedback loop means documentation improves over time as the community contributes.
The tool is open-source under the MIT license. You can find the project on GitHub at https://github.com/andrewyng/context-hub. Whether you are a developer using AI coding assistants or a team managing internal APIs, Context Hub can improve your workflow.
Give it a try today and see the results.