Sam Babichenko

Reading notes / Bandits and exploration

Adversarial and corrupted bandits

Auer et al., 2002; Lykouris et al., 2018

Adversarial bandit (EXP3)
KKnumber of arms
iian arm, one of 1,…,K1,\dots,K
TThorizon: the total number of rounds
tta round, t=1,…,Tt=1,\dots,T
xi(t)x_i(t)reward of arm ii at round tt, in [0,1][0,1], fixed by the adversary before play; in the corrupted model, the reward after the adversary's change, which is what the learner observes
iti_tarm played at round tt
GiG_iarm ii's total reward over the game, Gi=∑t≤Txi(t)G_i=\sum_{t\le T}x_i(t)
Gmax⁡G_{\max}largest total reward of a single arm, Gmax⁡=max⁡iGiG_{\max}=\max_iG_i
RTR_Tregret Gmax⁡−∑txit(t)G_{\max}-\sum_tx_{i_t}(t) against the best arm in hindsight
wi(t)w_i(t)EXP3's weight on arm ii at round tt: starts at 1 and is multiplied by exp⁡(γx^i(t)/K)\exp(\gamma\hat x_i(t)/K) each round
WtW_tEXP3's total weight at round tt, Wt=∑iwi(t)W_t=\sum_iw_i(t)
pi(t)p_i(t)probability that EXP3 plays arm ii at round tt, pi(t)=(1−γ)wi(t)/∑jwj(t)+γ/Kp_i(t)=(1-\gamma)w_i(t)/\sum_jw_j(t)+\gamma/K
x^i(t)\hat x_i(t)importance-weighted estimate of arm ii's reward at round tt: xi(t)/pi(t)x_i(t)/p_i(t) if arm ii was played, else 0; unbiased for xi(t)x_i(t)
G^j\hat G_jestimated total reward of arm jj, G^j=∑t≤Tx^j(t)\hat G_j=\sum_{t\le T}\hat x_j(t)
Ei\mathbb E_iexpectation in the lower-bound construction (Step 3) when arm ii is the good arm, paying 1 with probability 12+ε\tfrac{1}{2}+\varepsilon while the others are fair coins
E0\mathbb E_0expectation in the lower-bound construction (Step 3) when every arm is a fair coin
NiN_inumber of rounds in which the algorithm plays arm ii (Step 3)
Corrupted stochastic bandit
μi\mu_imean of arm ii's reward distribution before corruption
μ∗\mu^*best mean, μ∗=max⁡iμi\mu^*=\max_i\mu_i
i∗i^*a best arm, one with mean μ∗\mu^*
Δi\Delta_igap of arm ii, Δi=μ∗−μi\Delta_i=\mu^*-\mu_i
xiS(t)x^{\rm S}_i(t)stochastic reward before corruption (the paper writes rSt(a)r^t_S(a))
ctc_tcorruption injected at round tt, ct=max⁡i∣xi(t)−xiS(t)∣c_t=\max_i|x_i(t)-x^{\rm S}_i(t)|: the largest change the adversary makes to any arm's reward
CCbound on the total corruption: the instance is CC-corrupted if ∑tct≤C\sum_tc_t\le C on every sample path; the race does not know CC
ZtZ_tcorruption the slow rule observes at round tt (Step 6): at most ctc_t if the slow rule acts at round tt, else 0
ℓ\ella layer of the race, ℓ=1,…,⌈log⁡2T⌉\ell=1,\dots,\lceil\log_2T\rceil: an elimination rule picked with probability 2−ℓ2^{-\ell} each round
ℓ∗\ell^*first layer that tolerates the corruption: the smallest ℓ\ell with 2ℓ≥C2^\ell\ge C
rir_iconfidence radius of arm ii after nn plays; with CC known, ri=ln⁡(2KT/δ)/n+C/nr_i=\sqrt{\ln(2KT/\delta)/n}+C/n (Step 5); the paper writes wd(a)\mathrm{wd}(a)
Constants
γ\gammaEXP3's exploration rate in (0,1](0,1]: the share of probability spread uniformly over the arms; tuned in (a) to min⁡{1,Kln⁡K/((e−1)g)}\min\{1,\sqrt{K\ln K/((e-1)g)}\}
ggknown upper bound on Gmax⁡G_{\max} used to tune γ\gamma in (a)
ε\varepsilonadvantage of the good arm in the lower bound (b): it pays 1 with probability 12+ε\tfrac{1}{2}+\varepsilon; set to 14min⁡{K/T,1}\tfrac{1}{4}\min\{\sqrt{K/T},1\}
δ\deltafailure probability: the bounds of EXP3.P and of (c) hold with probability at least 1−δ1-\delta
α\alphaEXP3.P's bonus scale, 2ln⁡(KT/δ)2\sqrt{\ln(KT/\delta)}, Step 4
MMnumber of experts EXP4 competes with (the paper writes NN)
HHnumber of segments of the comparison sequence in EXP3.S, which switches arms at most H−1H-1 times
aalower exponent in (d): the corruption level CC lies between TaT^a and Ta′T^{a'}, with 0<a<a′<10\lt a\lt a'\lt1
a′a'upper exponent in (d): the corruption level CC lies between TaT^a and Ta′T^{a'}, with 0<a<a′<10\lt a\lt a'\lt1
bbconstant in the stochastic bound assumed in (d): pseudo-regret at most bln⁡T/Δb\ln T/\Delta on every two-armed instance with gap Δ\Delta

