context-discipline

Installation
SKILL.md

Context Discipline

Core Principles

  1. MCP tools first, file reads second — A Roslyn MCP query costs 30-150 tokens. Reading a file costs 500-2000+ tokens. For navigation and understanding, always try MCP tools before opening files. Only read files when you need to modify them or MCP tools don't provide enough detail.

  2. Lazy load everything — Don't read files "just in case." Don't load all skills upfront. Don't explore directories you aren't about to modify. Load information at the moment you need it, not before.

  3. Subagents are context isolation chambers — Every subagent gets its own context window. Offload exploration, research, and analysis to subagents. They process information and return a summary — your main context stays clean.

  4. Summarize and discard — After exploring a subsystem, summarize what you learned in a few lines. The summary is what stays in context, not the raw file contents. Think of it as compressing information.

  5. Know your budget — A 200k token window sounds large but fills fast. A typical .cs file is 500-2000 tokens. Loading 50 files can consume half your budget. Plan your reads like you plan your sprints — deliberately.

Patterns

MCP-First Navigation

Always prefer MCP tools for understanding code structure:

Installs
32
GitHub Stars
435
First Seen
Mar 17, 2026
context-discipline — codewithmukesh/dotnet-claude-kit