Skip to content

About

Inventory forecasting lab - FastAPI mini-WMS, FIFO batches, Prophet per-product forecasts, honest MAE/MAPE evaluation harness (synthetic data)

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Inventory Demand Forecasting (Mini-WMS Lab)

A self-contained inventory forecasting lab: a local FastAPI mini-WMS backed by SQLite, FIFO batch consumption, Prophet-based per-product demand forecasting, and an evaluation harness that scores every forecast against held-out actuals with MAE/MAPE and comparison plots.

Built as my Database & Data Management Systems course project (VIT, SEM5), developed alongside my warehouse-management internship work at Sandvik Rock Tools — this repo is the fully synthetic, self-contained academic companion. An IEEE-format paper accompanies the work (withheld from the repo pending employer co-author sign-off).

What it does

seed synthetic products & transactions  (app/data_generator_min.py, app/seed.py)
        ↓
FastAPI mini-WMS: products, FIFO batch consumption   (app/main.py, app/fifo.py)
        ↓
per-product Prophet forecasts, 30-day horizon        (app/forecast_all.py)
        ↓
evaluation: MAE / MAPE vs held-out actuals + plots   (app/compare.py, app/report_*.py)

Honest results (synthetic data, 30-day horizon, 10 products)

Metric Value
MAE 3.4 – 6.3 units/day across products
MAPE 30% – 237%

MAPE is reported but unstable on intermittent, low-volume demand — when actual daily demand is near zero, small absolute errors explode the percentage (PROD-003's 237% is 6 units of MAE on a slow mover). That behaviour, and why MAE is the better headline metric for this data, is exactly what the evaluation harness is built to expose. Full numbers in results/metrics_hist_30d.csv.

Example forecast vs actuals

Running

pip install -r requirements.txt
python -m app.seed                # create wms.db with synthetic data
uvicorn app.main:app --reload     # mini-WMS API on :8000
python -m app.forecast_all        # per-product 30-day forecasts
python -m app.compare             # MAE/MAPE + comparison plots

Stack

FastAPI · SQLAlchemy · SQLite · Prophet · pandas · Matplotlib

About

Inventory forecasting lab - FastAPI mini-WMS, FIFO batches, Prophet per-product forecasts, honest MAE/MAPE evaluation harness (synthetic data)

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages