context-management — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited context-management (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
Note: The bash examples below are reference snippets. If you enable disableSkillShellExecution in Claude Code settings (v2.1.101+), any inline shell execution from skills is blocked. These fenced examples are safe to read; copy-paste them into your terminal to run.Context windows are finite. When you estimate you've used roughly 70% of available context, it's time to act. Don't wait until you're out of room — you lose the ability to reason well before you hit the hard limit.
Signs you're running low:
Use when: you're mid-task and need more room but want to keep working. What it does: summarizes conversation history, freeing context. Pair with: PostCompact hook that re-reads CLAUDE.md and PROGRESS.md automatically.
After compaction, always re-orient:
Use when: you're starting a genuinely new task with no relationship to the current one. What it does: wipes conversation entirely. Caution: you lose ALL context. Make sure PROGRESS.md is updated first.
Use when: a side task would pollute your main context (research, testing, file generation). What it does: spawns a separate context that does work and returns results. Your main context stays clean.
| Situation | Action |
|---|---|
| ~70% context, mid-task | /compact |
| Task complete, starting unrelated work | /clear |
| Need to research something tangential | Subagent |
| Need to run tests while continuing design | Subagent |
| Context feels sluggish, responses degrading | /compact |
| Long debugging session, found the fix | /compact, then implement |
The workflow installs a PostCompact hook that runs:
cat CLAUDE.md && cat docs/spec/PROGRESS.md 2>/dev/null || trueOn Windows, this command runs in Git Bash (installed with Git for Windows).
This ensures you never lose your bearings after compaction. The hook fires automatically — you don't need to re-read these files manually.
The workflow automatically maintains session continuity:
When a new Claude Code session opens, a hook automatically injects:
.claude/sessions/You don't need to manually re-read these. The hook handles it. Use /start for additional context (handoff files, agent routing).
Session summaries are written to .claude/sessions/ by:
/commit-push-pr — writes a summary before committing (completed work)/end — writes a summary before the handoff commit (in-progress work)These are local files (gitignored) that bridge the gap between sessions. They're automatically picked up by the next session's SessionStart hook.
Session 1: work → /commit-push-pr → writes session summary → push
Session 2: SessionStart hook → reads summary → knows what happened → /start for extrasIf the session summary is missing or stale, /start still reads PROGRESS.md and handoff files as fallback. The system degrades gracefully.
Control which hooks fire via the WORCLAUDE_HOOK_PROFILE environment variable:
| Profile | Hooks Active | Use When |
|---|---|---|
minimal | SessionStart, PostCompact only | Exploring, learning, minimal overhead |
standard | All hooks (default) | Normal development |
strict | All hooks + TypeScript checking | Pre-release, team CI, maximum safety |
Set in your shell:
export WORCLAUDE_HOOK_PROFILE=minimal # lightweight
export WORCLAUDE_HOOK_PROFILE=standard # default (same as unset)
export WORCLAUDE_HOOK_PROFILE=strict # maximum enforcementOr per-session:
WORCLAUDE_HOOK_PROFILE=strict claudeThe default is standard if the variable is not set. You don't need to do anything for normal development — the default just works.
Approximate values from Claude Code v2.1.88 source (March 2026). These may change between releases.
| Resource | Budget |
|---|---|
| Context window (default) | 200,000 tokens |
| Context window (Opus 4.6 / Sonnet 4.6 with 1M) | 1,000,000 tokens |
| Max output tokens (Sonnet 4.6) | 32,000 default, 128,000 upper limit |
| Max output tokens (Opus 4.6) | 64,000 default, 128,000 upper limit |
| Tool presence overhead | ~500 tokens (added when any tools are enabled) |
| Post-compact file restore | 5 files max, 50,000 token budget, 5,000 per file |
| Post-compact skills restore | 25,000 token budget, 5,000 per skill |
| Compact summary output | 20,000 tokens max |
| CLAUDE.md total budget | ~40,000 characters across all loaded instruction files |
| MEMORY.md (native, ~/.claude/) | 200 lines / 25,000 bytes |
Practical takeaways:
so the most important files are recently read.
Monitor your context usage and adjust behavior accordingly:
| Tier | Context Free | Behavior |
|---|---|---|
| PEAK | >75% | Normal operation — read files freely, keep full context |
| GOOD | 50-75% | Be selective about file reads — summarize large files |
| DEGRADING | 25-50% | Summarize before reading new files, consider /compact |
| CRITICAL | <25% | Save state immediately, /compact, reload only essentials |
Heuristics (you cannot measure exact tokens):
compaction helps but won't get you back to fresh. Consider /clear if the task is done.
instructions and file paths — don't assume they know what you know.
understanding of the changes you've been building up.
may have lost important details.
~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.