Update hierarchical_swarm_example.py

pull/1101/head
CI-DEV 1 week ago committed by GitHub
parent 60e80e6104
commit 655687671a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -7,7 +7,7 @@ from swarms.structs.hiearchical_swarm import (
HierarchicalSwarm,
SwarmSpec,
)
from swarms.utils.function_caller_model import OpenAIFunctionCaller
from swarms.utils.litellm_wrapper import LiteLLM
load_dotenv()
@ -15,9 +15,9 @@ load_dotenv()
# ------------------------------------------------------------------------------
# Director LLM: Responsible for orchestrating tasks among the agents
# ------------------------------------------------------------------------------
llm = OpenAIFunctionCaller(
base_model=SwarmSpec,
api_key=os.getenv("OPENAI_API_KEY"),
llm = LiteLLM(
model_name="gpt-4o",
response_format=SwarmSpec,
system_prompt=(
"As the Director of this Hierarchical Agent Swarm, you are in charge of "
"coordinating and overseeing all tasks, ensuring that each is executed "

Loading…
Cancel
Save