The Inventory Problem
Most ERPNext users set static reorder points and safety stock — numbers that were estimated once and never revised. Seasonal demand changes, supplier lead time variability, and new product introductions make these static numbers wrong within weeks.
AI demand forecasting makes reorder decisions dynamic: the system learns from historical sales patterns and adjusts safety stock and reorder quantities automatically.
Our Forecasting Architecture
We use Facebook Prophet (now just "prophet") as the primary forecasting model for its ability to handle seasonality and holiday effects relevant to Indian businesses (Diwali, year-end stocking, etc.).
The pipeline: ERPNext Stock Ledger Entry data → data cleaning and feature engineering → Prophet model training per item-warehouse combination → forecast output → automatic Material Request creation in ERPNext for items falling below predicted safety stock.
Implementation Notes
- You need at least 12 months of sales history for reliable forecasts — 24+ months is better
- Slow-moving and new items need different treatment: use simple weighted moving average for items with fewer than 20 transactions/year
- Validate the model by backtesting on the last 3 months of data before deploying to production
- Run forecasts weekly, not daily — daily is computationally expensive and demand doesn't change that fast