Context. Stochastic bandit rules such as upper confidence bound: play the arm whose average reward plus a bonus is largest, the bonus shrinking as the arm is played more. Reading note: UCB and Thompson sampling assume each arm's rewards are drawn independently from a fixed distribution and lean heavily on early samples. When rewards drift or someone manipulates them, those early samples mislead. Lykouris et al. (2018) point to automated searches or clicks that imitate users in order to change which ads a platform learns to show, where bots trigger a competitor's ad without clicking so its estimated click rate drops. Auer et al. (2002) drop the statistical model altogether. An adversary fixes every arm's reward sequence in advance, and the learner competes with the best single arm in hindsight. Lykouris et al. study the middle ground, stochastic rewards perturbed by a bounded total corruption unknown to the learner.

Both papers defend against an adversary by randomizing, since an opponent who cannot predict the next play cannot target it. Auer et al.'s exponential-weight algorithm for exploration and exploitation: play each arm with probability proportional to the exponential of a multiple of its estimated total reward, mixed with a little uniform play weights each arm exponentially in an importance-weighted estimate of its total reward. Those estimates stay unbiased against any reward sequence, and expected regret stays of order TKln⁡K\sqrt{TK\ln K}, within ln⁡K\sqrt{\ln K} of a universal lower bound. Lykouris et al. randomize over levels of caution instead. They run parallel rules that play every remaining arm in turn and discard an arm once its confidence interval lies wholly below another remaining arm's, sampled with probabilities 1/2,1/4,…1/2,1/4,\dots. Under total corruption CC, the layer sampled at rate about 1/C1/C sees only constant expected corruption and eliminates bad arms reliably. Regret scales linearly in CC without knowing CC, and a lower bound shows linear growth in CC is unavoidable for any rule that keeps logarithmic regret on clean data.

Setting. There are KK arms and TT rounds. Before play begins, an adversary fixes rewards the reward arm ii would pay at round tt, in [0,1][0,1]∈[0,1]{}\in[0,1] for every arm ii and round tt. At round tt the learner picks the arm played at round tt, possibly drawn at random, possibly at random, and observes only xit(t)x_{i_t}(t). Write GiG_i=∑t=1Txi(t){}=\sum_{t=1}^Tx_i(t) for arm ii's total and Gmax⁡G_{\max}=max⁡iGi{}=\max_iG_i. Regret is the reward lost against the best single arm in hindsight,RT=Gmax⁡−∑t=1Txit(t),R_T=G_{\max}-\sum_{t=1}^Tx_{i_t}(t),which is random through the learner's draws. The paper calls RTR_T the weak regret, and EXP3 bounds its expectation ERT\mathbb E R_T. Against an unrestricted sequence of arms, an adversary can force linear regret on any learner, so this benchmark fixes one arm for all TT rounds. Auer et al. also bound regret against arm sequences with a limited number of switches.

EXP3 keeps a weight arm ii's weight at round tt, starting at wi(1)=1w_i(1)=1 and multiplied each round by exp⁡(γx^i(t)/K)\exp(\gamma\hat x_i(t)/K), where x^i(t)\hat x_i(t) is the arm's estimated reward; arms with larger estimated totals get larger weights per arm, starting at wi(1)=1w_i(1)=1. At round tt, it mixes the normalized weights with the uniform distribution at exploration rate EXP3's exploration rate, in (0,1](0,1]: the share of probability spread uniformly over the arms∈(0,1]{}\in(0,1]. That gives each arm's play probability pi(t)p_i(t):pi(t)=(1−γ)wi(t)∑jwj(t)+γK.p_i(t)=(1-\gamma)\frac{w_i(t)}{\sum_jw_j(t)}+\frac{\gamma}{K}.The rule draws iti_t from p(t)p(t) and forms an importance-weighted estimate EXP3's importance-weighted estimate of xi(t)x_i(t): xi(t)/pi(t)x_i(t)/p_i(t) for the played arm and 0 for the others for every arm, setting unplayed arms to zero:x^i(t)=xi(t)pi(t) 1[i=it].\hat x_i(t)=\frac{x_i(t)}{p_i(t)}\,\mathbb 1[i=i_t].It then multiplies each weight wi(t)w_i(t) by exp⁡(γx^i(t)/K)\exp(\gamma\hat x_i(t)/K). The uniform component floors every probability at γ/K\gamma/K. That floor stops estimates from blowing up under tiny denominators and keeps sampling any arm whose early rewards were poor in case its rewards rise later.

