Pronunciation

Manage the global pronunciation dictionary of a speaker. Entries saved here apply to every future request for that speaker, unlike the per-request custom_pronunciations field on inference calls.

Per-request overrides

Include custom_pronunciations in any generate or stream request:

"custom_pronunciations": {
  "words": { "computer": "compyuter" },
  "phonemes": {}
}

Add word pronunciation

POSThttps://api.lucidweights.ai/v1/tts/pronunciation/{speaker}/words
FieldTypeDefaultDescription
wordstringrequiredThe original word to replace
pronunciationstringrequiredReplacement string
languagestringrequiredISO 639-1 language code
Example
curl -X POST "https://api.lucidweights.ai/v1/tts/pronunciation/emily/words" \
  -H "x-api-key: lw_YOUR_SECRET" \
  -H "Content-Type: application/json" \
  -d '{"word":"computer","pronunciation":"compyuter","language":"en"}'

Add phoneme pronunciation

POSThttps://api.lucidweights.ai/v1/tts/pronunciation/{speaker}/phonemes
FieldTypeDefaultDescription
phonemestringrequiredOriginal phoneme to replace
replacementstringrequiredReplacement phoneme
languagestringrequiredISO 639-1 language code

Delete word pronunciation

DELETEhttps://api.lucidweights.ai/v1/tts/pronunciation/{speaker}/words/{word}

Query param language (default en).

Delete phoneme pronunciation

DELETEhttps://api.lucidweights.ai/v1/tts/pronunciation/{speaker}/phonemes/{phoneme}

Query param language (default en).