mirror of
https://github.com/wassname/Clover-Edition.git
synced 2026-10-30 12:50:18 +08:00
update
This commit is contained in:
1 parent
c1601f60b1
commit
cdd9a24fa7
1 file changed
+2
-1
@@ -302,7 +302,8 @@ class CTRLGenerator():
|
||||
num_new_lines = 0
|
||||
for token in range(len(text) - 1, total_text_len - 1):
|
||||
idx = self.generate_next_token(token, tokens_generated, options, num_new_lines, token_num, first_token=first_token, forbid_newline=False)
|
||||
if self.idx2word[idx] == '\n' and token_num > 7:
|
||||
is_nothing = len(cut_trailing_sentence(result)) == 0 or len(cut_trailing_quotes(result)) == 0
|
||||
if self.idx2word[idx] == '\n' and token_num > 7 and not is_nothing:
|
||||
return self.result_replace(result)
|
||||
elif self.idx2word[idx] == '\n':
|
||||
idx = self.generate_next_token(token, tokens_generated, options, num_new_lines, token_num,
|
||||
|
||||
Reference in new issue
Block a user