compaction-resilience-guard
Installation
SKILL.md
Compaction Resilience Guard
What it does
Memory compaction can fail silently: the LLM produces empty output, summaries that are larger than their input, or garbled text. When this happens, compaction stalls and context overflows.
Compaction Resilience Guard enforces a three-level escalation chain inspired by lossless-claw:
| Level | Strategy | When used |
|---|---|---|
| L1 — Normal | Standard summarization prompt | First attempt |
| L2 — Aggressive | Low temperature, reduced reasoning, shorter output target | After L1 failure |
| L3 — Deterministic | Pure truncation: keep first N + last N lines, drop middle | After L2 failure |
This ensures compaction always makes progress — even if the LLM is broken.