mirror of
https://github.com/KoboldAI/KoboldAI-Client.git
synced 2025-06-05 21:59:24 +02:00
Fix chat mode empty generation error
This commit is contained in:
2
utils.py
2
utils.py
@@ -714,7 +714,7 @@ def applyoutputformatting(txt, no_sentence_trimming=False, no_single_line=False)
|
|||||||
txt = replaceblanklines(txt)
|
txt = replaceblanklines(txt)
|
||||||
|
|
||||||
# trim off starting new lines in replies if we're in chat mode
|
# trim off starting new lines in replies if we're in chat mode
|
||||||
if koboldai_vars.chatmode and txt[0] == "\n":
|
if koboldai_vars.chatmode and txt and txt[0] == "\n":
|
||||||
txt = txt[1:]
|
txt = txt[1:]
|
||||||
|
|
||||||
# Remove special characters
|
# Remove special characters
|
||||||
|
Reference in New Issue
Block a user