ldchaowin/dsh-plugin-notify-sound
notify sound for DeepSeek harness
已收录
2
Voice
Bundle 已验证
预览
功能介绍
按工作区定制的任务完成铃声,以及审批、提问、计划评审、目标受阻、任务失败等需要人介入事件的注意提示音,支持内置合成音、语音播报与自定义音频。
适合
- 会暂时离开长时间运行的 DSH Web 任务、需要完成提示音的用户。
- 希望为不同工作区设置不同完成铃声的多工作区用户。
- 包含审批、提问、计划评审、目标受阻或后台任务失败,并需要及时人工介入的工作流。
不适合
- 无头工作流,或浏览器音频与 TTS 不可用或被刻意静音的环境。
- 需要跨浏览器或设备同步通知设置的用户;当前配置保存在浏览器 localStorage 中。
- 不支持 bundle 插件或不具备文档所列 pnpm 前置条件的 DSH 安装。
README
dsh-plugin-notify-sound
| English | 中文 |
A DeepSeek Harness (DSH) plugin for the Web UI: play a customizable ringtone when a task finishes — per workspace — and an attention sound whenever something needs a human.
Features
Completion sounds (per workspace)
- Plays when a session turn finishes (
running: true → false) or a background job completes. - The sound is resolved per workspace: a workspace-specific override wins, otherwise the default.
- Three sound sources:
- Built-in synthesized sounds — 6 options (Ding / Chime / Bell / Complete / Success / Mute), generated live with Web Audio, no audio files required.
- Voice announcement (TTS) — the browser speaks a custom phrase (e.g. “我做完啦!”, “All done!”) using a system Chinese voice; voice and rate are configurable.
- Custom audio — upload any MP3/WAV/etc. file.
Attention sounds (when a human is needed)
The following events always ring (they are not affected by the “quiet current session” option):
| Event | Detection | Default sound |
|---|---|---|
| Approval request | session pendingInteraction: approval
|
generic attention sound |
| User question | pendingInteraction: question |
generic attention sound |
| Plan review | pendingInteraction: plan-review |
generic attention sound |
| Goal blocked | goal projection enters blocked
|
generic attention sound |
| Background task failure | job status failed
|
Bell (dedicated failure sound) |
Each kind can override the generic attention sound, or use a shared TTS phrase (e.g. “需要你的确认” / “Your confirmation is needed”).
Settings panel (Settings → 通知铃声 / Notification Sounds)
Master switch, “quiet when viewing the current session”, default completion sound, per-workspace completion sounds, generic + per-kind attention sounds, voice settings (voice / rate / preview / refresh), per-row preview and custom-audio upload.
Install
Requires a DSH version with bundle-plugin support (dsh.profile.bundles + dsh.bundle.patch)
and pnpm on PATH (corepack enable or npm i -g pnpm).
# One command: pnpm installs the package and adds it to the profile's bundle layer
dsh plugin --profile web add dsh-plugin-notify-sound
# Restart the server (or refresh the page), then open Settings → 通知铃声
Other profiles work the same way: dsh plugin --profile <name> add dsh-plugin-notify-sound.
Manual install (without pnpm)
- Copy this package and its runtime deps (
@deepseek-ai/schemastery,@deepseek-ai/cosmokit,@standard-schema/spec) into$DSH_HOME/profiles/web/node_modules/. - Append
"dsh-plugin-notify-sound"todsh.profile.bundlesin$DSH_HOME/profiles/web/package.json. - Restart
dsh web.
Configuration storage
- The browser half persists its configuration in localStorage (key
dsh-notify-sound:config), sanitizing every read and filling defaults. - The host half also registers the
dsh-plugin-notify-soundsettings namespace: on rc.6 the settings API allowlist (WEB_SETTINGS_NAMESPACESindsh-host-apiproxy) does not expose third-party namespaces to browsers, so the client does not depend onsettingsScopetoday; the registration keeps the migration path open for future releases.
Development
npm test # 50+ assertions across host and client halves (Node only, no browser needed)
npm run check # syntax check
Layout:
-
lib/index.js— host half: registers the settings namespace (schema + defaults) -
lib/client.js— browser bundle: completion/attention event detection, sound engine (Web Audio / TTS / Audio), settings panel -
lib/types/index.d.ts— host-side type declarations -
cordis.patch.yml— bundle patch layer (inserts thenotify-soundrow) -
tools/— tests and verification scripts (not shipped in the npm package)
Publish
npm login # npm account (2FA recommended)
npm publish --access public
License
常见问题常见问题
在启用了 DSH 的终端中执行已验证命令 dsh plugin --profile default add github:ldchaowin/dsh-plugin-notify-sound。命令会解析公开 package 元数据,并保持插件与本页展示的目录身份一致。
兼容性以页面上展示的 bundle 与 profile 状态为准。如果某个 profile 尚未检测到,请先保持禁用,并在生产启用前阅读仓库文档。
GitHub 链接和 activity 元数据是 release 与维护状态的来源。新版本发布后重新查看本页,确认目录已经观察到最新版本。