fix line breaks
Browse files
tabbed.py
CHANGED
@@ -35,7 +35,7 @@ def user(message, history):
|
|
35 |
def chat(history, system_message, max_tokens, temperature, top_p, top_k, repeat_penalty):
|
36 |
history = history or []
|
37 |
|
38 |
-
messages = system_message + \
|
39 |
"\n".join(["\n".join(["USER: "+item[0], "ASSISTANT: "+item[1]])
|
40 |
for item in history])
|
41 |
|
@@ -63,7 +63,7 @@ def chat(history, system_message, max_tokens, temperature, top_p, top_k, repeat_
|
|
63 |
def rp_chat(history, system_message, max_tokens, temperature, top_p, top_k, repeat_penalty):
|
64 |
history = history or []
|
65 |
|
66 |
-
messages = "<|system|>" + system_message + \
|
67 |
"\n".join(["\n".join(["<|user|>"+item[0], "<|model|>"+item[1]])
|
68 |
for item in history])
|
69 |
|
|
|
35 |
def chat(history, system_message, max_tokens, temperature, top_p, top_k, repeat_penalty):
|
36 |
history = history or []
|
37 |
|
38 |
+
messages = system_message.strip() + "\n" + \
|
39 |
"\n".join(["\n".join(["USER: "+item[0], "ASSISTANT: "+item[1]])
|
40 |
for item in history])
|
41 |
|
|
|
63 |
def rp_chat(history, system_message, max_tokens, temperature, top_p, top_k, repeat_penalty):
|
64 |
history = history or []
|
65 |
|
66 |
+
messages = "<|system|>" + system_message.strip() + "\n" + \
|
67 |
"\n".join(["\n".join(["<|user|>"+item[0], "<|model|>"+item[1]])
|
68 |
for item in history])
|
69 |
|