Skip to content

ljime080/Capstone-Project

Repository files navigation

RL Options Trading Bot

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.


🚀 Running Instructions

  1. Clone the repository
  2. Set your API keys in utils/config.py
  3. Install dependencies
    pip install -r requirements.txt
  4. Train the RL model
    python rl_model/train_rl_model.py
  5. Run the Streamlit app
    streamlit run app/app.py
  6. If you'd like to see backtest results run the file called "backtest_dynamic_option_chain.ipynb

🧠 Model Type

  • Deep Q-Network (DQN)
  • Implemented with Stable Baselines3
  • Custom OpenAI Gym environment for options trading

🏆 Reward Function

  • +1 for each successful sell action
  • 0 otherwise
    (See OptionsTradingEnv.step in rl_model/trading_env.py)

📈 Model Results

Trading App Screenshot

Metric Value
💰 ROI 6.25%
📊 Sharpe Ratio 0.14

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published