Introduction¶
Building agents in DeepSeek Harness (DSH) works fine with text chat, but once you want to “listen while talking,” stream responses, or interrupt at any time, common approaches usually involve external cloud voice APIs, running a separate Python service, or occupying extra ports. These paths increase dependencies, latency, and privacy boundaries, and are inconsistent with DSH’s philosophy of “everything as a plugin” and keeping logic within the host.
Below is an introduction to the community plugin dsh-plugin-voice-local (maintainer: god1sdfghjkl, category: Model Inference): TTS and ASR inference runs within the host process; it does not spawn independent processes, does not use extra ports, and does not use cloud voice APIs by default; routing is loopback only. Clicking the microphone entry next to the input box allows you to chat with DSH in a fullscreen call interface.
What is it¶
dsh-plugin-voice-local is a local streaming voice plugin for DSH: pluggable ONNX TTS + sherpa-onnx ASR, running inference within the host via worker threads; optionally connects to BreezeBlue streaming TTS or DSH’s official speechToText. Current package version 0.9.20 (MIT License), requires DSH >=0.2.0 <0.3.0-0 and Node >=20 (desktop version 0.2.2-rc.1 tested according to README).
- Directory: https://www.skillhub.cn/plugins/god1sdfghjkl/dsh-plugin-voice-local
- Source & Docs: https://github.com/god1sdfghjkl/dsh-plugin-voice-local
Core Features¶
Full-Duplex Call & Interface¶
The fullscreen call interface supports: speaking -> pausing for approx. 0.9s for auto-send -> receiving streaming subtitles + voice playback -> interrupting during playback (barge-in). When not in fullscreen, there is a small voice bar next to the input box where you can view levels, subtitles, and end the session. The interface provides 7 background themes (4 dark, 3 light), with responsive adaptation for desktop, narrow windows, and mobile browsers.
During calls, “normal person” speaking rules (colloquialisms, short sentences, etc.) can be automatically injected; it reverts to the default written style after hanging up. The configuration callPersona: false can disable this behavior.
Local Inference & Model Management¶
TTS and ASR are managed via a model registry: placing models in the designated directory makes them appear in the dropdown, supporting hot switching without restarting the host. Models are not distributed with the npm package; the detection order is: configured path -> environment variable -> dataRoot (default $DSH_HOME/voice-local) -> standalone project directory.
On first launch, if no TTS is available and autoDownloadModels is enabled, the example voice tl196m declared in the package will be automatically downloaded (approx. 161MB, segmented download + SHA256 verification). The model downloader in the interface supports resuming .part files and retrying on failure.
When only ASR is configured, the plugin degrades to voice input without reading back replies; when only TTS is configured, manual playback testing can be performed.
Optional Capabilities¶
| Capability | Configuration Points |
|---|---|
| BreezeBlue Streaming TTS | ttsProvider: "breeze", configure API Key / voice_id; falls back to local TTS if no key. |
| Auto Emotion (Breeze) | breezeAutoEmotion; optional breezeSmartEmotion to generate performance instructions per sentence using the main model. |
| DSH Official ASR | asrProvider: "dsh", uses official speechToText (finalizes the whole sentence, but this plugin still outputs streaming text by default). |
| Voiceprint Lock | voiceprintEnabled; embeddings are stored locally, can restrict answering only to registered voices. |
| LLM Streaming Playback | Default llmTap: true, tap llm/stream to auto-play. |
Local-first: models, audio, and text do not leave the machine by default; routing is loopback only with Origin checks.
Installation & Activation¶
While the npm package is being prepared, you can download the tarball from GitHub Releases. After upgrading the plugin, you need to refresh the host page (F5) to load the new client bundle; the host side updates automatically.
Method A: DSH Settings Page (Recommended)
Settings -> Plugins -> Install dsh-plugin-voice-local-<version>.tgz from local path / tarball, then refresh the page. A microphone entry should appear to the right of the input box.
Method B: CLI
dsh plugin --profile <profile> add ./dsh-plugin-voice-local-0.9.20.tgz
# Or from npm (after release)
dsh plugin --profile <profile> add dsh-plugin-voice-local
Refresh the DSH page after installation. Clicking the microphone for the first time will request microphone permissions; it is recommended to configure at least one TTS or streaming ASR model (both configured provides the most complete experience).
Model Directory¶
The default data root is $DSH_HOME/voice-local, which can be overridden by the environment variable VOICE_DATA_ROOT or the configuration dataRoot. The typical structure is as follows:
$DSH_HOME/voice-local/
└── models/
├── tts/
│ └── melo-zh/
│ ├── model.json
│ ├── model.onnx
│ ├── tokens.txt
│ └── lexicon.txt
└── asr/
├── streaming/<id>/
└── final/<id>/
Each model subdirectory can contain model.json to declare the engine type, download manifest, etc.; fields can be omitted and auto-detected by filename. Model weight licenses are separate from the MIT code; please verify the license for each model before redistribution (see THIRD_PARTY_NOTICES.md and docs/models.md in the repository).
Configuration Summary¶
Adjust behavior in the config section of cordis.patch.yml. Common items example:
| Key | Default | Description |
|---|---|---|
basePath |
/voice-local |
Route prefix |
dataRoot |
$DSH_HOME/voice-local |
Model data root |
autoStart |
true |
Warm up models on load |
autoDownloadModels |
true |
Auto-download example model if no TTS available |
vadThreshold |
0.012 |
Voice activity detection threshold |
autoEndSilenceMs |
900 |
How long to pause before auto-submitting |
bargeIn |
true |
Allow interrupting during playback |
ttsProvider |
local |
local or breeze |
asrProvider |
local |
local or dsh |
llmTap |
true |
Auto-play LLM streaming output |
Breeze-related keys are recommended to be saved via the “Voice API Settings” in the interface to avoid writing them into the repository config file.
Typical Usage¶
- Install and refresh the page as per the previous section, confirming the microphone entry is visible.
- Wait for the first auto-download to complete, or select/download TTS and streaming ASR from the “Models” dropdown in the top bar.
- Click the microphone to enter fullscreen call mode: speak, pause briefly for auto-send; listen to streaming subtitles and playback, interrupt if needed.
- The top bar can switch background themes and models; voiceprint functions are registered and debugged in the “Voiceprint” panel.
- Minimizing (using
—orEsc) does not interrupt the call; hanging up ends voice mode.
When only ASR is configured, it acts as voice input; to test playback, configure only TTS.
Use Cases & Notes¶
Who is it for: Developers who want to complete local or semi-local voice dialogue within DSH, emphasize data staying on the machine, and do not want to start an extra voice microservice; scenarios requiring full-duplex, streaming subtitles, and optional cloud TTS enhancement.
Must note:
- The plugin runs with the current DSH process permissions; read the source code and MIT license before installing, and separately verify the license of the model weights used.
- Voiceprint, microphone, and local routing remain sensitive capabilities; please assess the risks yourself in production or shared environments.
- The DSH community directory (e.g., SkillHub) is an independent site with no official affiliation with DeepSeek or Hypersphere; this plugin is a community-maintained work.
- Requires DSH 0.2.x and Node 20+; if inconsistent with the README environment table, refer to the repository documentation.
Conclusion¶
dsh-plugin-voice-local brings ONNX TTS, sherpa-onnx streaming ASR, and call UI into the DSH host, defaults to local, loopback routing, and retains optional extensions like Breeze, official ASR, and voiceprint. If you are building an agent on DSH 0.2 that needs to “speak and listen,” you can install the tarball from Releases, configure $DSH_HOME/voice-local/models/, and start by clicking the microphone.
- Directory: https://www.skillhub.cn/plugins/god1sdfghjkl/dsh-plugin-voice-local
- GitHub: https://github.com/god1sdfghjkl/dsh-plugin-voice-local