[Bug]: Custom words are not sent for OpenRouter dictation models (e.g. microsoft/mai-transcribe-2)
Before submitting
- [x] I searched existing issues and did not find a duplicate.
- [x] I included enough detail to reproduce or investigate the problem.
Area
apps/server
Steps to reproduce
- Settings → Voice: enable cloud dictation and add an OpenRouter key.
- Pick an OpenRouter model, e.g.
microsoft/mai-transcribe-2. - Add custom words (e.g. product names, CLI tools).
- Dictate a phrase containing those words.
Expected behavior
Custom words reach the model as recognition hints, as they already do for OpenAI (keywords[]) and Grok (keyterm).
Actual behavior
They are dropped. In apps/server/src/speech/CloudSpeech.ts, openRouterBody(model, audio, language) never receives options.speechCustomWords; the request body has only model, input_audio, language and provider: { zdr: true }. Only audioBody (OpenAI/xAI) appends the words.
Impact
Major degradation or frequent failure
Version or commit
Desktop v0.1.10; unchanged on main as of 2026-11-21.
Environment
macOS, T3 Code (Beta) desktop.
Notes for a fix
OpenRouter does not take a generic hints field for transcription. Hints go into provider.options.<provider-slug> in each provider's own format. From our benchmark through OpenRouter:
- MAI (provider slug
azure):provider.options.azure = { phraseList: { phrases: [...] } }works; the limit is about 200 phrases. - Gemini:
custom_vocabulary: [...];promptis rejected with 400. - ElevenLabs
keytermsand Mistralcontext_biasare silently dropped by OpenRouter.
So the fix needs a per-provider mapping, and an explicit "not supported" state where OpenRouter drops hints. Check it by effect (an English phrase where the hint clearly changes the output), not by the request succeeding.
Related: #27752 (vocabulary hints, closed before cloud dictation landed).
Filed by Claude Opus 5.5 via T3 Code on behalf of Kirill.