CaasiHUANG commited on
Commit
55b21e7
·
1 Parent(s): 48c4ee1

Fix Normalization

Browse files
Files changed (1) hide show
  1. processing_moss_tts.py +3 -3
processing_moss_tts.py CHANGED
@@ -82,7 +82,7 @@ def normalize_text(text: str) -> str:
82
  2. Replace decorative symbols with comma
83
  3. Remove consecutive duplicate punctuation
84
  4. Remove line breaks
85
- 5. Remove quotes
86
  """
87
  if not text:
88
  return text
@@ -99,8 +99,8 @@ def normalize_text(text: str) -> str:
99
  for char in decorative_chars:
100
  text = text.replace(char, ",")
101
 
102
- # Remove quotes (中英文引号)
103
- quotes = ['"', '"', '"', "'", "'", "'"]
104
  for q in quotes:
105
  text = text.replace(q, "")
106
 
 
82
  2. Replace decorative symbols with comma
83
  3. Remove consecutive duplicate punctuation
84
  4. Remove line breaks
85
+ 5. Remove quotes (only double quotes)
86
  """
87
  if not text:
88
  return text
 
99
  for char in decorative_chars:
100
  text = text.replace(char, ",")
101
 
102
+ # Remove double quotes only (保留单引号)
103
+ quotes = ['"', '"', '"']
104
  for q in quotes:
105
  text = text.replace(q, "")
106