Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -29,13 +29,11 @@ def bot(response):
|
|
| 29 |
yield history
|
| 30 |
|
| 31 |
with gr.Blocks() as demo:
|
| 32 |
-
|
| 33 |
-
|
| 34 |
-
|
| 35 |
|
| 36 |
-
|
| 37 |
-
bot, chatbot, chatbot
|
| 38 |
-
)
|
| 39 |
|
| 40 |
demo.queue()
|
| 41 |
demo.launch()
|
|
|
|
| 29 |
yield history
|
| 30 |
|
| 31 |
with gr.Blocks() as demo:
|
| 32 |
+
chatbot = gr.Chatbot()
|
| 33 |
+
msg = gr.Textbox()
|
| 34 |
+
clear = gr.ClearButton([msg, chatbot])
|
| 35 |
|
| 36 |
+
msg.submit(generate_text, [msg, chatbot], [msg, chatbot], queue=False).then(bot, chatbot, chatbot)
|
|
|
|
|
|
|
| 37 |
|
| 38 |
demo.queue()
|
| 39 |
demo.launch()
|