Level 0: Foundation
★☆☆☆☆ Introductory⏱ 5 minGeneral audience. No mathematics required.Keeping score with just a few numbers
To estimate how often a robot’s grasp succeeds, you don’t need the full list of every try, only how many tries and how many successes. Those few numbers capture everything the data can tell you. They’re called sufficient statistics.
Better still, you can start with a guess that’s worth a few imaginary tries, then simply add the real tries as they happen. The updated belief has the same shape as the starting guess, just sharper. Starting beliefs that work like this are called conjugate priors.
A robot choosing between grasp strategies, or a website comparing two button designs, can update its beliefs after every trial with a couple of additions, fast enough to run on tiny onboard computers. It can then decide what to try next by sampling from those beliefs.
- 1. To estimate a success rate you need…
- 2. Prior worth 2 successes + 2 failures, then 7 successes + 3 failures. Estimate?
- 3. With lots of data, the prior matters…
Level 1: Beginner
★★☆☆☆ Basic⏱ 15 minSecondary-school mathematics: arithmetic and elementary algebra.The exponential-family form
Here is the natural parameter, the sufficient statistic, and the log-partition (normalizer).
| Family | |||
|---|---|---|---|
| Bernoulli() | (logit) | ||
| Poisson() | |||
| Normal(, known ) | |||
| Normal() | … | ||
| Exponential, Gamma, Beta, Dirichlet, Categorical | all exponential families |
Conjugate pairs
| Likelihood | Conjugate prior | Posterior after data |
|---|---|---|
| Bernoulli/Binomial | Beta() | Beta() |
| Categorical/Multinomial | Dirichlet() | Dirichlet() (A4.2-3) |
| Poisson | Gamma() | Gamma() |
| Normal (known ) | Normal() | precisions add, mean precision-weighted |
| Normal covariance | inverse-Wishart | (A4.2-3) |
- 1. Bernoulli's natural parameter is…
- 2. The conjugate prior for a Poisson rate is…
- 3. Beta(2, 2) prior + 7 successes, 3 failures → ?
Level 2: Intermediate
★★★☆☆ Intermediate⏱ 45 minUndergraduate students and practising engineers.The log-partition generates moments
- For the Bernoulli: and .
- For the Poisson: .
Maximum likelihood = moment matching
The log-likelihood of i.i.d. data is . It’s concave, because is convex, and its maximizer solves
So set the model’s expected sufficient statistic equal to the data’s average. That’s why the Gaussian MLE uses the sample mean and covariance, and why logistic regression’s gradient is (A3.3-4).
Why conjugate priors exist
For a likelihood , take a prior of the same shape: . The posterior is , still in the family. The prior acts as pseudo-observations with total statistic (Diaconis and Ylvisaker, 1979).
- 1. A′(η) equals…
- 2. The exponential-family log-likelihood in η is…
- 3. The exponential-family MLE sets the model mean of T equal to…
Level 3: Advanced
★★★★☆ Advanced⏱ 40 minGraduate level, with full derivations and proofs.Proofs
. Differentiate : , so . Differentiating again gives . ∎
Sufficiency (Fisher–Neyman factorization). is sufficient iff . For exponential families, , so is sufficient. Two datasets with the same give identical likelihood functions, and so identical inferences (Exercise 1). ∎
Pitman–Koopman–Darmois. Among families with fixed support, only exponential families have sufficient statistics of fixed dimension for any sample size. That’s why they dominate practical modelling.
Predictive distributions
Integrating the parameter out gives the posterior predictive:
- Beta–Bernoulli: .
- Gamma–Poisson: a negative binomial, with variance . That’s bigger than the mean, because parameter uncertainty fattens predictions. It’s the standard model for overdispersed counts (A4.2-1; Practice Code 5).
Exercise 3.1: Show that the normal–normal posterior has precision 1/v₀ + n/σ²
Prior and likelihood . The exponent’s coefficient is . Completing the square gives a Gaussian with that precision and mean .
- 1. Fisher–Neyman says T is sufficient iff the likelihood…
- 2. The Gamma–Poisson posterior predictive is…
- 3. Fixed-dimensional sufficient statistics essentially characterize…
Level 4: Expert
★★★★★ Expert⏱ 45 minResearchers: original papers and open problems.Thompson sampling
To choose among options with unknown success rates (grasp strategies, controller gains, ad layouts), keep a conjugate Beta posterior per option. Sample one rate from each posterior and try the option whose sample is highest (Thompson, 1933). Options you’re unsure about sometimes produce high samples, so they get explored. Options that are clearly worse stop being chosen.
- Updating costs one addition.
- Regret grows only logarithmically (Agrawal and Goyal, 2012).
- In practice it often beats more complex methods (Chapelle and Li, 2011; Russo et al., 2018).
- Pure greedy choice can lock onto a worse option forever.
Exponential families everywhere
- Generalized linear models. The canonical link (logit for Bernoulli, log for Poisson) makes , which gives concave likelihoods and simple gradients (McCullagh and Nelder, 1989; A3.3-4).
- Variational inference and message passing use expected sufficient statistics. Mean-field updates in conjugate-exponential models are closed form (Winn and Bishop, 2005), and so is Kalman smoothing.
- Energy-based models and maximum entropy. The max-entropy distribution with given expected statistics is exactly the exponential family with those (Jaynes, 1957). It underlies maximum-entropy inverse RL for learning from demonstrations (Ziebart et al., 2008).
- Reliability with few tests. Gamma–Poisson and Beta–binomial updating combine prior engineering knowledge with sparse test data, for example estimating failure rates from a handful of qualification tests.
References
- L. Brown (1986). Fundamentals of Statistical Exponential Families. IMS.
- P. Diaconis, D. Ylvisaker (1979). “Conjugate priors for exponential families.” Annals of Statistics, 7(2).
- W. Thompson (1933). “On the likelihood that one unknown probability exceeds another in view of the evidence of two samples.” Biometrika, 25.
- S. Agrawal, N. Goyal (2012). “Analysis of Thompson sampling for the multi-armed bandit problem.” COLT.
- O. Chapelle, L. Li (2011). “An empirical evaluation of Thompson sampling.” NeurIPS.
- D. Russo, B. Van Roy, A. Kazerouni, I. Osband, Z. Wen (2018). “A tutorial on Thompson sampling.” Foundations and Trends in ML, 11(1).
- P. McCullagh, J. Nelder (1989). Generalized Linear Models, 2nd ed. Chapman & Hall.
- J. Winn, C. Bishop (2005). “Variational message passing.” JMLR, 6.
- E. T. Jaynes (1957). “Information theory and statistical mechanics.” Physical Review, 106(4).
- B. Ziebart, A. Maas, J. A. Bagnell, A. Dey (2008). “Maximum entropy inverse reinforcement learning.” AAAI.