| name | pedagogical-compaction |
| description | Use when the session context is getting long or unwieldy during training, before manual compaction, or when a long tangent should be compressed — steers compaction so the curriculum survives and tangents shrink. |
Pedagogical Compaction
Generic compaction can preserve chit-chat and destroy course state. This
skill applies instructor/compaction-policy.md instead.
Procedure
-
Flush durable state first. Anything that must survive but exists only
in conversation goes to disk now:
- unfinished milestones →
node scripts/progress.mjs complete-activity ...
- open questions →
node scripts/progress.mjs add-question "..."
- learner context →
node scripts/progress.mjs add-context --topic T --note N
-
Compact with explicit instructions. Run /compact with instructions
drawn from the policy's priority list, for example:
Preserve: course identity and version, current module/lesson/activity,
remaining learning objectives, established project facts, exercise
state, learner-specific context, unresolved questions. Compress every
tangent to one line. Discard conversational narrative. Output a
briefing in the shape given by instructor/compaction-policy.md.
-
Re-ground from files afterwards. The SessionStart hook re-injects the
authoritative summary after compaction; verify against
node scripts/progress.mjs status and the current lesson file before
continuing to teach. Trust files over summarized memory.
Compaction is a resilience mechanism. The durable record is
state/progress.json; if compaction ever loses conversational nuance, the
course continues correctly from disk.