Skip to content

fix(desktop): wire Ctrl+B voice, declutter voice settings, stop endless TTS hang - #52187

Merged
OutThisLife merged 1 commit into
mainfrom
bb/desktop-voice
Jun 25, 2026
Merged

OutThisLife merged 1 commit into
mainfrom
bb/desktop-voice

Conversation

@OutThisLife

Copy link
Copy Markdown
Contributor

Summary

Three voice-mode bugs in the desktop app:

1. Ctrl+B never triggered voice

The voice docs and the voice.record_key setting (default ctrl+b) advertise Ctrl+B to talk, but the desktop app never bound it — ⌘B/Ctrl+B only toggled the sidebar. Added a rebindable composer.voice keybind that toggles the voice conversation:

  • macOS: defaults to ⌃B (literal Control+B), distinct from the ⌘B sidebar toggle — matches the docs exactly.
  • Windows/Linux: ctrl folds into the mod accelerator, which is the long-standing sidebar chord, so it ships unbound there (assignable in the shortcuts panel) rather than hijacking the sidebar.

The global keybind reaches the composer (which owns the voice state) via a new requestVoiceToggle() focus-bus event. Starting with STT unconfigured surfaces the existing "configure speech-to-text" notice instead of silently no-opping.

2. The Voice settings page was a wall of fields

Every TTS/STT provider's options rendered simultaneously (~30 rows), so setting "edge free" was buried in OpenAI/ElevenLabs/xAI/MiniMax/… fields. Now only the selected provider's sub-fields show (voiceFieldVisible), and STT provider fields hide when STT is disabled — making it clear that voice chat needs both a TTS provider and STT enabled.

3. Voice mode hung "speaking" forever

Free Edge TTS occasionally returns audio that never fires playing/ended/error, so playSpeechText's playback promise never settled and the conversation stuck in speaking. Added a stall watchdog — rearmed on every timeupdate, so legitimately long speech is never cut off — that rejects a stuck stream so the loop recovers with a clear error.

Test plan

  • vitest run apps/desktop/src/app/settings/voice-field-visible.test.ts (new) — provider filter incl. STT-disabled + provider-switch cases.
  • tsc -p apps/desktop --noEmit
  • eslint on changed files (no new issues).
  • Manual (macOS): ⌃B starts/stops a voice conversation; shortcuts panel shows it and lets you rebind.
  • Manual: Voice settings shows only the selected provider's fields and reacts to switching providers / toggling STT.
  • Manual: a wedged Edge TTS response ends the turn instead of spinning forever.

…ss TTS hang

Three voice-mode papercuts in the desktop app:

1. Ctrl+B did nothing. The docs + `voice.record_key` advertise Ctrl+B to
   talk, but the desktop never bound it (only ⌘B = sidebar existed). Add a
   rebindable `composer.voice` action that toggles the voice conversation,
   defaulting to ⌃B on macOS (distinct from ⌘B; off-macOS `ctrl` folds to
   the sidebar chord, so it ships unbound there to avoid stealing it). The
   global keybind reaches the composer through a new focus-bus event.

2. The Voice settings page rendered every provider's options at once (~30
   fields). Filter to the *selected* TTS/STT provider's sub-fields; STT
   provider fields hide when STT is off. Picking "edge" now shows just the
   Edge voice, making it obvious voice chat also needs STT enabled.

3. Voice mode could hang "speaking" forever. Free Edge TTS sometimes returns
   audio that never fires `playing`/`ended`/`error`, so the playback promise
   never settled. Add a stall watchdog (rearmed on each progress tick, so
   long speech is never cut off) that rejects a stuck stream, letting the
   loop recover with a clear error.
@alt-glitch alt-glitch added type/bug Something isn't working comp/desktop Electron desktop app (apps/desktop/*) tool/tts Text-to-speech and transcription P3 Low — cosmetic, nice to have labels Jun 24, 2026
@OutThisLife
OutThisLife merged commit 70650e8 into main Jun 25, 2026
21 checks passed
@OutThisLife
OutThisLife deleted the bb/desktop-voice branch June 25, 2026 00:03
waefrebeorn pushed a commit to waefrebeorn/slermes that referenced this pull request Jul 2, 2026
fix(desktop): wire Ctrl+B voice, declutter voice settings, stop endless TTS hang
habarmc1223-sudo pushed a commit to habarmc1223-sudo/hermes-agent-fluxmem that referenced this pull request Jul 8, 2026
fix(desktop): wire Ctrl+B voice, declutter voice settings, stop endless TTS hang
santhreal pushed a commit to santhreal/hermes-agent that referenced this pull request Jul 13, 2026
fix(desktop): wire Ctrl+B voice, declutter voice settings, stop endless TTS hang
Gravezzz pushed a commit to Gravezzz/hermes-agent that referenced this pull request Jul 21, 2026
fix(desktop): wire Ctrl+B voice, declutter voice settings, stop endless TTS hang
leewenjie pushed a commit to leewenjie/hermes-agent that referenced this pull request Aug 7, 2026
fix(desktop): wire Ctrl+B voice, declutter voice settings, stop endless TTS hang
melon-xf added a commit to melon-xf/hermes-agent that referenced this pull request Sep 3, 2026
fix(desktop): wire Ctrl+B voice, declutter voice settings, stop endless TTS hang
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/desktop Electron desktop app (apps/desktop/*) P3 Low — cosmetic, nice to have tool/tts Text-to-speech and transcription type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants