Model or dataset
hsliuping/TradingAgents-CN avatar
hsliuping/TradingAgents-CN

TradingAgents-CN: a Chinese-language multi-agent LLM stock analysis platform

基于多智能体LLM的中文金融交易框架 - TradingAgents中文增强版

31,942 stars6,679 forksPythonNOASSERTION

At a glance

What is it?
TradingAgents-CN is a fork of Tauric Research's TradingAgents that adds Chinese localization, A-share and Hong Kong data sources, a FastAPI plus Vue stack, and a mixed licence that puts app/ and frontend/ under commercial terms. It is a research and teaching tool, not a trading system.
Who is it for?
Adopt TradingAgents-CN if you want a Chinese-language environment for studying how multiple LLM agents split an equity research task, and you are comfortable with a Python 3.10+ stack, MongoDB, Redis and a mandatory data sync step before any analysis runs. Do not adopt it if you need a commercially licensed product, because app/ and frontend/ sit outside the Apache 2.0 grant and the README states that no commercial authorization has been granted to any organization.
Can I use it commercially?
Check first. The repository uses a licence we do not classify automatically, so read its LICENSE file before any commercial use.
Is it still maintained?
Yes. The repository last received commits 8 days ago.
What is it written in?
Mainly Python, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on September 22, 2026, and from our analysis. They are not legal advice.

Editorial analysis

What TradingAgents-CN adds to the upstream TradingAgents project

The upstream project, TauricResearch/TradingAgents, is an English-language multi-agent trading framework. TradingAgents-CN keeps that architecture and rebuilds the surrounding product for Chinese users: A-share and Hong Kong coverage, Chinese documentation, and a web interface instead of a script you run from a shell. The README describes the project's mission as learning and research, and states plainly that it does not issue live trading instructions. That framing matters, because the interesting engineering work here is not the agent prompts but the data plumbing and the deployment surface.

The target reader is a developer or quantitatively minded analyst who wants to watch several LLM roles argue about a stock in Chinese, using mainland data sources rather than Yahoo Finance alone. If you only need English-language analysis of US tickers, the upstream repository is the shorter path. The fork's value is concentrated in localization and in the operational scaffolding around it.

The analyst-agent pipeline and where the data comes from

The framework assigns distinct roles to separate LLM calls, then routes their outputs through a graph. The repository layout shows a tradingagents/ package alongside a separate app/ directory, and the release notes for v1.1.0 name specific modules: trading_graph.py holds the main provider initialization path, fundamentals_analyst.py handles fundamental analysis, and an llm_clients abstraction layer sits under the model calls. The release notes also mention a risk-control reference fix and layer-parameter passing, which tells you the graph is parameterized rather than hardcoded per role.

Market data arrives through Tushare, AkShare and BaoStock, with yfinance, finnhub-python and eodhd also listed in pyproject.toml for non-mainland coverage. The README carries a warning in bold: before analyzing a stock, you must complete the data sync according to the documentation, otherwise the analysis will contain data errors. That is not boilerplate. A multi-agent pipeline that reads stale or missing fundamentals will produce confident prose about numbers that do not exist, and the failure is silent because the LLM has no way to know the row is absent.

Storage is MongoDB plus Redis. The docker-compose.yml sets TRADINGAGENTS_CACHE_TYPE to redis and points MongoDB at a local container, with a healthcheck against http://localhost:8000/api/health. Reports can be exported as Markdown, Word or PDF, which pulls in pypandoc and pdfkit, and pdfkit in turn requires the wkhtmltopdf binary to be present on the host.

Installing TradingAgents-CN and running a first analysis

The README offers two paths and links both to WeChat articles rather than in-repo instructions: a Docker deployment for production and cross-platform use, and a local source install for developers. The repository also ships docker-compose.yml, docker-compose.hub.nginx.yml and an ARM64 variant. The requirements.txt file is explicitly deprecated and points to pyproject.toml, which requires Python 3.10 or newer.

Start by copying the environment template. The .env.example file marks MongoDB, Redis, JWT and CSRF settings as required, and you should replace the placeholder secrets before anything starts.

bash
cp .env.example .env
python -c "import secrets; print(secrets.token_urlsafe(32))"

The second command generates a value you can paste into JWT_SECRET. The template warns that the default JWT and CSRF secrets must be changed in production.

For a local source install, the deprecated requirements.txt tells you the supported form:

bash
pip install -e .
# or, with uv:
uv pip install -e .

For the containerized path, the compose file defines a backend service on port 8000 with volumes for ./logs, ./config and ./data, and depends on healthy MongoDB and Redis containers. Bringing it up is the standard two-step:

bash
docker compose up -d
docker compose ps

After startup, the backend healthcheck endpoint is /api/health on port 8000. If the container reports unhealthy, the compose file's start_period of 60s means you should wait before concluding the build failed.

The examples/ directory contains runnable entry points including simple_analysis_demo.py, cli_demo.py, batch_analysis.py and test_installation.py. The README does not document the arguments these scripts accept, so read the files themselves before running them. Whichever path you take, sync your stock data first; the README treats this as a precondition for correct output.

The mixed licence is the largest adoption risk

