Regularized Contextual Bandits

Xavier Fontaine, Quentin Berthet, Vianney Perchet

Abstract: We consider the stochastic contextual bandit problem with additional regularization. The motivation comes from problems where the policy of the agent must be close to some baseline policy which is known to be safe or effective. We propose a framework that optimizes a loss function combining expected reward with a convex regularization term, achieving theoretical regret bounds that interpolate between "slow" and "fast" convergence rates depending on the problem's complexity and a novel "margin condition."

Introduction

In a standard stochastic contextual bandit problem, an agent observes a "context" (like a user's browsing history), chooses an action (an "arm"), and receives a reward. The goal is to learn a policy that maximizes the cumulative reward over time. However, in many real-world applications—such as online advertising or clinical trials—purely maximizing reward can be risky or undesirable. A company might have a "handcrafted" legacy policy that is known to be safe, and they want the learning agent to stay relatively close to it. This paper, presented at AISTATS 2019, addresses this challenge by adding a regularization term $\rho$ to the loss function, effectively penalizing the agent for deviating too far from a desired distribution of actions.

Methodology

The authors employ a nonparametric approach combined with optimization techniques to solve the regularized problem:

  1. Context Binning (UCBograms): The context space (represented as a $d$-dimensional unit cube) is divided into smaller cubic "bins." Within each bin, the reward functions are assumed to be $\beta$-Hölder smooth. This discretization turns a complex functional optimization problem into a series of independent, simpler regularized multi-armed bandit problems.
  2. Regularized Loss: Instead of just minimizing the loss $\mu(x)$, they minimize $L(p) = \int [\langle \mu(x), p(x) \rangle + \lambda(x)\rho(p(x), x)] dx$, where $p(x)$ is the action probability distribution and $\rho$ is the regularizer.
  3. UC-FW Algorithm: Within each bin, they run a version of the Upper-Confidence Frank-Wolfe (UC-FW) algorithm. Frank-Wolfe is a projection-free optimization algorithm well-suited for working on the simplex (the space of probability distributions).
  4. Pre-sampling: To handle regularization functions that might behave poorly at the edges of the simplex (like Entropy, which has an infinite gradient at zero), the algorithm includes a pre-sampling phase. This ensures the agent has a "baseline" amount of information about every arm, keeping the policy away from the boundaries.

Theoretical Results

The most significant theoretical contribution is showing how a "margin condition" (a concept borrowed from nonparametric classification) can bridge the gap between "slow" rates and "fast" rates. If the optimal policy is "well-behaved" and stays away from the boundaries of the action space, the agent learns much faster.

Summary of theoretical error rates and regret bounds for slow and fast regimes.

As summarized in the table above, the regret $R(T)$ depends on the smoothness $\beta$ and dimension $d$. For general smooth convex regularizers, they achieve a "slow" regret bound of approximately $O(T^{-\frac{\beta}{2\beta+d}})$. Under stronger assumptions (strong convexity and the optimal policy being far from the boundary), they achieve a significantly better "fast" rate of $O(T^{-\frac{2\beta}{2\beta+d}})$.

Empirical Validation

The paper validates its findings using synthetic simulations with 3 arms ($K=3$) and contexts drawn uniformly from $[0, 1]^d$. Rewards were generated using Poisson, Exponential, and Bernoulli distributions to test different levels of smoothness.

Empirical validation showing normalized regret for different smoothness parameters $\beta$, confirming the predicted fast rates.

The simulations confirm that the regret scales exactly as predicted by their theoretical exponents. As shown in Figure 1, when the regret is normalized by the theoretical "fast" rate $(T/\log^2(T))^{-2\beta/(2\beta+d)}$, the resulting curves for different values of $\beta$ are roughly constant, demonstrating the tightness of the derived bounds.

Conclusion

This work provides a principled way to balance exploration with conservatism relative to a baseline. While the binning-based approach faces the "curse of dimensionality" (where the number of bins grows exponentially with $d$), the introduction of the margin condition provides a robust framework for understanding convergence in regularized settings. Future work could explore adaptive binning, such as decision trees, to split the context space more efficiently where reward functions change rapidly.

Summary updated

BibTeX
@inproceedings{fontaine2019regularized,
  author = {Xavier Fontaine and Quentin Berthet and Vianney Perchet},
  title = {{Regularized Contextual Bandits}},
  booktitle = {International Conference on Artificial Intelligence and Statistics},
  year = {2019},
  url = {https://openreview.net/forum?id=PMqRSGWlEtv},
}
Figure