haoku123/dsh-voice
haoku123★ 0JavaScriptLast synced: 2026-08-15
Full-duplex voice mode for DeepSeek Harness: streamed ASR → LLM → TTS with barge-in. Local whisper transcription, Edge TTS playback, zero API key.
README excerpt
dsh-voice Full-duplex voice mode for DeepSeek Harness: streamed ASR → LLM → TTS with barge-in. Status v0.4.0 — barge-in complete. The full voice loop is wired end to end. Speak into the composer mic: the assistant silences itself (playback stops, host synthesis queue drops), the running turn is cancelled (the stop-button route), and your speech is transcribed locally and submitted. The reply streams back as spoken audio with live captions. Known limitation: barge-in detection is triggered by the mic's leading speech edge, which relies on browser-level echo cancellation ( getUserMedia({ echoCancellation: true }) ). Loud TTS playback may leak into the mic on some platforms; there is no JS-level AEC. Demo The loop: a user prompt streams back as spoken audio sentence-by-sentence, then the user's voice interrupts playback and stops the running turn mid-reply (true barge-in). The mic keeps recording the new speech. How it works - The llm/stream tap is lossless : every chunk is yielded unchanged, the segmenter only observes. The model stream is never blocked by synthesis. - ASR runs fully locally in the browser: transformers.js loads from a CDN via a native dynamic import (kept intact by …
View full README on GitHub →