TradingAgents
Multi-agent LLM framework for collaborative financial trading decisions
A multi-agent trading framework that mirrors real-world trading firms, deploying specialized LLM-powered agents (fundamental, sentiment, news, and technical analysts, researchers, traders, risk managers, and portfolio managers) that collaboratively evaluate market conditions and inform trading decisions through dynamic discussions.
Overview
Overview
TradingAgents is a multi-agent trading framework that mirrors the dynamics of real-world trading firms. The system deploys specialized LLM-powered agents that collaboratively evaluate market conditions and inform trading decisions through structured debates and analysis.
Agent Architecture
The framework decomposes complex trading tasks into specialized roles:
Analyst Team: Fundamentals Analyst evaluates company financials and intrinsic values. Sentiment Analyst aggregates news headlines, StockTwits, and Reddit chatter. News Analyst monitors global news and macroeconomic indicators. Technical Analyst utilizes indicators like MACD and RSI to detect trading patterns.
Researcher Team: Bullish and bearish researchers critically assess analyst insights through structured debates, balancing potential gains against inherent risks.
Trader Agent: Composes reports from analysts and researchers to make informed trading decisions, determining timing and magnitude of trades.
Risk Management and Portfolio Manager: Continuously evaluates portfolio risk by assessing market volatility and liquidity. Risk management team provides assessment reports to the Portfolio Manager for final approval or rejection of transactions.
Implementation
Built with LangGraph for flexibility and modularity. Supports multiple LLM providers: OpenAI, Google, Anthropic, xAI, DeepSeek, Qwen, GLM, MiniMax, OpenRouter, Ollama for local models, and Azure OpenAI for enterprise. Includes LangGraph checkpoint persistence with SQLite backend and persistent decision logging.
Usage
Available as both an interactive CLI (tradingagents command) and a Python package. Configure LLM providers, debate rounds, and other parameters through the configuration system. Includes backtesting framework and Docker support for containerized deployment.
Disclaimer
Designed for research purposes. Trading performance varies based on LLM choice, model temperature, trading periods, data quality, and other non-deterministic factors. Not intended as financial, investment, or trading advice.
Primitives
Analyzes company financials and performance metrics
Aggregates sentiment from news, StockTwits, and Reddit
Monitors global news and macroeconomic indicators
Applies technical indicators (MACD, RSI) for pattern detection
Conducts bullish vs bearish research debates
Executes informed trading decisions
Evaluates portfolio risk and market volatility
Approves or rejects transaction proposals
Outcomes
- 01Informed trading decisions based on multi-agent analysis
- 02Balanced risk-adjusted portfolio positions
- 03Comprehensive market insights from multiple perspectives
Integrations
Autonomy & guardrails
- Portfolio manager must approve all trades
- Risk management team provides assessment before execution
- Framework designed for research purposes, not live trading
Guardrails & requirements
Guardrails
- Risk management team evaluates all trades
- Portfolio manager approval required for execution
- Continuous portfolio risk assessment
- Research designed for educational purposes only
Requirements
- Python 3.10+
- API key for chosen LLM provider (OpenAI, Google, Anthropic, xAI, DeepSeek, Qwen, GLM, MiniMax, OpenRouter, Ollama, or Azure)
- Alpha Vantage API key for market data
Technical specifications
Runtime
- Harness
- LangGraph
- Deployment
- Self-hosted Python application; Docker support included; CLI and programmatic API
- Data residency
- Local deployment; data residency depends on chosen LLM provider
- License
- Not specified in provided files
- Version
- v0.2.5
Models & tooling
- Models
- GPT-5.xGemini 3.xClaude 4.xGrok 4.xDeepSeekQwenGLMMiniMaxOllama (local models)
- Tooling
- backtraderyfinancestockstatspandasLangChainLangGraphRedis
Security & compliance
- Auth model
- API key-based authentication for LLM providers and market data services
Architecture notes
Memory architecture
LangGraph checkpoint persistence with SQLite backend; decision log stored persistently
Context strategy
Specialized agents maintain domain-specific context; structured debates between bullish/bearish researchers; reports aggregated by trader and portfolio manager
Evaluation
Backtesting framework included; performance varies based on LLM choice, temperature, trading periods, and data quality