Demand forecasting for a makeup supply chain using a neural network.
This repository contains a full demand forecasting solution for a fashion & beauty startup’s makeup supply chain. By predicting “Number of products sold”, the model helps optimize inventory, reduce stockouts, and enhance supply-chain efficiency.
- Data Preparation & EDA
- Neural-Network Model (128 → 64 → 32 layers)
- Training & Validation
- Evaluation (MSE + scatter plot)
- Model Export & Inference
- Interactive Streamlit App
.
├── data/
│ └── supply_chain_data.csv # Raw dataset
├── notebooks/
│ └── supply_chain_demand_forecasting.ipynb # Colab-ready notebook
├── models/
│ ├── demand_forecasting_model.keras # Trained Keras model
│ ├── scaler.pkl # StandardScaler used in training
│ └── feature_columns.pkl # Feature column order used for prediction
├── streamlit_app/
│ └── app.py # Streamlit dashboard app
├── assets/
│ └── true_vs_predicted.png # Sample visualization
└── README.md # Project overview
|__ requirements.txt # All necessary libraries to download.
pip install pandas numpy matplotlib scikit-learn tensorflow streamlit joblibOpen notebooks/demand_forecasting.ipynb in Google Colab or Jupyter:
- Upload your dataset (CSV)
- Clean & preprocess the data
- Train the neural network model
- Evaluate results with MSE & plot
- Save the model, scaler, and feature columns to disk
From your project root:
streamlit run streamlit_app/app.pyUpload your CSV to get instant sales predictions and visual feedback!
Features:
- Live file upload
- Automatic preprocessing (date + categorical)
- Prediction of "Number of products sold"
- MSE & R² score display
- Scatter plot of true vs predicted
- Option to download prediction CSV
- 🔧 Perform hyperparameter tuning (e.g., with KerasTuner)
- 📈 Try advanced models like LSTM or XGBoost
- ✨ Enhance Streamlit with interactive filters, export buttons, etc.
Built with ❤️ by Anas
