Probabilistic demand forecasting at scale

Hagop Dippel9 Mar 2023

Problem

Logistics teams at an online fashion retailer need demand forecasts for inventory replenishment, warehouse staffing and assortment planning. Each stock keeping unit (SKU) forecast is one input to a downstream stochastic inventory-optimization model, and aggregated forecasts size warehouse staffing. Demand is driven by weather, taste shifts, the economy and shocks such as the pandemic, so one predicted number hides how risky it is. The same mean of 5,000 units for a shoe means different purchase decisions under a narrow, a wide or a heavy-tailed distribution.

Solution in brief

Replace point forecasts with probabilistic ones that give the noise level at every future step. The talk presents two families: learning distribution parameters and learning quantiles with the pinball loss. Quantiles avoid a distribution assumption that is hard to defend for hundreds of thousands of series; the best choice depends on inference versus training time. Models train on GPU clusters (Amazon SageMaker) and run daily batch inference, one series per request. About 150,000 series take about 45 minutes per day.

Questions this case answers
  • How to produce forecasts with a calibrated noise level per horizon step for a very large number of time series when a single distribution cannot be assumed for all of them
  • How to forecast demand for hundreds of thousands of SKUs while keeping the uncertainty of each forecast?
  • How to choose between learning distribution parameters and learning quantiles for demand forecasts?
  • How to evaluate a probabilistic demand forecast when demand has many zeros and rare spikes?

Tools and methods

  • Quantile regression (pinball loss) — learn chosen quantiles of demand without assuming a distribution
  • Distribution-parameter models (DeepAR-style, Gaussian or negative binomial outputs) — learn the distribution parameters by maximum likelihood
  • LightGBM, CatBoost — fast gradient boosting with a quantile loss
  • Temporal Fusion Transformer, MQ-CNN — deep quantile models
  • WAPE, CRPS, cross entropy — evaluation metrics
  • Amazon SageMaker — GPU training and batch-transform inference
Continue reading — it's free

Google or a one-time email code. No password.