Extra tweak to the text preprocessing
Discards any text to be generated that is 0 or 1 characters in length after the sentence is split down (usually this is a * or a " and just produces a strange sound).
This commit is contained in:
1 parent
07b32d0190
commit
803c58b44e
1 file changed
+2
-2
@@ -499,8 +499,8 @@ def output_modifier(string, state):
|
||||
parts = re.split(r'"', decoded_text)
|
||||
audio_files_paragraph = []
|
||||
for i, part in enumerate(parts):
|
||||
# Skip empty parts
|
||||
if not part:
|
||||
# Skip parts that are too short
|
||||
if len(part.strip()) <= 1:
|
||||
continue
|
||||
# Determine if it's a narrator or voice part within double quotes
|
||||
is_narrator_part = is_narrator if i % 2 == 0 else False
|
||||
|
||||
Reference in new issue
Block a user