Sub topic 6
Label-free proxy signals and their limits
This chapter assumes you know the monitoring gap from earlier in the tutorial: the period when predictions exist but their labels have not arrived. It also assumes you are comfortable with pandas, scikit-learn, and ROC AUC. Here you will learn which signals you can compute today without labels, what each one tells you, and when each one misleads you.
What a proxy signal is
A proxy signal is a number you can compute from the prediction log alone, or from data that arrives sooner than the true label. You use it as a stand-in for "is the model still working?". A proxy does not measure performance. It measures something that tends to change when performance changes.
There are three families:
- Input signals. Statistics of the features: null rates, ranges, category frequencies, row counts.
- Output signals. Statistics of the model's predictions: mean score, share of positive calls, score histogram, average confidence.
- Early-outcome signals. Events that arrive before the real label and correlate with it: a missed first payment before a default, a support ticket before churn, a manual reviewer overriding the model.
| Family | Example | Catches well | Misses |
|---|---|---|---|
| Input | Null rate of `amount` jumps from 1% to 30% | Broken pipelines, schema changes, upstream outages | Shifts that keep each feature's marginal distribution the same |
| Output | Positive-call rate halves | Population shifts that the model reacts to | Changes the model cannot see in its inputs |
| Early outcome | First-payment miss rate rises | Real changes in behavior, including concept drift | Cases where the early event and the final label decouple |
Why proxies are cheap and why they are risky
Proxies are available immediately, need no labeling budget, and work for any model. Those properties make them the first line of defense during the monitoring gap.
The risk is that a proxy is correlated with performance, not equal to it. Two failure modes follow, and you should be able to name both.
- False alarm. The proxy moves and performance does not. A holiday weekend changes the mix of customers, the positive-call rate rises, and the model is still accurate on the new mix.
- Missed degradation. Performance falls and the proxy stays flat. This happens whenever the relationship between features and outcome changes while the features themselves look the same.
The second failure is the dangerous one, so the next section shows it concretely.
A proxy that stays flat while performance collapses
Concept drift means that P(y | x), the outcome given the features, changes. Input and output signals only see x and the model's score, which is a function of x. If x looks the same, they cannot see the change.
The script below trains a model on one relationship, then evaluates it on two fresh batches. In the second batch the features have the same distribution, but the outcome now depends on the other feature.
import numpy as np
from sklearn.linear_model import LogisticRegression
from sklearn.metrics import roc_auc_score
rng = np.random.default_rng(0)
def make(n, w):
X = rng.normal(size=(n, 2))
p = 1.0 / (1.0 + np.exp(-(X @ w)))
return X, rng.binomial(1, p)
w_old = np.array([2.0, 0.0]) # outcome driven by feature 0
w_new = np.array([0.0, 2.0]) # outcome now driven by feature 1
X_train, y_train = make(5000, w_old)
model = LogisticRegression().fit(X_train, y_train)
for name, w in [("before", w_old), ("after", w_new)]:
X, y = make(5000, w)
score = model.predict_proba(X)[:, 1]
print(
f"{name:6s} mean_score={score.mean():.3f} "
f"positive_rate={(score >= 0.5).mean():.3f} "
f"auc={roc_auc_score(y, score):.3f}"
)The mean score and the positive-call rate are nearly identical in both rows, within sampling noise. The AUC falls from roughly 0.8 to roughly 0.5, which is no better than random ranking. Every input and output proxy reports "all normal" while the model has stopped working.
The reverse case: a loud proxy with no harm
Now consider covariate shift, where the feature distribution changes but P(y | x) does not. Suppose a marketing campaign brings in many more young customers, and the model handles them as well as it handled everyone else. The input signals and the positive-call rate will move, and an alert will fire. Performance may be unchanged.
So a proxy alert is a reason to investigate. It is not proof of harm. Later chapters show how to turn a covariate-shift alert into a performance estimate with importance weighting.
Building a basic proxy monitor
A practical monitor computes a small set of daily summaries and flags days that fall far outside a baseline window. The code below does this with pandas. Keep the set small: every extra signal adds false alarms.
import numpy as np
import pandas as pd
def daily_proxies(log: pd.DataFrame, threshold: float = 0.5) -> pd.DataFrame:
"""Per-day proxy signals from a prediction log.
log: columns predicted_at (datetime), score (float), amount (float, may be null)
"""
day = log["predicted_at"].dt.floor("D")
g = log.groupby(day)
return pd.DataFrame({
"n": g.size(),
"mean_score": g["score"].mean(),
"positive_rate": g["score"].apply(lambda s: (s >= threshold).mean()),
"null_rate_amount": g["amount"].apply(lambda s: s.isna().mean()),
})
def flag_outliers(daily: pd.DataFrame, baseline_days: int = 28, z: float = 3.0):
"""True where a day is more than z standard deviations from the baseline."""
signals = daily.drop(columns="n")
base = signals.iloc[:baseline_days]
mu = base.mean()
sd = base.std(ddof=1).replace(0, np.nan)
return ((signals - mu) / sd).abs() > z
if __name__ == "__main__":
rng = np.random.default_rng(1)
n = 40 * 500
log = pd.DataFrame({
"predicted_at": pd.Timestamp("2026-01-01")
+ pd.to_timedelta(np.arange(n) // 500, unit="D"),
"score": rng.beta(2, 5, size=n),
"amount": rng.lognormal(3, 1, size=n),
})
# Simulate an upstream outage on the last day: amount goes missing.
last = log["predicted_at"] >= log["predicted_at"].max().floor("D")
log.loc[last, "amount"] = np.nan
flags = flag_outliers(daily_proxies(log))
print(flags.tail(3))The final day is flagged on null_rate_amount. The score signals stay quiet, because the outage did not change the score distribution. This is an example of a proxy doing its real job: catching a data pipeline fault quickly.
Two details matter in practice:
- A baseline of 28 days is a choice. Use a window long enough to include weekly cycles, and exclude periods you already know were abnormal.
- A z-score threshold of 3 assumes roughly bell-shaped daily values. For rates on small daily volumes, expect more outliers than the threshold suggests.
Early-outcome signals
Early-outcome signals are the strongest proxies, because they sit on the causal path to the label. Examples include a missed first installment, a customer who stops logging in, or a transaction a human analyst reverses within an hour.
They are still proxies. Check three things before you rely on one:
- Coverage. What fraction of eventual positives show the early event? If only 30% of defaulters miss a first payment, a flat early-event rate says little about the other 70%.
- Precision of the link. What fraction of early events end in a positive label? Many early events are noise.
- Stability of the link. The relationship between the early event and the label can itself drift, for example when a lender changes its collections process.
Estimate all three from matured cohorts, where you have both the early event and the final label. If you cannot measure them, you do not know how far to trust the signal.
Deciding which proxies to keep
Treat each proxy as a hypothesis: "when this moves, performance is likely to have moved." You can test that hypothesis once labels arrive. Over several months, record every proxy alert and whether matured performance later fell. A proxy with many false alarms and no true alarms should be removed or have its alert threshold raised. A proxy that preceded real degradation earns a higher alert priority.
A reasonable default policy:
- Treat input-quality signals (nulls, schema, volume) as page-worthy. They indicate faults, and a fault is actionable regardless of performance.
- Treat distribution-shift signals as tickets that start an investigation, not as pages.
- Treat early-outcome signals as stronger evidence, but verify their coverage first.
- Never treat the absence of alerts as evidence of good performance.
Common errors
- Reading a flat dashboard as a clean bill of health. Concept drift and some label shift are invisible to input and output proxies.
- Alerting on every feature. With 200 features and a 3-sigma threshold, several alerts per week occur by chance. Teams then ignore the alerts.
- Comparing against a stale baseline. If the baseline is the training set, seasonal effects look like drift forever. Compare against a recent window as well.
- Ignoring volume. A positive rate computed from 20 predictions is noise. Report counts next to rates.
- Using the model's own confidence as accuracy. Average confidence only tracks accuracy when scores are calibrated, which is the topic of a later chapter.
Exercise
A fraud model's input features and score distribution look identical to last month's, and the positive-call rate has not moved. A week later, matured labels show precision has dropped sharply because fraudsters changed tactics. Which kind of drift is this, and why did the proxies miss it? Name one early-outcome signal that might have caught it sooner.
Show answer
This is concept drift: P(y | x) changed while P(x) did not. Input and output proxies only observe x and the score, which is a function of x, so with an unchanged feature distribution they have nothing to react to. An early-outcome signal such as the rate of analyst reversals or customer-reported fraud within the first day could have moved sooner, provided it covers a meaningful share of true fraud cases.