# A general recipe for data-adaptive anytime-valid envelopes for iterative algorithms

arXiv: https://arxiv.org/abs/2610.23570 · HTML: https://mlsanity.com/paper/2610.23570/

## Key facts

- No citing papers in the map yet (data through 26 Nov 2026).
- Builds on 25 of its 172 references that are in the map.
- Submitted 16 Oct 2026.

## Builds on (most cited first, 25 of 25)

- [OpenAI Gym](https://mlsanity.com/paper/1606.01540/) (2016)
- [Handbook of Convergence Theorems for (Stochastic) Gradient Methods](https://mlsanity.com/paper/2301.11235/) (2023)
- [Stochastic approximation with cone-contractive operators: Sharp ℓ_∞-bounds for Q-learning](https://mlsanity.com/paper/1905.06265/) (2019)
- [Gymnasium: A Standard Interface for Reinforcement Learning Environments](https://mlsanity.com/paper/2407.17032/) (2024)
- [Fast Convergence of Stochastic Gradient Descent under a Strong Growth Condition](https://mlsanity.com/paper/1308.6370/) (2013)
- [Simple and optimal high-probability bounds for strongly-convex stochastic gradient descent](https://mlsanity.com/paper/1909.00843/) (2019)
- [Statistical Inference for Policy Evaluation with Temporal Difference Learning](https://mlsanity.com/paper/2410.16106/) (2024)
- [Can SGD Handle Heavy-Tailed Noise?](https://mlsanity.com/paper/2508.04860/) (2025)
- [Uncertainty quantification for Markov chain induced martingales with application to temporal difference learning](https://mlsanity.com/paper/2502.13822/) (2025)
- [On the near-optimality of betting confidence sets for bounded means](https://mlsanity.com/paper/2310.01547/) (2023)
- [SGD with Dependent Data: Optimal Estimation, Regret, and Inference](https://mlsanity.com/paper/2601.01371/) (2026)
- [Stopping Rules for Stochastic Gradient Descent via Anytime-Valid Confidence Sequences](https://mlsanity.com/paper/2512.13123/) (2025)
- [Asymptotic Time-Uniform Inference for Parameters in Averaged Stochastic Approximation](https://mlsanity.com/paper/2410.15057/) (2024)
- [Concentration of General Stochastic Approximation Under Heavy-Tailed Markovian Noise](https://mlsanity.com/paper/2605.20999/) (2026)
- [Square distance functions are Polyak-Lojasiewicz and vice-versa](https://mlsanity.com/paper/2301.10332/) (2023)
- [The Anytime Convergence of Stochastic Gradient Descent with Momentum: From a Continuous-Time Perspective](https://mlsanity.com/paper/2310.19598/) (2023)
- [Distribution-uniform anytime-valid sequential inference and the Robbins-Siegmund distributions](https://mlsanity.com/paper/2311.03343/) (2023)
- [The Exact Time-Uniform Rate Frontier for Stochastic Gradient Descent on Smooth Convex Objectives](https://mlsanity.com/paper/2609.08537/) (2026)
- [A Generalized Version of Chung's Lemma and its Applications](https://mlsanity.com/paper/2406.05637/) (2024)
- [High-Probability Bounds for SGD under the Polyak-Lojasiewicz Condition with Markovian Noise](https://mlsanity.com/paper/2603.14514/) (2026)
- [Self-Normalized Inference for Constant-Stepsize Temporal-Difference Learning under Markovian Sampling](https://mlsanity.com/paper/2608.10896/) (2026)
- [Breaking a Logarithmic Barrier in the Stopping Time Convergence Rate of Stochastic First-order Methods](https://mlsanity.com/paper/2506.23335/) (2025)
- [Closed-form empirical Bernstein confidence sequences for scalars and matrices](https://mlsanity.com/paper/2512.21300/) (2025)
- [Gaussian-efficient testing by betting on the mean of bounded data](https://mlsanity.com/paper/2608.21694/) (2026)
- [Beyond Optimal Rates in Stochastic Optimization: Trajectory-Adaptive Stopping Rules](https://mlsanity.com/paper/2608.25551/) (2026)

## Abstract (arXiv)

Most convergence guarantees for iterative stochastic algorithms are stated at a fixed iteration count and do not justify stopping at a data-dependent time. Recent anytime-valid envelopes do, but deterministic ones are typically too conservative for practical stopping, and existing data-adaptive ones are derived case-by-case, each concerned with a specific algorithm and a specific noise model and boundary construction. This paper provides a general recipe for sharp, data-adaptive anytime-valid envelopes for a large class of iterative algorithms. Our approach has two key steps: an optimization module derives a one-step recursion that performance measures of many such algorithms satisfy, reducing the error analysis to time-uniform concentration for predictably weighted sums of noise. Then, a statistical module ports the sub-psi condition to vector-valued processes, uniformly over predictable weights, and derives off-the-shelf boundaries via mixtures, stitching, and product betting martingales. Combining the two yields readymade envelopes for many iterative algoithms including but not limited to stochastic gradient descent (SGD), Oja's algorithm, temporal difference learning, Q-learning, and Bures-Wasserstein SGD, many with no prior data-adaptive anytime-valid guarantees. Specifically, for SGD, our framework recovers, often under weaker conditions, or significantly sharpens every existing envelope we are aware of. Our constructions come with explicit implementation details and are substantiated by numerical experiments.
