Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
|
@@ -90,10 +90,14 @@ function(chatbot){
|
|
| 90 |
console.log(chatbot)
|
| 91 |
}
|
| 92 |
"""
|
| 93 |
-
|
| 94 |
-
|
| 95 |
-
with demo as chat
|
| 96 |
chatbot.change(None,[chatbot],[],js=js)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 97 |
|
| 98 |
if __name__ == "__main__":
|
| 99 |
init()
|
|
|
|
| 90 |
console.log(chatbot)
|
| 91 |
}
|
| 92 |
"""
|
| 93 |
+
with gr.Blocks() as demo:
|
| 94 |
+
chatbot = gr.Chatbot()
|
|
|
|
| 95 |
chatbot.change(None,[chatbot],[],js=js)
|
| 96 |
+
msg = gr.Textbox()
|
| 97 |
+
clear = gr.ClearButton([msg, chatbot])
|
| 98 |
+
|
| 99 |
+
#demo = gr.ChatInterface(call_generate_text,chatbot=chatbot,type="messages")
|
| 100 |
+
msg.submit(respond, [msg, chatbot], [msg, chatbot])
|
| 101 |
|
| 102 |
if __name__ == "__main__":
|
| 103 |
init()
|