@ -1173,82 +1173,78 @@ autoswarm.run("Analyze these financial data and give me a summary")
Inspired by Einops and einsum, this orchestration techniques enables you to map out the relationships between various agents. For example you specify linear and sequential relationships like `a -> a1 -> a2 -> a3` or concurrent relationships where the first agent will send a message to 3 agents all at once: `a -> a1, a2, a3`. You can customize your workflow to mix sequential and concurrent relationships
Inspired by Einops and einsum, this orchestration techniques enables you to map out the relationships between various agents. For example you specify linear and sequential relationships like `a -> a1 -> a2 -> a3` or concurrent relationships where the first agent will send a message to 3 agents all at once: `a -> a1, a2, a3`. You can customize your workflow to mix sequential and concurrent relationships
```python
```python
from swarms import Agent, Anthropic, AgentRearrange,
from swarms import Agent, AgentRearrange, rearrange, Anthropic
## Initialize the workflow
agent = Agent(
# Initialize the director agent
agent_name="t",
agent_description=(
director = Agent(
"Generate a transcript for a youtube video on what swarms"
agent_name="Director",
" are!"
system_prompt="Directs the tasks for the workers",
),
system_prompt=(
"Generate a transcript for a youtube video on what swarms"
" are!"
),
llm=Anthropic(),
llm=Anthropic(),
max_loops=1,
max_loops=1,
autosave=True,
dashboard=False,
dashboard=False,
streaming_on=True,
streaming_on=True,
verbose=True,
verbose=True,
stopping_token="<DONE>",
stopping_token="<DONE>",
state_save_file_type="json",
saved_state_path="director.json",
)
)
agent2 = Agent(
agent_name="t1",
# Initialize worker 1
agent_description=(
"Generate a transcript for a youtube video on what swarms"
worker1 = Agent(
" are!"
agent_name="Worker1",
),
system_prompt="Generates a transcript for a youtube video on what swarms are",
llm=Anthropic(),
llm=Anthropic(),
max_loops=1,
max_loops=1,
system_prompt="Summarize the transcript",
autosave=True,
dashboard=False,
dashboard=False,
streaming_on=True,
streaming_on=True,
verbose=True,
verbose=True,
stopping_token="<DONE>",
stopping_token="<DONE>",
state_save_file_type="json",
saved_state_path="worker1.json",
)
)
agent3 = Agent(
agent_name="t2",
# Initialize worker 2
agent_description=(
worker2 = Agent(
"Generate a transcript for a youtube video on what swarms"
agent_name="Worker2",
" are!"
system_prompt="Summarizes the transcript generated by Worker1",