Smartphone Time-to-Empty (TTE) Prediction — Baseline, Features, Cold Start, Evaluation, and Monitoring
Context
You are building a per-device predictor of minutes until the battery reaches 0% state-of-charge (SoC). Telemetry arrives at minute-level with the following columns:
-
device_id, model
-
t_minute (timestamp in minutes)
-
soc_percent ∈ [0, 100]
-
screen_on ∈ {0, 1}
-
brightness_pct ∈ [0, 100]
-
cpu_util ∈ [0, 1]
-
temp_c (device temperature, °C)
-
net_type (e.g., wifi, LTE, 5G)
-
app_fg_cat (foreground app category)
-
charging ∈ {0, 1}
-
battery_health_days (age proxy)
-
ambient_lux
For a specific device at “now” with soc_percent = 37, estimate minutes until 0%. Assume we evaluate offline using full-session data but make clear how you would operate online (i.e., at a moment in time without future data).
Tasks
-
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 to 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).