PracHub
QuestionsCoachesLearningGuidesInterview Prep
|Home/Machine Learning/Google

Decide between two vendors under constraints

Last updated: Mar 29, 2026

Quick Overview

This question evaluates a candidate's competency in decision modeling and cost‑sensitive machine learning, including causal inference for selection bias, propensity estimation, constrained optimization for capacity and SLA trade‑offs, and offline/online evaluation in the Machine Learning domain for a Data Scientist role.

  • medium
  • Google
  • Machine Learning
  • Data Scientist

Decide between two vendors under constraints

Company: Google

Role: Data Scientist

Category: Machine Learning

Difficulty: medium

Interview Round: Onsite

You have two third‑party search vendors, A and B, plus historical order‑level data: lead_time_days, unit_price, on_time_rate, defect_rate, min_order_qty, capacity, distance_km, historical_cancellation_rate, late_penalty_per_order, stockout_cost_per_day, and whether SLA was met. Design a decisioning model to choose A vs B for each incoming order to minimize expected total cost while maintaining SLA attainment ≥95% and a monthly budget cap. - Define the objective function and write the expected‑cost decision rule explicitly (include price, expected late penalties, expected quality failure cost, and stockout costs). - Propose features and a modeling approach (e.g., cost‑sensitive logistic regression predicting SLA miss probability with a cost‑based threshold; pairwise learning‑to‑rank; or a contextual bandit). Justify your choice under class imbalance and non‑stationarity. - Address selection bias from historical routing (e.g., propensity modeling, inverse propensity weighting, counterfactual risk minimization). Specify how you would estimate propensities and stabilize weights. - Describe offline evaluation (time‑based cross‑validation, constrained metrics for SLA ≥95%, cost curves) and an online rollout with safety constraints and vendor capacity limits. - Handle cold start for a new vendor and per‑vendor capacity constraints (e.g., knapsack/assignment layer atop predictions). What diagnostics would you run if A appears cheaper but late penalties rise?

Quick Answer: This question evaluates a candidate's competency in decision modeling and cost‑sensitive machine learning, including causal inference for selection bias, propensity estimation, constrained optimization for capacity and SLA trade‑offs, and offline/online evaluation in the Machine Learning domain for a Data Scientist role.

Related Interview Questions

  • LLM Foundations: Architecture, Adaptation, and Steering - Google (easy)
  • Explain ranking cold-start strategies - Google (medium)
  • Explain LLM fine-tuning and generative models - Google (medium)
  • Compare NLP tokenization and LLM recommendations - Google (medium)
  • Explain LLM lifecycle and trade-offs - Google (medium)
|Home/Machine Learning/Google

Decide between two vendors under constraints

Google logo
Google
Oct 13, 2025, 9:49 PM
mediumData ScientistOnsiteMachine Learning
3
0

You have two third‑party search vendors, A and B, plus historical order‑level data: lead_time_days, unit_price, on_time_rate, defect_rate, min_order_qty, capacity, distance_km, historical_cancellation_rate, late_penalty_per_order, stockout_cost_per_day, and whether SLA was met. Design a decisioning model to choose A vs B for each incoming order to minimize expected total cost while maintaining SLA attainment ≥95% and a monthly budget cap.

  • Define the objective function and write the expected‑cost decision rule explicitly (include price, expected late penalties, expected quality failure cost, and stockout costs).
  • Propose features and a modeling approach (e.g., cost‑sensitive logistic regression predicting SLA miss probability with a cost‑based threshold; pairwise learning‑to‑rank; or a contextual bandit). Justify your choice under class imbalance and non‑stationarity.
  • Address selection bias from historical routing (e.g., propensity modeling, inverse propensity weighting, counterfactual risk minimization). Specify how you would estimate propensities and stabilize weights.
  • Describe offline evaluation (time‑based cross‑validation, constrained metrics for SLA ≥95%, cost curves) and an online rollout with safety constraints and vendor capacity limits.
  • Handle cold start for a new vendor and per‑vendor capacity constraints (e.g., knapsack/assignment layer atop predictions). What diagnostics would you run if A appears cheaper but late penalties rise?
Loading comments...

Browse More Questions

More Machine Learning•More Google•More Data Scientist•Google Data Scientist•Google Machine Learning•Data Scientist Machine Learning

Write your answer

Your first approved answer each day earns 20 XP.

Sign in to write your answer.
PracHub

Master your tech interviews with 8,500+ real questions from top companies.

Product

  • Questions
  • Learning Tracks
  • Interview Guides
  • Resources
  • Premium
  • For Universities
  • Student Access

Browse

  • By Company
  • By Role
  • By Category
  • Topic Hubs
  • SQL Questions
  • AI Coding Questions
  • Compare Platforms
  • Discord Community

Support

  • support@prachub.com
  • (916) 541-4762

Legal

  • Privacy Policy
  • Terms of Service
  • About Us

© 2026 PracHub. All rights reserved.