You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
swarms/README.md

2.1 KiB

The Enterprise-Grade Production-Ready Multi-Agent Orchestration Framework

Python Version

🐦 Twitter   •   📢 Discord   •   Swarms Platform   •   📙 Documentation

[Previous content remains unchanged until the new section...]

AsyncWorkflow

The AsyncWorkflow class enables asynchronous execution of multiple agents in parallel, allowing for efficient task processing and improved performance. This workflow is particularly useful when dealing with multiple independent tasks that can be executed concurrently.

Methods

Method Description Parameters Return Value
__init__ Initialize the AsyncWorkflow agents: List of Agent objects
max_workers: Maximum number of concurrent workers
None
run Execute tasks asynchronously tasks: List of tasks to be processed List of results from all tasks

Inputs

Input Type Description
agents List[Agent] List of Agent objects to process tasks
max_workers int Maximum number of concurrent worker threads
tasks List[str] List of tasks to be processed

Output

The run method returns a list containing the results from all processed tasks.

Example Usage