Skip to Content
Skillsnav-compact

nav-compact

Clear conversation context while preserving all knowledge in a context marker — like a git commit before switching branches.

Triggers

Natural-language phrases that auto-invoke the skill:

  • “clear context” / “start fresh” / “reset conversation”
  • “I’m done with this task” / “moving to next feature”
  • “approaching token limit” / “context getting full”
  • “compact” / “clean up context”

What it does

  • Detects whether the project has the PreCompact hook installed. If present, takes the fast path: the hook writes the marker automatically on /compact (and on silent auto-compact), so the skill just instructs you to run /compact.
  • Legacy path (no hook): estimates conversation size and confirms before compacting (suggests waiting under 20 messages).
  • Creates an automatic marker named before-compact-{YYYY-MM-DD}-{HHmm} capturing summary, files modified, decisions, and next steps.
  • Writes the marker filename to .agent/.context-markers/.active so the next session offers to restore it.
  • Cannot clear the conversation itself (Claude Code limitation) — it prepares the marker and guides you to start a new conversation or run /clear.

Example

"Feature complete, clear context for next task"

Navigator creates a marker, sets the .active file, and tells you to start a fresh session. On next start, Navigator detects the marker and offers to restore your state.