From task-tracker
This skill should be used when the user asks about "context compaction", "preserving context", "session summarization", "avoiding context loss", "pre-compaction checkpoints", "context window management", or needs guidance on documenting context before compaction occurs, managing large context windows, or recovering from context loss.
How this skill is triggered — by the user, by Claude, or both
Slash command
/task-tracker:context-preservationThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Context compaction occurs when the conversation exceeds the context window limit. During compaction, the conversation is summarized, and detailed context can be lost. This skill provides strategies for preserving critical context before compaction.
Context compaction occurs when the conversation exceeds the context window limit. During compaction, the conversation is summarized, and detailed context can be lost. This skill provides strategies for preserving critical context before compaction.
When about to perform token-heavy operations:
When PreCompact triggers, immediately:
Create a comprehensive checkpoint with:
## Pre-Compaction Checkpoint: YYYY-MM-DD HH:MM:SS
### Session Summary
[High-level summary of this entire session's work]
### Key Accomplishments
1. [Major accomplishment 1]
2. [Major accomplishment 2]
3. [Major accomplishment 3]
### Critical Decisions Made
- **Decision**: [What was decided]
**Rationale**: [Why this choice]
**Alternatives Rejected**: [What else was considered]
### Research Findings
- **Topic**: [What was researched]
**Finding**: [Key insight]
**Source**: [Where found]
**Implication**: [What it means for the work]
### Current Work State
- **Active file(s)**: [Files being worked on]
- **Pending changes**: [Uncommitted work]
- **Test status**: [Pass/fail/pending]
- **Blockers**: [Any obstacles]
### Context Required for Continuation
[Specific context that MUST be preserved]
- Variable states: [...]
- Working assumptions: [...]
- Temporary workarounds: [...]
### Next Session Should
1. [First action to take]
2. [Second action]
3. [Third action]
### Files Modified This Session
- `path/to/file1.ts` - [brief description]
- `path/to/file2.ts` - [brief description]
Before firecrawl_scrape, firecrawl_search, firecrawl_crawl:
After research:
When reading many files:
When debugging consumes tokens:
If compaction has occurred:
Use /resume-task command to automate this recovery.
The task-tracker plugin monitors context usage:
| Threshold | Action |
|---|---|
| 50% | Informational note on firecrawl ops |
| 75% | Warning with checkpoint recommendation |
| 90% | Urgent checkpoint prompt |
| PreCompact | Mandatory checkpoint creation |
/checkpoint - Manual checkpoint creation/task-status - View current context state/resume-task - Recover after compaction/set-task - Initialize task trackingThe status line (when configured) shows:
ctx:X% - Current context usage percentagetask:name - Active task nameColors indicate urgency:
npx claudepluginhub victor-software-house/task-tracker-pluginManages Claude Code context window by snapshotting session state, compacting conversation, and resuming via hook. Use when context exceeds 70% or starting a large new task.
Manages context window in long Claude Code sessions: detects limits via tool counts, triggers smart compaction, preserves critical state, injects dev/research/review behavioral modes.
Preserves critical data before automatic context compression. Creates snapshots, verifies integrity, and prevents information loss during sessions.