"On day one I knew what a healthy resting heart rate looked like. Four hundred days later the person had aged, the sensor had yellowed, and I had quietly retrained myself into confident nonsense. Nobody told me. That was the whole problem."
A Chastened AI Agent
The big picture
Every earlier section of this chapter got a model working: a personalized baseline, a fused wearable stream, a contactless vital sign, a glucose-derived digital biomarker. This section is about what happens next, over months and years, when that model keeps running on a body that changes, a sensor that ages, and a population that was never fully in the training set. Three clocks tick at once. The sensor drifts as adhesive dries and photodiodes yellow. The person drifts as they age, gain weight, start a medication, or shift with the seasons. And the model itself can drift, because an online-updating baseline that absorbs a slow real decline will happily normalize a developing illness into the new "healthy." A continuous health monitor is only as trustworthy as its ability to tell these three apart and to respond to each correctly: recalibrate the sensor, re-baseline the person, and escalate the illness. Getting that triage wrong is not a metric regression on a dashboard; it is a missed atrial fibrillation or a false alarm at 3 a.m. that teaches the user to ignore the device. Responsible deployment is the discipline of keeping a long-lived monitor honest.
This section assumes the personalized-baseline machinery of Section 33.2 and the change-detection vocabulary of Chapter 12. Drift is the deployment-scale cousin of the distribution shift treated formally in Chapter 66, and the calibration language here (does a 0.8 alarm still mean an 80% chance of the event?) comes from Chapter 18. The regulatory machinery for changing a deployed medical model, the predetermined change control plan, waits in Chapter 34; here we build the technical monitoring that such a plan governs.
Three drifts you must never confuse
The word "drift" hides three physically distinct processes, and the correct response to each is different, so conflating them is the root cause of most bad long-term monitors.
Sensor drift is the measurement chain changing while the body stays the same. A skin-temperature thermistor develops a slow offset; an optical PPG path loses contact as adhesive cures; an electrochemical glucose sensor's sensitivity decays across its wear period. This is the drift of Chapter 2: a change in the measurement model, not in the quantity measured. The correct response is recalibration or a hardware replacement, never a clinical alert.
Physiological drift is the body genuinely changing on a slow clock: aging raises arterial stiffness, a summer heat wave lifts resting heart rate, a new beta-blocker lowers it, pregnancy reshapes half the panel. Some of this drift is benign adaptation the baseline should track; some of it is the early slope of a disease the baseline must not absorb. Distinguishing the two is the central clinical judgment of the whole chapter.
Model or concept drift is the relationship between features and label decaying even when both input and body are stable, because the label distribution or care pathway changed, or because an online learner has slowly poisoned itself. This is where a self-updating personalized baseline turns dangerous: if it adapts fast enough to fold a two-week decline into its running mean, it erases exactly the trend a physician needed to see.
Key insight
A personalized baseline that adapts is a low-pass filter on the truth. Its time constant sets a policy: anything slower than the adaptation window becomes invisible because the baseline moves with it. Choose that window on purpose. Fast adaptation kills sensor-drift false alarms but blinds you to slow disease; slow adaptation preserves disease trends but drowns the user in alerts every time they change deodorant or fly across time zones. There is no universally correct constant, only a defensible one you can state, justify, and monitor.
Detecting drift across a fleet
You cannot label most of this in the field, so drift monitoring is unsupervised: watch distributions, not accuracy. Three complementary signals catch most problems. First, input drift: compare the recent feature distribution against a reference window with a divergence statistic. The Population Stability Index (PSI) and the two-sample Kolmogorov-Smirnov statistic are the workhorses; a PSI above roughly 0.2 on a feature is a standard "investigate" threshold. Second, prediction drift: the model's own output histogram (fraction of windows flagged anomalous, mean risk score) should be roughly stationary for a stable individual, so a rising flag rate with no matching input shift usually indicts the model or the sensor, not the patient. Third, calibration drift: whenever a delayed ground truth does arrive (a clinic visit, a confirmed event, a labeled CGM excursion), recompute reliability. A monitor whose 0.8-score events used to fire 80% of the time and now fire 40% has decalibrated, and per Chapter 18 that silently breaks every downstream threshold.
The subtlety unique to health is separating input drift from a real clinical event, because both look like "the distribution moved." The discriminator is timescale and reversibility. Sensor and seasonal drift are slow, monotone, and correlated with context you can measure (device age, ambient temperature, wear duration); an acute event is fast and often correlated with symptoms or other modalities. This is why the multimodal fusion of Section 33.3 pays a second dividend at deployment: a heart-rate shift that co-moves with an accelerometer activity change is behavior, while the same shift at rest with rising temperature is a candidate fever, not a broken sensor.
Practical example: the yellowing badge in a hospital ward
A clinical wearable vendor deployed a chest-patch continuous monitor across a cardiology step-down unit, streaming heart rate, respiration, and skin temperature to an early-deterioration score. Six weeks in, the night-shift nurses reported a creeping rise in low-priority alerts that resolved themselves by morning. The score had not changed logic; the adhesive optical window had begun clouding after about four days of wear, attenuating the PPG amplitude and inflating the model's motion-artifact estimate. Input drift on the raw-amplitude feature crossed PSI 0.3 while the clinical picture and the accelerometer were flat, the exact signature of sensor drift rather than patient decline. The fix was a two-part policy: a per-patch amplitude-normalization recalibration that reset the reference each morning, plus a hard 96-hour patch-replacement rule enforced by the score pipeline itself, which now refused to emit a deterioration score on a patch past its validated wear window rather than guessing through the fog. Nuisance alerts fell by two thirds and, more importantly, the one real deterioration that week was no longer buried in them.
A minimal fleet drift monitor
The code below implements the input-drift half of that policy: it computes PSI between a reference window and a current window for one feature, and, critically, gates the verdict on whether a matched context channel (here, activity) also moved. That gate is what stops the monitor from screaming "sensor drift" every time the wearer simply started exercising. You would run this per feature, per device, on a rolling schedule inside the fleet-operations stack of Chapter 69.
import numpy as np
def psi(reference, current, bins=10):
edges = np.quantile(reference, np.linspace(0, 1, bins + 1))
edges[0], edges[-1] = -np.inf, np.inf
r = np.histogram(reference, edges)[0] / len(reference) + 1e-6
c = np.histogram(current, edges)[0] / len(current) + 1e-6
return float(np.sum((c - r) * np.log(c / r)))
def triage(feat_ref, feat_cur, ctx_ref, ctx_cur, feat_thr=0.2, ctx_thr=0.2):
d_feat = psi(feat_ref, feat_cur) # how much the vital-sign feature moved
d_ctx = psi(ctx_ref, ctx_cur) # how much the context channel moved
if d_feat < feat_thr:
return "stable", d_feat
if d_ctx > ctx_thr:
return "behavioral: feature moved with context, do not alert", d_feat
return "sensor-or-physiological drift: investigate, do not auto-adapt", d_feat
rng = np.random.default_rng(0)
hr_ref = rng.normal(62, 4, 2000) # resting HR, healthy baseline window
hr_cur = rng.normal(70, 4, 2000) # HR has risen 8 bpm
act_flat = rng.normal(0.1, 0.05, 2000) # still, both windows
print(triage(hr_ref, hr_cur, act_flat, act_flat))
Library shortcut
The hand-rolled PSI, KS tests, drift thresholds, and reporting above are roughly 150 lines once you add multiple features, reference-window management, and dashboards. Evidently's DataDriftPreset or alibi-detect's KSDrift/MMDDrift detectors do the statistics, per-feature reports, and HTML summaries in about 8 lines, and hold the reference window for you. Write the detector once yourself so you understand PSI 0.2; reach for the library in production so the fleet dashboard is maintained code, not yours.
From monitoring to responsible response
Detecting drift is the easy half; responding without harm is the hard half, and it is where sensing meets ethics. Four rules separate a responsible long-term monitor from a liability. Do not auto-adapt through uncertainty: when drift is flagged and its cause is ambiguous, freeze the personalized baseline rather than update it, because a wrong update is silent and compounding. Design for the alert budget, not the ROC curve: a screening monitor worn by millions produces alarms at population scale, so alert fatigue, the clinician or user learning to swipe away a chronically noisy device, is a safety failure exactly as much as a missed event. Positive predictive value at the deployed prevalence, not sensitivity in the lab, is the number that governs trust. Watch for over-medicalization: a contactless or wearable monitor that surfaces every benign variation converts healthy people into anxious patients and floods clinics; the responsible default for an ambiguous, low-consequence signal is to observe and trend, not to alarm. Audit for equity: drift is rarely uniform. PPG-derived signals degrade differently across skin tones, and a fleet retrained on whoever wears the device most will drift toward that majority, so drift metrics must be sliced by demographic and device cohort or the model will quietly get worse for the underserved, a fairness obligation developed fully in Chapter 70.
Research frontier
Wearable foundation models trained self-supervised on very long unlabeled streams are reframing drift as an in-distribution problem: Google's Large Sensor Model (LSM, 2024) and PaPaGei's open PPG foundation model learn representations meant to stay stable across sensor generations and demographics, so a downstream head can be re-fit cheaply as the world moves. Paired with test-time adaptation (Chapter 66) and drift-aware conformal prediction, which widens prediction intervals as covariate shift is detected so coverage guarantees survive, the emerging pattern is a frozen large backbone plus a continually monitored, cheaply re-baselined head. The open question is governance: how to let such a head adapt on-device (Chapter 62) while keeping the frozen, auditable behavior a regulator can approve under a change-control plan.
Exercise
Take a public long-term wearable dataset (for example a multi-week PPG-plus-accelerometer recording). Split it into a 2-week reference window and successive 1-week current windows. Compute PSI per feature across weeks and plot the trajectory. Now inject two synthetic drifts: a linear sensor offset (a slow additive ramp on one channel) and an abrupt physiological step (a sustained resting-heart-rate increase). Show that your context-gated monitor labels them differently, and state the adaptation time constant at which the physiological step would have been silently absorbed by an online baseline.
Self-check
1. A deployed monitor's daily anomaly-flag rate has doubled over a month while the input feature distributions are unchanged. Which of the three drifts is this, and why is retraining the wrong first move?
2. Why can a fast-adapting personalized baseline make a monitor less safe, and what quantity sets the boundary between disease it hides and noise it usefully removes?
3. You improve sensitivity from 0.85 to 0.92 but positive predictive value at deployment prevalence falls from 0.30 to 0.18. Why might this update be rejected for a consumer-scale screening wearable?
Lab 33
build a wearable anomaly detector that learns a personal baseline and flags deviations; add a contactless-vitals comparison.
Bibliography
Drift, distribution shift, and calibration over time
The canonical taxonomy of concept drift and detection/adaptation strategies; the source of the vocabulary this section maps onto sensor, physiological, and model drift.
Systematic comparison of two-sample and dimensionality-reduction shift detectors, the empirical basis for choosing KS/MMD/PSI-style monitors in a deployed fleet.
Guo, C., Pleiss, G., Sun, Y., Weinberger, K. (2017). On Calibration of Modern Neural Networks. ICML.
Shows modern networks are miscalibrated by default; motivates monitoring calibration drift, since a decalibrated score silently invalidates every deployed alert threshold.
Wearable and sensor foundation models
Narayanswamy, G., et al. (2024). Scaling Wearable Foundation Models (LSM). arXiv.
Google's Large Sensor Model trained on very large unlabeled wearable streams; the frontier argument that stable self-supervised representations reduce downstream drift.
Pillai, A., et al. (2024). PaPaGei: Open Foundation Models for Optical Physiological Signals. arXiv.
An open PPG foundation model; useful as the frozen backbone in the frozen-backbone-plus-re-baselined-head deployment pattern this section advocates.
Responsible deployment and clinical monitoring
The landmark population-scale screening-wearable study; concrete evidence of why positive predictive value at real prevalence, not lab sensitivity, governs trust and clinic load.
Practical account of alert fatigue, silent model decay, and monitoring obligations once an ML product runs continuously in a real clinical workflow.
U.S. FDA (2024). Predetermined Change Control Plans for AI-Enabled Device Software Functions.
The regulatory frame that governs when and how a deployed learning monitor may adapt; the governance counterpart to the technical drift monitoring built here.
What's Next
In Chapter 34, we turn the monitoring discipline of this section into an approvable process: how software as a medical device is validated prospectively, how a predetermined change control plan lets a model adapt without a new submission each time, and how the same physiological signals that reveal disease can also re-identify the person, forcing biometric privacy to the center of any long-lived health deployment.