NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Sample Complexity of Kernel-Based Q-Learning

Sing-Yuan Yeh, Fu-Chieh Chang, Chang-Wei Yueh, Pei-Yuan Wu, Alberto Bernacchia, Sattar Vakili

Abstract

Modern Reinforcement Learning (RL) often struggles with enormous or infinite state-action spaces, necessitating non-linear function approximation. This paper introduces KQLearn, a novel kernel-based Q-learning algorithm, and provides the first finite, order-optimal sample complexity bounds for learning an $\epsilon$-optimal policy in discounted Markov Decision Processes (MDPs) using general kernel models. By leveraging the properties of Reproducing Kernel Hilbert Spaces (RKHS), KQLearn effectively reduces infinite-dimensional problems into manageable sampling tasks, achieving sample complexity that scales optimally with respect to error tolerance.

Introduction

In Reinforcement Learning, an agent's ability to find a near-optimal policy is measured by its sample complexity—the number of interactions required with the environment. While sample complexity is well-understood for "tabular" MDPs (small, discrete environments) and "linear" MDPs (where dynamics are linear combinations of features), these models often fail to capture the complexity of real-world tasks like robotics.

To handle continuous and highly complex spaces, researchers employ non-linear function approximation, such as kernel ridge regression. However, establishing rigorous sample complexity bounds in infinite-dimensional, non-parametric kernel spaces is mathematically challenging. Prior work often lacked finite guarantees for difficult kernels or was restricted to episodic settings. KQLearn addresses this gap by providing a finite sample complexity bound for discounted MDPs using a generative model under general kernel-based assumptions.

Methodology: The KQLearn Algorithm

KQLearn operates by strategically navigating virtually infinite state-action spaces through two primary phases:

  1. Maximum Uncertainty Sampling: Operating within an RKHS, the algorithm calculates uncertainty (surrogate posterior variance) across the state-action space. It greedily constructs a finite set of informative state-action pairs by targeting points where the model's uncertainty is highest.
  2. Approximate Bellman Updates: The algorithm queries a generative model at these specific points. It then uses kernel ridge regression to approximate the Bellman operator, allowing the value function updates to generalize from the finite sample set to the entire infinite state-action space.

Key Results and Comparison

The primary contribution of this work is the derivation of the first finite sample complexity bounds for finding an $\epsilon$-optimal policy across various kernel models. The complexity is fundamentally dictated by the eigendecay of the kernel—the rate at which the eigenvalues of the kernel operator shrink—which serves as a proxy for the environment's "smoothness."

Comparison of sample complexity bounds for various RL algorithms across different MDP settings and function approximations.

As shown in the table above, KQLearn achieves the following bounds:

  • Exponential Eigendecay (e.g., Squared Exponential kernels): $\tilde{\mathcal{O}}\left(\frac{1}{\epsilon^2 (1-\gamma)^7}\right)$.
  • Polynomial Eigendecay (e.g., Matérn kernels): $\tilde{\mathcal{O}}\left(\frac{1}{\epsilon^{\frac{2\beta_p}{\beta_p-1}}} \frac{1}{(1-\gamma)^{\frac{7\beta_p-1}{\beta_p-1}}}\right)$, where $\beta_p > 1$.

Notably, KQLearn's scaling with respect to the error tolerance $\epsilon$ is order-optimal, matching theoretical lower bounds from simpler kernel bandit problems. This demonstrates that KQLearn is highly efficient in its use of samples relative to the required precision.

Discussion and Future Work

While KQLearn provides optimal scaling for $\epsilon$, its dependency on the discount factor $\gamma$ (scaling with $\frac{1}{(1-\gamma)^7}$ for smooth kernels) is currently suboptimal compared to tabular or linear settings, where variance-reduction techniques have achieved $\frac{1}{(1-\gamma)^3}$.

The extension of variance-reduction methods to non-parametric kernel settings remains a significant theoretical challenge. Future research aims to bridge this gap, potentially improving the efficiency of kernel-based RL in environments with long horizons (high $\gamma$).

Summary updated

BibTeX
@inproceedings{yeh2023sample,
  author = {Sing-Yuan Yeh and Fu-Chieh Chang and Chang-Wei Yueh and Pei-Yuan Wu and Alberto Bernacchia and Sattar Vakili},
  title = {{Sample Complexity of Kernel-Based Q-Learning}},
  booktitle = {International Conference on Artificial Intelligence and Statistics},
  year = {2023},
}
Figure