mirror of
https://github.com/oobabooga/text-generation-webui.git
synced 2024-11-21 23:57:58 +01:00
Add .rstrip(' ') to openai api
This commit is contained in:
parent
3f1bfba718
commit
c746a5bd00
@ -70,7 +70,7 @@ def deduce_template():
|
||||
.replace('<|user|>', instruct.get('user', ''))\
|
||||
.replace('<|bot|>', instruct.get('bot', ''))\
|
||||
.replace('<|user-message|>', '{instruction}\n{input}')
|
||||
return instruct.get('context', '') + template[:template.find('<|bot-message|>')]
|
||||
return instruct.get('context', '') + template[:template.find('<|bot-message|>')].rstrip(' ')
|
||||
except:
|
||||
return default_template
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user