context-compactor
Compress long-run context into handoff, backlog, and action logs.
When & Why to Use This Skill
The Context Compactor is a high-efficiency Claude skill designed to optimize long-running AI sessions by systematically compressing conversation history into structured handoff documents, backlogs, and action logs. By rotating context and maintaining strict line budgets, it prevents token overflow and performance degradation, ensuring that critical project state remains recoverable and organized across extended workflows.
Use Cases
- Complex Software Engineering: Managing state and pending tasks across multi-day coding sessions to stay within token limits without losing project context or architectural decisions.
- Agent-to-Agent Handoffs: Generating structured 'HANDOFF.md' files that allow different AI agents or new sessions to resume work with a clear understanding of the current state and next steps.
- Long-term Research Projects: Maintaining a concise record of findings and a prioritized backlog of open questions during extensive information gathering and analysis phases.
- Audit and Compliance: Recording a compact Action Log that provides a clear trail of AI-driven modifications and decisions for review without needing to parse thousands of lines of chat history.
| name | context_compactor |
|---|---|
| description | Compress long-run context into handoff, backlog, and action logs. |
| short-description | Compact long-run context |
Purpose
Keep context small and recoverable across long sessions.
Steps
- Summarize current state into
HANDOFF.md. - Rotate or trim
AUTO_CONTEXT.md. - Update
BACKLOG.mdwith open items. - Respect
LINE_BUDGETS.yamllimits. - Record a compact Action Log entry.
Guardrails
- Do not remove evidence or required references.