Provably Efficient RL with Features
Linear MDPs, LSVI-UCB and the lower bounds that limit function approximation.
Give an agent features of each state–action pair. How many episodes does it need to learn a near-optimal policy, with no dependence on the number of states? It depends sharply on what the features are assumed to capture. If the dynamics are linear in them, optimism plus least squares gives regret polynomial in and the horizon. If only the optimal values are linear, every algorithm can need exponentially many samples, even with a simulator. This lesson develops both sides, and the complexity measures that try to say exactly when RL with function approximation is tractable.
What you’ll learn
- Define linear and linear-mixture MDPs, and prove that in a linear MDP every policy's Q-function is linear and the linear class is Bellman complete.
- State LSVI-UCB and its regret bound, and sketch the proof: optimism from self-normalized concentration plus the elliptical potential lemma.
- State the exponential lower bounds for approximately and exactly realizable value functions, online, with a generative model and offline, with their conditions.
- Place Bellman rank, the Bellman–Eluder dimension and the decision–estimation coefficient on a map of tractable settings.
Linear MDPs
Throughout, the setting is episodic with horizon and possibly step-dependent dynamics and rewards ; the agent plays episodes, steps in all, and its regret is . A feature map is known.
For any function on states, the expected next value is linear in the features, with a weight vector that depends on :
Hence for every policy, is linear, and so is . More: the Bellman backup of any function lands in the linear class, which is Bellman completeness, the property that makes least-squares value iteration consistent.
A different structure, the linear mixture MDP (Ayoub et al., 2020), assumes for known base models and unknown weights . It is model-based, and estimates by value-targeted regression: regress the observed next value on the features . Their UCRL-VTR has regret , and Zhou, Gu & Szepesvári (2021) reached with a matching lower bound. With a generative model and discounting, Yang & Wang (2019) learn an -optimal policy from samples under a related linear transition assumption (with "anchor" state–action pairs), matching their lower bound up to logarithmic factors.
LSVI-UCB: optimism with least squares
LSVI-UCB (Jin, Yang, Wang & Jordan, 2020), regularizer λ = 1, bonus scale β
for episode k = 1, ..., K:
Q[H+1] ← 0
for h = H down to 1: # least-squares value iteration
Λ ← λI + Σ_{τ<k} φ(s_h^τ, a_h^τ) φ(s_h^τ, a_h^τ)ᵀ
w ← Λ⁻¹ Σ_{τ<k} φ(s_h^τ, a_h^τ) · ( r_h^τ + max_a Q[h+1](s_{h+1}^τ, a) )
Q[h](s, a) ← min( wᵀφ(s, a) + β · sqrt(φ(s, a)ᵀ Λ⁻¹ φ(s, a)), H )
for h = 1, ..., H:
play a_h = argmax_a Q[h](s_h, a); observe r_h and s_{h+1}The bonus is large in directions of feature space the data have not covered, exactly as in LinUCB (Linear Bandits: LinUCB & OFUL). The values are computed only where needed, at visited next states, so the cost is polynomial in , and , independent of .
Concentration. At step , is a ridge regression of targets whose mean is , linear in by completeness. A self-normalized martingale bound, combined with a union bound over a covering of the possible functions (which depend on the same data), gives for all with high probability
Optimism. Backward induction from then gives at every step, so the greedy policy's planned value overestimates . Regret decomposition. The overestimate is paid for by the bonuses actually collected along the episode, plus a martingale term of order :
Elliptical potential. Each new feature vector is added to , so the bonuses shrink in the directions explored. For and , Cauchy–Schwarz and the determinant argument of linear bandits give
Multiply: steps, bonus scale , potential . The extra in (a linear bandit needs only ) is the price of the union bound over value functions, whose class has dimension about through the matrix .
By what factor does LSVI-UCB's regret bound grow when the feature dimension doubles and everything else stays fixed?
Show the answer
2.83
. The nearly minimax bound would grow by only 2. Doubling the number of states changes neither bound, which is the point of the linear structure.
Completeness can be relaxed. Zanette, Lazaric, Kochenderfer & Brunskill (2020) assume only a small inherent Bellman error (the linear class is closed under backups up to an error IBE) and obtain regret with step-dependent dimensions , a sharper dependence on the dimension than LSVI-UCB's that matches their lower bound; their algorithm is not known to be computationally efficient.
When good features are not enough: lower bounds
Linear MDPs assume a lot: the dynamics themselves are linear. The weakest natural assumption is realizability, that (or every ) is linear, perhaps up to an error . A run of lower bounds shows that realizability alone does not buy sample efficiency.
| Result | Assumption and access | Lower bound |
|---|---|---|
| Du, Kakade, Wang & Yang (2020) | for every policy; 2 actions; even known transitions | trajectories for a -optimal policy: exponential once |
| Weisz, Amortila & Szepesvári (2021) | exactly linear; generative model (local planning); an action set exponentially large in | queries; in the discounted setting |
| Wang, Wang & Kakade (2021) | exactly linear plus a constant suboptimality gap; online | : exponential in |
| Wang, Foster & Kakade (2021) | Offline evaluation; every exactly linear; data with well-conditioned feature covariance | Exponential in |
| Foster, Krishnamurthy, Simchi-Levi & Xu (2022) | Offline; realizability plus concentrability | Polynomial in : no bound in terms of alone |
What separates the upper bounds from these lower bounds is not dimension but closure. In a linear MDP, the backup of any estimate stays in the class, so regression targets are always realizable; under realizability of alone, the intermediate targets of value iteration can fall outside the class, and errors compound without control. The same distinction between realizability and completeness reappears in batch RL (Fitted Q-Iteration & Its Guarantees).
LSVI-UCB enjoys polynomial regret in linear MDPs, while Weisz, Amortila & Szepesvári prove an exponential lower bound when is exactly linear, even with a simulator. What does the linear MDP assume that exact realizability of does not?
- A smaller feature dimension
- Deterministic transitions
- That the Bellman backup of every function is linear in the features (completeness), because the transitions themselves are linear
- A positive suboptimality gap
Show the answer
C. That the Bellman backup of every function is linear in the features (completeness), because the transitions themselves are linear
With linear transitions, is linear for every , so every regression target in least-squares value iteration is realizable. Realizability of says nothing about the targets built from the algorithm's current, imperfect estimates, and the lower-bound constructions exploit exactly that gap.
Structural conditions: when is RL with function approximation tractable?
The search for the right general condition produced a sequence of complexity measures, each containing the previous tractable cases.
- Bellman rank (Jiang, Krishnamurthy, Agarwal, Langford & Schapire, 2017). For candidate value functions , form the average Bellman error of on the state distribution of 's greedy policy at step . If this matrix, indexed by , has rank , the OLIVE algorithm learns a near-optimal policy with a number of samples polynomial in , , , and , independent of the number of observations. OLIVE eliminates hypotheses and is not computationally efficient in general.
- Eluder dimension (Russo & Van Roy, 2013): how long a sequence of inputs can keep surprising a function class, the quantity behind optimistic exploration with general classes.
- Bellman–Eluder dimension (Jin, Liu & Miryoosefi, 2021): an eluder dimension of the Bellman errors, which subsumes tabular and linear MDPs, reactive POMDPs, low Bellman rank and low eluder dimension. Under realizability and completeness, their GOLF algorithm has regret with logarithmic in the covering number of the function classes.
- Bilinear classes (Du et al., 2021) organize many of these examples by one algebraic condition on Bellman errors.
- The decision–estimation coefficient (Foster, Kakade, Qian & Rakhlin, 2021) measures, for a class of models, the best trade-off between the regret of a decision and the information it reveals; they prove a lower bound on regret in terms of it for any algorithm, and an upper bound for their Estimation-to-Decisions method that matches it up to the cost of estimation.
These theories assume the features, or the function class, are given. In a low-rank MDP only the existence of a -dimensional factorization is assumed, with and in known classes and . FLAMBE (Agarwal, Kakade, Krishnamurthy & Sun, 2020) learns such features while exploring, with sample complexity polynomial in , , and and logarithmic in , given a maximum-likelihood oracle over both classes: representation learning with a guarantee (Representation Learning for RL).
Key takeaways
- In a linear MDP, is linear for every , so every is linear and the linear class is Bellman complete.
- LSVI-UCB adds the bonus to least-squares value iteration and has regret , independent of ; is nearly minimax.
- Realizability alone is not enough: approximately linear with , exactly linear with a simulator (and many actions), and offline evaluation with every linear all have exponential lower bounds.
- The divide is closure under the Bellman operator (completeness); Bellman rank, the Bellman–Eluder dimension and the DEC generalize the tractable cases, mostly without efficient algorithms.
Check yourself
In the interactive lesson these are scored with your confidence, and what you miss comes back for review.
Why is linear in for every policy in a linear MDP?
- Because the optimal policy is linear
- Because is linear for any function , so is linear
- Because the rewards are bounded
- Because the features are one-hot
Show the answer
B. Because is linear for any function , so is linear
Linearity of the transitions passes to the expectation of any next-state function. That gives realizability of every and of and, more importantly for algorithms, closure of the linear class under Bellman backups.
Write LSVI-UCB's regret in terms of the number of episodes , with .
Show the answer
C.
. Papers state bounds in either or , and the horizon exponent shifts by one inside the square root when converting; the later bound equals .
Which statement matches the lower bound of Weisz, Amortila & Szepesvári (2021)?
- Even if is exactly linear in known features and the planner has a generative model, it can need queries
- If is only approximately linear, planning needs exponentially many queries, but exact linearity makes it easy
- Linear MDPs require exponentially many samples
- The lower bound disappears with a constant suboptimality gap
Show the answer
A. Even if is exactly linear in known features and the planner has a generative model, it can need queries
Their construction has exact realizability of and simulator access, the most favorable setting short of linear dynamics, and still forces exponentially many queries. Du et al.'s earlier bound needed approximation error ; this one needs none.
Further reading
- C. Jin, Z. Yang, Z. Wang & M. I. Jordan, "Provably efficient reinforcement learning with linear function approximation", COLT (2020).
- S. S. Du, S. M. Kakade, R. Wang & L. F. Yang, "Is a good representation sufficient for sample efficient reinforcement learning?", ICLR (2020).
- G. Weisz, P. Amortila & C. Szepesvári, "Exponential lower bounds for planning in MDPs with linearly-realizable optimal action-value functions", ALT (2021).
- C. Jin, Q. Liu & S. Miryoosefi, "Bellman eluder dimension: New rich classes of RL problems, and sample-efficient algorithms", NeurIPS (2021).
- A. Agarwal, N. Jiang, S. M. Kakade & W. Sun, Reinforcement Learning: Theory and Algorithms (monograph draft, 2019–2022).