From 9fe7479ddc935390b748374f73d9b09288e87a2a Mon Sep 17 00:00:00 2001 From: Vuong Hoang Date: Wed, 12 Aug 2026 17:31:04 -0700 Subject: [PATCH] fix(gateway-chat): honor UI endpoint/model/voice for TTS + standard-audio playback The TTS path was hardwired to the parked zonos-gateway: it force-reverted the endpoint field back to zonos :8890 on load, hardcoded model=ext-tts, and decoded the response as Zonos-specific raw float32 PCM @ 44.1kHz. Result: quoted-text TTS was dead once zonos was parked, and pointing the field elsewhere silently failed. - Honor the interface: set endpoint/model/voice defaults only when a field is empty; never rewrite a user-typed value (removed the zonos auto-revert regex). - Add a TTS model field (ttsModel); send the UI's model instead of hardcoding. - Playback: request standard OpenAI /v1/audio/speech mp3 and decode via audioCtx.decodeAudioData (handles wav/mp3/ogg/flac from any endpoint). - Defaults: endpoint = LiteLLM ext-tts alias (fleet TTS gateway), voice = nova. --- stacks/gateway-chat/conf/index.html | 80 +++++++++++++++-------------- tools/gateway-chat.html | 78 +++++++++++++--------------- 2 files changed, 76 insertions(+), 82 deletions(-) diff --git a/stacks/gateway-chat/conf/index.html b/stacks/gateway-chat/conf/index.html index 69337b4..e575e44 100644 --- a/stacks/gateway-chat/conf/index.html +++ b/stacks/gateway-chat/conf/index.html @@ -67,11 +67,12 @@
- + - - -
Settings persist locally. No tools field is ever sent. Reasoning models show their reasoning_content above the answer. With 🔊 on, quoted text in each reply auto-plays via mOrpheus (irv-ml1, internal).
+ + + +
Settings persist locally. No tools field is ever sent. Reasoning models show their reasoning_content above the answer. With 🔊 on, quoted text auto-plays via the endpoint + model + voice set above (OpenAI /v1/audio/speech, mp3).
@@ -85,11 +86,15 @@