mirror of
https://github.com/oobabooga/text-generation-webui.git
synced 2026-03-26 07:14:39 +01:00
Fix prompt corruption when continuing with context truncation (#7439)
This commit is contained in:
parent
1dda5e4711
commit
bde496ea5d
|
|
@ -434,6 +434,8 @@ def generate_chat_prompt(user_input, state, **kwargs):
|
|||
messages.append({"role": "user", "content": "fake user message replace me"})
|
||||
|
||||
def make_prompt(messages):
|
||||
if _continue:
|
||||
messages = copy.deepcopy(messages)
|
||||
last_message = messages[-1].copy()
|
||||
if _continue:
|
||||
if state['mode'] == 'chat-instruct':
|
||||
|
|
|
|||
Loading…
Reference in a new issue