Understand the TN Pipeline architecture
masterThe Text Normalization (TN) pipeline consists of three logical components designed to allow exact input/output span mapping through normalize_with_mapping():
- Classification and raw-field tagging: Identifies segments and tags them. The tagger must preserve the original written form in its fields.
- Non-standard word (NSW) verbalization: Converts non-standard forms (like numbers, dates, or symbols) into their spoken/verbalized equivalents.
- Output post-processing: Handles final transformations such as character-width conversion, symbol mapping, and blacklist removal.
Before modifying rules, refer to the Python rule architecture and contribution guide.