GapRunner is a production-ready overnight gap trading system built by Roman Slack that implements a momentum-gap strategy with real-time data collection, advanced portfolio simulation, and comprehensive risk management. The system trades the top K gap-up stocks each session, using a sophisticated momentum strategy with multiple exit conditions including profit targets, trailing stops, hard stops, and time-based exits.
The platform follows a two-tier architecture. Tier 1 is a data layer featuring a robust data pipeline with progress tracking, multi-source data providers (Yahoo Finance, Polygon, Tiingo), partitioned Parquet storage for efficient access, and data validation. Tier 2 is an analysis and trading layer that pairs a Streamlit dashboard with real-time gap detection and ranking, an advanced portfolio simulation engine, and comprehensive performance analytics.
GapRunner's strategy enters the top gap-up stocks at the 09:30 ET market open and applies configurable exits: a +10% profit target, a 2% trailing stop from session high, a -4% hard stop, and a 15:55 ET time stop. Risk management includes configurable position sizing, maximum position limits, and sector diversification, while the cost model accounts for commissions and slippage in all P&L calculations. The system is configured entirely through validated YAML files and emphasizes security hardening and production readiness.
Notable for its professional-grade engineering, GapRunner provides CLI tools with rich progress bars for data collection and gap analysis, a web-based configuration UI, API key encryption, audit logging, and a documented Python API exposing Config, DataCollector, GapEngine, and PortfolioEngine classes for backtesting and live execution.
Key Features
- Two-tier architecture separating data collection from analysis and trading
- Multi-source data providers with failover (Yahoo Finance, Polygon, Tiingo)
- Real-time gap detection and ranking with technical indicators
- Advanced portfolio simulation and backtesting engine with cost modeling
- Configurable exit conditions: profit target, trailing stop, hard stop, time stop
- Interactive Streamlit dashboard with risk metrics and drawdown analysis
- YAML-based configuration with validation and security hardening
Tech Stack
Designed and built by Roman Slack, Lead AI Platform Engineer. See more of Roman Slack's work on the projects page or get in touch via the contact page.