Abstract
To provide rigorous uncertainty quantification for online learning models, we develop a framework for constructing uncertainty sets that provably control risk—such as coverage of confidence intervals, false negative rate, or F1 score—in the online setting. This extends conformal prediction to apply to a larger class of online learning problems. Our method guarantees risk control at any user-specified level even when the underlying data distribution shifts drastically, even adversarially, over time in an unknown fashion. The technique we propose is highly flexible as it can be applied with any base online learning algorithm, requiring minimal implementation effort and essentially zero additional computational cost. We further demonstrate the utility of our method on real-world tabular time-series data sets and an online image-depth estimation problem.
Introduction
In real-world applications like autonomous driving or financial forecasting, machine learning models face a constant stream of data where distributions shift unpredictably. Traditional evaluation on static test sets fails to account for these dynamics. While standard Conformal Prediction offers a way to quantify uncertainty, it often struggles with non-i.i.d. data or complex risk metrics beyond simple coverage.
We present Rolling Risk Control (Rolling RC), a flexible framework that provides rigorous uncertainty quantification for online learning models. Rolling RC constructs uncertainty sets that provably control various risks—such as confidence interval coverage, false negative rates, or F1 scores—even under drastic or adversarial distribution shifts.
The Rolling Risk Control Framework
Rolling RC operates as a feedback loop around any base online learning algorithm (e.g., an LSTM or a Deep Neural Network). At each time step, the system produces a prediction set. Once the ground truth is revealed, the system calculates the loss. If the loss exceeds the target risk level, the framework widens the prediction sets for subsequent steps; if the loss is lower, it shrinks them.
Adaptive Stretching Functions
To enhance responsiveness, we introduce "stretching functions" ($\phi$). Our Error Adaptive stretching function adjusts the interval width based on the magnitude of recent errors, allowing the system to react more aggressively to sudden changes in model performance. This ensures the model remains both safe and informative.
Multi-Risk Control
A key strength of Rolling RC is its ability to handle multiple safety requirements simultaneously. In a depth-sensing system, for instance, one might require 80% global accuracy while demanding 90% accuracy in the center of the frame to ensure critical obstacle detection.
Experimental Validation: Online Image-Depth Estimation
We validated Rolling RC on real-world tabular time-series data and the KITTI benchmark for online image-depth estimation. In the KITTI experiment, the goal was to predict object distances in a video stream while providing a "depth-valued" uncertainty interval for every pixel.
As shown in the figure above, Rolling RC successfully generates pixel-wise uncertainty maps. The method controlled both global image miscoverage and local center-frame failure rates simultaneously—a task previous sequential calibration schemes could not handle.
Key Insights and Results
- Loss-Agnosticism: Rolling RC works for any bounded loss function, enabling control over precision, recall, or custom business logic. Unlike previous methods tied to 0-1 losses, this opens the door to complex risk management.
- Provable Safety: The paper provides a mathematical proof (Theorem 3.1) that Rolling RC will converge to the desired risk level regardless of how erratic or adversarial the data stream is.
- Efficiency: The "Error Adaptive" approach produced intervals up to 15% narrower than standard methods while maintaining safety guarantees, providing more informative predictions for downstream decision-making.
Conclusion and Future Work
Rolling RC adds essential "safety rails" to online learning with minimal computational overhead. While the current implementation requires tuning the step-size parameter ($\gamma$), which determines the speed of adaptation versus stability, future work aims to develop meta-algorithms for automatic hyperparameter optimization. This will further streamline the deployment of reliable, risk-controlled models in dynamic environments.
Summary updated