The README describes a hybrid licence model: files outside app/ and frontend/ fall under Apache 2.0, while app/ (the FastAPI backend) and frontend/ (the Vue front end) are proprietary and require commercial authorization. The repository root contains LICENSE, LICENSING.md, COPYRIGHT.md and COMMERCIAL_LICENSE_TEMPLATE.md, which is consistent with that split, but the GitHub licence field reports NOASSERTION because the combination does not map to a single SPDX identifier.

The README also states that the project group has granted no commercial authorization to any organization, and names tradingagents-ai.com as an unauthorized user of the code. For an engineer evaluating this for a company, that paragraph is the decision point. Apache 2.0 covers the analysis library, but the web application most people actually want to deploy sits behind a separate grant that has to be requested by email.

The version roadmap compounds this. v2.0 is described as developed and stable but not yet open sourced, and will only be released after v3.0 ships. v3.0 is described as development-complete with internal testing underway, and includes features not present in the open v1.1.0: an AI workflow designer, review research, position research, a Skill system and an assistant. So the open code is deliberately one or two generations behind the private code. That is a legitimate business model, but you should plan around it rather than assume the public branch will track the upstream project's pace.

Upstream synchronization is manual and selective. The docs/maintenance/upstream-sync.md and manual-upstream-absorption-checklist.md files document this, and the README lists the upstream capabilities already absorbed into v1.1.0, including the llm_clients abstraction layer, provider canonical key normalization and a qwen fresh LLM rebuild path in fundamentals_analyst.py. Manual absorption means upstream fixes do not arrive automatically; someone has to decide to take them.

Where the platform breaks down, and when to pick something else

The most concrete limitation is the data dependency. The README's warning about syncing before analysis means the system is only as good as your local mirror of Tushare, AkShare or BaoStock data. If a sync job fails partway, the agents still run and still produce reports. There is no documented gate that refuses to analyze a stock with incomplete fundamentals, and the README does not document rollback for a partial sync.

The second constraint is infrastructure weight. MongoDB and Redis are both marked required in .env.example, and the compose file wires them as dependencies. That is a heavier footprint than a single-process script, and it means the Docker path is the realistic one for anyone who does not already run those services. The local install is rated as harder in the README's own comparison table.

The third is network topology. The example environment file includes a NO_PROXY list covering eastmoney.com, gtimg.cn, sinaimg.cn, api.tushare.pro and baostock.com, with a note that Windows does not support wildcards and requires full domain names. If you route Google AI traffic through a proxy while mainland data sources must go direct, that split has to be configured correctly or the data sync will fail in ways that look like provider errors.

A different tool for a different job: if your goal is backtesting a defined strategy against historical prices, a vectorized backtesting library is the right instrument and this is not it. TradingAgents-CN produces narrative analysis from LLM agents; it does not give you a fill-by-fill simulation with slippage modelling. The README positions the built-in simulated trading system as a way to validate strategy ideas, not as a backtest engine. Choose based on whether you want reasoning traces or return statistics.

Frequently asked questions about TradingAgents-CN

The questions below cover the points that come up most often when deciding whether to install the project, drawn from what the README, pyproject.toml, docker-compose.yml and .env.example actually state.

Editorial conclusion

Adopt TradingAgents-CN if you want a Chinese-language environment for studying how multiple LLM agents split an equity research task, and you are comfortable with a Python 3.10+ stack, MongoDB, Redis and a mandatory data sync step before any analysis runs. Do not adopt it if you need a commercially licensed product, because app/ and frontend/ sit outside the Apache 2.0 grant and the README states that no commercial authorization has been granted to any organization. Before committing, verify three things: which licence actually covers the directories you intend to ship, whether the Tushare, AkShare and BaoStock sync completes for your tickers, and whether your chosen LLM provider (DeepSeek, Qwen, Google AI or VolcEngine Ark) is reachable through your network and proxy settings.

Frequently asked questions

What is the TradingAgents multi-agent LLM financial trading framework?

It is a framework that assigns separate analyst roles to separate LLM calls and routes their outputs through a graph to produce equity research. TradingAgents-CN is a Chinese-localized fork of Tauric Research's original project, adding A-share and Hong Kong coverage plus a FastAPI and Vue web interface.

How do I install TradingAgents-CN?

The README lists two paths: a Docker deployment for production and cross-platform use, and a local source install for developers. For local installs, requirements.txt is deprecated and directs you to pip install -e . or uv pip install -e . against pyproject.toml, which requires Python 3.10 or newer.

Can I deploy TradingAgents-CN with Docker?

Yes. The repository ships docker-compose.yml plus nginx variants for amd64 and ARM64. The compose file defines a backend on port 8000, depends on healthy MongoDB and Redis services, and exposes a healthcheck at /api/health.

Is TradingAgents-CN free for commercial use?

The README describes a hybrid licence: files outside app/ and frontend/ are Apache 2.0, while app/ and frontend/ are proprietary and require commercial authorization. The README also states that no commercial authorization has been granted to any organization, with authorization requests directed to the project email.

Which market data sources does TradingAgents-CN support?

pyproject.toml lists akshare, baostock, tushare, yfinance, finnhub-python and eodhd. The README warns that stock data must be synced before analysis, otherwise results will contain data errors.

Official sources

  1. hsliuping/TradingAgents-CN on GitHub
  2. Issues
  3. README
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/hsliuping-tradingagents-cn.svg)](https://hysenlabs.com/projects/hsliuping-tradingagents-cn)