Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -283,8 +283,12 @@ with gr.Blocks(css="""
|
|
| 283 |
|
| 284 |
state = gr.State(history)
|
| 285 |
|
| 286 |
-
submit_btn.click(fn=sysml_chatbot, inputs=[msg, state], outputs=[
|
| 287 |
-
msg.submit(fn=sysml_chatbot, inputs=[msg, state], outputs=[
|
|
|
|
|
|
|
|
|
|
|
|
|
| 288 |
clear.click(fn=lambda: ([], ""), inputs=None, outputs=[chatbot, msg])
|
| 289 |
|
| 290 |
if __name__ == "__main__":
|
|
|
|
| 283 |
|
| 284 |
state = gr.State(history)
|
| 285 |
|
| 286 |
+
submit_btn.click(fn=sysml_chatbot, inputs=[msg, state], outputs=["", chatbot])
|
| 287 |
+
msg.submit(fn=sysml_chatbot, inputs=[msg, state], outputs=["", chatbot]) # still supports enter key
|
| 288 |
+
|
| 289 |
+
# submit_btn.click(fn=sysml_chatbot, inputs=[msg, state], outputs=[gr.Textbox.update(value=""), chatbot])
|
| 290 |
+
# msg.submit(fn=sysml_chatbot, inputs=[msg, state], outputs=[gr.Textbox.update(value=""), chatbot])
|
| 291 |
+
|
| 292 |
clear.click(fn=lambda: ([], ""), inputs=None, outputs=[chatbot, msg])
|
| 293 |
|
| 294 |
if __name__ == "__main__":
|