Skip to content

MayankSahu297/Automated-Warehouse-System

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

6 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

LogisTech: Automated Warehouse Management System

![LogisTech Banner] Screenshot 2025-11-24 132101

๐ŸŒ Live Demo

๐Ÿ‘‰ Deployed Link: https://logistech-prime.onrender.com/

Project Description

LogisTech is a full-stack Automated Warehouse Orchestration System that simulates real-world warehouse operations. It manages incoming packages, finds optimal storage bins using Binary Search, loads trucks using Stack logic, and validates fragile shipments through Backtracking. A centralized Singleton Controller powers the entire workflow, while SQL audit logs ensure complete traceability of every operation.

๐Ÿ“‘ Table of Contents

  1. Features
  2. System Architecture
  3. Algorithms Implemented
  4. Tech Stack
  5. Database Schema
  6. Installation Steps
  7. How to Run
  8. API Endpoints
  9. UI Screenshots
  10. Future Enhancements
  11. License

๐Ÿš€ Features

๐Ÿ“ฆ Package Ingestion (Queue โ€“ FIFO)

  • Add new packages to conveyor belt
  • Processes items in arrival order (First-In, First-Out)

๐Ÿ—„๏ธ Smart Storage Allocation (Binary Search)

  • Bins are sorted by capacity
  • Finds the best-fitting bin in $O(\log N)$ time
  • Prevents storage inefficiency and item damage

๐Ÿšš Truck Loading Simulator (Stack โ€“ LIFO)

  • Load packages in LIFO (Last-In, First-Out) order
  • Rollback mechanism to unload items if the wrong package is loaded

๐Ÿ” Shipment Planner (Backtracking)

  • Validates fragile package combinations
  • Checks if a specific set of bundles fits inside the truck capacity

๐Ÿง  Singleton Warehouse Controller

  • Centralized decision-making
  • Prevents race conditions by ensuring only one controller instance exists

๐Ÿ—ƒ SQL Audit Logging

  • Logs every storage, loading, and rollback event
  • Ensures traceability after server restart

๐Ÿ— System Architecture

The system follows a centralized "Control Tower" architecture where the WarehouseController (Singleton) coordinates all operations.

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                         USER / WEB UI                        โ”‚
โ”‚                    (HTML + CSS + JavaScript)                 โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                         โ”‚ HTTP Requests
                         โ–ผ
โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                      FastAPI Backend                         โ”‚
โ”‚                    (REST API Endpoints)                      โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                         โ”‚
                         โ–ผ
โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚              LogisTech Controller (Singleton)                โ”‚
โ”‚                  Centralized Orchestration                   โ”‚
โ””โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
  โ”‚           โ”‚            โ”‚              โ”‚
  โ–ผ           โ–ผ            โ–ผ              โ–ผ
โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚Queue โ”‚  โ”‚Stack โ”‚  โ”‚Binary    โ”‚  โ”‚Backtracking โ”‚
โ”‚(FIFO)โ”‚  โ”‚(LIFO)โ”‚  โ”‚Search    โ”‚  โ”‚Planner      โ”‚
โ””โ”€โ”€โ”ฌโ”€โ”€โ”€โ”˜  โ””โ”€โ”€โ”ฌโ”€โ”€โ”€โ”˜  โ””โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”˜  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”˜
   โ”‚         โ”‚           โ”‚                โ”‚
   โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ดโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ดโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                         โ”‚
                         โ–ผ
              โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
              โ”‚  SQLite Database     โ”‚
              โ”‚  (Audit Logs + Bins) โ”‚
              โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Explanation:

  • Frontend โ†” Backend โ†” Database are loosely coupled for scalability.
  • The Controller acts as the brain, managing the state of the Queue, Stack, and Inventory.

๐Ÿงฎ Algorithms Implemented

