Skip to content

Async Tool Calls

Compare
Choose a tag to compare
@VRSEN VRSEN released this 17 Jul 16:07
· 48 commits to main since this release

New Features

  • Async Tools - You can now set async_mode to tools_threading inside the Agency class. With this mode on, all tool calls made by your agents will be executed in separate threads (max 4, depending on your CPU). This can signifincatly speed up the workflow when executing multiple I/O bound tasks.
  • Concurrent API Calls - Now all API tools created with schemas_folder or ToolFactory.from_openapi_schema return coroutines, which are executed concurrently in an event loop.
  • Async BaseTool.run Method Support - All async run methods in your BaseTool classes are now executed concurrently in an event loop as well.
  • File Search Configuration - Added file_search configuration to the Agent class - This parameter allows you to modify the configuration of the FileSearch tool. Currently, only {max_num_results: int} is available. See OpenAI API Docs
  • Parallel Tool Call Controls - Added parallel_tool_calls parameter to the Agent class - When set to False, the agent won't call multiple tools at once and will execute all tools sequentially.

Bug Fixes

  • Fixed bug with duplicate call IDs assignment when the agent calls the same tool multiple times and the request times out. #151

Full Changelog: v0.2.5...v0.2.6