Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -102,13 +102,13 @@ with block as demo_1:
|
|
| 102 |
chatbot = gr.Chatbot(label='ChatYuan')
|
| 103 |
message = gr.Textbox()
|
| 104 |
state = gr.State()
|
| 105 |
-
message.submit(chatyuan_bot_api, inputs=[message, state], outputs=[chatbot, state])
|
| 106 |
with gr.Row():
|
| 107 |
clear_history = gr.Button("π ζΈ
ι€εε²ε―Ήθ―")
|
| 108 |
clear = gr.Button('π§Ή ζΈ
ι€ειζ‘')
|
| 109 |
send = gr.Button("π ει")
|
| 110 |
|
| 111 |
-
send.click(chatyuan_bot_api, inputs=[message, state], outputs=[chatbot, state])
|
| 112 |
clear.click(lambda: None, None, message, queue=False)
|
| 113 |
clear_history.click(fn=clear_session , inputs=[], outputs=[chatbot, state], queue=False)
|
| 114 |
|
|
|
|
| 102 |
chatbot = gr.Chatbot(label='ChatYuan')
|
| 103 |
message = gr.Textbox()
|
| 104 |
state = gr.State()
|
| 105 |
+
message.submit(chatyuan_bot_api, inputs=[api_key,message, state], outputs=[chatbot, state])
|
| 106 |
with gr.Row():
|
| 107 |
clear_history = gr.Button("π ζΈ
ι€εε²ε―Ήθ―")
|
| 108 |
clear = gr.Button('π§Ή ζΈ
ι€ειζ‘')
|
| 109 |
send = gr.Button("π ει")
|
| 110 |
|
| 111 |
+
send.click(chatyuan_bot_api, inputs=[api_key,message, state], outputs=[chatbot, state])
|
| 112 |
clear.click(lambda: None, None, message, queue=False)
|
| 113 |
clear_history.click(fn=clear_session , inputs=[], outputs=[chatbot, state], queue=False)
|
| 114 |
|