From 6494f675687e6f2437ab5a28dd0d1e6213938b7c Mon Sep 17 00:00:00 2001 From: yumoqing Date: Sun, 25 May 2025 14:09:01 +0800 Subject: [PATCH] bugfix --- appPublic/textsplit.py | 6 ------ 1 file changed, 6 deletions(-) diff --git a/appPublic/textsplit.py b/appPublic/textsplit.py index c569393..d2116d0 100644 --- a/appPublic/textsplit.py +++ b/appPublic/textsplit.py @@ -15,12 +15,6 @@ def split_english_sentences(text): sentences = [s.replace('', '.') for s in sentences if s.strip()] return sentences -def split_engish1_sentences(text): - # 匹配以 '. ', '? ', '! ' 结尾的英文句子,保留分隔符 - sentence_endings = re.compile(r'(?<=[.!?]) +') - sentences = sentence_endings.split(text.strip()) - return [s.strip() for s in sentences if s.strip()] - def split_text_with_dialog_preserved(text): # 正则匹配中英文引号对话 text = ' '.join(text.split('\n'))