Keep German domain endings natural in TTS
This commit is contained in:
@@ -259,7 +259,11 @@ def normalize_for_german_speech(text: str) -> str:
|
||||
r"\.(de|com|org|net|io|ai)\b",
|
||||
lambda match: (
|
||||
match.group(1).replace(".", " Punkt ")
|
||||
+ " Punkt " + " ".join(match.group(2).upper())
|
||||
+ " Punkt "
|
||||
+ (
|
||||
"de" if match.group(2).lower() == "de"
|
||||
else " ".join(match.group(2).upper())
|
||||
)
|
||||
),
|
||||
text,
|
||||
flags=re.IGNORECASE,
|
||||
|
||||
Reference in New Issue
Block a user