How nmissi-nadia/pfe_optimisation_de_la_gestion_des_stocks_avec_la_pr-diction_de_la_demande works
Project Type and Purpose
• This is a data-science prototype (a demand-forecasting pipeline) aimed at optimizing inventory management.
• Inputs: historical orders (Order.csv). Processing: Python/Pandas in a Jupyter notebook. Output: demand forecasts, cost-reduction and stock-out analytics.
File-Structure Analysis
• Top-level files only:
• Order.csv – raw data source
• Orders.ipynb – end-to-end analysis & modeling flow
• README.md – project overview
• Rapport_de_projet_fin_etude.pdf – final report
• No separate “src” or “models” directory indicates a notebook-centric, linear pipeline rather than a multi-service architecture.
Key Insights from README
• Core goal: predict demand to cut inventory costs by ~10% and stockouts by ~20%.
• Tech stack: Python + Pandas (likely with scikit-learn or time-series libs implied).
Components
a. Data Ingestion Layer
• Raw data: Order.csv (could evolve into a database or data lake in a production rollout).
• Optionally: an automated ETL job to load CSV into a staging table or DataFrame.
b. Data Processing & Feature Engineering
• Cleaning & normalization (date parsing, missing values, aggregations).
• Feature creation (lags, rolling averages, seasonality indicators).
c. Model Training & Validation
• ML/time-series model block (e.g., ARIMA, Prophet, RandomForest, XGBoost).
• Cross-validation or backtesting component.
d. Forecast Generation
• Inference pipeline: apply trained model to generate demand predictions for future periods.
e. Reporting & Visualization
• Notebook outputs (charts, metrics).
• Final report PDF (Rapport_de_projet_fin_etude.pdf).
f. (Optional) Deployment / Serving
• Containerized API endpoint (Flask/FastAPI) for real-time forecasting.
• Dashboard (e.g., Plotly Dash, Streamlit) for interactive visualization.
Relationships & Data Flow
• Cleaned Data → Feature Engineering → Feature Store
• Feature Store → Model Training → Trained Model
• Trained Model + New Features → Inference → Forecast Outputs
• Forecast Outputs → Reporting/Notebook → PDF report
Architectural Patterns & Principles
• Pipeline pattern: clearly delineated stages (ETL → FE → Train → Serve).
• Modularity: each stage can be refactored into a reusable function or micro-service.
• Separation of concerns: data handling separate from modeling logic and reporting.