How Modern TTS Handles Text Normalization
Modern Text-to-Speech (TTS) front-ends rely on text normalization to convert written non-standard words (NSWs)—such as dates, currencies, and abbreviations—into spoken phonetic text. Because ambiguous text like "$20" or "St." cannot be fed directly into acoustic models without causing speech errors, modern pipelines use a combination of rule-based grammars, contextual classification, and neural sequence-to-sequence models to detect, disambiguate, and verbalize these expressions accurately.
The Challenge of Non-Standard Words
Written language heavily relies on semiotic tokens that do not reflect their spoken phonetics:
- Dates: "03/04/2024" can mean "March fourth, twenty twenty-four" or "the third of April, twenty twenty-four," depending on locale and context.
- Currencies: "$10.50" requires reordering symbols and numbers into "ten dollars and fifty cents" rather than "dollar ten point fifty."
- Abbreviations and Homographs: "St." might represent "Street" or "Saint," while "Dr." could mean "Doctor" or "Drive."
Failing to normalize these correctly leads to unnatural cadence, semantic misunderstanding, or outright acoustic breakdown during synthesis.
Two-Step Pipeline: Classification and Verbalization
To handle NSWs, modern TTS front-ends generally split text normalization into two distinct sub-tasks:
- Token Classification (Semiotic Tagging): The raw
text is tokenized, and each token is labeled with its semiotic class
(e.g.,
DATE,MONEY,TELEPHONE,PLAIN). For example, in the sentence "Meet at 20 St. John St. on 05/12," the system identifies the first "St." as a title (Saint), the second "St." as an address suffix (Street), and "05/12" as a date. - Verbalization: Once categorized, the semiotic
tokens are transformed into full lexical words. The verbalizer converts
the structured data (e.g.,
date { month: "May" day: "12" }) into an expanded string ("May twelfth") suitable for the phonetic generator.
Weighted Finite-State Transducers (WFSTs)
For decades, Weighted Finite-State Transducers (WFSTs) have served as the industry standard for text normalization frameworks (such as Google’s Sparrowhawk and Kestrel).
WFSTs use hand-crafted context-free grammars to map written patterns directly to their spoken targets. Their strength lies in total predictability: they do not hallucinate numbers or dates, which is critical in safety-critical applications like automated customer service or navigation. However, pure WFST approaches scale poorly across hundreds of languages and struggle with nuanced syntactic disambiguation.
Deep Learning and Transformer-Based Disambiguation
To overcome the fragility of hand-written rules, contemporary front-ends incorporate neural models:
- Pretrained Language Models: Models based on BERT or RoBERTa analyze broad contextual windows to solve polysemy (e.g., determining whether "St." precedes a name or follows a number). The contextual embeddings accurately predict the correct semiotic class before verbalization occurs.
- Neural Sequence-to-Sequence Normalizers: Encoder-decoder architectures (like T5 or specialized RNNs) map raw text sequences directly to expanded words. While these models handle complex phrasing and slang effortlessly, they introduce a significant failure mode: unconstrained hallucinations (e.g., converting "$15" into "fifty dollars").
The Modern Industry Standard: Hybrid Systems
Due to the hallucination risk of pure neural networks and the rigidity of pure grammars, state-of-the-art TTS architectures (such as NVIDIA NeMo's text processing pipeline) employ hybrid architectures.
In these systems, deep learning models perform the contextual classification and disambiguation, while deterministic WFST grammars enforce strict verbalization rules. By constraining neural outputs with finite-state rules, modern front-ends guarantee that numeric quantities, dates, and currency amounts remain mathematically intact while benefiting from human-like contextual understanding.