cs.LGFeb 16, 2026

Replicable Constrained Bandits

Authors: Matteo Bollini, Gianmarco Genalti, Francesco Emanuele Stradi, Matteo Castiglioni, Alberto Marchesi

Organizations: Politecnico di Milano

Abstract

Algorithmic replicability has recently been introduced to address the need for reproducible experiments in machine learning. A replicable online learning algorithm is one that takes the same sequence of decisions across different executions in the same environment, with high probability. We initiate the study of algorithmic replicability in constrained MAB problems, where a learner interacts with an unknown stochastic environment for TT rounds, seeking not only to maximize reward but also to satisfy multiple constraints. Our main result is that replicability can be achieved in constrained MABs. Specifically, we design replicable algorithms whose regret and constraint violation match those of non-replicable ones in terms of TT. As a key step toward these guarantees, we develop the first replicable UCB-like algorithm for unconstrained MABs, showing that algorithms that employ the optimism in-the-face-of-uncertainty principle can be replicable, a result that we believe is of independent interest.

Figures & tables

Explore similar work

Apr 21, 2026

Replicable Bandits with UCB based Exploration

We study replicable algorithms for stochastic multi-armed bandits (MAB) and linear bandits with UCB (Upper Confidence Bound) based exploration. A bandit algorithm is ρρ-replicable if two executions using shared internal randomness but independent reward realizations produce the same action sequence with probability at least 1−ρ1-ρ. Prior approaches to this problem are elimination-based and, in linear bandits with infinitely many actions, rely on discretization, leading to suboptimal dependence on the dimension dd and ρρ. We develop optimistic alternatives for both settings. For stochastic multi-armed bandits, we propose RepUCB, a replicable batched UCB algorithm and show that it attains a regret O ⁣(K2log⁡2Tρ2∑a:Δa>0(Δa+log⁡(KTlog⁡T)Δa))O\!\left(\frac{K^2\log^2 T}{ρ^2}\sum_{a:Δ_a>0}\left(Δ_a+\frac{\log(KT\log T)}{Δ_a}\right)\right). For stochastic linear bandits, we first introduce RepRidge, a replicable ridge regression estimator that satisfies both a confidence guarantee and a ρρ-replicability guarantee. Beyond its role in our bandit algorithm, this may also be of independent interest in other statistical estimation settings. We then use RepRidge to design RepLinUCB, a replicable optimistic algorithm for stochastic linear bandits, and show that its regret is bounded by O~ ⁣((d+d3ρ)T)\widetilde{O}\!\big(\big(d+\frac{d^3}ρ\big)\sqrt{T}\big). This improves the best prior regret guarantee by a factor of O(d/ρ)O(d/ρ), showing that our optimistic algorithm can substantially reduce the price of replicability. This is the first linear-bandit algorithm with an optimal dependence on ρρ for large number of arms. Finally, we extend our framework to stochastic generalized linear bandits by developing RepGLM, a replicable penalized GLM estimator, and RepGLMUCB, a replicable optimistic algorithm for this setting.
Feb 12, 2024

Replicability is Asymptotically Free in Multi-armed Bandits

We consider a replicable stochastic multi-armed bandit algorithm that ensures, with high probability, that the algorithm's sequence of actions is not affected by the randomness inherent in the dataset. Replicability allows third parties to reproduce published findings and assists the original researcher in applying standard statistical tests. We observe that existing algorithms require O(K2/ρ2)O(K^2/ρ^2) times more regret than nonreplicable algorithms, where KK is the number of arms and ρρ is the level of nonreplication. However, we demonstrate that this additional cost is unnecessary when the time horizon TT is sufficiently large for a given K,ρK, ρ, provided that the magnitude of the confidence bounds is chosen carefully. Therefore, for a large TT, our algorithm only requires K2/ρ2K^2/ρ^2 times smaller amount of exploration than existing algorithms. To ensure the replicability of the proposed algorithms, we incorporate randomness into their decision-making processes. We propose a principled approach to limiting the probability of nonreplication. This approach elucidates the steps that existing research has implicitly followed. Furthermore, we derive the first lower bound for the two-armed replicable bandit problem, which implies the optimality of the proposed algorithms up to a log⁡log⁡T\log\log T factor for the two-armed case.
Feb 16, 2026

Truly Adapting to Adversarial Constraints in Constrained MABs

We study the constrained variant of the multi-armed bandit (MAB) problem, in which the learner aims not only at minimizing the total loss incurred during the learning dynamic, but also at controlling the violation of multiple unknown constraints, under both full and bandit feedback. We consider a non-stationary environment that subsumes both stochastic and adversarial models and where, at each round, both losses and constraints are drawn from distributions that may change arbitrarily over time. In such a setting, it is provably not possible to guarantee both sublinear regret and sublinear violation. Accordingly, prior work has mainly focused either on settings with stochastic constraints or on relaxing the benchmark with fully adversarial constraints (e.g., via competitive ratios with respect to the optimum). We provide the first algorithms that achieve optimal rates of regret and positive constraint violation when the constraints are stochastic while the losses may vary arbitrarily, and that simultaneously yield guarantees that degrade smoothly with the degree of adversariality of the constraints. Specifically, under full feedback we propose an algorithm attaining O~(T+C)\widetilde{\mathcal{O}}(\sqrt{T}+C) regret and O~(T+C)\widetilde{\mathcal{O}}(\sqrt{T}+C) {positive} violation, where CC quantifies the amount of non-stationarity in the constraints. We then show how to extend these guarantees when only bandit feedback is available for the losses. Finally, when bandit feedback is available for the constraints, we design an algorithm achieving O~(T+C)\widetilde{\mathcal{O}}(\sqrt{T}+C) {positive} violation and O~(T+CT)\widetilde{\mathcal{O}}(\sqrt{T}+C\sqrt{T}) regret.