Difference between UCB and Gaussian Thompson sampling
- User
Difference between UCB and Gaussian Thompson sampling
Assistant
Both Upper Confidence Bound (UCB) and Gaussian Thompson Sampling (GTS) are popular algorithms for solving the multi-armed bandit (MAB) problem, but they differ in their approach to balancing exploration and exploitation. Here’s a detailed comparison:
1. Core Idea
-
UCB:
- Uses an optimistic approach by selecting the arm with the highest upper confidence bound.
- The bound is constructed using the mean reward estimate plus a confidence term (based on the number of times the arm has been pulled).
- Formula:
[
UCB_t(a) = \hat{\mu}_a + c \sqrt{\frac{\log t}{N_a(t)}}
]
where:
- (\hat{\mu}_a) = empirical mean of arm (a),
- (N_a(t)) = number of times arm (a) has been pulled by time (t),
- (c) = exploration constant.
-
Gaussian Thompson Sampling (GTS):
- Uses a probabilistic approach by sampling from a posterior distribution of rewards for each arm.
- Assumes rewards follow a Gaussian distribution (or another conjugate prior).
- At each step, it samples a reward from the posterior of each arm and selects the one with the highest sampled value.
- The posterior is updated using Bayesian inference (e.g., Gaussian-Gaussian conjugate updates).
2. Exploration vs. Exploitation
-
UCB:
- Explicit exploration via the confidence term ((\sqrt{\frac{\log t}{N_a(t)}})).
- The more an arm is pulled, the narrower its confidence interval becomes, reducing exploration for that arm.
-
GTS:
- Implicit exploration through random sampling from the posterior.
- Arms with high uncertainty (wide posterior) are more likely to be sampled with high values, encouraging exploration.
3. Assumptions
-
UCB:
- Works well with bounded rewards (e.g., Bernoulli, Gaussian with known variance).
- Requires tuning the exploration constant (c).
-
GTS:
-
- User
Isn't Gaussian thompson sampling more statistically justifiable as it's based on posterior of joint normal
Assistant
- User
Is it fair to say that much of the MAB work is based on heuristics as opposed to asymptotic guarantees?
Assistant
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.