sequential decision making
Online Learning and Regret Minimization
You should know: stochastic optimization, game theory introduction
Overview
Online learning studies sequential decision-making: at each round t, an algorithm chooses x_t from a convex set X, then observes a loss function f_t and incurs loss f_t(x_t). The goal is to minimize regret -- the difference between total loss and the best fixed decision in hindsight: R_T = sum_{t=1}^T f_t(x_t) - min_{x in X} sum_{t=1}^T f_t(x). Key algorithms include Online Gradient Descent (OGD) and Follow The Regularized Leader (FTRL). The regret bounds O(sqrt(T)) are minimax optimal for adversarial (worst-case) sequences. Online learning connects to game theory (no-regret learning -> Nash equilibria), statistics (PAC learning), and stochastic optimization.
Intuition
Imagine investing in stocks. Each day you allocate your portfolio (x_t = weights), then see the day's returns (f_t). Regret measures how much worse your strategy is compared to the best fixed allocation in hindsight. A no-regret algorithm guarantees R_T/T -> 0 as T -> inf: your average loss approaches the best average in hindsight. This is achievable even against an adversary choosing f_t adversarially -- but only by making online decisions without knowing future f_t. The key insight: the minimax optimal regret is Theta(sqrt(T)) for general convex losses.
Formal Definition
Online convex optimization protocol: (1) Learner picks x_t in X (convex compact). (2) Adversary reveals f_t: X -> R (convex). (3) Learner incurs loss f_t(x_t). Regret: R_T = sum_{t=1}^T f_t(x_t) - min_{x in X} sum_{t=1}^T f_t(x). An algorithm is no-regret if R_T = o(T) (R_T/T -> 0). Online Gradient Descent (OGD): x_{t+1} = Pi_X(x_t - eta_t * nabla f_t(x_t)) where Pi_X is the projection onto X. FTRL: x_{t+1} = argmin_{x in X} {sum_{s=1}^t f_s(x) + (1/eta) R(x)} where R is a strongly convex regularizer.
Notation
| Notation | Meaning |
|---|---|
| Regret at time T | |
| Projection onto feasible set X | |
| Diameter of feasible set X | |
| Bound on gradient norms: ||nabla f_t(x)|| <= G |
Theorems
Worked Examples
- 1
t=1: x_1 = 0. Observe f_1(x) = x. Gradient: nabla f_1(x_1) = 1. Update: x_2 = Pi_{[-1,1]}(0 - (1/2)*1) = Pi_{[-1,1]}(-1/2) = -1/2.
- 2
t=2: x_2 = -1/2. Observe f_2(x) = -x. Gradient: nabla f_2(x_2) = -1. Update: x_3 = Pi_{[-1,1]}(-1/2 - (1/2)*(-1)) = Pi_{[-1,1]}(0) = 0.
- 3
Losses: f_1(x_1) + f_2(x_2) = 0 + (1/2) = 1/2.
- 4
Best fixed: min_{x in [-1,1]} {f_1(x)+f_2(x)} = min_{x in [-1,1]} {x + (-x)} = min 0 = 0. Regret = 1/2 - 0 = 1/2.
✓ Answer
After 2 rounds, total loss = 1/2, best fixed loss = 0. Regret = 1/2. Note: OGD oscillates between -1/2 and 0, tracking the adversarial sequence.
Practice Problems
Explain why the minimax optimal regret for online convex optimization with general convex losses is Theta(sqrt(T)).
Common Mistakes
Thinking online learning is the same as stochastic optimization.
Stochastic optimization assumes i.i.d. loss functions (f_t ~ distribution P) and uses the statistical structure to accelerate convergence. Online learning makes no distributional assumption -- it works against an adversary who can choose f_t based on the learner's history. Online learning results are worst-case (minimax) while stochastic optimization results exploit distributional structure. SGD is both: viewed online, it's a no-regret algorithm; viewed statistically, it minimizes expected loss.
Quiz
Historical Background
Hannan's regret-minimizing algorithm (1957) predates the modern framework. Cesa-Bianchi and Lugosi's book (2006) formalized the field. Online gradient descent was analyzed by Zinkevich (2003). The reduction from online learning to game theory (no-regret dynamics -> Nash equilibria) was developed by Freund-Schapire (1996) and Hart-Mas-Colell (2000). Hazan's 2016 lecture notes and Shalev-Shwartz's 2012 survey are standard references.
- 1957
Hannan proves the first regret bound for sequential decision-making
James Hannan
- 1996
Freund-Schapire AdaBoost and multiplicative weights for online learning
Yoav Freund, Robert Schapire
- 2003
Zinkevich proves O(sqrt(T)) regret for Online Gradient Descent
Martin Zinkevich
- 2006
Cesa-Bianchi and Lugosi -- Prediction, Learning, and Games textbook
Nicolo Cesa-Bianchi, Gabor Lugosi
Summary
- Online learning: sequential decisions x_t, then f_t revealed. Regret R_T = total loss - best fixed in hindsight.
- OGD: x_{t+1} = Pi_X(x_t - eta * grad f_t(x_t)). Regret = O(sqrt(T)) for convex losses.
- Strongly convex losses: OGD achieves O(log T) regret (much faster).
- No-regret dynamics in games: time-averaged strategies converge to Nash equilibria.
References
- BookCesa-Bianchi, N. and Lugosi, G. Prediction, Learning, and Games. Cambridge, 2006.
- BookHazan, E. Introduction to Online Convex Optimization. MIT Press, 2022.
Mathematics