Main results. (a) EXP3 (Auer et al., Theorem 3.1 and Corollary 3.2). Choosing γ\gamma balances two costs. Exploring forfeits a fraction of Gmax⁡G_{\max}, while a tiny γ\gamma slows weight updates. For any reward assignment and any γ∈(0,1]\gamma\in(0,1],ERT≤(e−1)γGmax⁡+Kln⁡Kγ.\mathbb E R_T\le(e-1)\gamma G_{\max}+\frac{K\ln K}{\gamma}.Given an upper bound an upper bound on Gmax⁡G_{\max} known in advance, used to set γ\gamma; g=Tg=T always works≥Gmax⁡{}\ge G_{\max}, such as g=Tg=T, setting γ=min⁡{1,Kln⁡K/((e−1)g)}\gamma=\min\{1,\sqrt{K\ln K/((e-1)g)}\} yieldsERT≤2e−1gKln⁡K≤2.63gKln⁡K.\begin{aligned}\mathbb E R_T&\le2\sqrt{e-1}\sqrt{gK\ln K}\\&\le2.63\sqrt{gK\ln K}.\end{aligned}Per-round regret thus falls like Kln⁡K/T\sqrt{K\ln K/T}. When neither TT nor Gmax⁡G_{\max} is known, EXP3.1 restarts EXP3 with guesses of gg growing by factors of 4 and achieves ERT≤10.5Gmax⁡Kln⁡K+13.8K+2Kln⁡K\mathbb E R_T\le10.5\sqrt{G_{\max}K\ln K}+13.8K+2K\ln K.

(b) Lower bound (Auer et al., Theorem 5.1). For any K≥2K\ge2 and any TT, some distribution over reward assignments forces every algorithm to sufferERT≥120min⁡{KT, T},\mathbb E R_T\ge\tfrac{1}{20}\min\{\sqrt{KT},\,T\},averaged over rewards and the algorithm's draws. EXP3 is therefore optimal up to ln⁡K\sqrt{\ln K}. Because the construction uses independent coin flips, the bound covers stochastic bandits as well. It does not clash with the ln⁡T\ln T regret of stochastic rules, because the quantifiers run in opposite orders. Stochastic bounds fix the gaps while TT grows, whereas here the best arm's advantage shrinks with TT. With K−1K-1 worse arms at gap Δ\Delta, a stochastic rule such as UCB loses at most about min⁡{TΔ, Kln⁡T/Δ}\min\{T\Delta,\ K\ln T/\Delta\} up to constants, since playing a worse arm every round costs TΔT\Delta. That bound peaks where the two terms meet,Δ≈Kln⁡T/T,ERT≈KTln⁡T.\begin{aligned}\Delta&\approx\sqrt{K\ln T/T},\\\mathbb ER_T&\approx\sqrt{KT\ln T}.\end{aligned}The lower bound's advantage ε≍K/T\varepsilon\asymp\sqrt{K/T} hits this hardest gap up to the logarithm.

The paper's extensions reuse the same exponential-weight machinery. EXP3.P adds a confidence bonus to each estimate and achieves regret of order KTln⁡(KT/δ)\sqrt{KT\ln(KT/\delta)} with probability 1−δ1-\delta. EXP4 competes with the best of MM strategies that each recommend, every round, a probability distribution over the arms; they may depend on anything seen so far at regret O(gKln⁡M)O(\sqrt{gK\ln M}), logarithmic in MM. EXP3.S competes with any arm sequence that switches at most H−1H-1 times, with regret O(HKTln⁡(KT))O(\sqrt{HKT\ln(KT)}). Restarting EXP3.P on doubling horizons yields EXP3.P.1, which achieves the average regret per round against every fixed strategy goes to 0 with probability 1 as the game is repeated in repeated games with unknown payoffs, driving average regret to zero with probability 1. In a two-player zero-sum game with an unknown payoff matrix, a player running EXP3.1 earns in expectation at least the game's max⁡pmin⁡qp⊤Gq\max_p\min_qp^\top Gq for payoff matrix GG over mixed strategies p,qp,q: the expected payoff per round a player can guarantee whatever the opponent does per round, up to a term vanishing with TT.

