Thompson sampling
Thompson sampling, named after William Rae Thompson, is a heuristic for choosing actions that address the exploration–exploitation dilemma in the multi-armed bandit problem. It consists of choosing the action that maximizes the expected reward with respect to a randomly drawn belief. Source: e01 Encyclopedia. Licence: CC BY-SA 4.0.
Thompson sampling, named after William Rae Thompson, is a heuristic for choosing actions that address the exploration–exploitation dilemma in the multi-armed bandit problem. It consists of choosing the action that maximizes the expected reward with respect to a randomly drawn belief. past observations triplets \mathcal{D} = \{(x; a; r)\} ; a posterior distribution P(\theta|\mathcal{D}) \propto P(\mathcal{D}|\theta)P(\theta) , where P(\mathcal{D}|\theta) is the likelihood function. Thompson sampling consists of playing the action a^\ast \in \mathcal{A} according to the probability that it maximizes the expected reward; action a^\ast is chosen with probability \int \mathbb{I} \left[ \mathbb{E}(r|a^\ast,x,\theta) = \max_{a'} \mathbb{E}(r|a',x,\theta) \right] P(\theta|\mathcal{D}) d\theta, where \mathbb{I} is the indicator function. In practice, the rule is implemented by sampling. In each round, parameters \theta^\ast are sampled from the posterior P(\theta|\mathcal{D}) , and an action a^\ast chosen that maximizes \mathbb{E}[r|\theta^\ast,a^\ast,x] , i.e. the expected reward given the sampled parameters, the action, and the current context. Conceptually, this means that the player instantiates their beliefs randomly in each round according to the posterior distribution, and then acts optimally according to them. In most practical applications, it is computationally onerous to maintain and sample from a posterior distribution over models. As such, Thompson sampling is often used in conjunction with approximate sampling techniques. P(a_{T+1}|\hat{a}_{1:T}, o_{1:T}) = \int_{\Theta} P(a_{T+1}|\theta, \hat{a}_{1:T}, o_{1:T}) P(\theta|\hat{a}_{1:T}, o_{1:T}) \, d\theta , where P(\theta|\hat{a}_{1:T}, o_{1:T}) is the posterior distribution over the parameter \theta given actions a_{1:T} and observations o_{1:T} . In practice, the Bayesian control amounts to sampling, at each time step, a parameter \theta^\ast from the posterior distribution P(\theta|\hat{a}_{1:T}, o_{1:T}) , where the posterior distribution is computed using Bayes' rule by only considering the (causal) likelihoods of the observations o_1, o_2, \ldots, o_T and ignoring the (causal) likelihoods of the actions a_1, a_2, \ldots, a_T , and then by sampling the action a^\ast_{T+1} from the action distribution P(a_{T+1}|\theta^\ast,\hat{a}_{1:T},o_{1:T}) .
Cite this
"Thompson sampling". 1782991132. e01 Encyclopedia. CC BY-SA 4.0. https://en.wikipedia.org/w/index.php?oldid=1362198073 JSON record · API collection · BibTeX · RIS · CSL-JSON · citation policy