Spaces:
Paused
Paused
nroggendorff
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -32,6 +32,6 @@ def predict(input_text, history):
|
|
32 |
outputs = model.generate(**inputs, max_new_tokens=512)
|
33 |
|
34 |
generated_text = tokenizer.batch_decode(outputs)[0]
|
35 |
-
return generated_text
|
36 |
|
37 |
gr.ChatInterface(predict, theme="soft").launch()
|
|
|
32 |
outputs = model.generate(**inputs, max_new_tokens=512)
|
33 |
|
34 |
generated_text = tokenizer.batch_decode(outputs)[0]
|
35 |
+
return generated_text.split("<|assistant|>")[-1]
|
36 |
|
37 |
gr.ChatInterface(predict, theme="soft").launch()
|