What problem does it solve?
Claude Code sessions often waste tokens on irrelevant files loaded into context, repeated full reads of large files, accumulated session noise from not clearing context after direction changes, and verbose command output that floods the context window, slowing down work and increasing costs for long-running development projects.
Core Features & Use Cases
- Auto-configure .claudeignore: Automatically generates or updates .claudeignore to block irrelevant files (like node_modules, build artifacts) from loading into context, cutting unnecessary context footprint.
- Large file read guidance: Detects files over 500 lines and prescribes split-read strategies to avoid repeated full-file token costs, and flags burst read patterns for further optimization.
- Context state management: Guides optimal /clear timing after direction changes and model switching (Haiku for simple tasks, Sonnet for coding, Opus for architecture decisions) to prevent context rot.
- Hub context auditing: For meta-harness users, audits bloated CLAUDE.md, MEMORY.md and other context files, recommending compression to keep context lean.
Use case: A developer working on a long-term project with a large codebase can use this skill to automatically set up .claudeignore, avoid re-reading 1000-line config files repeatedly, and clear context when switching from bug fixing to feature implementation, reducing session token use by up to 60%.
Quick Start
Invoke the context-doctor skill to audit your current Claude Code session for token waste and receive automatic, actionable prescriptions to reduce context bloat and command output.