dsh-web
zhu1090093659/dsh-webDeepSeek Harness(DSH)Web 插件聚合生态包 · 一切皆插件,创意工坊分发(dsh-market.com)
Browser notifications for the DeepSeek Harness Web GUI.
Browser notifications for the DeepSeek Harness Web GUI.
Targets DSH 0.1.5-rc.2 and its split session-controller / UI-session client APIs.
Shows a browser notification when:
web_notify__send(message) and can notify you at a meaningful intermediate milestone without ending its turn. Routine progress, final completion, and pending interactions remain automatic and should not call it.requireInteraction and stay on screen until you click or dismiss them (set the REQUIRE_INTERACTION constant in client/index.ts to false, then rebuild, for the OS default auto-dismiss timing).Add the plugin to your dsh profile and register it in the Loader.
dsh plugin --profile web add github:vilicvane/dsh-plugin-web-notify
This is equivalent to running pnpm add github:vilicvane/dsh-plugin-web-notify
inside the profile directory.
Once the package is published to the npm registry:
dsh plugin --profile web add dsh-plugin-web-notify
Then append an insert row to the profile's cordis.patch.yml
($DSH_HOME/profiles/web/cordis.patch.yml):
- insert:
- id: web-notify
name: dsh-plugin-web-notify
config:
provider: deepseek-official
model: deepseek-chat
The config block is optional and defaults to deepseek-official /
deepseek-chat. All settings and their defaults:
| Key | Default | Meaning |
|---|---|---|
provider | deepseek-official | LLM provider route used for summaries. |
model | deepseek-chat | Small/fast model used for summaries. |
maxInputChars | 4000 | Per-side cap on joined human input and assistant output from the completed logical work segment sent to the model. |
maxOutputTokens | 150 | Cap on the summary length. |
timeoutMs | 60000 | Summary generation timeout. |
systemPrompt | (built-in) | System prompt for the summarization call. |
Restart dsh web, refresh the page, and click anywhere once to grant the
notification permission.
index.ts is the host assembly layer. It registers /web-notify/summary
and /web-notify/capability on the DSH web server, registers the
web_notify__send(message) tool and its session projection, and delegates
to typed modules under lib/. Both HTTP routes use the DSH connection
service's cookie authentication and origin checks.lib/tool.ts returns a normal successful tool result whose durable
presentation metadata contains the notification request. It does not end
the turn or append a plugin-private event. lib/projection.ts folds the
latest successful request from Native tool/result events or Code Mode
tool/code-dispatch events into webNotifyRequest.lib/turn-summary.ts finds the latest matching turn/start → turn/end
interval and follows only verified Turn Memory continuation links to their
predecessor turns. It includes human-authored user messages and text-bearing
assistant messages from that completed logical segment, while excluding
runtime/plugin context, unrelated older turns, and a later open turn.lib/summary-service.ts calls the configured model through
ctx.llm.stream with the session-title purpose, deduplicates concurrent
requests for the same completed logical segment, and bounds its in-memory
cache.client/index.ts is the typed Cordis client source. It injects the
sessions and uiSession services, watches the session-list snapshot for
running → false transitions and changes to the webNotifyRequest
projection, and independently subscribes to uiSession.pendingInteractions
(approval / plan-review / question). Request keys distinguish successive
interactions of the same kind. Pending interactions take priority over
agent-requested updates while unresolved. It probes the
capability route at apply (and again after server connection resets), so
webNotifyCompletion projection suppresses the transient idle boundary after
a successful continue_after_turn_compression handoff. Other completion
notifications start with a "summarizing…" hint only when the
host summary is actually available. The client polls the summary route;
the summary replaces the hint (same tag) once ready, and failures degrade
back to the plain completion text. A per-session generation invalidates an
older summary request as soon as a newer completion or pending interaction
arrives, preventing stale summaries from replacing actionable notices.
Projection identities are seeded from the initial snapshot, so refreshing
or reconnecting never replays an old agent-requested notification.scripts/build-client.mjs bundles client/index.ts into the published
loader artifact client.js. The generated file is checked in so GitHub and
npm installs work without a build step.requireInteraction so notifications
stay visible until clicked or dismissed.pnpm install
pnpm build:client
pnpm check
pnpm check proves that client.js matches its TypeScript source, runs the
host/client behavior tests, and type-checks both environments. See
design.md for the lifecycle and concurrency invariants.
MIT