Spaces:
Sleeping
Sleeping
NicholasGuerrero
commited on
Commit
·
10ed1b5
1
Parent(s):
e29fc26
update
Browse files
app.py
CHANGED
|
@@ -26,11 +26,11 @@ def generate_text(
|
|
| 26 |
top_p,
|
| 27 |
):
|
| 28 |
temp = ""
|
| 29 |
-
input_prompt = f"
|
| 30 |
for interaction in history:
|
| 31 |
-
input_prompt = input_prompt + str(interaction[0]) + str(interaction[1])
|
| 32 |
|
| 33 |
-
input_prompt = input_prompt + str(message)
|
| 34 |
|
| 35 |
output = llm(
|
| 36 |
input_prompt,
|
|
|
|
| 26 |
top_p,
|
| 27 |
):
|
| 28 |
temp = ""
|
| 29 |
+
input_prompt = f"[INST] <<SYS>>\n{system_message}\n<</SYS>>\n\n "
|
| 30 |
for interaction in history:
|
| 31 |
+
input_prompt = input_prompt + str(interaction[0]) + " [/INST] " + str(interaction[1]) + " </s><s> [INST] "
|
| 32 |
|
| 33 |
+
input_prompt = input_prompt + str(message) + " [/INST] "
|
| 34 |
|
| 35 |
output = llm(
|
| 36 |
input_prompt,
|