zeropointnine/dsh-compact-and-branch

zeropointnine★ 2JavaScriptLast synced: 2026-08-23

Open on GitHub

Compact a session and continue the work in a new one

README excerpt

dsh-compact-and-branch: /compact-and-branch A focused out-of-tree DeepSeek Harness plugin for treating canonical context compaction as a clean session branch point. Motivation Long-running coding-agent sessions can accumulate a great deal of useful working context before reaching a natural phase boundary. DSH's /compact command is useful for reducing that history while preserving the state needed to continue, but sometimes it is preferable to make that compaction a clean branch point: continue from the resulting state in a fresh session while leaving the compacted source session independently resumable. This is especially useful with relatively limited context windows, as is common with local LLMs, where long agent trajectories can otherwise require repeated compactions and make session boundaries more consequential. /compact-and-branch is intended to have essentially the same model-facing effect as running /compact and continuing normally in the original session, except that the continuation occurs in a new root session. It deliberately reuses DSH's canonical compaction result rather than introducing a separate handoff summary or another lossy transformation of the session state. …

View full README on GitHub →
Tools / Devdeepseek-harnessdshdsh-pluginsession-compactionagent

Category