Download for macOS
Skill

context-compression

@muratcankoylan Updated 2026-08-19

This skill should be used when long-running agent sessions need context compression, structured summarization, compaction, token-per-task optimization, or durable handoff summaries that preserve decisions, files, risks, and next actions.

Install

git clone https://github.com/muratcankoylan/Agent-Skills-for-Context-Engineering /tmp/Agent-Skills-for-Context-Engineering && ln -s /tmp/Agent-Skills-for-Context-Engineering/skills/context-compression ~/.claude/skills/context-compression

From README

Context Compression Strategies When agent sessions generate millions of tokens of conversation history, compression becomes mandatory. The naive approach is aggressive compression to minimize tokens per request. The correct optimization target is tokens per task: total tokens consumed to complete a task, including re-fetching costs when compression loses critical information. When to Activate Activate this skill when: Agent sessions exceed context window limits Codebases exceed context windows (5M+ token systems) Designing conversation summarization strategies Debugging cases where agents "forget" what files they modified Building evaluation frameworks for compression quality Creating durable handoff summaries that preserve decisions, files, risks, and next actions Do not activate this skill for adjacent work owned by other skills: General token-efficiency tactics such as masking, prefix caching, or partitioning: context-optimization.