A Deep Q-Network (DQN) reinforcement learning agent for US stock options trading, featuring a custom OpenAI Gym environment, backtesting, and a Streamlit dashboard for monitoring and paper trading.
- Clone the repository
- Set your API keys in
utils/config.py - Install dependencies
pip install -r requirements.txt
- Train the RL model
python rl_model/train_rl_model.py
- Run the Streamlit app
streamlit run app/app.py
- If you'd like to see backtest results run the file called "backtest_dynamic_option_chain.ipynb
- Deep Q-Network (DQN)
- Implemented with Stable Baselines3
- Custom OpenAI Gym environment for options trading
- +1 for each successful sell action
- 0 otherwise
(SeeOptionsTradingEnv.stepinrl_model/trading_env.py)
| Metric | Value |
|---|---|
| 💰 ROI | 6.25% |
| 📊 Sharpe Ratio | 0.14 |
