Skip to content

Data Adapters

weich97 edited this page May 17, 2026 · 1 revision

Data Adapters

TradeArena's stable market-data boundary is normalized OHLCV CSV.

Data source -> Date,Open,High,Low,Close,Volume CSV -> CsvMarketDataProvider

This lets users connect data providers without rewriting the agent runner.

Supported Paths

  • Synthetic market data for quick local tests.
  • Yahoo-style OHLCV CSV files for historical experiments.
  • Optional sidecar CSV files for news, macro, filings, and alternative data.
  • AkShare download path for A-share daily history.

A-Share Example

python -m pip install -e ".[ashare]"
python scripts/download_akshare_ashare_daily.py \
  --symbols 600519.SS,300750.SZ \
  --start 2021-01-01 \
  --end 2026-05-14 \
  --output-dir data/real/akshare_ashare_daily

Then reuse the same benchmark stack:

python -m trading_agent_os.cli \
  --benchmark tradearena-core \
  --data-source csv \
  --real-data-dir data/real/akshare_ashare_daily \
  --symbols 600519.SS,300750.SZ \
  --real-max-periods 80

Clone this wiki locally