← All resourcesTR
124October 3, 2026·5 items

An open source project that builds an investment firm out of AI agents: TradingAgents. But it's not a trading bot, it's a research tool

TradingAgents is a free framework that mimics how a real investment firm works, using AI agents. You enter a ticker; four analysts look at the company from different angles, a bull and a bear researcher debate, the trader decides, the risk team challenges it and the portfolio manager has the final say. It writes every decision to a memory file, and the next time it looks at the same stock it checks what actually happened and draws a lesson. Below: how the organization works, the install, how to try it on non-US stocks, and the limits you should know before using it.

Geliştirici Araçları

The project itself

The repo is Apache 2.0 licensed, completely free, with over 100k stars on GitHub. There's an arXiv paper behind it too. If you'd rather go straight there, the button opens the repo.

What's extra below: which agent does what and in which order, two small differences that break the install on Windows, why fundamentals can come up short on non-US stocks, and how the "it scores itself" part actually works.

TradingAgents repo

How the organization works

The idea: instead of asking one model "buy or sell this stock," split the work into roles the way a real firm does. Each agent focuses on its own job, and the decision comes from a process rather than a single model.

What happens when you enter a ticker

  1. 1

    Four analysts

    Fundamentals, news and macro, sentiment (StockTwits, Reddit), technical indicators. They run at the same time

  2. 2

    Bull vs bear debate

    Two researchers read the reports and argue it out: upside versus risk

  3. 3

    Trader

    Turns all the reports into a trade proposal: timing and size

  4. 4

    Risk team

    Looks at volatility and liquidity, challenges and adjusts the proposal

  5. 5

    Portfolio manager

    Approves or rejects. If approved, the order goes to a simulated exchange

The key word in the last step: simulated exchange. TradingAgents doesn't connect to your broker and doesn't place real orders. Its output is a decision plus the reports behind it.

Install

You need Python 3.11 or newer. Clone the repo, create a virtual environment and install the package.

Mac / Linux
git clone https://github.com/TauricResearch/TradingAgents.git
cd TradingAgents
python3 -m venv .venv
source .venv/bin/activate
pip install .
Windows (PowerShell)
git clone https://github.com/TauricResearch/TradingAgents.git
cd TradingAgents
python -m venv .venv
.venv\Scripts\Activate.ps1
pip install .

Then add your API key. The README shows export commands, but export doesn't work in PowerShell; the .env file is the smoothest route and it's the same on every OS.

Create the .env file
cp .env.example .env
# On Windows: copy .env.example .env
# Then open .env and fill in your provider's line:
# ANTHROPIC_API_KEY=...  or  OPENAI_API_KEY=...
Run it
tradingagents

On the screen that opens you pick the ticker, the analysis date, the LLM provider and the research depth, and watch the agents work live. If you prefer Docker the repo supports that too: after filling in .env, docker compose run --rm tradingagents.

Where the install trips people up

Typing source .venv/bin/activate on Windows.

The folder is different on Windows: .venv\Scripts\Activate.ps1. If script execution is blocked, run Set-ExecutionPolicy -Scope CurrentUser RemoteSigned once in PowerShell.

Entering only a Claude key and carrying on with the default models.

The default models are OpenAI's. Pick whichever provider your key is for in the CLI; Claude, Gemini, DeepSeek, OpenRouter and local Ollama are all supported.

Trying it on non-US stocks

Price data comes from Yahoo Finance, and the project accepts any market Yahoo covers using the exchange suffix: 0700.HK, 7203.T, AZN.L, RELIANCE.NS. Borsa Istanbul stocks use .IS, for example THYAO.IS. For crypto, BTC-USD.

Past-dated runs lose fundamentals

US companies' statements come from SEC EDGAR, exactly as they stood on that date. For non-US companies Yahoo is used, and since Yahoo can't say when a figure was published, a run dated in the past doesn't get those statements. A run dated today is fine. So if you analyze a non-US stock as of a day last year, the fundamentals part comes up thin; it's not a bug, it's a deliberate choice that stops it from seeing the future.

How the "it scores itself" part actually works

Memory is always on. Every finished run appends its decision to ~/.tradingagents/memory/trading_memory.md. The next time you run the same ticker it looks up the realized return of the earlier decision, both raw and relative to that market's benchmark, writes a one-paragraph reflection, and puts it in front of the portfolio manager along with recent decisions.

So the learning isn't model training: it's adding past decisions and their outcomes as notes to the next prompt. It works, but only when you come back to the same stock over time. Run a single analysis today and memory gives you nothing.

If you want to see whether the system actually decides well, there's a backtest command: it runs the same pipeline over several tickers across a date range and scores each decision against the return that followed. It doesn't touch your own memory file.

Backtest
tradingagents backtest NVDA,AAPL --start 2026-06-01 --end 2026-08-01 --every 7

Before you use it

The project describes itself plainly as a research tool and states it is not investment advice. Two runs on the same ticker and date can reach different decisions, because the models reason differently each time and news and social data change over time. Also, every analysis means many model calls across a dozen agents; the API bill grows much faster than with a single chat. Keep research depth low on your first try.

DOA: Yapay Zeka ve Otomasyon

Installing these tools on your own is one thing; actually building with them is another. The community has people using these daily and people building systems from scratch.

DOA: Yapay Zeka ve Otomasyon

If you want a system that actually runs in your business, let's talk for 10 minutes; I'll look at what you're trying to build and tell you which path fits. Free, and not a sales pitch.

Book a 10-minute call

If you'd rather learn this alongside people doing the same work instead of on your own, the community is always open:

Join the community

This is an affiliate link.

← All resources