Skip to content

Commit b0e7f90

Browse files
author
jiangtao
committed
add print log
1 parent 64a523b commit b0e7f90

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

core/utils/util.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,10 @@ def write_json_file(file_path, data):
3434
json.dump(data, file, ensure_ascii=False, indent=4)
3535

3636

37-
def is_segment(tokens):
38-
if tokens[-1] in (",", ".", "?", ",", "。", "?", "!", "!", ";", ";", ":", ":"," "):
37+
def is_segment(tokens, start):
38+
if tokens[-1] in (",", ".", "?", ",", "。", "?", "!", "!", ";", ";", ":", ":"):
39+
return True
40+
elif tokens[-1] in (" ") and len("".join(response_message[start:])) > 10:
3941
return True
4042
else:
4143
return False

0 commit comments

Comments
 (0)