efe66c62eab12fecce1f30839071876c62e61760
中文 | English
AITD - AI Trading Agent
🤖 AITD is a local AI trading agent project that can run on almost any machine. You can configure it, validate in paper trading, and run live trading directly in the browser.
Highlights
- Fully customizable trading prompts so you can shape the strategy around your own style
- Define the AI trader role, core principles, entry rules, and position management rules
- Save prompts, load historical prompts, and switch to a saved prompt with one click
- Dynamic candidate universe support for flexible symbol selection
- Useful for sourcing hot symbols from your own workflow
- Custom trading intervals
- Real-time visibility into AI trader inputs and decisions
- Check whether the input data for each cycle looks correct
- Check whether the trading actions from each cycle look correct
- Rich portfolio risk controls and detailed trade records
- One-click switching between paper trading and live trading
- Support for major AI model providers
- Fully local runtime so account credentials, prompts, and other sensitive information stay on your machine
Supported Exchanges
- Crypto:
- ✅ Binance
- OKX (todo)
- BYBIT (todo)
- Gate (todo)
- Futures:
- CTP (todo)
- IBKR (todo)
Requirements
✅ All you need is Python 3.11+
Quick Start
After downloading the project, run this in the project root:
python3 run.py
You can also specify the port explicitly:
python3 run.py --port 1234
Then open the local address printed in the terminal, for example:
http://127.0.0.1:8788/trader.html
First-Time Setup Suggestions
- Prepare your LLM
API_KEY - Prepare your exchange
API Key / Secret, and add your local machine IP to the exchange whitelist if required
- Start from the
Paper Tradingpage. - In
AI Model Config, fill inProvider / Model / API Key / Base URL. - If you need a proxy, enable it in
Proxy Configand enter the proxy address. - In the
Prompttab, edit your trading logic and test it to make sure the AI model works correctly. - In the
Candidate Pooltab, choose one of the following:Static Candidate Pool: manually enter the symbols you want to tradeDynamic Candidate Pool: write a Python function to fetch dynamic symbols
- Click
Start Tradingon the current page. - Check
Trading / Prompt / Logto confirm everything is working as expected. - After paper trading runs end to end successfully, configure your live account and start live trading.
Feature Overview
Tradingshows account status, equity curve, open positions, candidate symbols, and recent decisions
Promptlets you edit trading logic, adjust position management logic, and test whether the prompt works correctly
Candidate Poolsupports either static symbols or a dynamic Python function
Logshows runtime logs and error messages from the current process
Key Files
- run.py Startup entry point
- dashboard/ Browser UI assets
- config/ Default configuration files
Contact
- X: @ywa_ywa_ywa
- Telegram: @ywa_yl
Copyright and Usage
Copyright © 2026 Yaolin Wang. All rights reserved.
This repository is currently shared for evaluation, learning, and personal reference only. Any commercial use, redistribution, hosted deployment, or integration into paid services requires prior written permission.
For commercial licensing, please contact me through the links above.
Languages
Python
58.7%
JavaScript
24.8%
CSS
11.3%
HTML
5.2%




