NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Efficient and Adaptive Posterior Sampling Algorithms for Bandits

Bingshan Hu, Zhiming Huang, Tianyue H. Zhang, Mathias Lécuyer, Nidhi HegdearXiv 2024 · DOI

Abstract

Thompson Sampling (TS) is a widely used Bayesian approach for the Multi-Armed Bandit (MAB) problem. However, it has historically suffered from loose theoretical regret bounds and high computational costs in large-scale settings. This paper addresses these challenges by providing a significantly tighter regret bound for Gaussian-prior TS and introducing two adaptive algorithms, TS-MA-$\alpha$ and TS-TD-$\alpha$, which drastically reduce computational overhead by minimizing redundant sampling.

Introduction

The Multi-Armed Bandit problem is a fundamental framework in reinforcement learning with applications ranging from clinical trials to online advertising. Thompson Sampling is a popular heuristic for MAB, but it faces two significant hurdles:

  1. Theoretical Gap: Previous regret bounds for TS with Gaussian priors involved astronomical constants (e.g., $1.8 \times 10^{30}$), making them practically vacuous for realistic time horizons.
  2. Computational Scalability: Standard TS requires sampling from the posterior of every arm in every round. In environments with a large number of arms ($K$), this becomes a major bottleneck.

Methodology

The authors propose a multi-pronged approach to improve both the theory and practice of Thompson Sampling.

Tighter Analysis

By refining technical lemmas concerning the concentration of the optimal arm's posterior distribution, the authors reduced the leading constant in the problem-dependent regret bound from over $10^{30}$ down to 1270, making the theory relevant for real-world applications.

Adaptive Algorithms

Two new algorithms are introduced to handle large-scale bandit problems:

  • TS-MA-$\alpha$ (Model Aggregation): This algorithm draws a batch of samples and commits to the best one, re-sampling only when an arm is pulled and its data is updated. This decouples the number of samples from the total number of arms $K$.
  • TS-TD-$\alpha$ (Timestamp Duelling): A hybrid approach that uses standard TS for frequently pulled arms and batch sampling for sub-optimal arms. It uses "timestamp duelling" to ignore arms that haven't provided new information recently.

Both algorithms utilize a parameter $\alpha \in [0, 1]$ to balance the trade-off between cumulative reward (regret) and computational efficiency. Setting $\alpha=0$ optimizes for the best possible reward, while $\alpha=1$ minimizes the number of samples drawn.

Experimental Results

The algorithms were evaluated using synthetic stochastic bandits with Bernoulli reward distributions, a standard benchmark in theoretical bandit research.

Computational Efficiency

Experiments demonstrate that the proposed adaptive algorithms significantly reduce the number of posterior samples required. As shown in Figure 1, increasing $\alpha$ leads to a substantial decrease in data-dependent samples across various arm configurations. For instance, with one optimal arm out of 20, TS-TD-$\alpha$ requires only about 12.5% of the samples used by standard Thompson Sampling.

Reduction in data-dependent samples across different alpha values and arm configurations.

Regret Performance

Despite the reduction in sampling, the proposed algorithms maintain competitive regret performance. Both TS-MA and TS-TD achieve $O(K \ln^{\alpha+1}(T)/\Delta)$ regret. Figure 3 illustrates the regret curves for different $\alpha$ values, showing that for $\alpha=0$, the performance matches standard optimal bandit algorithms while remaining more computationally efficient.

Regret performance comparison across different alpha values (0, 0.8, 1) for various bandit algorithms.

Conclusion

This work bridges the gap between the theoretical analysis and practical implementation of Thompson Sampling. By providing tighter bounds and computationally efficient adaptive variants, the authors enable the deployment of TS in large-scale, real-time systems. Future work includes extending these algorithms to be "anytime" (removing the dependency on a known horizon $T$) and exploring their performance with non-Gaussian reward distributions.

Summary updated

BibTeX
@misc{hu2024efficient,
  author = {Bingshan Hu and Zhiming Huang and Tianyue H. Zhang and Mathias Lécuyer and Nidhi Hegde},
  title = {{Efficient and Adaptive Posterior Sampling Algorithms for Bandits}},
  year = {2024},
  eprint = {2405.01010},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2405.01010},
}
Figure