Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -67,6 +67,7 @@ with gr.Blocks() as demo:
|
|
67 |
clear = gr.ClearButton([msg, chatbot])
|
68 |
|
69 |
def respond(user, quiz_count, gen, types, message, chat_history, request: gr.Request):
|
|
|
70 |
done = info[user]['done']
|
71 |
start, end = GEN_RANGE[gen]
|
72 |
sdf = df[start:end]
|
@@ -96,7 +97,7 @@ with gr.Blocks() as demo:
|
|
96 |
|
97 |
chat_history.append((message, bot_message))
|
98 |
print(info)
|
99 |
-
return "", chat_history, MD.format(content='\n'.join([f"{u}({info[u]['score']}점)" for u in USERS]))
|
100 |
|
101 |
msg.submit(respond, [user, quiz_count, generation, poke_types, msg, chatbot], [msg, chatbot, markdown])
|
102 |
|
|
|
67 |
clear = gr.ClearButton([msg, chatbot])
|
68 |
|
69 |
def respond(user, quiz_count, gen, types, message, chat_history, request: gr.Request):
|
70 |
+
global info
|
71 |
done = info[user]['done']
|
72 |
start, end = GEN_RANGE[gen]
|
73 |
sdf = df[start:end]
|
|
|
97 |
|
98 |
chat_history.append((message, bot_message))
|
99 |
print(info)
|
100 |
+
return "", chat_history, MD.format(content='\n'.join([f"- {u}({info[u]['score']}점)" for u in USERS]))
|
101 |
|
102 |
msg.submit(respond, [user, quiz_count, generation, poke_types, msg, chatbot], [msg, chatbot, markdown])
|
103 |
|