Corrupted stochastic bandits. Lykouris et al. start from a stochastic bandit. Arm ii has a reward distribution on [0,1][0,1] with mean the mean of arm ii's uncorrupted reward distribution, a best arm an arm with the largest mean μ∗\mu^* has mean μ∗\mu^*, and Δi\Delta_i=μ∗−μi{}=\mu^*-\mu_i. Each round, the learner picks a distribution over arms and nature draws a stochastic reward arm ii's reward at round tt as drawn from its distribution, before the adversary changes it for every arm. The adversary observes those draws, the history, and the learner's distribution, why: if the adversary saw the arm, or the layer behind it, it could corrupt exactly the rounds that feed the cautious layer, and subsampling (Step 6) would give no protection. It then replaces each xiS(t)x^{\rm S}_i(t) with any xi(t)∈[0,1]x_i(t)\in[0,1]. Finally, the learner draws iti_t and observes xit(t)x_{i_t}(t). The instance is the corruption summed over rounds, taking at each round the largest change to any arm, is at most CC on every sample path if every sample path satisfies∑t=1Tmax⁡i∣xi(t)−xiS(t)∣≤C.\sum_{t=1}^T\max_i\big|x_i(t)-x^{\rm S}_i(t)\big|\le C.As in EXP3, regret RTR_T is measured on the observed rewards, and the bounds hold with probability at least 1−δ1-\delta for a chosen failure probability the failure probability, chosen by the learner: the bounds hold with probability at least 1−δ1-\delta, and they contain ln⁡(KT/δ)\ln(KT/\delta), so a smaller δ\delta costs only logarithmically.

(c) Corruption-robust elimination (Lykouris et al., Theorems 1 to 3). When CC is known, widening each confidence interval by C/nC/n after nn plays yields regret O(∑i≠i∗(ln⁡(KT/δ)+C)/Δi)O\big(\sum_{i\ne i^*}(\ln(KT/\delta)+C)/\Delta_i\big), though it pays the CC term even on clean data. The Lykouris et al.'s algorithm: about log⁡2T\log_2T elimination rules run side by side, layer ℓ\ell picked at random with probability 2−ℓ2^{-\ell} each round, and an arm removed by a slower layer is removed from the faster ones (Step 8) needs no knowledge of CC. With probability 1−δ1-\delta, it achievesRT=O(∑i≠i∗KCln⁡KTδ+ln⁡TΔi×ln⁡KTδ).\begin{aligned}R_T=O\bigg(\sum_{i\ne i^*}&\frac{KC\ln\frac{KT}\delta+\ln T}{\Delta_i}\\&\times\ln\frac{KT}{\delta}\bigg).\end{aligned}At C=0C=0 this recovers the stochastic rate ∑iln⁡(KT/δ)/Δi\sum_i\ln(KT/\delta)/\Delta_i up to one extra factor of ln⁡T\ln T.

(d) Linear cost of corruption (Lykouris et al., Theorem 4). Take any algorithm whose the regret in expectation against the arm with the best expected total, max⁡iE∑t(xi(t)−xit(t))\max_i\mathbb E\sum_t(x_i(t)-x_{i_t}(t)); on uncorrupted data, the sum over worse arms of gap times expected number of plays on every two-armed stochastic instance with gap Δ\Delta is at most bln⁡T/Δb\ln T/\Delta, for a constant bb. For any exponents 0<a<a′<10\lt a\lt a'\lt1, there exist a corruption level C∈[Ta,Ta′]C\in[T^a,T^{a'}] and a CC-corrupted instance on which the algorithm suffers regret Ω(C)\Omega(C) with constant probability. Linear dependence on CC is the price of logarithmic regret on clean data. The upper bound (c) matches that linear growth in CC, though its factors KK, 1/Δi1/\Delta_i, and logarithms are not shown to be needed.

What it means. When rewards drift arbitrarily or come from an opponent, EXP3 guarantees O(T)O(\sqrt{T}) regret against any sequence fixed in advance. EXP3 trades away the ln⁡T\ln T stochastic rate, and its realized regret has large variance around its expectation. On mostly stochastic data with bounded manipulation, the layered race keeps near-stochastic regret and pays linearly in the corruption, provided the adversary cannot see which layer is drawn each round. A deterministic rule such as UCB1 has no such shield. An an adversary that may choose each round's rewards after seeing the play so far can compute its next arm and corrupt exactly that arm's reward. The race's bound multiplies each arm's term by KCln⁡(KT/δ)KC\ln(KT/\delta), leaving a wide gap above the Ω(C)\Omega(C) lower bound (d). Later work (Gupta et al., 2019) cut total regret to an additive term of order KCKC plus the stochastic rate up to a logarithmic factor.

Step 1

