Run a clean A/B test for autocomplete
Design an Online Controlled Experiment for ML-Ranked Autocomplete and Search Satisfaction
You are tasked with designing an A/B test to evaluate the impact of an ML-ranked autocomplete (typeahead) system on user search satisfaction. Your plan should be comprehensive and cover the following aspects:
Design and Assignment
- Unit of Randomization: Define the appropriate unit of randomization and justify your choice.
- Bucketing and Identity Resolution: Describe the bucketing strategy (hashing, number of buckets, persistence) and how user identity will be resolved.
- Exposure Rules and Eligibility: Specify rules for user exposure across devices and sessions to prevent contamination. This includes cross-device consistency, cache key isolation, model snapshotting, and defining eligibility criteria.
- Traffic Ramp Plan: Propose a phased traffic ramp-up plan, including gating criteria and rollback conditions.
Metrics (with exact formulas)
- Primary Metric: Choose one primary metric and provide its exact formula. This should be session-level query success rate.
- Guardrail Metrics: Select at least three relevant guardrail metrics for typeahead and search, and provide their exact formulas. Examples include time to first click (TTFC), p99 typeahead latency, typeahead error rate, zero-results rate, abandonment, and suggestion click-through rate (CTR).
- Quantiles and Clustering: Explain how quantiles and clustering will be handled for metric calculations.
Variance Reduction and Analysis
- Variance Reduction: Describe the application of CUPED or other variance-reduction strategies, including the variables, window, and estimator used, and how they apply to the chosen analysis unit.
- Statistical Analysis: Specify the statistical test, standard errors, and clustering methodology.
- Sequential Monitoring: Justify how sequential monitoring will be performed without inflating the Type I error rate.
Sample Size
- Sample Size Calculation: Compute the required sample size to detect a 1.0 percentage-point absolute lift from a 60.0% baseline at alpha=0.05 and power=0.80. Show the formula and the numeric result. Discuss any design-effect and CUPED adjustments.
Operational Risks and Validity
- Risk Mitigation: Explain how you will handle operational risks such as novelty effects, carryover effects, bots and spam traffic, missing logs, seasonality, and heterogeneous treatment effects (e.g., by locale or device).
- Validation Checks: Propose at least one falsification (placebo/negative control) check and an offline backtest plan.
AI interview prep
Core dilemma
Balancing the statistical rigor of an A/B test with the practical complexities of real-world user behavior, system limitations, and potential for confounding factors, all while ensuring the experiment accurately reflects the impact of an ML model on user satisfaction.
3 tradeoffs and 3 stress tests locked
Interview prep
Unlock the interviewer X-Ray rubric, tradeoff matrix, stress tests, clarifying questions, and key concepts.
Run a clean A/B test for autocomplete
Design an Online Controlled Experiment for ML-Ranked Autocomplete and Search Satisfaction
You are tasked with designing an A/B test to evaluate the impact of an ML-ranked autocomplete (typeahead) system on user search satisfaction. Your plan should be comprehensive and cover the following aspects:
Design and Assignment
- Unit of Randomization: Define the appropriate unit of randomization and justify your choice.
- Bucketing and Identity Resolution: Describe the bucketing strategy (hashing, number of buckets, persistence) and how user identity will be resolved.
- Exposure Rules and Eligibility: Specify rules for user exposure across devices and sessions to prevent contamination. This includes cross-device consistency, cache key isolation, model snapshotting, and defining eligibility criteria.
- Traffic Ramp Plan: Propose a phased traffic ramp-up plan, including gating criteria and rollback conditions.
Metrics (with exact formulas)
- Primary Metric: Choose one primary metric and provide its exact formula. This should be session-level query success rate.
- Guardrail Metrics: Select at least three relevant guardrail metrics for typeahead and search, and provide their exact formulas. Examples include time to first click (TTFC), p99 typeahead latency, typeahead error rate, zero-results rate, abandonment, and suggestion click-through rate (CTR).
- Quantiles and Clustering: Explain how quantiles and clustering will be handled for metric calculations.
Variance Reduction and Analysis
- Variance Reduction: Describe the application of CUPED or other variance-reduction strategies, including the variables, window, and estimator used, and how they apply to the chosen analysis unit.
- Statistical Analysis: Specify the statistical test, standard errors, and clustering methodology.
- Sequential Monitoring: Justify how sequential monitoring will be performed without inflating the Type I error rate.
Sample Size
- Sample Size Calculation: Compute the required sample size to detect a 1.0 percentage-point absolute lift from a 60.0% baseline at alpha=0.05 and power=0.80. Show the formula and the numeric result. Discuss any design-effect and CUPED adjustments.
Operational Risks and Validity
- Risk Mitigation: Explain how you will handle operational risks such as novelty effects, carryover effects, bots and spam traffic, missing logs, seasonality, and heterogeneous treatment effects (e.g., by locale or device).
- Validation Checks: Propose at least one falsification (placebo/negative control) check and an offline backtest plan.