PROJECT DATA SCIENCE LEAD

O'Donoghues Demand Forecast

Cut demand-forecast error by ~30% vs a same-hour-last-week baseline using walk-forward validated XGBoost models.

Tech Stack
PythonXGBoostStreamlitPandasscikit-learnOptuna

Architecture

Frontend

  • Streamlit dashboard
  • Shift-level status cards (lunch/evening/late bar)
  • Hourly forecast charts with baseline overlay
  • Feature-importance panel

Backend

  • XGBoost regressors per shift
  • 8-fold walk-forward (rolling-origin) cross-validation
  • Live weather, footfall, and event enrichment pipeline
  • Leakage-safe feature set for next-day forecasting

Challenges & Solutions

Problem

The city's pedestrian footfall counters publish with a 1-2 day lag, so 'today's' footfall reading was often still zero — which the dashboard displayed as a misleadingly blank signal instead of real data.

Solution

Added a fallback that detects a zero/missing current reading and substitutes the most recent available non-zero reading, explicitly labeled with its actual date (e.g. 'as of 3 Jul') so the manager reading the dashboard knows exactly how stale the number is rather than assuming it's live.

Problem

An early version of the dashboard showed generic 'Forecast Drivers' — static feature-importance weights from training — which told a manager what the model generally cares about, not what was actually happening on the specific day they were looking at.

Solution

Replaced it with a 'Today's Signals' panel driven entirely by that day's actual input values (real airport-arrival z-score, real rain forecast, real footfall reading) rather than static training-time weights, making the panel answer 'why is today busy' instead of 'what does the model usually weigh.'

Key Achievements

30.5% MAE improvement over baseline for hourly orders

24.5% MAE improvement for kitchen food tickets

Split-conformal 80% prediction intervals segmented by hour-of-day

Hourly automated refresh pipeline via GitHub Actions

Deep Dive

Turning a Guessing Game Into a Forecast

O’Donoghues on Suffolk Street is a busy Dublin city-centre pub: food service from 9am–9pm, live music most evenings, and demand that swings hard based on weather, tourism, and events. Kitchen and bar staff were planning prep and staffing off gut feel. This project builds the decision-support system to replace that guesswork.

The Approach

Rather than one generic model, the system splits demand into three operational windows — lunch, evening food service, and the late bar rush — because each is driven by different signals. On top of the venue’s own operating history, it enriches every forecast with live public data: Met Éireann weather, Dublin Airport passenger arrivals, Dublin Port cruise-ship schedules, Dublin City Council pedestrian footfall counters near the venue, and a maintained calendar of concerts, matches, and public holidays.

Keeping the Model Honest

The hardest part of forecasting demand is not leaking information the model wouldn’t actually have at prediction time. A strict SAFE_FOR_NEXT_DAY feature set excludes anything not knowable in advance — current-hour footfall, for instance, is dropped from the feature set entirely, while 24h+ demand lags and forecasted weather are kept in. Every model is validated with 8-fold walk-forward (rolling-origin) cross-validation, training only on data available up to a cutoff and testing on the following month, so the reported accuracy reflects how the model would have performed in production, not hindsight.

Results

Against a same-hour-last-week baseline, the XGBoost models cut mean absolute error by 30.5% for hourly order volume and 24.5% for kitchen food tickets. The top predictive signals are recent demand history (1-week and 2-week lags), Friday/Saturday flags, and a composite event-intensity score — with footfall-counter features expected to gain importance once real point-of-sale data replaces the current synthetic training set.

The dashboard never shows a bare point forecast. Split-conformal prediction bands, computed from walk-forward out-of-sample residuals and segmented by hour-of-day, give an 80% coverage interval around every forecast — so a volatile late-bar-rush hour gets a visibly wider band than a predictable Tuesday lunch, instead of false precision.

The Dashboard

A Streamlit dashboard gives a shift manager three things at a glance before service starts: a status card per shift (quiet/normal/busy/slammed with a suggested staffing intensity), an hourly chart overlaying the forecast against last week’s actuals, and a signals panel explaining why — rain, a cruise ship in port, a match at the Aviva, or a live-music night driving the number up.