Update auto_swarm_builder.py

pull/666/merge
Kye Gomez 4 weeks ago committed by GitHub
parent e6e989de27
commit 770b4a15fd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -50,13 +50,11 @@ class SwarmConfig(BaseModel):
name="Research-Agent", name="Research-Agent",
description="Gathers information", description="Gathers information",
system_prompt="You are a research agent...", system_prompt="You are a research agent...",
max_loops=2,
), ),
AgentConfig( AgentConfig(
name="Writing-Agent", name="Writing-Agent",
description="Writes content", description="Writes content",
system_prompt="You are a writing agent...", system_prompt="You are a writing agent...",
max_loops=1,
), ),
], ],
) )
@ -195,7 +193,7 @@ class AutoSwarmBuilder:
self.name = agents_dictionary.name self.name = agents_dictionary.name
self.description = agents_dictionary.description self.description = agents_dictionary.description
self.max_loops = getattr( self.max_loops = getattr(
agents_dictionary, "max_loops", 1 agents_dictionary
) # Default to 1 if not set ) # Default to 1 if not set
logger.info( logger.info(
@ -213,7 +211,6 @@ class AutoSwarmBuilder:
agent_name=agent_config.name, agent_name=agent_config.name,
agent_description=agent_config.description, agent_description=agent_config.description,
agent_system_prompt=agent_config.system_prompt, agent_system_prompt=agent_config.system_prompt,
# max_loops=agent_config.max_loops,
) )
agents.append(agent) agents.append(agent)

Loading…
Cancel
Save