Design an a/b test analytics pipeline
PremiumData pipelineMedium
- A/b testing
- Experiment exposures
- Sample ratio mismatch
Quick answer
This data pipeline interview question asks you to design an a/b test analytics pipeline. Aim for a design that moves data from sources to consumers reliably and on time, then explain ingestion, processing, storage and trade-offs. Interviewers want to see how you handle volume, late or bad data and failures along the way.
The problem
Design an A/B test analytics pipeline for a large consumer app: it joins experiment exposures with metric events and produces each variant's metrics, lift and confidence interval every day for 1,000 live experiments. The hard parts are joining billions of events correctly, ratio metrics, sample ratio mismatch and honest stats.
Product teams decide launches on these numbers. A pipeline that is fast but subtly wrong is worse than none, because it ships bad features with confidence.
What must an a/b test analytics pipeline do?
- Per-variant results: For each experiment, compute each metric per variant, the lift versus control and a 95% confidence interval.
- Correct attribution: Count a user's metric events only after their first exposure to that experiment.
How well must it do it?
- Trust: The same inputs always give the same numbers, and every number traces back to its metric definition and data.
- Freshness: Daily results by 08:00; guardrail alerts within 1 hour.
What scale should you design for?
Use these numbers in your estimates.
The scale numbers unlock with this questionUnlock
Key concepts
- A/b testing
- Experiment exposures
- Sample ratio mismatch
- Delta method
- CUPED
- Sequential testing
How you’ll practise
- Requirements
- Data volume
- Ingestion
- Storage and processing
- Serving and freshness
- Wrap-up
Lala, personalized to you, gives a hint when you ask and reviews your design when you are ready.
What do interviewers look for?
In any data pipeline design round.
- Clarifies sources, consumers and freshness needs
- Chooses batch, streaming or both with reasons
- Handles late, duplicate and malformed records
- Makes each stage safe to retry
- Explains storage formats and partitioning
- Plans monitoring, backfills and data quality checks
Questions people ask about this interview question
- Which design type is this question?
- It is a data pipeline question. You design an a/b test analytics pipeline and explain your choices the way you would in an interview.
- Is this question asked at entry level?
- It is marked Medium. Entry-level engineers can practise it, but it expects you to reason about requirements and trade-offs, not only list components.
- What should I cover first?
- Start with the data sources, the consumers and how fresh the data must be. Agree on scope with the interviewer before you design anything.
- Can I practise it for free?
- It is a premium question. Sign up and unlock it once for 10 credits; it then stays unlocked. When you finish, Lala, your personalized AI mentor, can review your design for 30 credits.
Related questions
Updated · Written by the SevyDevy team