Dividing by the probability of play makes every arm's estimate unbiased. Given the history, the rule plays arm ii with probability pi(t)p_i(t) while the rewards are already fixed, so for every arm ii,E[x^i(t)∣past]=pi(t)xi(t)pi(t)+(1−pi(t))⋅0=xi(t).\begin{aligned}\mathbb E[\htmlData{gr=g12}{\hat x_i(t)}\mid\text{past}]&=p_i(t)\frac{x_i(t)}{p_i(t)}\\&\quad+(1-p_i(t))\cdot0\\&=x_i(t).\end{aligned}Variance is the price. Because x^i(t)\hat x_i(t) is 0 on most rounds and xi(t)/pi(t)x_i(t)/p_i(t) when arm ii is played, its second moment equals xi(t)2/pi(t)x_i(t)^2/p_i(t), which can reach K/γK/\gamma. Weighting the estimates by the play probabilities recovers the realized reward, ∑ipi(t)x^i(t)=xit(t)\sum_ip_i(t)\hat x_i(t)=x_{i_t}(t). Because rewards are at most 1 and only arm iti_t has a nonzero estimate, ∑ipi(t)x^i(t)2=xit(t)x^it(t)≤∑ix^i(t)\sum_ip_i(t)\hat x_i(t)^2=x_{i_t}(t)\hat x_{i_t}(t)\le\sum_i\hat x_i(t). Step 2 uses both identities.

Step 2

The total weight grows at most as fast as the learner's reward, and at least as fast as the best arm's estimate. Write WtW_t=∑iwi(t){}=\sum_iw_i(t) and G^j\hat G_j=∑tx^j(t){}=\sum_t\hat x_j(t). Because pi(t)≥γ/Kp_i(t)\ge\gamma/K, the update exponent u=γx^i(t)/Ku=\gamma\hat x_i(t)/K stays at most 1, where eu≤1+u+(e−2)u2e^u\le1+u+(e-2)u^2. The mixing rule also gives wi(t)/Wt=(pi(t)−γ/K)/(1−γ)≤pi(t)/(1−γ)w_i(t)/W_t=(p_i(t)-\gamma/K)/(1-\gamma)\le p_i(t)/(1-\gamma). Expand Wt+1/WtW_{t+1}/W_t with these two bounds and Step 1's identities, take logs via ln⁡(1+z)≤z\ln(1+z)\le z, and sum over rounds to obtain the upper bound below. The lower bound follows from W1=KW_1=K and WT+1≥wj(T+1)=eγG^j/KW_{T+1}\ge w_j(T+1)=e^{\gamma\hat G_j/K}:ln⁡WT+1W1≤γ/K1−γ∑txit(t)+(e−2)(γ/K)21−γ∑t,ix^i(t),ln⁡WT+1W1≥γKG^j−ln⁡K.\begin{aligned}\ln\frac{W_{T+1}}{W_1}&\le\frac{\gamma/K}{1-\gamma}\sum_tx_{i_t}(t)\\&\quad+\frac{(e-2)(\gamma/K)^2}{1-\gamma}\sum_{t,i}\hat x_i(t),\\\ln\frac{W_{T+1}}{W_1}&\ge\frac{\gamma}{K}\hat G_j-\ln K.\end{aligned}Chain the two inequalities and multiply through by (1−γ)K/γ(1-\gamma)K/\gamma. Taking expectations with EG^i=Gi\mathbb E\hat G_i=\htmlData{gr=g7}{G_i} (Step 1) and ∑iGi≤KGmax⁡\sum_iG_i\le KG_{\max} gives Gj−E∑txit(t)≤γGj+(e−2)γGmax⁡+Kln⁡K/γG_j-\mathbb E\sum_tx_{i_t}(t)\le\gamma G_j+(e-2)\gamma G_{\max}+K\ln K/\gamma. Setting jj to the best arm yields (a).

With learning rate η=γ/K\eta=\gamma/K, shifting the weights from uniform onto one arm costs about ln⁡K/η\ln K/\eta, and each round adds about η\eta times the estimates' second moment. By Step 1, that expected second moment isE∑ipi(t)x^i(t)2=∑ixi(t)2≤K,\begin{aligned}\mathbb E\textstyle\sum_ip_i(t)\hat x_i(t)^2&=\textstyle\sum_ix_i(t)^2\\&\le K,\end{aligned}compared with ∑ipi(t)xi(t)2≤1\sum_ip_i(t)x_i(t)^2\le1 when every arm's reward is observed. Balancing ERT≈ln⁡K/η+ηKT\mathbb ER_T\approx\ln K/\eta+\eta KT at η=ln⁡K/(KT)\eta=\sqrt{\ln K/(KT)} gives 2KTln⁡K2\sqrt{KT\ln K}. Uniform exploration adds γT=ηKT\gamma T=\eta KT, the same order. Seeing only one arm per round multiplies the variance by KK and the regret by K\sqrt{K}.

Step 3

