Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -245,12 +245,8 @@ mychatbot = gr.Chatbot(
|
|
245 |
)
|
246 |
|
247 |
|
248 |
-
|
249 |
-
|
250 |
-
output, chatbot_visible, accuse_btn_visible = output
|
251 |
-
chatbot.visible = chatbot_visible
|
252 |
-
accuse_btn.visible = accuse_btn_visible
|
253 |
-
return output, chatbot, textbox, accuse_btn
|
254 |
|
255 |
def chatbot_interface(request: gr.Request):
|
256 |
chatbot_interface = gr.ChatInterface(
|
@@ -260,7 +256,7 @@ def chatbot_interface(request: gr.Request):
|
|
260 |
retry_btn=None,
|
261 |
undo_btn=None,
|
262 |
clear_btn=None,
|
263 |
-
additional_inputs=[
|
264 |
submit_btn="Parler",
|
265 |
css="footer {visibility: hidden !important} .gradio-container {background-color: #2D4059 !important; color: #FFD460 !important;}",
|
266 |
js=js_func
|
|
|
245 |
)
|
246 |
|
247 |
|
248 |
+
with gr.Blocks():
|
249 |
+
accuse_btn=gr.Button("Accuser")
|
|
|
|
|
|
|
|
|
250 |
|
251 |
def chatbot_interface(request: gr.Request):
|
252 |
chatbot_interface = gr.ChatInterface(
|
|
|
256 |
retry_btn=None,
|
257 |
undo_btn=None,
|
258 |
clear_btn=None,
|
259 |
+
additional_inputs=[accuse_btn],
|
260 |
submit_btn="Parler",
|
261 |
css="footer {visibility: hidden !important} .gradio-container {background-color: #2D4059 !important; color: #FFD460 !important;}",
|
262 |
js=js_func
|