Skip to content
 
 

Latest commit

 

History

276 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Stock Ticker Analysis and Prediction System using Stacked LSTM

Python TensorFlow XGBoost Streamlit React Docker License

📋 About

Ticker-Prediction System is an advanced machine learning project that leverages LSTM (Long Short Term Memory) neural networks combined with XGBoost ensemble methods to predict stock market trends using time-series analysis.

Key Features

  • 🤖 Deep Learning Architecture: Stacked LSTM model for capturing temporal dependencies in stock data
  • 📊 Data Preprocessing: Advanced techniques for continuous dataset normalization and transformation
  • 🚀 Ensemble Method: XGBoost integration to enhance prediction accuracy
  • 🎨 Dual Interface: Both Streamlit web app and React-based frontend
  • 🐳 Docker Support: Containerized deployment with version tracking
  • 📈 Time-Series Prediction: Sophisticated forecasting for financial data

Note: All research, testing, and model training work are maintained in a separate repository with different epoch cycles and parameters.

📖 Description

This project combines cutting-edge deep learning techniques with practical deployment strategies:

  • Core Technology: LSTM networks with XGBoost ensemble methods for superior prediction performance
  • Multiple Interfaces:
    • Streamlit Application - Quick web-based interface
    • React Application - Full-featured frontend with advanced UI/UX
  • Containerization: Docker images for consistent deployment across environments with semantic versioning

🚀 Getting Started

Prerequisites

  • Python 3.8+
  • Node.js 14+
  • Docker (optional, for containerized deployment)
  • Git

1. Local Installation

Frontend (React)

Navigate to the Ticker Predictor Website folder:

cd "Ticker Predictor Website"
cd "Front-end"
npm install
npm run start

The React app will be available at https://localhost:3000

Backend (Python)

In a separate terminal, navigate to the Backend folder:

cd "Ticker Predictor Website"
cd "Backend"
python waitress_server.py

The backend server will connect with the React frontend automatically.

Visual Guide:

Terminal Output Example:
✓ Backend running on http://localhost:5000
✓ Frontend running on http://localhost:3000
✓ Connected and ready for predictions

2. Docker Deployment

Option A: React + Python Backend

Terminal 1 - Backend:

docker run -p 5000:5000 debasishray/predictor-backend:latest

Terminal 2 - Frontend:

docker run -p 3000:3000 debasishray/predictor-frontend:latest

Then navigate to: https://localhost:3000

Option B: Streamlit Application

docker run -p 8501:8501 debasishray/streamlit-app:latest

Access the app via the link provided in the terminal output.

🐳 Docker Image Deployment to GitHub Packages

Step-by-Step Guide

  1. Create a Docker image replica with a new tag:
docker tag debasishray/streamlit-app:v1.0 webapp
  1. Tag for GitHub Container Registry:
docker tag webapp ghcr.io/debasishray16/stockpredictor/webapp:latest
docker image ls
  1. Authenticate with GitHub Packages:
echo "YOUR_PAT_TOKEN" | docker login ghcr.io -u debasishray16 --password-stdin
  1. Push to GitHub Packages:
docker push ghcr.io/debasishray16/stockpredictor/webapp:latest

Format: ghcr.io/<username>/<repository>/<image>:tag

📊 Project Structure

StockPredictor/
│
├── 📄 README.md                          # Project documentation
├── 📄 LICENCE                            # MIT License
├── 📄 .gitignore                         # Git ignore configuration
├── 📄 docker-compose.yml                 # Docker Compose configuration
│
├── 📂 Ticker Predictor Website/          # Main application folder
│   │
│   ├── 📂 Front-end/                     # React Frontend Application
│   │   ├── 📄 package.json               # Node.js dependencies
│   │   ├── 📄 package-lock.json          # Dependency lock file
│   │   ├── 📄 tailwind.config.js         # Tailwind CSS configuration
│   │   ├── 📄 Dockerfile                 # Frontend container config
│   │   ├── 📄 .dockerignore              # Docker ignore rules
│   │   ├── 📄 .gitignore                 # Git ignore rules
│   │   │
│   │   ├── 📂 public/                    # Static public assets
│   │   │   ├── 📄 index.html             # Main HTML entry point
│   │   │   ├── 📄 manifest.json          # PWA manifest
│   │   │   └── 📄 robots.txt             # SEO robots configuration
│   │   │
│   │   └── 📂 src/                       # Source code
│   │       ├── 📄 index.js               # React entry point
│   │       ├── 📄 index.css              # Global CSS styles
│   │       ├── 📄 App.js                 # Main App component
│   │       ├── 📄 App.css                # App-specific styles
│   │       ├── 📄 reportWebVitals.js     # Performance monitoring
│   │       │
│   │       ├── 📂 Components/            # React Components
│   │       │   ├── 📄 Main.js            # Main dashboard component
│   │       │   ├── 📄 Sidebar.js         # Sidebar navigation (70KB)
│   │       │   ├── 📄 Dashboardview.js   # Dashboard view component
│   │       │   ├── 📄 StockPredictionChart.js  # Chart visualization
│   │       │   ├── 📄 LoadingAnim.js     # Loading animation component
│   │       │   ├── 📄 Spinner.js         # Spinner component
│   │       │   ├── 📄 aboutModel.js      # Model information component
│   │       │   ├── 📄 companyInfo.js     # Company details (9KB)
│   │       │   ├── 📄 companyDesc.js     # Company description
│   │       │   │
│   │       │   └── 📂 Styles/            # Component-specific styles
│   │       │       └── 📄 spinner.css    # Spinner animations
│   │       │
│   │       ├── 📂 router/                # Route configuration
│   │       │   └── 📄 Router.js          # React Router setup
│   │       │
│   │       └── 📂 assets/                # Media assets
│   │           ├── 🎞️ idle.gif          # Idle state animation
│   │           ├── 🎞️ loading.gif       # Loading animation
│   │           └── 🎞️ loading2.gif      # Alternative loading animation
│   │
│   └── 📂 Back-end/                      # Python Backend Server
│       ├── 📄 model_api.py               # ML model API (12.7KB)
│       ├── 📄 waitress_server.py         # WSGI server launcher
│       ├── 📄 requirements.txt           # Python dependencies
│       ├── 📄 Dockerfile                 # Backend container config
│       ├── 📄 .dockerignore              # Docker ignore rules
│       │
│       └── 📂 model/                     # Trained ML Models
│           ├── 🤖 8_15_23_125_LXg.h5     # LSTM model (2.2MB)
│           └── 🤖 8_15_23_300_LXg.h5     # LSTM model (2.2MB)
│
├── 📂 assets/                            # Project assets
│   ├── 📂 images/                        # Documentation images
│   │   ├── 🖼️ Website_Preview.png       # Website screenshot
│   │   └── 🖼️ terminal_screenshot.png   # Terminal output screenshot
│   │
│   └── 📂 dataset/                       # Training datasets (optional)

🔗 Related Resources

👥 Contributors

📝 License

This project is licensed under the MIT License - see the LICENSE file for details.

🤝 Support & Contributing

For questions, suggestions, or issues:


Last Updated: 2026-04-29 | Status: Active Development

About

"Stock Ticker Predictor" project basically aims to provide a visual representation and analysis of data related to time-series data which is constantly changing. This provides a dashboard to user, made using reactJs - tailwindCSS, displaying current trends and stocks data which uses "LSTM" + "XGBoost" model.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages