Time Series ForecastingStatistical Models (ARIMA, Exponential Smoothing)Hard⏱️ ~3 min

Failure Modes and Production Monitoring

Core Challenge
Statistical models assume the future resembles the past. When this breaks—new competitors, pandemics, policy changes—forecasts fail. Monitoring detects failures early.

STRUCTURAL BREAKS

Permanent shifts in level, trend, or seasonality. Models trained on pre-break data produce systematically wrong forecasts. Detection: sustained bias (consistently over/under-forecasting). Fix: retrain on post-break data only.

PROMOTIONS AND EVENTS

Sales spikes look like outliers. Models either ignore them or learn elevated baseline. Fix: indicator variables marking promotional days, or separate models for promotional vs normal periods.

💡 Insight: Missing data breaks ARIMA—cannot use yesterday if missing. Impute first: linear interpolation, same period last year, or model-based fill.

MONITORING IN PRODUCTION

Track forecast error over time. MAE = average absolute error. MAPE = average percentage error. Alert when error exceeds baseline or trends upward. Compare to naive—if model loses to "predict yesterday," investigate immediately.

RESIDUAL DIAGNOSTICS

Residuals (actual minus forecast) should look random: no patterns, centered at zero. Patterns (rising, Monday spikes) mean model is missing something. Plot residuals after retraining to catch degradation.

⚠️ Retraining Triggers: Accuracy drops below threshold, residuals show patterns, external event occurs. Weekly or monthly retraining suffices for stable series.
💡 Key Takeaways
Structural breaks (permanent shifts) cause systematic forecast errors; retrain on post-break data
Promotions and events look like outliers; use indicator variables or separate models
Missing data breaks ARIMA—impute with interpolation or same-period-last-year
Monitor MAE/MAPE over time; alert when error exceeds baseline or trends upward
Residuals should look random; patterns indicate the model is missing something
📌 Interview Tips
1If model loses to naive baseline, investigate immediately—something is broken
2Watch for sustained bias (consistently over or under-forecasting) to detect structural breaks
← Back to Statistical Models (ARIMA, Exponential Smoothing) Overview