Preface

When processing tasks with DeepSeek Harness (DSH), tasks may enter “approval required”, “needs a response”, or “error” states. If these state changes are not captured in time, tasks may become stuck or be ignored. The dsh-task-notifier plugin uses in-app banners, synthesized sounds, and system notifications to ensure you can perceive these state changes in real time.

The plugin is maintained by xubin0628, licensed under the MIT License, and is primarily designed to address the issue of “missed state changes”.

Core Features

The plugin subscribes to four core DSH events and dispatches three notification forms:

  1. Event coverage:

    • agent/status: Task completed (not in a waiting-for-user-input state).
    • approval/request: Approval required (e.g., sandbox/permission calls).
    • user-questions/request: A response to a question is required.
    • agent/error: Execution error.
    • Note: State changes while waiting for approval/responses will not trigger another “task completed” notification, avoiding duplicate alerts.
  2. Notification forms:

    • In-app banner: Implemented with Shadow DOM, style-isolated, and configurable for display duration.
    • Sound: Synthesized using WebAudio, requiring no external audio files; supports crisp/bell/droplet tones and volume adjustment.
    • System notification: Uses the page-side Notification API.
  3. Configuration flexibility:

    • Provides a “Notifications” page in settings, allowing independent toggling of the four events, whether to include sub-agents, and banner display duration.
    • Provides a preview feature that takes effect in real time.

Installation and Activation

The plugin is installed as a Bundle. Because the official desktop client uses an exclusive desktop profile and cannot be managed directly through CLI plugin management, the built-in plugin_manager must be invoked inside a DSH session.

# 软链安装(推荐开发期使用,修改源码即时生效)
install_bundle target = link:<插件目录绝对路径>

# 拷贝安装(推荐生产环境,源码丢失不影响运行)
install_bundle target = file:<插件目录绝对路径>

After installation, new versions usually take effect hot. If changes involve package.json or host process modules, restart the client.

Configuration and Settings

Plugin configuration is divided into two places:

  1. Host-side defaults (in the config section of cordis.patch.yml):

    • Controls notification switches (completion, approval, response, error), whether to include sub-agents, debounce time, volume, etc.
    • Changes here require restarting the client to take effect.
  2. User-side preferences (Settings page “Notifications”):

    • Stored in the browser’s localStorage (key: dsh-task-notifier:settings:v1).
    • Once the user modifies any item on the settings page, user-side settings take precedence and do not fall back to defaults.

Self-Check and Troubleshooting

The plugin provides RESTful endpoints for checking status and testing the notification path.

Check plugin status and awaiting sessions:

Invoke-RestMethod http://127.0.0.1:19387/dsh-notifier/status

View recent notification records:

Invoke-RestMethod 'http://127.0.0.1:19387/dsh-notifier/recent?limit=20'

Test the notification path:

Invoke-RestMethod 'http://127.0.0.1:19387/dsh-notifier/test?kind=approval'
# kind 可取: done | approval | question | error

Development and Known Limitations

After code changes, activation depends on the changed file:

Modified file Activation method Reason
assets/notifier-client.js Refresh the page Host re-reads based on mtime
lib/client.js Refresh the page Updated when the page reloads
lib/index.js Restart the client Node ESM module cache
package.json / cordis.patch.yml Restart the client Requires re-applying the patch

Known desktop client limitations:
* Notification limitation: The desktop client runs in a separate child process and cannot directly access the Electron Notification API (causes WinRT error 0x80073D54); it must rely on the page-side Notification API.
* Injection limitation: The desktop client index injection table is collected once when the host starts; after changing injection logic, restart the client.
* Settings isolation: Settings are stored in localStorage and are not written into profile configuration; switching browsers or clearing cache resets them to defaults.

Conclusion

dsh-task-notifier is a lightweight notification enhancement tool that, through SSE event streams and WebAudio synthesis, provides DSH with both visual and auditory feedback. In scenarios requiring long-running agents or frequent human-agent interaction, it can effectively reduce the risk of missing status changes.

For more details and source code, visit the SkillHub directory or the GitHub repository.