This project serves as an ideal solution to the above key question. We evaluate the trading capability of LLM across various financial markets given a unified environment. The LLM shall ingest external information, drive a multi-agent system, and make trading decisions. The LLM performance will be presented in a trading arena view across various dimensions.
π Car-racing is for illustration only. LLM performance is subject to the real market.
βΌοΈ This project is for research purposes only, it DOES NOT TRADE.
- 2025-07-03: Visit paradoox.ai and join waitlist to get early access to our product-ready release.
- 2025-06-20: Our vision paper is accepted by IJCAI 2025 FinLLM Workshop.
- 2025-06-09: DeepFund & Arena Leaderboard is available for demonstration.
- 2025-05-24: Our project paper is released on arXiv.
This project aims to be a long-term research project. We are adding more particular analysts, expanding market coverage and building dashboard to deliver fresh insights.
- General Inquiries: Mr. Changlun Li, cli942[at]connect.hkust-gz.edu.cn
- Research Collaboration: Prof. Yuyu Luo, yuyuluo[at]hkust-gz.edu.cn
-
Choose an environment manager:
- If you want to use Anaconda: Install Conda (if not already installed): Go to anaconda.com/download.
- If you want to use uv: Install uv (if not already installed): Go to uv installation guide.
-
Clone the repository:
git clone https://github.com/HKUSTDial/DeepFund.git
cd DeepFund
-
Create a virtual env from the env configuration file:
- If you are using Anaconda:
conda env create -f environment.yml # if using Conda
- If you are using uv:
uv sync # detects pyproject.toml, create an venv at project root, and install the dependencies source .venv/bin/activate # or .venv\Scripts\activate for windows to activate the venv
- If you are using Anaconda:
-
Set up environment variables:
# Create .env file for your API keys (OpenAI, DeepSeek, etc.)
cp .env.example .env
To better track the system performance, DeepFund uses a database to timely monitor the trading status. Besides, it also stores the LLM reasoning results for future analysis and traceback.
DeepFund connects to Supabase by default.
- Supabase is a PostgreSQL-compatible Cloud Database
- You can create a free account on Supabase website.
- Refer to
src/database/supabase_setup.sql
to create the tables. - Update the
SUPABASE_URL
andSUPABASE_KEY
in.env
file.
SQLite is a lightweight database that stores data locally.
- Run the following command to create a sqlite database in the path
cd src
python database/sqlite_setup.py
- You may need to install VSCode Extension SQLite Viewer to explore the database.
- Path:
src/assets/deepfund.db
DeepFund system gets supported by four elementary tables:
- Config: store user-defined configurations
- Portfolio: record the portfolio updates
- Decision: record the trading decisions from managers
- Signal: record the signals generated from analysts
The ERD is generated by Supabase - DB Schema Visualizer.
Enter the src
directory and run the main.py
file with configuration:
cd src
python main.py --config xxx.yaml --trading-date YYYY-MM-DD [--local-db]
trading-date
coordinates the trading date for the system. It can be set to historical trading date till the last trading date. As the portfolio is updated daily, client must use it in chronological order to replay the trading history.
Switch to local DB by adding --local-db
option in the command line.
Configs are saved in src/config
. Below is a config template:
# Deep Fund Configuration
exp_name: "my_unique_exp_name"
# Trading settings
tickers:
- ticker_a
- ticker_b
# Analysts to run, refer to graph.constants.py
planner_mode: true/false
workflow_analysts:
- analyst_a
- analyst_b
- analyst_c
# LLM model settings, refer to llm/inference.py
llm:
provider: "provider_name"
model: "model_name"
We use planner_mode
configs to switch the mode:
- True: Planner agent orchestrates which analysts to run from
workflow_analysts
. - False: All workflow analysts are running in parallel without orchestration.
exp_name
is unique identifier for each experiment. You shall use another one for different experiments when configs are changed.- Specify
--local-db
flag to use SQLite. Otherwise, DeepFund connects to Supabase by default.
deepfund/
βββ src/
β βββ main.py # Main entry point
β βββ agents/ # Agent build and registry
β βββ apis/ # APIs for external financial data
β βββ config/ # Configuration files
β βββ database/ # Database setup and helper
β βββ example/ # Expected output
β βββ graph/ # Workflow, prompt, and schema
β βββ llm/ # LLM providers
β βββ util/ # Utility functions and helpers
βββ environment.yml # For Conda
βββ README.md # Project documentation
βββ ...
Technical Guide - Detailed information for developers including:
- Analyst breakdown and system architecture
- System dependencies and API requirements
- Advanced usage: Adding new analysts and LLM providers
The project gets inspiration and supports from the following projects:
- AI Hedge Fund, An AI Hedge Fund Team
- LangGraph, Tutorial on Workflows and Agents
- OpenManus, An open-source framework for building general AI agents
- Supabase, The Open Source Firebase Alternative
- Cursor AI, The AI Code Editor
If you find it useful, please cite it as follows:
- Project Paper
@misc{li2025timetravel,
title={Time Travel is Cheating: Going Live with DeepFund for Real-Time Fund Investment Benchmarking},
author={Changlun Li and Yao Shi and Chen Wang and Qiqi Duan and Runke Ruan and Weijie Huang and Haonan Long and Lijun Huang and Yuyu Luo and Nan Tang},
year={2025},
eprint={2505.11065},
archivePrefix={arXiv},
primaryClass={cs.CE},
url={https://arxiv.org/abs/2505.11065},
}
- Vision Paper
@misc{li2025deepfund,
title={DeepFund: Will LLM be Professional at Fund Investment? A Live Arena Perspective},
author={Changlun Li and Yao Shi and Yuyu Luo and Nan Tang},
year={2025},
eprint={2503.18313},
archivePrefix={arXiv},
primaryClass={cs.MA},
url={https://arxiv.org/abs/2503.18313},
}