One slightly better arm hidden among fair coins forces regret of order KT\sqrt{KT}. Pick one good arm uniformly at random. It pays 1 with probability 12+ε\tfrac{1}{2}+\varepsilon, while every other arm is a fair coin. Write expectations in the construction when arm ii is the good arm, paying 1 with probability 12+ε\tfrac{1}{2}+\varepsilon while every other arm is a fair coin, and when every arm is a fair coin for expectations when arm ii is good and when all arms are fair, and let the number of rounds in which the algorithm plays arm ii count arm ii's plays. Under the two laws, the algorithm's observations differ only on plays of arm ii, each adding KL divergence −12ln⁡(1−4ε2)≈2ε2-\tfrac{1}{2}\ln(1-4\varepsilon^2)\approx2\varepsilon^2. Combining the for two laws P,QP,Q of a sequence y1,…,yny_1,\dots,y_n, KL(P∥Q)=∑t≤nEP KL(P(yt∣y<t) ∥ Q(yt∣y<t))\mathrm{KL}(P\|Q)=\sum_{t\le n}\mathbb E_P\,\mathrm{KL}\big(P(y_t\mid y_{\lt t})\,\|\,Q(y_t\mid y_{\lt t})\big): the divergence of the whole sequence is the sum over steps of the expected divergence of each observation given the past with ∣P(A)−Q(A)∣≤KL(P∥Q)/2|P(A)-Q(A)|\le\sqrt{\mathrm{KL}(P\|Q)/2} for every event AA: a small divergence keeps all probabilities close and 0≤Ni≤T0\le N_i\le T caps how much more often arm ii can be played when it is good. Summing over arms with ∑iE0Ni=T\sum_i\mathbb E_0N_i=T, so that ∑iE0Ni≤KT\sum_i\sqrt{\mathbb E_0N_i}\le\sqrt{KT} by Cauchy-Schwarz, yieldsEiNi≤E0Ni+T2−E0Niln⁡(1−4ε2),∑iEiNi≤T+T2−KTln⁡(1−4ε2).\begin{aligned}\mathbb E_iN_i&\le\mathbb E_0N_i\\&\quad+\tfrac{T}{2}\sqrt{-\mathbb E_0N_i\ln(1-4\varepsilon^2)},\\\textstyle\sum_i\mathbb E_iN_i&\le T\\&\quad+\tfrac{T}{2}\sqrt{-KT\ln(1-4\varepsilon^2)}.\end{aligned}

Averaging over the random choice of good arm, the algorithm plays it 1K∑iEiNi\tfrac{1}{K}\sum_i\mathbb E_iN_i times on average. Dividing the second display line by KK and using −ln⁡(1−4ε2)≈4ε2-\ln(1-4\varepsilon^2)\approx4\varepsilon^2 shows the rule misses the good arm on at least about T(1−1K−εT/K)T\big(1-\tfrac{1}{K}-\varepsilon\sqrt{T/K}\big) rounds. Each missed round loses ε\varepsilon, so expected regret is at least about εT(1−1K−εT/K)\varepsilon T\big(1-\tfrac{1}{K}-\varepsilon\sqrt{T/K}\big). Setting ε=14min⁡{K/T,1}\varepsilon=\tfrac{1}{4}\min\{\sqrt{K/T},1\} proves (b). Any learner must try every arm to find the good one, and over T/KT/K plays per arm an advantage of K/T\sqrt{K/T} sits right at the noise level of each arm's sample mean.

Step 4

EXP3's regret has a large spread, and a confidence bonus controls it. The variance of x^i(t)\hat x_i(t) can approach 1/pi(t)1/p_i(t), which at the tuned γ\gamma is of order T\sqrt{T} for fixed KK. Summed over TT rounds, the variance reaches order T3/2T^{3/2}, so realized regret can hit order T3/4T^{3/4}, far above its expectation. EXP3.P adds a bonus α/(pi(t)KT)\alpha/(p_i(t)\sqrt{KT}) to each arm's estimate before the exponential update, with α=2ln⁡(KT/δ)\alpha=2\sqrt{\ln(KT/\delta)}. A martingale bound ensures that the estimated total plus α\alpha times a running width exceeds every arm's true total with probability 1−δ1-\delta. Running Step 2's weight argument on those upper confidence bounds then gives, with probability at least 1−δ1-\delta,RT≤4KTln⁡KTδ+453KTln⁡K+8ln⁡KTδ.\begin{aligned}R_T\le{}&4\sqrt{KT\ln\tfrac{KT}{\delta}}\\&+4\sqrt{\tfrac{5}{3}KT\ln K}\\&+8\ln\tfrac{KT}{\delta}.\end{aligned}

Step 5

Corrupting early rounds can make a stochastic elimination rule discard the best arm permanently. a stochastic bandit rule that plays the remaining arms in turn and removes an arm once its confidence interval lies entirely below another remaining arm's (Even-Dar et al., 2006) cycles through surviving arms and drops an arm once its upper confidence bound falls below another arm's lower bound. It decides from the first O(ln⁡T)O(\ln T) plays and never returns to a dropped arm. An adversary who corrupts those early plays of the best arm can force it out, causing the rule to lose Δ\Delta on every remaining round and turning O(ln⁡T)O(\ln T) corruption into linear regret.

