ChatGPT Micro-Cap Experiment — Detailed Introduction
This repository contains the code, data, documentation and research behind a live trading experiment in which a large language model (ChatGPT) is used as the decision engine to manage a real-money micro-cap stock portfolio.
What the project does
- Runs a daily loop where market data is fed to an LLM and it recommends trades.
- Applies strict automated stop-loss and portfolio management rules implemented in Python.
- Records every trading-day result to CSV files and produces performance visualizations comparing the experiment to benchmarks (e.g., S&P 500).
- Publishes weekly deep-research reports, performance updates, and logs for transparency.
Repository contents (high level)
- trading_script.py — core trading engine that evaluates prices, executes position sizing and enforces stop-loss automation.
- Scripts and CSV Files/ — daily portfolio CSVs and trade history used for performance tracking.
- Start Your Own/ — templates and step-by-step guide for running a similar experiment.
- Weekly Deep Research (MD|PDF)/ — research summaries and full reports used by the experiment for periodic reevaluation.
- Experiment Details/ — methodology, prompts, Q&A, disclaimers and auxiliary documentation.
- Visualization and analytics tools — matplotlib scripts and routines for drawdown, Sharpe/Sortino, CAPM analysis, etc.
Key design points and features
- LLM-powered decision engine: the experiment uses a ChatGPT model to generate trade ideas and decisions based on supplied market data and research.
- Live trading focus: the repo is explicitly built around a real-money experiment (micro-cap stocks) with daily updates and logs.
- Safety & reproducibility: configurable stop-loss rules, detailed logging, and CSV-based state make the experiment auditable and reproducible.
- Data sources: primary market data via Yahoo Finance with Stooq as a fallback, plus utilities for backtesting via ASOF_DATE overrides.
- Transparency: weekly writeups on a public blog, full logs and CSVs in the repo, and published prompts and methodology so others can replicate or critique the setup.
Intended audience
Developers, researchers and traders interested in experiments at the intersection of LLMs and algorithmic trading, especially those who want a transparent, reproducible example of using generative models to inform trading decisions.
Limitations and disclaimers
- The author notes the portfolio has, at times, underperformed its benchmark; the repo includes disclaimers and encourages careful review before replicating with real funds.
- The experiment covers a defined period (June 2025 to December 2025) and uses specific model/versioning choices described in the docs and prompts.
How to get started
Follow the Start Your Own/README.md in the repo for templates, required dependencies (Python 3.11+, pandas, yfinance, matplotlib) and step-by-step instructions to run the trading engine and reproduce the tracking/visualizations.
(For more details, see the repository pages: code, prompts, research and performance CSVs.)
