Tech Abstractions
ML System Design·Hard

Design an Ad Click Prediction Pipeline at Scale

Asked at Google, Meta, ByteDance

Design a click-through rate (CTR) prediction pipeline for a digital advertising platform serving billions of ad impressions daily. The system must predict the probability that a user will click on each candidate ad in real time, and these predictions feed into an auction system that selects the winning ad to display.

Scale Requirements

  • 10 billion ad impressions per day
  • 100 million active ad campaigns
  • Inference latency budget: under 10ms per ad (scoring phase)
  • 1 billion training examples generated daily
  • Model must adapt to changing user behavior and new campaigns within hours

Design Requirements

  1. Design the end-to-end data pipeline from impression event to model training.
  2. Choose and justify the model architecture for CTR prediction at this scale.
  3. Design the real-time inference serving system.
  4. Explain how you would implement online learning to keep the model fresh.
  5. Discuss how the prediction system integrates with the ad auction and budget management.

Your Answer

Unlock AI-powered scoring, all questions, and progress tracking.

Study the related chapter →