context-budget

Audits Claude Code context window consumption across agents, skills, MCP servers, and rules.

1|Updated Oct 11, 2025
One-click install
npx skills add https://github.com/ibytechaos/claude --skill context-budget-ibytechaos
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: context-budget
Source: https://github.com/ibytechaos/claude/tree/main/plugins/everything-claude-code/skills/context-budget
Command: npx skills add https://github.com/ibytechaos/claude --skill context-budget-ibytechaos

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Claude Code sessions accumulate context overhead from agents, skills, MCP servers, rules, and CLAUDE.md files, degrading performance and shrinking usable context without visibility into where tokens go. ## Core Features & Use Cases - Component Inventory: Scans agents, skills, rules, MCP servers, and CLAUDE.md files, estimating token consumption per component with heuristics like words × 1.3 and ~500 tokens per MCP tool schema. - Issue Detection: Flags bloated agent descriptions, heavy files, redundant components, MCP over-subscription, and CLAUDE.md bloat, then classifies components into keep, on-demand, or remove buckets. - Prioritized Report: Produces a context budget report with per-component token breakdowns and ranked optimization recommendations, plus a verbose mode with per-file detail. - Use Case: Before adding five new MCP servers, run an audit to learn current overhead is 33% and that removing two CLI-replaceable servers first keeps you under a 40% overhead target. ## Quick Start Ask Claude to run a context budget audit of the current setup and report the top token-saving optimizations.

Frequently Asked Questions about context-budget

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I audit Claude Code context window usage?

Run the /context-budget command to scan all agents, skills, rules, MCP servers, and CLAUDE.md files. It estimates token consumption per component and produces a report with a breakdown table and ranked optimization recommendations.

How much context do MCP servers use in Claude Code?

Each MCP tool schema costs roughly 500 tokens, so a 30-tool server can consume more context than all your skills combined. Servers wrapping simple CLI tools like gh, git, or npm are flagged as replaceable to reclaim that overhead.

Why is my Claude Code session getting slower over time?

Accumulated agents, skills, MCP servers, and rules inflate the context loaded into every session, reducing effective available space. An audit identifies heavy files over 200 lines, bloated descriptions over 30 words, and redundant components driving the slowdown.

Can I check context headroom before adding more MCP servers?

Yes, the audit reports current overhead as a percentage of the context window and estimates the cost of planned additions. It recommends removals, such as CLI-replaceable servers, when the expansion would push overhead too high.

What are the limitations of token estimation in a context audit?

Estimates use heuristics like words × 1.3 for prose and chars / 4 for code, so figures are approximations rather than exact tokenizer counts. Use verbose mode when you need per-file detail to pinpoint the specific files driving overhead.