AI Agents Overview: Your Team of Specialized AI Experts
This section introduces you to the specialized AI agents within the AI Hedge Fund platform. Think of them as your personal team of expert advisors, each playing a unique role in analyzing market information and helping make smart investment decisions. Understanding what each agent does will clearly show you how the entire AI system works together.
Your AI Expert Team
Our AI system is not a single, all-knowing entity. Instead, it’s a powerful team made up of 12 different Investor-Inspired Agents (each thinking like a famous investor) and 6 different Functional Agents (each performing a specific, objective analysis). This diverse team works together to cover all aspects of investment decision-making.
How Your AI Experts Work: A Simple Step-by-Step Process
Every AI agent in our system follows a clear, simple process to contribute to the overall investment decision:
-
They Get Information: Each agent looks at a shared “whiteboard” (called
AgentState
) to get the latest market data, company details, or signals from other agents. This ensures everyone is working with the most current information. -
They Do Their Expert Analysis: Each agent then uses its special skills and knowledge to process this information. This might involve complex calculations, reading and interpreting financial news, or thinking like a famous investor.
-
They Provide Insights: After their analysis, agents write their findings back onto the shared “whiteboard” (
AgentState
). These insights are usually a straightforward signal (like “bullish” - suggesting to buy, or “bearish” - suggesting to sell) and a simple reason why they reached that conclusion.
This continuous flow of information and insights between agents, all using the AgentState
as their central hub, forms the backbone of our AI team’s collaborative decision-making.
Two Categories of AI Experts
1. Investor-Inspired Agents: Thinking Like Investment Legends
These AI agents are specifically designed to analyze and evaluate companies just like famous, successful investors would. They embody the unique philosophies and strategies of these financial legends. This allows you to gain deep insights from various, well-defined investment perspectives.
Each of these agents systematically gathers specific financial data, performs quantitative analyses based on their namesake’s criteria, and then uses an LLM (Large Language Model) as its “brain.” The LLM is guided by strict “thinking instructions” (prompts) to interpret these facts and deliver an investment opinion in that investor’s distinct style.
2. Functional Agents: Providing Objective Analysis and Rules
These agents perform specific, factual analysis tasks that are vital for building a complete and disciplined investment strategy. They give you solid data and enforce critical rules to keep your strategy on track.
Related Code Files
Feature/Responsibility | Code File | Purpose and Implementation Details |
---|---|---|
Agent State Definition | src/graph/state.py | Defines the AgentState TypedDict, which acts as the shared memory for all agents, containing messages , data , and metadata fields for information exchange. |
Warren Buffett Agent Logic | src/agents/warren_buffett.py | Implements the specific logic for the Warren Buffett-inspired agent, including data fetching, quantitative analysis functions (e.g., analyze_fundamentals , analyze_moat ), intrinsic value calculation, and the LLM prompting structure. |
Benjamin Graham Agent Logic | src/agents/ben_graham.py | Implements the logic for the Benjamin Graham-inspired agent, focusing on earnings stability, financial strength, and deep value valuation methods like Net-Net and Graham Number. |
Bill Ackman Agent Logic | src/agents/bill_ackman.py | Implements the logic for the Bill Ackman-inspired agent, focusing on business quality, financial discipline, activism potential, and valuation with a margin of safety. |
Cathie Wood Agent Logic | src/agents/cathie_wood.py | Implements the logic for the Cathie Wood-inspired agent, focusing on disruptive potential, innovation-driven growth, and high-growth valuation scenarios. |
Charlie Munger Agent Logic | src/agents/charlie_munger.py | Implements the logic for the Charlie Munger-inspired agent, focusing on moat strength, management quality, business predictability, and Munger-style valuation. |
Michael Burry Agent Logic | src/agents/michael_burry.py | Implements the logic for the Michael Burry-inspired agent, focusing on deep value, contrarian sentiment, balance sheet strength, and insider activity. |
Mohnish Pabrai Agent Logic | src/agents/mohnish_pabrai.py | Implements the logic for the Mohnish Pabrai-inspired agent, focusing on downside protection, simple businesses, FCF yield, and “heads I win, tails I don’t lose much” valuation. |
Peter Lynch Agent Logic | src/agents/peter_lynch.py | Implements the logic for the Peter Lynch-inspired agent, focusing on “growth at a reasonable price” (GARP), consistent growth, manageable debt, and the PEG ratio. |
Rakesh Jhunjhunwala Agent Logic | src/agents/rakesh_jhunjhunwala.py | Implements the logic for the Rakesh Jhunjhunwala-inspired agent, focusing on profitability, growth, balance sheet, cash flow, management actions, and intrinsic value with a significant margin of safety. |
Stanley Druckenmiller Agent Logic | src/agents/stanley_druckenmiller.py | Implements the logic for the Stanley Druckenmiller-inspired agent, focusing on asymmetric risk-reward, growth, momentum, sentiment, insider activity, and valuation. |
Aswath Damodaran Agent Logic | src/agents/aswath_damodaran.py | Implements the logic for the Aswath Damodaran-inspired agent, focusing on rigorous intrinsic valuation framework, cash flow-based DCF models, and comprehensive risk assessment. |
Fundamentals Analyst Logic | src/agents/fundamentals.py | Implements a general fundamental analysis agent, assessing profitability, growth, financial health, and valuation ratios (P/E, P/B, P/S). |
Technicals Analyst Logic | src/agents/technicals.py | Implements a comprehensive technical analysis agent, combining trend following, mean reversion, momentum, volatility, and statistical arbitrage signals. |
Valuation Analyst Logic | src/agents/valuation.py | Implements a comprehensive valuation agent, combining owner earnings, enhanced DCF with scenarios, EV/EBITDA, and Residual Income models for a holistic intrinsic value assessment. |
Sentiment Analyst Logic | src/agents/sentiment.py | Implements the logic for the Sentiment Analyst agent, including fetching insider trades and company news, analyzing sentiment from both sources, and combining signals with weighted proportions. |
Risk Manager Logic | src/agents/risk_manager.py | Implements the deterministic logic for the Risk Manager agent, including fetching historical prices, calculating volatility and correlation metrics, and computing volatility- and correlation-adjusted position limits. |
Portfolio Manager Logic | src/agents/portfolio_manager.py | Implements the logic for the Portfolio Manager agent, responsible for synthesizing all agent signals, strictly adhering to risk constraints, deterministically calculating allowed actions, and generating final simulated trading decisions using an LLM. |
Financial Data Tools | src/tools/api.py | Contains functions (e.g., get_financial_metrics , search_line_items , get_market_cap , get_insider_trades , get_company_news , get_prices ) which are used by various agents to fetch real-time and historical financial data from external APIs. |
LLM Interaction Utility | src/utils/llm.py | Provides the call_llm function, which handles sending prompts to the Large Language Model and parsing its structured outputs based on Pydantic models (e.g., WarrenBuffettSignal , PortfolioDecision ). |
LangGraph Orchestration | app/backend/services/graph.py | Contains the create_graph function that dynamically builds the LangGraph state machine from user-defined nodes and edges, including the logic for mandatory insertion of the risk_management_agent . |