ChatGPT_Trading_Bot  by llSourcell

Trading bot for automated stock decisions

Created 2 years ago
976 stars

Top 37.9% on SourcePulse

GitHubView on GitHub
Project Summary

This repository provides the code for a "ChatGPT Trading Bot" as demonstrated in a YouTube video by Siraj Raval. It's designed for individuals interested in algorithmic trading and AI, offering a practical example of using reinforcement learning for stock price prediction and automated trading decisions.

How It Works

The project utilizes a single iPython notebook to execute a five-step process. It begins by downloading 30 days of historical trading data via Yahoo Finance. A simulated trading environment is then created using this data with the FinRL library. A neural network is trained within this simulation using reinforcement learning to predict stock prices. Finally, the trained model is backtested on the past 30 days of data to calculate potential returns, with trading decisions (buy/hold/sell) executed via the Alpaca API based on predefined return thresholds.

Quick Start & Requirements

  • Install/Run: Upload the provided iPython notebook to Google Colab.
  • Prerequisites: Python 3.7, Alpaca SDK, FinRL, Vercel, Firebase.
  • Setup: Requires uploading the notebook to Colab. Deployment for automated execution involves setting up a Flask app on Vercel with cron jobs to trigger the Colab notebook.

Highlighted Details

  • Leverages reinforcement learning for stock price prediction.
  • Integrates with Alpaca API for automated trading execution.
  • Demonstrates a full pipeline from data acquisition to trading decisions.
  • Codebase is contained within a single iPython notebook for ease of use in Colab.

Maintenance & Community

The core notebook is a published example from the FinRL team. Credits are also given to Alpaca for their API. No specific community links or active maintenance signals are provided in the README.

Licensing & Compatibility

The repository does not explicitly state a license. The code is presented as an example from the FinRL team and uses the Alpaca API, which has its own terms of service. Compatibility for commercial use or closed-source linking is not specified.

Limitations & Caveats

The project is presented as a demonstration for educational purposes, with a strong disclaimer against investing real money without willingness to lose it. The effectiveness of the trading strategy is not guaranteed, and the setup for automated execution requires additional deployment steps on platforms like Vercel.

Health Check
Last Commit

2 years ago

Responsiveness

Inactive

Pull Requests (30d)
0
Issues (30d)
0
Star History
8 stars in the last 30 days

Explore Similar Projects

Feedback? Help us improve.