seek://map/dsh-session-resilience
DSH Session Resilience — Safe Restart and Session Recovery
#session-recovery #restart #resilience #reliability #web
TL;DR
Per its README, dsh-session-resilience keeps long-running DSH web sessions recoverable across host restarts, disconnects, token limits, and repeated work: loopback restart and stop controls, a host-owned continuation engine, token-aware reconnect, and Safe/Balanced/Long task/Manual recovery policies in the settings card. Community plugin by hasan-aghayev, MIT.
Long DSH web sessions used to die with the host process. This bundle adds a restart control that records active root sessions, starts a replacement host on the configured port, and reconnects the browser to its tokenized launch URL, plus a continuation engine that resumes qualifying interrupted turns under the selected recovery policy — with loop protection, adaptive backoff, and a settings card that reports recovery state instead of false success. It fills this map's session-reliability gap: no other indexed entry covers safe host restart and session recovery.
Facts
- install
- dsh plugin add https://github.com/hasan-aghayev/dsh-session-resilience
- license
- MIT
- note
- 重启接力要求根浏览器会话在接力窗口内重连;进程在写入重启标记前被杀则无法接力;生产 profile 应固定 commit,勿用移动分支。
Key points
- Per its README, the plugin keeps long-running web sessions recoverable when the local DSH host restarts, disconnects, reaches the token limit, or begins repeating the same work, combining loopback restart and stop controls with a host-owned continuation engine, token-aware reconnect, idempotency guards, adaptive backoff, loop protection, and a small live recovery panel
- Recovery policies — Safe, Balanced, Long task, Manual — coordinate the recovery window, cooldown, retry cap, scan range, and backoff together, and Manual keeps every individual control editable; per its README, handoffs run 5/10/30 minutes with 2/3/8 consecutive resumes across Safe, Balanced, and Long task
- Token-aware reconnect: the browser waits for the replacement host's actual launch URL before reconnecting instead of reopening an unauthenticated root page, and per its README a restart is not reported as ready until the replacement host is reachable and its fresh launch URL has been found
- The model surface is just restart_dsh and shutdown_dsh — both accept an empty object, shutdown only on an explicit stop request, and restart results include the instance, previous process, port, captured root sessions, and helper log paths; recovery policy and browser controls stay outside the model prompt, and the plugin adds no fixed system-prompt prefix
- The continuation engine resumes only machine-interrupted, transiently failed, or token-limited turns — user aborts and policy-blocked turns are not resumed; permanent failures such as authentication, balance, missing-model, and context-limit errors are skipped and can surface as browser notifications, and the loop guard cancels and redirects turns that repeat identical tool calls or assistant text
- Local-first: restart markers, helper logs, and control routes stay on the DSH host with no analytics or remote service; Git-based installation requires no npm publication and the README directs production profiles to pin an exact commit; tested against DeepSeek Harness 0.1.5-rc.2 and Node 22.19+
FAQ
Which interrupted turns get resumed automatically?
Per its README, only machine-interrupted, transiently failed, or token-limited turns resume; user aborts and policy-blocked turns never do. Permanent failures — authentication, balance, missing-model, context-limit — are skipped and can be surfaced through browser notifications.
What does the model see, and what does it cost?
Only the restart_dsh and shutdown_dsh tools: restart on request or when the task explicitly requires it, shutdown only for an explicit stop, both accepting an empty object. Per its README the plugin adds no fixed system-prompt prefix — the model-visible contribution is the tool definitions, their results, and a continuation message when recovery triggers.
How do I install it?
Per its README: dsh plugin add https://github.com/hasan-aghayev/dsh-session-resilience, then add dsh-session-resilience to the profile's bundle list and run the profile's reconcile step. Git-based installation requires no npm publication; pin an exact commit for production profiles and avoid a moving branch.
Which DSH versions does it support?
The README's compatibility section: tested against DeepSeek Harness 0.1.5-rc.2 and Node 22.19+, with package metadata accepting DSH >=0.1.0-rc.7 <0.2.0; it targets a DSH web profile with the published @deepseek-ai/cordis and @deepseek-ai/dsh-tools peer packages.
Official references
- docsRepository ↗