Spaces:
Runtime error
Runtime error
Upload app.py
Browse files
app.py
CHANGED
@@ -252,7 +252,7 @@ def respond(message,chat_history):
|
|
252 |
|
253 |
|
254 |
def suggestion1():
|
255 |
-
response = generate_text(
|
256 |
return [suggestion_text_1,response]
|
257 |
"""
|
258 |
def suggestion2():
|
@@ -278,12 +278,8 @@ with gr.Blocks(theme=theme, css=css) as demo:
|
|
278 |
with gr.Column(elem_id="chat-interface"):
|
279 |
chat = gr.Chatbot(elem_id="chat-messages", show_label=False,avatar_images=[user_profile_image,bot_profile_image])
|
280 |
with gr.Row(elem_id="suggestions"):
|
281 |
-
#for i in suggestion:
|
282 |
-
# gr.Button(i, elem_classes="suggestion-btn").click(
|
283 |
-
# respond(i,chat)
|
284 |
-
# )
|
285 |
sugg1 = gr.Button(suggestion[0], elem_classes="suggestion-btn").click(
|
286 |
-
|
287 |
)
|
288 |
sugg2 = gr.Button(suggestion[1], elem_classes="suggestion-btn").click(
|
289 |
suggestion1, outputs=chat
|
|
|
252 |
|
253 |
|
254 |
def suggestion1():
|
255 |
+
response = generate_text(suggestion[0])
|
256 |
return [suggestion_text_1,response]
|
257 |
"""
|
258 |
def suggestion2():
|
|
|
278 |
with gr.Column(elem_id="chat-interface"):
|
279 |
chat = gr.Chatbot(elem_id="chat-messages", show_label=False,avatar_images=[user_profile_image,bot_profile_image])
|
280 |
with gr.Row(elem_id="suggestions"):
|
|
|
|
|
|
|
|
|
281 |
sugg1 = gr.Button(suggestion[0], elem_classes="suggestion-btn").click(
|
282 |
+
suggestion1, outputs=chat
|
283 |
)
|
284 |
sugg2 = gr.Button(suggestion[1], elem_classes="suggestion-btn").click(
|
285 |
suggestion1, outputs=chat
|