Use when a coding session is burning context fast, output is drowning in noise, the model keeps forgetting earlier decisions, or the user asks to reduce tokens, stop the verbose narration, work in a huge repo, or make a long session survive. Covers what to read, what to summarize, what to write to disk, and when to start fresh.
Collected from public GitHub. Every version is saved exactly as it was and never changes. Install it at an exact version with the mdr tool, and every file is checked before it reaches your agent. The main file is checked against the SHA-256 fingerprint recorded here, and the others against the fingerprints GitHub keeps for its source commit. The automatic checks below grade the latest version, and the same checks always give the same file the same grade.
What the file says
# Context Budget
Context is the scarcest resource in a long session. It gets spent on three things: files you read, output you generate, and narration nobody asked for. Only the first one is usually worth it.
## Core Behavior
Treat the context window like a budget with a balance. Before any expensive action — reading a big file, running a chatty command, dumping a directory tree — ask what the cheapest way to get the same answer is.
## Spend Rules
**Read narrowly.** `sed -n '120,190p' file.ts` beats reading a 2,000-line file to see one function. Grep for the symbol, then read the 40 lines around it. Read a whole file only when you are about to restructure it.
**Search before reading.** `grep -rn "symbolName" --include="*.ts"` costs a few hundred tokens and tells you which of forty files matters.
**Silence the noisy commands.** Pipe installs, builds, and test runs through a filter instead of dumping them whole:
```bash
npm test 2>&1 | tail -30
npm run build 2>&1 | grep -E "error|Error|warning" | head -20
npm install --silent 2>&1 | tail -5
git diff --stat # not git diff, unless you need the hunks
```
A passing test suite needs one line of proof, not 400.
…
The line at the top of this page pins the label git:20260920.97b5147, which is what most people want. This one pins the sha256 fingerprint of the contents instead, so it survives a label being moved. Either way the exact version is written to mdr.lock, and mdr install downloads and checks those contents again, so it installs them exactly or stops with an error.
GET https://markdownregistry.com/api/v1/artifacts/art_mzzb6ljsjtslxxqq
GET https://markdownregistry.com/api/v1/resolve?ref=onewave-ai/claude-skills/context-budget
GET https://markdownregistry.com/api/v1/blob/1183ad0188357a80aafb4d4c9e87e6282abe1c295d8d10fbd87c443c6da68c71
Your AI assistant does the legwork. You hear about the deals worth your word. Hand yours the standing instructions at modelranch.com and it joins the network that reads files like this one.
onewave-ai/claude-skills · accessibility-auditor/SKILL.md · Audit websites for accessibility issues and WCAG compliance. Use when checking accessibility, fixing a11y issues, or…
onewave-ai/claude-skills · agent-army/SKILL.md · Deploy a 2-layer parallel agent hierarchy for large, parallelizable work — big refactors, multi-file migrations…
onewave-ai/claude-skills · agent-eval-harness/SKILL.md · Use to test whether an AI agent, prompt, or skill actually works before or after it ships — build a small eval set…
onewave-ai/claude-skills · agent-swarm-deployer/SKILL.md · Deploys swarms of sub-agents for massive parallel data processing tasks. Unlike agent-army (which is for code changes)…
onewave-ai/claude-skills · agent-team-builder/SKILL.md · Designs and deploys custom agent teams for specific business workflows. Interactive discovery of business processes…
onewave-ai/claude-skills · agent-to-agent/SKILL.md · Agent-to-Agent (A2A) communication protocol. Connect two or more Claude agents that pass messages, share context…
onewave-ai/claude-skills · ai-coding-guardrails/SKILL.md · Use when an AI coding agent is writing or refactoring production code and its known failure modes need to be held in…
onewave-ai/claude-skills · ai-readiness-assessment/SKILL.md · Assesses how ready a business is for AI adoption across six dimensions. Evaluates data maturity, tech stack, team…
onewave-ai/claude-skills · animate/SKILL.md · Generate animated videos and motion graphics from natural language descriptions. Creates a standalone Vite + React…
onewave-ai/claude-skills · api-endpoint-scaffolder/SKILL.md · Generate REST API endpoints with proper structure, validation, error handling, and types. Use when creating new API…
ericrisco/rsc-harness · skills/context-budget/SKILL.md · Use when a long-horizon task is filling the context window and you must decide what to keep, offload, drop, or hand off…
frankxai/claude-skills-library · absorbed/harness/context-budget/SKILL.md · Count what a session loads before adding another skill or MCP server. Use when the default prompt is heavy, a new…
drayline/rootnode-skills · plugins/rootnode-projects/skills/context-budget/SKILL.md · Analyzes Claude Project context budget under the automatic-RAG-by-window model: knowledge files vs. threshold-exempt…
univers42/claude-deal-with-the-devil · skills/context-budget/SKILL.md · Measure and cut what a config costs in context every session: always-on rules, invocable descriptions, skills that…