DSH-Notify: System notifications for DSH task completion and pending replies

Introduction

When running long-running tasks with DeepSeek Harness (DSH), the Agent requires your attention at two specific moments: first, when it is “waiting for your reply,” such as during ask_user_question, approval requests, or plan confirmations; second, when the session transitions from running to idle, indicating the current round has finished. If you are constantly watching the DSH tab, status changes are visible on the interface. However, if you switch to another tab, minimize the browser, or close the browser entirely, you might miss them. The community plugin dsh-notify (maintainer: TaoYe599, Category: Client) sends notifications layered by “who is still alive when the task ends”: it uses web notifications when the page is open but you are not looking, and the Host triggers native Windows toasts if the browser is closed.

What is this

dsh-notify is a standard DSH bundle (declares dsh.bundle.patch, provides configuration patches with the package). It solves the problem of alerting you via system notifications when DSH needs you or when a task ends—triggering web notifications when the browser is open, and native Windows notifications directly from the DSH Host when the browser is closed.

Status Behavior Notification
It is waiting for you Questions, approvals, plan confirmations, etc. “Needs your reply / confirmation”
It doesn’t need you anymore Session transitions from running to idle “Task completed”

Repository: GitHub — TaoYe599/dsh-notify; Directory Page: SkillHub — dsh-notify. The current package version is 0.1.0, license MIT. The plugin runs with the current DSH process permissions; it is recommended to review the source code and license before installation.

Who sends notifications and when not to send

Coverage is divided based on “who is still alive when the task ends”:

Your Status Who Notifies Description
Watching the DSH page No notification You have already seen the status change
Switched to another tab / another app / browser minimized Client (Web Notification) Clicking the notification returns to the tab; an (N) unread badge appears on the tab title
Browser Closed Host (Native Windows Notification) The page is gone, but the DSH process is still running; the Host takes over

There are several constraints in the design worth knowing:

  • Layered by surviving processes: Web notifications are impossible after the browser is closed. The Host half uses Windows PowerShell 5.1’s WinRT ToastNotification to pop up native toasts (PowerShell 7 has removed this type projection, so 5.1 is specifically used).
  • No duplication across two channels: While the page holds the plugin, it pings /dsh-notify/presence every 20 seconds and uses sendBeacon to say goodbye upon closure; if the Host finds a live page, it remains silent and hands over completely to the client.
  • Interface-agnostic: No persistent settings items; a small card pops up on first use asking if notifications are allowed; if permission is denied or missed, the card returns with the reason (tri-state), rather than failing silently.
  • No missed events: The client reads the session running state and the pending interaction table, driven by DSH connection push, not polling.
  • No false positives for subtasks: The Host only notifies for top-level sessions in agents.roots(); sub-agents with an owning agent context are excluded.

Installation and Activation

Please use the official CLI for installation: dsh plugin forwards arguments to pnpm in the profile directory and automatically adds the package to dsh.profile.bundles if the package declares dsh.bundle.

Choose one of the following three methods (commands from the repository README):

# 1) Install from local directory (most common for development)
dsh plugin --profile web add <directory where this package is located>

# 2) Install from tarball (most convenient for distribution to colleagues)
pnpm pack                                                   # generates dsh-notify-0.1.0.tgz
dsh plugin --profile web add ./dsh-notify-0.1.0.tgz

# 3) Install from npm or GitHub (requires prior publishing/repository creation)
dsh plugin --profile web add dsh-notify
dsh plugin --profile web add github:<you>/dsh-notify

You can confirm the layer is active without starting DSH:

dsh --profile web --dump-config      # The output should show a "# == dsh-notify" layer

You must restart dsh web after installation or update: The bundle list and the Host half are loaded at profile startup; if only the client bundle changes, simply refreshing the page is sufficient.

Uninstallation:

dsh plugin --profile web remove dsh-notify

Then restart dsh web. To temporarily disable it, add disabled: true to the plugin’s line in the profile’s cordis.patch.yml.

Typical Usage and Permissions

After installation and restarting dsh web, use DSH Web normally; no additional configuration items are needed.

  1. Upon first entering a page with this bundle, the browser will ask if notifications are allowed; once allowed, if you are not watching the DSH tab, task completion or pending replies will trigger web notifications.
  2. After the browser is closed, if the Host is still running and determines there are no online pages, you will receive a native toast on Windows.
  3. To completely turn off web notifications in the browser: change the site’s “Notifications” setting to “Block” in site settings; the Host will still notify when the browser is closed.
  4. If you want to be asked again: clear the site’s data (this will clear the dsh-notify.asked in localStorage), and it will ask again after a refresh.

When distributing to colleagues, the README recommends prioritizing pnpm pack to send a .tgz file, and the recipient executes dsh plugin --profile web add ./dsh-notify-0.1.0.tgz. This package has zero runtime dependencies (the Host half only uses Node built-in modules), the client bundle is pre-built, and none of the three installation paths require build-time scripts.

Troubleshooting and Known Boundaries

The Host half appends JSONL diagnostics to ~/.dsh/dsh-notify.log.jsonl (or under $DSH_HOME), each with an event, for example: presence-route (handshake available), toast (native notification sent), skip (reasons like page-alive / subagent / repeat-window), toast-failed, no-web-server. Client logs are in the browser console with the prefix [dsh-notify].

Things to know before use:

  • Native notifications are currently Windows only; detection on non-Windows platforms still runs but skips display only.
  • Existence TTL is 150 seconds: Normally closing the browser sends a goodbye beacon immediately; in case of a crash where the beacon isn’t sent in time, the Host takes over after at most ~150 seconds.
  • Remote access may cause duplicate notifications: When accessing via a non-localhost domain, if the presence heartbeat path is not proxied, the Host might incorrectly judge no page exists, causing both the client and Host to trigger once; local 127.0.0.1 is not affected.
  • No notifications for sub-agent sessions is an intentional design.

Conclusion

dsh-notify maps the two DSH states—“Task Ended” and “Needs Your Reply”—to web notifications and native Windows toasts, using an existence handshake to avoid duplication across dual channels. It is suitable for DSH Web users who run long tasks and need to leave the page; users on non-Windows platforms or in purely remote proxy scenarios should evaluate against the boundaries mentioned above.

  • Directory Page: https://www.skillhub.cn/plugins/TaoYe599/dsh-notify
  • GitHub: https://github.com/TaoYe599/dsh-notify

The DSH ecosystem emphasizes “Everything is a plugin”; community directories like SkillHub are independent sites and have no official affiliation with DeepSeek / High-Flyer.

羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye