Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -73,7 +73,7 @@ def generate(prompt, history,max_new_tokens,temperature=temperature,top_p=top_p,
|
|
73 |
output += response.token.text
|
74 |
if history:
|
75 |
print (history)
|
76 |
-
yield "",
|
77 |
else:
|
78 |
yield "",[(prompt,output)]
|
79 |
|
@@ -92,7 +92,7 @@ def generate(prompt, history,max_new_tokens,temperature=temperature,top_p=top_p,
|
|
92 |
print(line)
|
93 |
|
94 |
if history:
|
95 |
-
return "",
|
96 |
else:
|
97 |
return "",[(prompt,output)]
|
98 |
|
|
|
73 |
output += response.token.text
|
74 |
if history:
|
75 |
print (history)
|
76 |
+
yield "",[(prompt,output)]
|
77 |
else:
|
78 |
yield "",[(prompt,output)]
|
79 |
|
|
|
92 |
print(line)
|
93 |
|
94 |
if history:
|
95 |
+
return "",history.append([(prompt,output)])
|
96 |
else:
|
97 |
return "",[(prompt,output)]
|
98 |
|