Design a battery-life predictor and cold-start strategy
Company: Google
Role: Data Scientist
Category: Machine Learning
Difficulty: hard
Interview Round: Technical Screen
You are building a per-device time-to-empty predictor for smartphones. You receive minute-level telemetry with columns: device_id, model, t_minute, soc_percent (0–100), screen_on (0/1), brightness_pct, cpu_util, temp_c, net_type, app_fg_cat, charging (0/1), battery_health_days, ambient_lux. For a specific device at now (soc_percent=37), estimate minutes until 0%. Requirements:
- Baseline: implement a piecewise linear interpolation using only this session’s discharge curve; handle irregular timestamps, short charging interludes (charging=1), and screen-off stretches. Define precisely how you exclude/merge segments and how you interpolate t at soc=37 and soc=0.
- Feature design: name at least 8 additional covariates you would engineer (e.g., recent discharge slope, duty-cycle features, thermal state, user activity mix) and specify the expected direction of their effect on time-to-empty.
- Cold start: when this exact model has no history, propose a similarity-based approach (e.g., hierarchical model across device families, metric-learning + kNN on [model, battery_health_days, usage_mix], or meta-learning) to transfer priors. Define the similarity metric, how you combine neighbors’ curves, and how you quantify uncertainty (prediction intervals or quantile loss).
- Evaluation: define an offline protocol using session-level folds; choose primary and secondary metrics (e.g., MAE, P50/P90 absolute error) and guardrails to bound underestimation risk (e.g., P95 underprediction <= X minutes). Explain how you’d weight errors by remaining capacity.
- Post-launch: describe monitoring for distribution shift (e.g., drift in discharge slope, ambient temperature) and an automatic recalibration procedure (e.g., isotonic regression or online Platt scaling on recent residuals).
Quick Answer: This question evaluates time-to-empty (TTE) prediction and related competencies including time-series forecasting, feature engineering, cold-start model transfer, uncertainty quantification, offline evaluation design, and post-launch monitoring within the Machine Learning domain.