Introduction¶
When engaging in agent conversations within DeepSeek Harness (DSH), reading long responses often requires staring at the screen. There are community SKILL-based approaches using Edge TTS, such as multilingual-tts-audio, which require running uv run --with edge-tts python ... every time. These approaches wait for the entire MP3 to finish writing and require manual triggering, causing a mismatch with the rhythm of the model’s output.
The following section introduces the plugin lemonhall/dsh-tts-reader (Maintainer: lemonhall, Category: Networking Tools): It resides within the DSH process, monitors the raw output stream from the model, fetches audio from Edge TTS sentence by sentence, and plays it continuously on the page via Web Audio. By default, it uses Xiaoyi (zh-CN-XiaoyiNeural) for narration and supports re-reading any historical response.
What is this¶
dsh-tts-reader is an injection-type plugin for the DSH Web client (meta.title in package.json is “Read Responses (Xiaoyi)”). The host side uses a zero-dependency Edge TTS client to synthesize MP3s, while the page side handles playback and toggles. It does not replace the DSH core; instead, it mounts routes via Cordis patches and listens for agent/assistant-stream.
Community Catalog Page: https://www.skillhub.cn/plugins/lemonhall/dsh-tts-reader (SkillHub is an independent plugin plaza and is not officially affiliated with DeepSeek or HFTC). Source Code & Documentation: https://github.com/lemonhall/dsh-tts-reader. The version in current materials is 0.1.0, License MIT.
Core Features¶
Two Entry Points, Two Queues¶
| Location | Function |
|---|---|
| Speaker icon to the right of the input box | Toggle for real-time narration of the entire session (Default On), status saved in localStorage |
| Speaker icon below each response | Located in the row with “Display / Copy / Like / Usage / Time”, Re-read this specific response; click again to stop |
Real-time narration and “Re-read specific item” are independent queues. Clicking re-read temporarily takes over the speaker; after finishing, it automatically reconnects real-time narration, continuing from the next sentence, without backfilling content missed during the interruption.
Data Path: Speak While Writing¶
When the model is still outputting, the plugin extracts text from the raw stream, earlier than the DOM:
agent/assistant-stream GET /dsh-tts/tail?session=…&since=…
(Raw text being written by model) (base64 MP3, fetched by sentence cursor)
│ ▲
▼ │
lib/index.js ──► lib/feed.js ──► lib/edge-tts.js
Host Side Sentence Queue Zero-dependency Edge TTS Client
│
Session.snapshotEvents() ────────────────┤
(Body text of a historical response) GET /dsh-tts/message?session=…&id=…&since=…
│ │
└──────────────► lib/feed.js ─────────┤
│
lib/client.js ──┘
Page Side: Seamless Web Audio Playback + Two Toggles
Synthesis is performed on the host side because the Edge TTS service requires a browser-like User-Agent for a WebSocket 101 upgrade, which cannot be customized via headers on the page side WebSocket. The page fetches via cursor every 400 ms; sessions without listeners will not trigger synthesis.
The text for re-reading a response comes from the stream (visible body text, excluding reasoning and tool calls) within assistant/message events found in ctx.sessions.get(id).snapshotEvents(). As long as the viewed session is alive in memory, the entire visible history is readable, regardless of when the plugin was installed.
What is Actually Read¶
The content read is colloquialized text, not the raw Markdown on the screen:
- Fenced code blocks are skipped entirely; inline code retains its literal value.
- Table cells are joined with “, “; separator rows are not read.
- Links only read the text; bare URLs are read as “link”.
- Titles, bold, quotes, list markers, etc., are removed.
- Reasoning processes and tool call arguments are not read.
Installation and Activation¶
The SkillHub catalog page does not provide a standalone dsh plugin ... one-liner command, but instead instructs the Harness to read the backend installation plan before execution. On the catalog page, use “Send to DeepSeek Harness to Install” or “Copy Install Prompt” to instruct the current DSH session regarding the plugin ID to install, for example:
Please install the DSH plugin lemonhall/dsh-tts-reader. Read the backend installation plan first before executing installation.
(Refer to the “Copy Install Prompt” on the catalog page for the full prompt.)
It is recommended to review the GitHub repository source code and the MIT License before installation. The plugin runs under the permissions of the current DSH process and will access the Edge TTS service via the network.
No additional commands are required after activation: the speaker icon to the right of the input box enables real-time narration by default. To disable the capability entirely on the host side, modify the configuration (see below); Do not use plugin_manager set_plugin to repeatedly toggle this plugin on and off—README testing shows that this results in a semi-broken state where routes remain but the agent/assistant-stream listener stops, causing real-time narration to silently fail. If you temporarily do not wish to listen, simply use the input box speaker toggle.
Configuration¶
Locate the config for the dsh-tts-reader entry in $DSH_HOME/profiles/desktop/cordis.patch.yml (The plugin does not export a Config schema; Cordis passes the entire config block to apply):
| Key | Default | Description |
|---|---|---|
enabled |
true |
Host-side master switch |
voice |
zh-CN-XiaoyiNeural |
Edge TTS short name, verified against the official voice catalog at startup |
rate / volume / pitch |
+0% / +0% / +0Hz |
Synthesis parameters |
maxPerRequest |
3 |
Maximum number of sentences returned per fetch |
After modifying lib/client.js, simply refresh the page (Ctrl+F5); modifying host modules like lib/index.js, lib/feed.js, lib/edge-tts.js requires restarting the application. The README notes: plugin_manager toggling cannot hot-reload the host side; changes to host code always require a restart expectation.
Typical Usage¶
- Normal Conversation: When the model streams output, Xiaoyi’s voice plays sentence by sentence by default.
- Temporarily Off: Click the speaker icon to the right of the input box; preference is written to
localStorage. - Re-listen to a Response: Click the speaker icon below that response; click again to stop. After re-reading finishes, real-time narration resumes from the next sentence.
- Change Voice or Speed: Modify
voice,rate,volume,pitchincordis.patch.ymland restart DSH to apply host configuration.
The maintainer provides self-test scripts within the repository (cases requiring network access must be able to reach Edge TTS):
cd E:\development\dsh-tts-reader
node test/feed.mjs # Sentence queue (purely offline)
node test/client-load.mjs # Client load (purely offline)
node test/host-e2e.mjs # Host end-to-end (requires network)
node test/smoke.mjs # Voice catalog + Synthesis + Text cleaning (requires network)
When debugging the host WebSocket, set the environment variable DSH_TTS_DEBUG=1 to print frame-level logs.
Use Cases and Caveats¶
Suitable for: Developers who wish to listen to responses hands-free within DSH Web conversations and can accept Edge TTS network synthesis; suitable for scenarios where one wants to listen while generation happens, rather than waiting for a whole MP3.
Notes:
- Depends on Edge online services; README records protocol details such as
User-Agent, SSML voice full names, and binary frame formats. When modifyinglib/edge-tts.jsyourself, cross-reference these descriptions to avoid 403s or silent disconnections. - Classified as a networking tool: confirm network policies and source code behavior before installation.
- Compared to SKILL solutions, the advantages lie in in-process residency, per-sentence streaming, and default following of assistant output; the trade-off is coupling to DSH plugins and Cordis deployment methods, rather than being an arbitrary Python script.
Conclusion¶
dsh-tts-reader reads assistant responses by default using Xiaoyi, queueing real-time streams and history re-reads separately, with host synthesis and page fetching/playback. It is suitable for listening while writing within DSH. For further information, visit the catalog page skillhub.cn/plugins/lemonhall/dsh-tts-reader and the GitHub repository github.com/lemonhall/dsh-tts-reader.