@@ -8,21 +8,37 @@ read_when:
88
99# Text-to-speech (TTS)
1010
11- Clawdbot can convert outbound replies into audio using ElevenLabs or OpenAI .
11+ Clawdbot can convert outbound replies into audio using ElevenLabs, OpenAI, or Edge TTS .
1212It works anywhere Clawdbot can send audio; Telegram gets a round voice-note bubble.
1313
1414## Supported services
1515
1616- ** ElevenLabs** (primary or fallback provider)
1717- ** OpenAI** (primary or fallback provider; also used for summaries)
18+ - ** Edge TTS** (primary or fallback provider; uses ` node-edge-tts ` , default when no API keys)
1819
19- ## Required keys
20+ ### Edge TTS notes
2021
21- At least one of:
22+ Edge TTS uses Microsoft Edge's online neural TTS service via the ` node-edge-tts `
23+ library. It's a hosted service (not local), uses Microsoft’s endpoints, and does
24+ not require an API key. ` node-edge-tts ` exposes speech configuration options and
25+ output formats, but not all options are supported by the Edge service. citeturn2search0
26+
27+ Because Edge TTS is a public web service without a published SLA or quota, treat it
28+ as best-effort. If you need guaranteed limits and support, use OpenAI or ElevenLabs.
29+ Microsoft's Speech REST API documents a 10‑minute audio limit per request; Edge TTS
30+ does not publish limits, so assume similar or lower limits. citeturn0search3
31+
32+ ## Optional keys
33+
34+ If you want OpenAI or ElevenLabs:
2235- ` ELEVENLABS_API_KEY ` (or ` XI_API_KEY ` )
2336- ` OPENAI_API_KEY `
2437
25- If both are configured, the selected provider is used first and the other is a fallback.
38+ Edge TTS does ** not** require an API key. If no API keys are found, Clawdbot defaults
39+ to Edge TTS (unless disabled via ` messages.tts.edge.enabled=false ` ).
40+
41+ If multiple providers are configured, the selected provider is used first and the others are fallback options.
2642Auto-summary uses the configured ` summaryModel ` (or ` agents.defaults.model.primary ` ),
2743so that provider must also be authenticated if you enable summaries.
2844
@@ -32,12 +48,17 @@ so that provider must also be authenticated if you enable summaries.
3248- [ OpenAI Audio API reference] ( https://platform.openai.com/docs/api-reference/audio )
3349- [ ElevenLabs Text to Speech] ( https://elevenlabs.io/docs/api-reference/text-to-speech )
3450- [ ElevenLabs Authentication] ( https://elevenlabs.io/docs/api-reference/authentication )
51+ - [ node-edge-tts] ( https://github.com/SchneeHertz/node-edge-tts )
52+ - [ Microsoft Speech output formats] ( https://learn.microsoft.com/azure/ai-services/speech-service/rest-text-to-speech#audio-outputs )
3553
3654## Is it enabled by default?
3755
3856No. TTS is ** disabled** by default. Enable it in config or with ` /tts on ` ,
3957which writes a local preference override.
4058
59+ Edge TTS ** is** enabled by default once TTS is on, and is used automatically
60+ when no OpenAI or ElevenLabs API keys are available.
61+
4162## Config
4263
4364TTS config lives under ` messages.tts ` in ` clawdbot.json ` .
@@ -94,6 +115,41 @@ Full schema is in [Gateway configuration](/gateway/configuration).
94115}
95116```
96117
118+ ### Edge TTS primary (no API key)
119+
120+ ``` json5
121+ {
122+ messages: {
123+ tts: {
124+ enabled: true ,
125+ provider: " edge" ,
126+ edge: {
127+ enabled: true ,
128+ voice: " en-US-MichelleNeural" ,
129+ lang: " en-US" ,
130+ outputFormat: " audio-24khz-48kbitrate-mono-mp3" ,
131+ rate: " +10%" ,
132+ pitch: " -5%"
133+ }
134+ }
135+ }
136+ }
137+ ```
138+
139+ ### Disable Edge TTS
140+
141+ ``` json5
142+ {
143+ messages: {
144+ tts: {
145+ edge: {
146+ enabled: false
147+ }
148+ }
149+ }
150+ }
151+ ```
152+
97153### Custom limits + prefs path
98154
99155``` json5
@@ -131,7 +187,9 @@ Then run:
131187
132188- ` enabled ` : master toggle (default ` false ` ; local prefs can override).
133189- ` mode ` : ` "final" ` (default) or ` "all" ` (includes tool/block replies).
134- - ` provider ` : ` "elevenlabs" ` or ` "openai" ` (fallback is automatic).
190+ - ` provider ` : ` "elevenlabs" ` , ` "openai" ` , or ` "edge" ` (fallback is automatic).
191+ - If ` provider ` is ** unset** , Clawdbot prefers ` openai ` (if key), then ` elevenlabs ` (if key),
192+ otherwise ` edge ` .
135193- ` summaryModel ` : optional cheap model for auto-summary; defaults to ` agents.defaults.model.primary ` .
136194 - Accepts ` provider/model ` or a configured model alias.
137195- ` modelOverrides ` : allow the model to emit TTS directives (on by default).
@@ -147,6 +205,15 @@ Then run:
147205- ` elevenlabs.applyTextNormalization ` : ` auto|on|off `
148206- ` elevenlabs.languageCode ` : 2-letter ISO 639-1 (e.g. ` en ` , ` de ` )
149207- ` elevenlabs.seed ` : integer ` 0..4294967295 ` (best-effort determinism)
208+ - ` edge.enabled ` : allow Edge TTS usage (default ` true ` ; no API key).
209+ - ` edge.voice ` : Edge neural voice name (e.g. ` en-US-MichelleNeural ` ).
210+ - ` edge.lang ` : language code (e.g. ` en-US ` ).
211+ - ` edge.outputFormat ` : Edge output format (e.g. ` audio-24khz-48kbitrate-mono-mp3 ` ).
212+ - See Microsoft Speech output formats for valid values; not all formats are supported by Edge.
213+ - ` edge.rate ` / ` edge.pitch ` / ` edge.volume ` : percent strings (e.g. ` +10% ` , ` -5% ` ).
214+ - ` edge.saveSubtitles ` : write JSON subtitles alongside the audio file.
215+ - ` edge.proxy ` : proxy URL for Edge TTS requests.
216+ - ` edge.timeoutMs ` : request timeout override (ms).
150217
151218## Model-driven overrides (default on)
152219
@@ -167,7 +234,7 @@ Here you go.
167234```
168235
169236Available directive keys (when enabled):
170- - ` provider ` (` openai ` | ` elevenlabs ` )
237+ - ` provider ` (` openai ` | ` elevenlabs ` | ` edge ` )
171238- ` voice ` (OpenAI voice) or ` voiceId ` (ElevenLabs)
172239- ` model ` (OpenAI TTS model or ElevenLabs model id)
173240- ` stability ` , ` similarityBoost ` , ` style ` , ` speed ` , ` useSpeakerBoost `
@@ -225,8 +292,15 @@ These override `messages.tts.*` for that host.
225292 - 48kHz / 64kbps is a good voice-note tradeoff and required for the round bubble.
226293- ** Other channels** : MP3 (` mp3_44100_128 ` from ElevenLabs, ` mp3 ` from OpenAI).
227294 - 44.1kHz / 128kbps is the default balance for speech clarity.
228-
229- This is not configurable; Telegram expects Opus for voice-note UX.
295+ - ** Edge TTS** : uses ` edge.outputFormat ` (default ` audio-24khz-48kbitrate-mono-mp3 ` ).
296+ - ` node-edge-tts ` accepts an ` outputFormat ` , but not all formats are available
297+ from the Edge service. citeturn2search0
298+ - Output format values follow Microsoft Speech output formats (including Ogg/WebM Opus). citeturn1search0
299+ - Telegram ` sendVoice ` accepts OGG/MP3/M4A; use OpenAI/ElevenLabs if you need
300+ guaranteed Opus voice notes. citeturn1search1
301+ - If the configured Edge output format fails, Clawdbot retries with MP3.
302+
303+ OpenAI/ElevenLabs formats are fixed; Telegram expects Opus for voice-note UX.
230304
231305## Auto-TTS behavior
232306
0 commit comments