Skip to content

Commit

Permalink
tool_call handler fix
Browse files Browse the repository at this point in the history
  • Loading branch information
phact committed Jul 16, 2024
1 parent 9d07c46 commit 7294995
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions client/astra_assistants/astra_assistants_event_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@ def on_tool_call_done(self, tool_call):
self.logger.info(f'arguments: {tool_call.function.arguments}')
self.tool_call_results = self.run_tool(tool_call)
if not isinstance(self.tool_call_results, str) and self.tool_call_results is not None:
tool_call_results = self.tool_call_results["output"].to_string()
tool_call_results_string = self.tool_call_results["output"].to_string()
self.tool_output = ToolOutput(
tool_call_id=tool_call.id,
output=self.tool_call_results
output=tool_call_results_string
)

self.stream = self.client.beta.threads.runs.submit_tool_outputs_stream(
Expand Down

0 comments on commit 7294995

Please sign in to comment.