/training:context-managementfrom training
Audits and reorganizes Claude Code context files (CLAUDE.md, rules, docs, skills) by sorting each line into the right location or deleting it. Use when context is too long or noisy.
Ships in training. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Sorts context lines with five questions and applies the moves you approve. One run audits the files you name. Nothing changes without your approval.
Ask them in order for each line. The first yes wins.
| # | Question | Yes means |
|---|---|---|
| 1 | Can a linter or CI check it? | Lint backlog. Out of context entirely. |
| 2 | Is it only true for this change? | Ticket. It stops being true when the ticket closes. |
| 3 | Does every session in this repo need it? | CLAUDE.md. |
| 4 | Only some files or folders? | .claude/rules/<topic>.md with a paths glob, or a nested CLAUDE.md in that folder. |
| 5 | Only some tasks? | docs/ for facts, with a one-line pointer from CLAUDE.md or the skill that needs it. A skill for steps. |
| - | No yes? | Delete it. |
Three checks run before the questions, because they are cheap and remove the most:
Two rules keep the moves honest:
paths glob. Without one it loads every session, the same as CLAUDE.md.docs/ on its own. Every line moved there leaves a one-line pointer behind.Evidence gate on moves into CLAUDE.md. Moving a line up into CLAUDE.md from somewhere narrower needs corroboration: two or more independent occurrences, or a team statement that it is a standing convention. Otherwise it stays where it is and is recorded as waiting on evidence. This keeps the skill from stuffing CLAUDE.md.
- [ ] Step 1: Pick the files and the mode
- [ ] Step 2: Split the files into lines
- [ ] Step 3: Route, then stop for approval
- [ ] Step 4: Apply and record
If the user named the files (/context-management CLAUDE.md), use them and skip discovery. Otherwise glob for what exists, without reading it yet: CLAUDE.md at the root and nested, .claude/rules/, .claude/skills/*/SKILL.md, docs/. Ask in one question which to review, offering only what exists, each with a count.
Mode is interactive unless the user says auto.
-> STOP only if the selection resolved to more than one file. Show the list and confirm the scope.
For each file, extract items: one item is one claim that could move, stay, or be deleted on its own. Read references/input-shapes.md for how to split each kind of file.
Then read CLAUDE.md, .claude/rules/ and docs/ once, only to answer the duplicate check. Do not edit them unless they were selected.
If context-audit.md exists from an earlier run, read it. Do not re-propose a move the user declined.
Nothing is edited in this step.
Apply the checks and the five questions to every item. Show only the items that move. A line routed to where it already lives is not a decision. Use references/routing-table.md for the table.
context-routing-proposal.md. -> STOP. Report its path. Apply only after the user approves it. If they edited it, re-read it first. Their version wins.Apply the approved moves:
.claude/rules/<topic>.md with paths frontmatter, one short topic per file. Claude Code asks before writing in .claude/.docs/<topic>.md and add the pointer line.Then write or append context-audit.md at the repo root, one dated section per run:
In auto mode, delete context-routing-proposal.md once the record is written.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
context-cleanup, claude-md, rules-organization, context-audit
Other plugins' skills for the same job
9 skills in this plugin
/api-playwright-testingGuides the creation of Playwright API tests from exploration through implementation. Covers API discovery, test plan creation, helper/data factory development, and test writing with human checkpoints at each stage./context-coverageAudit how agent context (CLAUDE.md, AGENTS.md, GitHub Copilot instructions, Cursor/Windsurf rules, rules directories, skills) lines up with the code across a set of repositories and generate a self-contained HTML report. The report leads with a short list of specific "things to check" (context behind the code, thin coverage for the codebase, oversized files, no per-area context), then per-repo raw metrics and a folder tree comparing folder LOC to context coverage, and can show what changed since an earlier run. Use when the user wants to audit context coverage across repos, "which repos are missing CLAUDE.md", "which repos have no Copilot instructions", "where is our agent context thin or stale", "context coverage across my org / projects folder", "track context coverage week over week", or "/context-coverage". Works on a local folder of clones, a whole GitHub org via the gh CLI, or a single monorepo scoped to just the areas one team owns./designing-ai-workflowsInterviews the user through the design of a new AI-enabled workflow. Frames it, drafts a skeleton early, then refines context, freedom, alignment, verification, and feedback phase by phase, including where the context window resets (same thread, a script, an in-skill subagent, or a separate skill) and where to fan out parallel agents. Scaffolds the result as one or more skills plus a living design-summary HTML with a visual flow map. Use when the user wants to design or build a new workflow or skill for a task type (integrations, modernization, maintenance, testing, incident triage, etc.), asks when to use subagents versus separate skills, or asks to be interviewed about a workflow./e2e-testingGuides the creation of Playwright E2E tests from planning through implementation. Covers test plan creation, data seeding, Page Object Model development, and test writing with human checkpoints at each stage./finding-skill-opportunitiesUse when asked to find skill opportunities in a codebase, audit a repo for automatable workflows, decide what skills to write, or mine git history, existing automation, and recent Claude Code session transcripts for recurring multi-step procedures worth turning into agent skills./managing-locatorsExplores features to discover stable locators and fixes broken locators in Playwright tests. Two modes — explore (proactive discovery) and fix (reactive repair) — both using Playwright MCP for live browser interaction.npx claudepluginhub devclarityai/devclarity-marketplace --plugin training