workflowstacks
multi-agent

TradingAgents

TradingAgents: Multi-Agents LLM Financial Trading Framework
98,226 stars18,920 forksPythonUpdated 7/18/2026100% free · open source
What it does

TradingAgents is a multi-agent framework for building and testing financial trading strategies using large language models (LLMs) in Python

Install / run
pip install -r requirements.txt
When to use it
  • When you need to develop and evaluate multiple trading strategies against each other
  • When you want to incorporate LLMs into your trading decision-making processes
  • When you require a flexible and customizable framework for backtesting and evaluating trading agents
Quick start
  1. 1 Clone the TradingAgents repository using `git clone https://github.com/TauricResearch/TradingAgents.git`
  2. 2Navigate to the `examples` directory and run `python simple_trading_agent.py` to see a basic example
  3. 3Modify the `config.json` file to define your own trading agents and LLM models
  4. 4Use the `trading_agent.py` script to run your custom trading agents, e.g., `python trading_agent.py --agent my_agent --model my_llm`
  5. 5Evaluate the performance of your trading agents using the `backtest.py` script, e.g., `python backtest.py --agent my_agent --start_date 2020-01-01 --end_date 2020-12-31`
Ready-to-paste prompt
python trading_agent.py --agent my_agent --model my_llm --paperTrading --verbose
Heads up: Make sure you have the required dependencies, including `transformers` and `pandas`, and that your Python version is compatible (Python 3.8 or later) before running the framework
Saves to your device

Topics

agent
finance
llm
multiagent
trading
How TradingAgents works
Codeflow
Free to inspect

TradingAgents is a medium Python project (~11k lines across 81 code files, plus 56 test files). Setup is light: installs like a normal app — add your API keys. Reading the code is optional. Last commit a month ago, Apache-2.0 license, has a test suite.

Size
Medium codebase
~11k lines · 81 code files · ~2 h to skim
Setup
One-command install
Installs like a normal app — add your API keys. Reading the code is optional.
Runs on
Python · Docker
Needs API keys (.env)
Python 100%
What happens, step by step

Tool analyzes market conditions

You give
Market data
1Data Input
Market data is collected
2Analysis
Specialized agents analyze data
tradingagents/__init__.py
3Discussion
Agents discuss optimal strategy
4Decision
Trading decision is made
main.py
You get
Trading decisions
Where to start reading
  1. 1
    README.md
    Start here — what it does and how to install it
  2. 2
    main.py
    Where the program starts running
  3. 3
    pyproject.toml
    Dependencies and the commands it exposes
  4. 4
    .env.example
    The API keys and settings you must provide
  5. 5
    tradingagents/__init__.py
    Inside tradingagents/ — the main logic begins here
What's in each folder
tradingagents/Core code — the actual logic71 files
cli/Command-line entry points8 files
scripts/Helper scripts1 files
tests/Tests — proof it works56 files
assets/Images & static assets10 files
.github/CI / automation (GitHub Actions)1 files
READMEHas testsDocumentedCI checksDocker readyApache-2.0 licenseUpdated this month
Quick Actions
Details
Creator
TauricResearch
Language
Python
Category
multi-agent
Published
12/28/2024

Are you the creator of this tool? Claim your listing → and earn 85% of every sale.