dsh-context-window
Run the following command in DeepSeek Harness:
dsh plugin install CooperZhuang/dsh-context-window
Paste the following prompt into your AI chat to install this plugin:
Run dsh plugin install CooperZhuang/dsh-context-window in your terminal to install this plugin from https://github.com/CooperZhuang/dsh-context-window; it loads with enabled set to false by default.
About this plugin
Summarization-based context compaction has a structural weakness: it is implicitly lossy. The model does not know what was dropped, quality degrades across multiple rounds, and lost information is unrecoverable. dsh-context-window brings the alternative path that Codex introduced into DSH workflows. Instead of shrinking context into a single summary, it replaces the entire window with a fresh initial context. The model knows the old content still exists elsewhere and can retrieve it when needed, while also skipping the extra model call that each compaction round would otherwise require.
Three core capabilities: token-budget threshold notices (default at 25%, 50%, and 75% of window consumption, plus a final reset reminder near exhaustion), a model-callable new_context tool (sets a flag that flips the window on the next turn), and configurable budget accounting (effective window ratio, hard clamp, and prefix-billing toggle all aligned with Codex defaults). Resets land on step boundaries, never splitting an in-flight tool call, so tool-pairing balance is always preserved.
Ideal for long-horizon agent workflows where context integrity matters: multi-step code generation, cross-file refactoring sessions, and complex reasoning chains that repeatedly reference early conversation details. The plugin ships with enabled set to false, so installing it changes nothing until you opt in. Mount it on the host plane for notices and the tool only, or inside a compaction realm to fully take over the compaction backend.
Use Cases
- Context window nearing exhaustion during long conversations, requiring an explicit reset instead of implicit summarization
- Multi-step agent tasks that repeatedly reference early conversation details without losing information
- Cross-file refactoring sessions where full context must be preserved without per-round compaction calls
Best For
- Developers building long-horizon agent workflows
- DSH users who prioritize context quality and information integrity
- Agent architects exploring alternatives to summarization-based compaction
Related Plugins
A method pack that makes AI coding agents plan against your real baseline, prove completion with fresh evidence, and reduce reworks and unsafe changes.
Turns the DeepSeek Harness session into a captain that builds a durable sub-agent team, splits goals into dependency-aware tasks, and coordinates work via direct messages and a live Web UI.
Gives coding agents design judgment, letting Claude Code, Cursor, and 70+ agents generate and iterate high-quality UI, presentations, and graphics right from the terminal.
Run the Pi ecosystem's plugins on DeepSeek Harness, unmodified, via a compatibility layer that implements Pi's public extension ABI on DSH's native services.