A. Binary Search (Best-Fit Storage Bin)

  • Why: To efficiently find the smallest bin that fits a package among thousands of bins.
  • Complexity: $O(\log N)$
  • Logic: Bins are sorted by capacity. The algorithm finds the first bin where bin.capacity >= package.size.

B. Stack (Truck Loading Simulator)

  • Why: Trucks are loaded from back to front. To remove an item deep inside, you must remove items in front of it first.
  • Logic: Uses LIFO (Last-In, First-Out).
  • Rollback: Supports popping the last $N$ items to correct loading errors.

C. Queue (Conveyor Belt)

  • Why: Packages arrive sequentially and must be processed in order.
  • Logic: Uses FIFO (First-In, First-Out).

D. Backtracking (Shipment Planner)

  • Why: To determine if a specific combination of packages (e.g., fragile bundles) can fit into the remaining truck space.
  • Logic: Recursively tries to fit packages. If a path leads to overflow, it backtracks and tries the next combination.

๐Ÿ›  Tech Stack

Frontend

  • HTML5, CSS3, JavaScript (Vanilla, Responsive Design)
  • Google Fonts (Outfit)

Backend

  • Python 3.x
  • FastAPI (High-performance web framework)
  • Singleton Pattern for Controller

Algorithms

  • Binary Search
  • Stack / Queue Data Structures
  • Backtracking Algorithm

Database

  • MySQL (Relational Database Management System)

๐Ÿ—„ Database Schema

The system uses a relational database to ensure data persistence.

๐Ÿ“„ shipment_logs

Column Type Description
id INT Primary Key (Auto Increment)
tracking_id VARCHAR Unique Package ID
bin_id INT ID of the bin (or -1 for Truck)
timestamp DATETIME Time of operation
status VARCHAR STORED, LOADED, ROLLBACK, etc.

๐Ÿ“ฆ bins

Column Type Description
bin_id INT Unique Bin ID (Auto Increment)
capacity INT Volume capacity
location_code VARCHAR Physical location (e.g., A1, B2)

๐Ÿ“ฅ Installation & Setup Instructions

1. Clone Project

git clone https://github.com/yourusername/logistech.git
cd logistech

2. Install Dependencies

pip install -r requirements.txt

(Note: Requires fastapi, uvicorn, mysql-connector-python, python-dotenv)

3. Configure Database

Create a .env file in the root directory with your MySQL credentials:

DB_HOST=localhost
DB_USER=root
DB_PASSWORD=yourpassword
DB_NAME=warehouse

Ensure your MySQL server is running and accessible.

4. Run Application

uvicorn api:app --reload

4. Open in Browser

Go to: http://127.0.0.1:8000

๐Ÿ”Œ API Endpoints

Method Endpoint Description
GET /status Get current bin inventory
POST /package/add Add package to conveyor queue
GET /package/queue View current queue
POST /package/process Process next item (Binary Search)
POST /truck/load Load item onto truck (Stack)
POST /truck/rollback Remove last N items
POST /truck/can-fit Check fit (Backtracking)
GET /logs View audit logs

๐Ÿ“ธ UI Screenshots

Placeholders for actual screenshots

Dashboard Overview

![Dashboard]Screenshot 2025-11-24 131830

Conveyor & Inventory

![Inventory] Screenshot 2025-11-24 131900 Screenshot 2025-11-24 131907

๐Ÿ”ฎ Future Enhancements

  • Real-time Updates: Implement WebSockets for instant dashboard updates without polling.
  • IoT Integration: Connect with RFID scanners for automated package tracking.
  • ML Optimization: Use Machine Learning to predict package sizes and optimize bin layout.
  • Multi-Warehouse: Scale the system to manage multiple warehouse locations.
  • User Auth: Add Admin/Staff roles for security.

๐Ÿ“œ License

MIT License

About

LogisTech- A Python-based Warehouse Management System (WMS) designed to automate inventory tracking, streamline order processing, and optimize internal logistics operations.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors