Problem Statement: Selling Impressions That Do Not Exist Yet
Frames ad inventory forecasting as a supply-prediction and risk problem for guaranteed ad sales, not a generic analytics dashboard.
Problem statement
Design an ad inventory forecasting system that predicts how many ad impressions will be available to sell and serve over upcoming days and weeks, per segment (geography, device, ad format, placement, time of day), factoring seasonality, trend, promotions, and current traffic patterns. The output is consumed by sales and yield teams to price and commit guaranteed delivery (GD) deals: contracts that promise an advertiser N impressions of a target segment by a flight date, with penalties or makegoods when the platform under-delivers.
The defining tension is asymmetric risk. Over-forecasting sells inventory that does not exist: deals under-deliver, triggering makegoods, penalties, and advertiser churn. Under-forecasting leaves impressions unsold (remnant inventory sold at a fraction of guaranteed CPMs) and directly destroys revenue. The system therefore must not output a single hopeful number; it must output a distribution per segment and horizon, and the business must choose a conservative sellable quantile (for example P25) that explicitly trades fill rate for delivery safety.
Why this is a distinctive big-data problem
A naive answer treats this as 'run ARIMA on a few series'. The reality is a data-platform problem with four planes:
- Ingestion plane: billions of ad-request and serve events per day, late arrivals, duplicates, invalid traffic filtering, schema evolution.
- Aggregation plane: rolling raw events into segment×time cubes fast enough that forecasts see today's traffic by tomorrow's run, with hierarchical rollups that stay mathematically coherent.
- Modeling plane: tens of thousands of correlated series with daily, weekly, and yearly seasonality, promo spikes, and heavy tails; a mix of statistical baselines, gradient boosting, and probabilistic deep models; nightly batch training plus intraday re-forecast triggers.
- Serving and consumption plane: interactive forecast queries from sales tools, batch availability checks against already-booked deals, versioned forecasts with prediction intervals, and alerting when booked demand approaches predicted supply.
Public scale context versus design assumptions
Public, company-reported figures establish the category's scale. The Trade Desk states its AI analyzes up to 15 million ad opportunities each second [[1]]. PubMatic reports processing over 100 billion ads and bid requests each day, and separately describes ~80 million bids per second generating ~100 terabytes of data daily [[57]][[59]]. Google's ad auctions resolve in roughly 100-300 milliseconds and occur billions of times daily [[18]][[23]]. Spotify maintains a dedicated Ads Forecasting squad whose charter is predicting future ad inventory, demand, and performance [[66]]. These are cited context, not requirements for our design.
For capacity planning this answer explicitly assumes a publisher network with 3.6 billion eligible ad requests per day, ~41.7K requests/second average, a 2.4× peak factor (~100K/s), ~18,500 active leaf segments, and a 120-day horizon. Every uncited number in this answer is a stated assumption, budget, or target.
The one-sentence invariant
Forecast supply as a distribution, reconcile it across the segment hierarchy, publish it as an immutable version, and let sales consume a conservative quantile minus already-booked demand — never a raw point estimate.
Key Highlights
- •Guaranteed-delivery economics make over-forecasting (under-delivery) and under-forecasting (unsold inventory) both expensive.
- •The system outputs distributions and sellable quantiles, not single point estimates.
- •Four planes: ingestion, aggregation, modeling, serving/consumption.
- •Public scale: TTD up to 15M ad opportunities/sec; PubMatic 100B+ requests/day; Google auctions in 100-300ms billions of times daily.
- •Design assumptions: 3.6B eligible requests/day, ~100K/s peak, 18.5K active leaf segments, 120-day horizon.
Section Rescue Kit
Buzzwords to use:
Safe statements:
- "Let me separate supply forecasting from demand booking first, then define availability as the difference."
- "Before choosing models, I want the segment hierarchy and the risk posture (which quantile we sell) explicit."