When CC is known, the simplest repair widens each confidence interval to absorb the worst-case corruption. If nn plays of arm ii carry total corruption at most CC, the observed average stays within C/nC/n of the uncorrupted stochastic average. Setting arm ii's confidence radius the radius of arm ii's confidence interval after nn plays: the average reward plus or minus rir_i contains the mean μi\mu_i with high probability tori=ln⁡(2KT/δ)n+Cnr_i=\sqrt{\frac{\ln(2KT/\delta)}{n}}+\frac{C}{n}keeps every true mean inside its interval with probability 1−δ1-\delta and yields regret O(∑i≠i∗(ln⁡(KT/δ)+C)/Δi)O\big(\sum_{i\ne i^*}(\ln(KT/\delta)+C)/\Delta_i\big). That repair still requires knowing CC in advance and pays the CC penalty even on clean data.

Step 6

A layer run with probability 1/C1/C sees only a constant amount of corruption. Still assuming CC is known, run two elimination rules side by side. A fast rule uses standard intervals, while a slow rule is chosen at random on a 1/C1/C fraction of rounds. Write ctc_t=max⁡i∣xi(t)−xiS(t)∣{}=\max_i|x_i(t)-\htmlData{gr=g20}{x^{\rm S}_i(t)}| for round tt's corruption, and the corruption the slow rule observes at round tt: at most ctc_t if the slow rule acts at round tt, else 0 for the corruption the slow rule observes, which is at most ctc_t when chosen and 0 otherwise. Because the adversary fixes ctc_t before the coin that picks the rule,E[∑tZt]≤∑tctC≤1.\mathbb E\Big[\sum_tZ_t\Big]\le\sum_t\frac{c_t}{C}\le1.The adversary adapts to the past, so the ZtZ_t are not independent. Their conditional variances still sum to at most 2, so a a tail bound for a sum of bounded martingale differences that scales with their summed conditional variance VV: with probability 1−δ1-\delta the sum is at most of order Vln⁡(1/δ)+ln⁡(1/δ)\sqrt{V\ln(1/\delta)}+\ln(1/\delta) (Freedman, 1975) gives ∑tZt≤ln⁡(1/δ)+3\sum_tZ_t\le\ln(1/\delta)+3 with probability 1−δ1-\delta. The slow rule operates on nearly clean data and needs only an extra interval width of order ln⁡(KT/δ)/n\ln(KT/\delta)/n.

Step 7

Propagating removals from the slow rule to the fast rule limits extra regret to a factor KCKC. Whenever the slow rule drops an arm, the fast rule drops it too. If the fast rule has eliminated every arm, it plays any arm the slow rule still keeps. With high probability, the slow rule never drops the best arm and eliminates each worse arm ii after about 18ln⁡(8KT/δ)/Δi218\ln(8KT/\delta)/\Delta_i^2 of its own plays of ii. The slow rule acts once every CC rounds on average and cycles over at most KK surviving arms. Arm ii therefore survives in the fast rule for about KCKC times that many rounds, with one extra ln⁡\ln factor in the high-probability bound. At cost Δi\Delta_i per round, corrupted regret is O(KC∑i≠i∗ln⁡2(KT/δ)/Δi)O\big(KC\sum_{i\ne i^*}\ln^2(KT/\delta)/\Delta_i\big), while on clean data both rules keep the usual O(∑i≠i∗ln⁡(KT/δ)/Δi)O\big(\sum_{i\ne i^*}\ln(KT/\delta)/\Delta_i\big).

Step 8

Running about log⁡2T\log_2T layers removes the need to know CC. The race runs layers ℓ=1,…,⌈log⁡2T⌉\ell=1,\dots,\lceil\log_2T\rceil of active arm elimination. Each round it picks layer ℓ\ell with probability 2−ℓ2^{-\ell}, giving the leftover probability to layer 1, and plays that layer's least-played surviving arm. Whenever a layer drops an arm, every faster layer drops it too, so no faster layer keeps an arm a slower layer has ruled out. Let the first layer that tolerates the corruption, the smallest ℓ\ell with 2ℓ≥C2^\ell\ge C be the smallest layer with 2ℓ≥C2^{\ell}\ge C. Every layer from ℓ∗\ell^* upward sees constant expected corruption (Step 6) and costs O(∑iln⁡(KT/δ)/Δi)O(\sum_i\ln(KT/\delta)/\Delta_i). Summing across about ln⁡T\ln T such layers yields the ln⁡T\ln T term of (c). Faster layers incur error only until layer ℓ∗\ell^* removes their bad arms, so Step 7 bounds their cost with 2ℓ∗<2C2^{\ell^*}\lt2C in place of CC, adding at most a factor of 2. As in Step 6, each round's layer is drawn at random and hidden from the adversary.

Step 9

