Spaces:
Sleeping
Sleeping
delay one sec
Browse files- gradio_interface.py +2 -2
gradio_interface.py
CHANGED
@@ -16,7 +16,7 @@ def create_interface():
|
|
16 |
|
17 |
# Get offender's response
|
18 |
offender_response, _ = chatbot_response(input_text, 'offender', n=1)
|
19 |
-
time.sleep(
|
20 |
|
21 |
# Add offender's response to history
|
22 |
chatbot_history.append((None, offender_response))
|
@@ -32,7 +32,7 @@ def create_interface():
|
|
32 |
yield chatbot_history, gr.update(choices=[])
|
33 |
|
34 |
offender_response, _ = chatbot_response(initial_message, 'offender', n=1)
|
35 |
-
time.sleep(
|
36 |
|
37 |
chatbot_history.append((None, offender_response))
|
38 |
_, victim_choices = chatbot_response(offender_response, 'victim', n=3)
|
|
|
16 |
|
17 |
# Get offender's response
|
18 |
offender_response, _ = chatbot_response(input_text, 'offender', n=1)
|
19 |
+
time.sleep(1) # 2-second delay
|
20 |
|
21 |
# Add offender's response to history
|
22 |
chatbot_history.append((None, offender_response))
|
|
|
32 |
yield chatbot_history, gr.update(choices=[])
|
33 |
|
34 |
offender_response, _ = chatbot_response(initial_message, 'offender', n=1)
|
35 |
+
time.sleep(1) # 2-second delay
|
36 |
|
37 |
chatbot_history.append((None, offender_response))
|
38 |
_, victim_choices = chatbot_response(offender_response, 'victim', n=3)
|