Skip to content
Back to skills

compaction-survival

ASecurity

Preserve working state across long sessions and context compaction by checkpointing decisions, edited files, blockers, open hypotheses, and unresolved errors into compact resumable artifacts. Use on long coding tasks, audits, research, or any session at risk of losing state after compaction.

  • 16 stars
  • 0 votes
  • 0 copies
  • 4 views
  • Added June 15, 2026
ai-agentsgorailsdebuggingdocumentation

Security analysis

A100/100

Pro scans all 3 files and shows the line behind each finding

Scanned June 15, 2026

npx -y skills add markoblogo/abvx-agent-skills --skill compaction-survival --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of compaction-survival?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for compaction-survival
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/markoblogo-compaction-survival/badge)](https://www.skillsdirectory.com/skills/markoblogo-compaction-survival)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: compaction-survival
description: Preserve working state across long sessions and context compaction by checkpointing decisions, edited files, blockers, open hypotheses, and unresolved errors into compact resumable artifacts. Use on long coding tasks, audits, research, or any session at risk of losing state after compaction.
license: MIT
metadata:
  abvx_status: experimental
  abvx_origin: adapted
---

# Compaction Survival

Save tokens by keeping the right state alive across compaction instead of re-deriving it after memory loss.

## Goal

When a session is getting long, preserve only the working state that would be expensive to reconstruct.

## What To Preserve

- current objective;
- active subtask list;
- key decisions and reversals;
- files changed or inspected deeply;
- unresolved errors and their current hypothesis;
- blockers, constraints, and pending verifications;
- exact artifact paths for large outputs or generated files.

## What Not To Preserve

- long narrative history;
- repeated summaries of already-resolved steps;
- raw logs that can be regenerated cheaply;
- generic project documentation already available on disk.

## Checkpoint Workflow

1. Detect compaction risk:
   - long session;
   - many files touched;
   - many turns of debugging or research;
   - user explicitly worried about token budget.
2. Emit a compact handoff artifact:
   - objective;
   - done / next / blocked;
   - decisive evidence only;
   - exact paths for deeper artifacts.
3. Keep the checkpoint stable unless the working state materially changes.
4. After compaction or resume, recover from the checkpoint first instead of replaying the whole session.

## Recommended Shapes

- concise handoff note;
- checked-location ledger;
- issue-specific status file in `docs/ai/tasks/` or equivalent;
- compact bullets over narrative prose.

## Guardrails

- Do not checkpoint secrets.
- Do not create noisy per-turn diary files.
- Do not preserve stale hypotheses after the evidence changed.
- Do not replace real verification with checkpoint confidence.

## Final Report

Say what was checkpointed, where it lives, and what should be reused first after resuming.

Files in this skill

  • SKILL.md2.1 KB
  • SKILL_CARD.md1.4 KB
  • agents/openai.yaml217 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.