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/example.py

31 lines
1.1 KiB

2 months ago
from swarms import Agent
from swarms.prompts.finance_agent_sys_prompt import (
FINANCIAL_AGENT_SYS_PROMPT,
)
4 months ago
5 months ago
# Initialize the agent
agent = Agent(
4 months ago
agent_name="Financial-Analysis-Agent",
1 month ago
agent_description = "Personal finance advisor agent",
system_prompt=FINANCIAL_AGENT_SYS_PROMPT + "Output the <DONE> token when you're done creating a portfolio of etfs, index, funds, and more for AI",
model_name="gpt-4o", # Use any model from litellm
max_loops="auto",
5 months ago
dynamic_temperature_enabled=True,
1 month ago
user_name="Kye",
retry_attempts=3,
2 months ago
streaming_on=True,
1 month ago
context_length=16000,
1 month ago
return_step_meta=False,
1 month ago
output_type="str", # "json", "dict", "csv" OR "string" "yaml" and
2 months ago
auto_generate_prompt=False, # Auto generate prompt for the agent based on name, description, and system prompt, task
1 month ago
max_tokens=16000, # max output tokens
interactive = True,
stopping_token="<DONE>",
execute_tool=True,
5 months ago
)
2 months ago
agent.run(
1 month ago
"Create a table of super high growth opportunities for AI. I have $40k to invest in ETFs, index funds, and more. Please create a table in markdown.",
2 months ago
all_cores=True,
5 months ago
)