Available in
Marketplaces, most starred first
Tags
Add to README
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
By anilcancakir Verifiedv1.0.0MITIn 1 marketplace
Lets you compact your context at phase changes and milestones rather than when auto-compaction fires mid-task. Hooks track tool calls and suggest compaction on their own, and a Stop hook checks context health after each response.
Trending plugins
7-day copy clicks
Claude loads one when your task matches it, or you run it by name.
1 critical · 2 cautions to review before installing
A hook runs before every tool call and can block or approve it
A hook runs when Claude uses the Bash tool
A hook runs when Claude writes or edits files
Static checks of hooks, mods, MCP servers and commands. Not a security audit.
1 marketplace, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Smart context management plugin for Claude Code. Suggests manual compaction at strategic points instead of relying on arbitrary auto-compaction.
Auto-compaction triggers when context is full, often mid-task. This loses important context at the worst possible time. Strategic compaction gives you control by suggesting compaction at logical breakpoints.
claude plugin add anilcancakir/strategic-compact
| Variable | Default | Description |
|---|---|---|
STRATEGIC_COMPACT_T1 | 50 | First suggestion threshold |
STRATEGIC_COMPACT_T2 | 75 | Second suggestion threshold |
STRATEGIC_COMPACT_T3 | 100 | Strong recommendation threshold |
STRATEGIC_COMPACT_TIME | 1800 | Time threshold in seconds (30 min) |
Conservative (fewer suggestions):
export STRATEGIC_COMPACT_T1=75
export STRATEGIC_COMPACT_T2=100
export STRATEGIC_COMPACT_T3=150
export STRATEGIC_COMPACT_TIME=3600
Aggressive (more suggestions):
export STRATEGIC_COMPACT_T1=30
export STRATEGIC_COMPACT_T2=50
export STRATEGIC_COMPACT_T3=75
export STRATEGIC_COMPACT_TIME=900
Session Start
│
├──► Initialize tracking (tool counts, timestamps)
│
▼
┌─────────────────────────────────────────────────────┐
│ EXPLORATION PHASE │
│ (Read, Grep, Glob, WebSearch, Task) │
│ │
│ [10+ exploration calls, then Edit/Write] │
│ → Phase transition suggestion │
└─────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────┐
│ IMPLEMENTATION PHASE │
│ (Edit, Write, Bash) │
│ │
│ [T1 calls] → Checkpoint suggestion │
│ [T2 calls] → Context filling up │
│ [T3 calls] → Strong recommendation │
└─────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────┐
│ MILESTONE DETECTION │
│ │
│ • Tests pass → "Milestone reached" │
│ • Git commit → "Code committed" │
│ • Build done → "Build completed" │
│ • Deploy → "Deployment complete" │
└─────────────────────────────────────────────────────┘
| Event | Script | Purpose |
|---|---|---|
SessionStart | session-init.sh | Initialize tracking state |
PreToolUse | track-and-suggest.sh | Track tool usage, suggest compact |
PostToolUse (Bash) | milestone-detector.sh | Detect milestones |
PreCompact | compact-instructions.sh | Inject preservation guidance |
Stop | stop-check.sh | Check context health before stopping |
| Skill | Description |
|---|---|
strategic-compact | Context management guidance and recommendations |
| Command | Use When |
|---|---|
/compact | Quick context reset, keep working |
/compact Focus on API changes | Custom summarization focus |
/clear | Complete reset for new task |
strategic-compact/
├── .claude-plugin/
│ └── plugin.json
├── hooks/
│ └── hooks.json
├── scripts/
│ ├── session-init.sh
│ ├── track-and-suggest.sh
│ ├── milestone-detector.sh
│ ├── compact-instructions.sh
│ └── stop-check.sh
├── skills/
│ └── strategic-compact/
│ └── SKILL.md
├── README.md
├── CHANGELOG.md
└── LICENSE
MIT License - see LICENSE
Anilcan Cakir - @anilcancakir
Built from public signals: copy clicks on this site, GitHub stars and activity, the README and the manifest. Not a security audit or an endorsement.
Plugins from other owners that cover similar ground
npx claudepluginhub anilcancakir/claude-code-plugins --plugin strategic-compactThe README's claude plugin add anilcancakir/strategic-compact fails in Claude Code: error: unknown command 'add'
Use the command above.