An algorithm that is fast on clean data can be misled for a stretch of length CC. Take two clean Bernoulli arms: arm 1 has mean 12−Δ\tfrac{1}{2}-\Delta and arm 2 has mean 12\tfrac{1}{2}. An algorithm with pseudo-regret at most bln⁡T/Δb\ln T/\Delta plays arm 1 only O(ln⁡T/Δ2)O(\ln T/\Delta^2) times in expectation. Split the rounds between TaT^a and Ta′T^{a'} into Θ(ln⁡T)\Theta(\ln T) disjoint intervals [C,3C)[C,3C) of geometrically growing length. For fixed Δ\Delta, at least one interval sees only a constant expected number of plays of arm 1. Now construct the corrupted instance by giving arm 1 true mean 12+Δ\tfrac{1}{2}+\Delta and lowering its rewards during rounds 1…C1\dots C to match draws from 12−Δ\tfrac{1}{2}-\Delta, using total corruption at most CC. The two instances coincide before round CC and differ afterward only when the learner plays arm 1. With constant probability the algorithm still plays arm 1 only a constant number of times across [C,3C)[C,3C). It then loses about Δ\Delta per round over those 2C2C rounds, suffering regret Ω(ΔC)\Omega(\Delta C), or Ω(C)\Omega(C) for the fixed gap in (d).

Terms

Weak regret
Gmax⁡−∑txit(t)G_{\max}-\sum_tx_{i_t}(t): reward lost against the best single arm in hindsight; EXP3 bounds its expectation
EXP3
pi=(1−γ)wi/∑jwj+γ/Kp_i=(1-\gamma)w_i/\sum_jw_j+\gamma/K; x^i=xi1[i=it]/pi\hat x_i=x_i\mathbb 1[i=i_t]/p_i; wi←wieγx^i/Kw_i\leftarrow w_ie^{\gamma\hat x_i/K}
Importance weighting
E[x^i(t)∣past]=xi(t)\mathbb E[\hat x_i(t)\mid\text{past}]=x_i(t) for every arm; second moment up to 1/pi1/p_i
EXP3 bound
(e−1)γGmax⁡+Kln⁡K/γ(e-1)\gamma G_{\max}+K\ln K/\gamma; tuned, 2.63gKln⁡K2.63\sqrt{gK\ln K}
Lower bound
120min⁡{KT,T}\tfrac{1}{20}\min\{\sqrt{KT},T\} for every algorithm; one arm better by about K/T\sqrt{K/T}
EXP3.P
confidence bonus α/(piKT)\alpha/(p_i\sqrt{KT}); regret O(KTln⁡(KT/δ))O(\sqrt{KT\ln(KT/\delta)}) with probability 1−δ1-\delta
EXP4
MM experts at regret O(gKln⁡M)O(\sqrt{gK\ln M})
CC-corrupted
∑tmax⁡i∣xi(t)−xiS(t)∣≤C\sum_t\max_i|x_i(t)-x^{\rm S}_i(t)|\le C; the adversary sees the learner's distribution, not its draw
Subsampling
a rule run with probability 1/C1/C sees expected corruption at most 1
Multi-layer race
layer ℓ\ell with probability 2−ℓ2^{-\ell}; removals propagate to faster layers; regret O(∑i(KCln⁡KTδ+ln⁡T)ln⁡KTδ/Δi)O(\sum_i(KC\ln\frac{KT}{\delta}+\ln T)\ln\frac{KT}{\delta}/\Delta_i)
Linear cost of corruption
O(ln⁡T/Δ)O(\ln T/\Delta) on clean data forces Ω(C)\Omega(C) on some CC-corrupted instance

Sources

Connected notes

  • Direct preference optimizationLearning from human preferences · Exponential tilting

    Without the KL term the best policy puts all its mass on one sequence; with it the target is πrefer/β/Z\pi_{\rm ref}e^{r/\beta}/Z, which puts mass on exactly the sequences the reference model gives mass to and moves toward the best sequences as β\beta falls.

  • Each token's gradient carries the ratio ρ\rho of its probability under the trained copy to that under the copy that sampled it; CISPO caps that weight at εmax⁡\varepsilon_{\max} where DAPO's clip drops the gradient of a token whose ratio has moved past the clipping range in the direction its advantage favors, which raises the fitted ceiling from 0.52 to 0.595; computing the output layer in FP32, which shrinks the kernel mismatch inside every ratio, raises the base recipe's ceiling from 0.52 to 0.61 on its own.

  • In a PAC-Bayes bound the KL from posterior to prior is the complexity term, and a Gaussian prior centered at the initialization makes it grow with how precisely the weights are specified and how far they move in training.

  • Sampling one action per decision divides each payoff by the probability ξ[z]\xi[z] of reaching it, and exploring at rate ε\varepsilon keeps that weight at most (∣Ai∣/ε)di(|A_i|/\varepsilon)^{d_i}, so the regret bound still holds but grows exponentially with the number of decisions.

Threads