Skip to content

v0.19.0

Release date: 2026-11-13

This release lets a synthesis request say how particular terms are pronounced, such as foreign names. Each pronunciation can carry the term's IPA and a respelling; the provider uses the IPA where its voice or model accepts phonemes, and the respelling otherwise, so the same request works with every provider.

Highlights

  • Pronunciations on requests — SynthesisConfig.Pronunciations carries each term's IPA and respelling
  • One shared rewriter — tts.ApplyPronunciations writes SSML phoneme elements or substitutes respellings, so providers behave alike
  • Terms to pronunciations — terminology.PronunciationsFor turns terminology-spec terms into a request's pronunciations for one locale

Added

Pronunciations (tts/)

  • Pronunciation, with Term, IPA and Respelling
  • SynthesisConfig.Pronunciations
  • ApplyPronunciations(text, pronunciations, phonemes):
  • with phonemes true, a term with IPA becomes <phoneme alphabet="ipa" ph="…">Term</phoneme>, keeping the text's own spelling;
  • otherwise, or without IPA, the respelling replaces the term;
  • terms match whole words in any script, ignoring case, longest first, with a shorter term used where a longer one isn't a whole word ("New" in "New Yorkshire"), and rewritten text is never matched again;
  • only the inserted element is XML-escaped.
cfg := tts.SynthesisConfig{
    VoiceID: voiceID,
    Pronunciations: []tts.Pronunciation{
        {Term: "Lamborghini", IPA: "lamborˈɡiːni", Respelling: "lambor gheeny"},
        {Term: "Miura", IPA: "ˈmjura"},
    },
}

Terminology (terminology/)

  • PronunciationsFor(terms, locale) returns each term's IPA and respelling for the locale, for its canonical form and every alias, leaving out terms with neither:
cfg.Pronunciations = terminology.PronunciationsFor(terms, "en-US")

Documentation

Provider Support

Providers apply Pronunciations in their releases built on omnivoice-core v0.19.0. elevenlabs-go v0.15.0 sends IPA as phoneme tags on the models that honour them and respellings on the others. Providers that don't support pronunciations ignore the field.

Dependencies

  • Requires github.com/plexusone/terminology-spec v0.2.0, which adds Term.IPA.

Compatibility

No breaking changes. Pronunciations is optional, and requests without it are unchanged.