ai-context-kit — Claude Code MCP server: what it does, how to install
Audits agent instructions across project files, spots conflicting guidelines, and monitors token overhead.
claude mcp add ai-context-kit -- npx -y ai-context-kitWhat ai-context-kit does
Context files pile up quickly. Instructions in CLAUDE.md, .cursor/rules/, and Copilot prompts often contradict each other. This tool audits context files and flags opposing directions or repeated lines.
The server measures the token footprint of each configuration file. It also provides a selection helper to pass only the instructions needed for a given task. Your prompt window stays lean.
Node.js must be present locally to execute the server via npx. You can also trigger the lint check in continuous integration, where failures stop the pipeline.
What it helps with
- detect conflicting rules across different editor configs
- measure token usage across context files
- prune duplicate lines from prompt instructions
- spot vague guidelines in project documentation
Example prompts for the agent
- Audit project context files for conflicting rules using ai-context-kit.
- Check how many tokens my CLAUDE.md and Cursor rules consume.
- Select context rules relevant only to the authentication task.
How to install ai-context-kit
Platform CLI
claude mcp add ai-context-kit -- npx -y ai-context-kitPlatform CLI
codex mcp add ai-context-kit -- npx -y ai-context-kitConfig file
{
"mcpServers": {
"ai-context-kit": {
"command": "npx",
"args": [
"-y",
"ai-context-kit"
]
}
}
}Config file
{
"servers": {
"ai-context-kit": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"ai-context-kit"
]
}
}
}Platform CLI
gemini mcp add ai-context-kit npx -y ai-context-kitStep by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about ai-context-kit
How to install ai-context-kit in Claude Code?
Run claude mcp add ai-context-kit -- npx -y ai-context-kit.
What does ai-context-kit do?
It inspects agent configuration files, flags conflicting guidelines, and calculates token consumption per rule file.
Which rule formats does ai-context-kit recognize?
The utility parses CLAUDE.md, .cursor/rules/, AGENTS.md, .cursorrules, and .github/copilot-instructions.md.