The voice bridge sent a fixed whisper-1 for every ASR request, ignoring
the user's picked engine. Now it forwards the configured voice_to_text_model
(empty means let the gateway pick its default). Also expose default/doubao/
whisper-1/baidu as ASR options and fix the empty 'default' option rendering
blank in both the web console and the desktop app.
Co-authored-by: cowagent <cow@cowagent.ai>
ModelsHandler was 2.3k lines, a third of what was left in web_channel.py
and the largest handler in the console by a wide margin. Both are pure
moves; the modules take only the imports their code actually reaches for.
They are re-exported from web_channel.py because build_app() resolves the
URL table against that module's globals, which is also why the tests can
keep importing them from there. What could not stay is the patch targets:
patching channel.web.web_channel.conf no longer reaches a handler that
reads conf out of its own module, so those tests now name the module the
handler actually lives in.
Co-authored-by: cowagent <cow@cowagent.ai>
The web stub is installed only when web.py is not already imported, so in a
full run these handlers resolved the real header() and died without a
request context; patching the name the handler uses makes them independent
of what ran first. The routing case builds its model via __new__, so it
also needed the per-session override fields __init__ would have set.
Dropped the deepseek-chat assertion: a6eb7843 removed it from the dropdown
deliberately, and the non-v4 path it guarded is covered by the case that
sets that model as the active one.
Co-authored-by: Cursor <cursoragent@cursor.com>
- Desktop chat input gets a mic button (matching the web console): record
via MediaRecorder, transcribe through /api/voice/asr, and fill the
recognized text into the input box
- ASR/TTS capability cards list user-created custom vendors: expand
custom:<id> cards in _asr_capability/_tts_capability and accept them as
the current TTS provider
- Route custom vendors at runtime via CustomVoice (OpenAI-compatible
/audio/transcriptions and /audio/speech) using the vendor's own
credentials; voice factory now handles custom / custom:<id>
- Desktop Models tab: ASR card allows a custom model name; TTS card gets
a free-form model input for custom vendors
- Desktop Models tab regression: seed the free-form model input with the
saved model so custom-vendor model names are visible again
Closes#3050