Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -192,8 +192,8 @@ def chat(message, history):
|
|
192 |
|
193 |
###
|
194 |
if tool_call_result:
|
195 |
-
print("### tool_call_id" + tool_call_id)
|
196 |
-
print("### tool_call_result" + tool_call_result)
|
197 |
run = client.beta.threads.runs.submit_tool_outputs(
|
198 |
thread_id=thread.id,
|
199 |
run_id=run.id,
|
@@ -205,6 +205,9 @@ def chat(message, history):
|
|
205 |
]
|
206 |
)
|
207 |
print(run)
|
|
|
|
|
|
|
208 |
###
|
209 |
|
210 |
messages = get_messages(client, thread)
|
|
|
192 |
|
193 |
###
|
194 |
if tool_call_result:
|
195 |
+
print("### tool_call_id=" + tool_call_id)
|
196 |
+
print("### tool_call_result=" + tool_call_result)
|
197 |
run = client.beta.threads.runs.submit_tool_outputs(
|
198 |
thread_id=thread.id,
|
199 |
run_id=run.id,
|
|
|
205 |
]
|
206 |
)
|
207 |
print(run)
|
208 |
+
run = wait_on_run(client, thread, run)
|
209 |
+
run_steps = get_run_steps(client, thread, run)
|
210 |
+
tool_call_id, tool_call_result = execute_tool_calls(run_steps)
|
211 |
###
|
212 |
|
213 |
messages = get_messages(client, thread)
|