Introduction

The DSH plugin ecosystem allows adding Web page capabilities as plugins. When doing listening and speaking practice, text replies are often insufficient: replies need to be suitable for reading aloud, conversations need to be read out, and users also need to input via microphone. dsh-voice-by-edge is a speech interaction practice plugin for DSH Web pages. Below is an introduction of its features, installation, enabling methods, and precautions.

What is this

dsh-voice-by-edge provides a speech interaction practice mode for DSH Web pages, including bilingual conversational replies, Text-to-Speech (TTS), and Speech-to-Text (STT).

The GitHub repository address is:

https://github.com/astr0mfly/dsh-voice-by-edge

The license is MIT. The documentation does not provide an explicit maintainer field; the owner in the repository URL is astr0mfly.

Core Features

This plugin adds the following capabilities to the DSH Web dialog box:

  1. Added a switch for the speech interaction mode
  2. Once enabled, the model responds in the target language using short, conversational sentences
  3. The browser automatically reads the conversation content, supporting the selection of corresponding voices for Chinese and English segments
  4. Supports microphone voice input (STT), with recognition results filled into the input box in real-time and capable of automatic sending
  5. Uses Microsoft Edge Neural Voices (edge-tts) for TTS synthesis, falling back to the browser’s local speechSynthesis if unreachable
  6. Provides features such as read-along playback, language selection, auto-read, shadowing playback, auto-send, speed adjustment, and stop control
  7. The server injects speech practice prompts into sessions that have the mode enabled

Installation and Enabling

First, execute the installation command. The command pins a specific commit:

dsh plugin --profile web add "github:astr0mfly/dsh-voice-by-edge#c2b51e1bc643687b4cbf53d4cc258a211ecf5f1b"

On the first installation, if pnpm intercepts the msedge-tts build script, first modify ~/.dsh/profiles/web/pnpm-workspace.yaml and change allowBuilds.msedge-tts to true, then re-execute the add command above. Confirm that it looks like this:

allowBuilds.msedge-tts: true

If you encounter ERR_PNPM_IGNORED_BUILDS, check if you have completed the build script permission step.

This plugin is handled as a bundle plugin; after installation, you need to restart DSH Web. You can use the following command to verify that the voice-by-edge layer is active:

dsh --profile web --dump-config

Typical Usage

Once enabled, simply operate according to browser permissions and network conditions.

  1. Use Chrome / Edge to open DSH Web
  2. Enable the speech interaction mode in the dialog box
  3. Select the practice language
  4. Turn on auto-read, or use read-along for individual replies
  5. Click the microphone button and allow browser microphone permissions
  6. The voice recognition results will be filled into the input box in real-time and can be sent automatically
  7. The speed can be adjusted within the range of 0.75×–1.5×, or you can use stop control

TTS synthesis requires access to the Microsoft Edge Voice Service. The synthesis results are cached in:

~/.dsh/cache/voice-by-edge/

When the Microsoft Edge Voice Service is unreachable, it falls back to the browser’s local speechSynthesis.

Applicable Scenarios and Notes

This plugin is suitable for users who need to use conversational dialogue, reading aloud, and microphone input within the same DSH Web session. Note the following limitations:

  • STT relies on the browser Web Speech API; voice input requires Chrome / Edge and microphone permission. If the browser does not support it, the microphone button will display a prompt.
  • Under Chrome, voice recognition requires HTTPS or localhost.
  • TTS relies on network access to the Microsoft Edge Voice Service; it falls back to the browser’s local speechSynthesis if unreachable.
  • Mode state is only stored in browser and server memory; you need to re-enable the mode after restarting DSH.
  • Prompt injection only affects sessions where the mode is enabled and does not modify history records.
  • TTS has a voice whitelist check.
  • The plugin runs with the permissions of the current DSH process; you should check the source code and license before installation. The license provided in this documentation is MIT; the repository URL is mentioned above.

Conclusion

dsh-voice-by-edge concentrates speech interaction mode, TTS reading, and STT input into the DSH Web dialog box. The DSH community directory is a separate site; this documentation does not provide the directory page URL, so a specific directory link is not provided. The GitHub repository is:

https://github.com/astr0mfly/dsh-voice-by-edge