Can Q-learning be Improved with Advice?

Noah Golowich, Ankur Moitra

Abstract

Traditional Reinforcement Learning (RL) theory focuses on minimax regret bounds, which characterize performance in the worst possible environments. However, in many practical applications, agents have access to prior knowledge or "advice"—such as physics simulators or historical data—that can guide exploration. This paper, presented at COLT 2022, introduces a framework for learning-augmented RL. The authors propose the QLearningPreds algorithm, which incorporates predictions of optimal Q-values. They prove that if the advice is accurate (a condition termed "distillation"), the regret scales with the size of the "fooling set" (where the advice is wrong) rather than the entire state-action space. Crucially, the algorithm remains robust, maintaining sublinear regret even if the advice is adversarial.

Introduction

In the field of Reinforcement Learning, theoretical analysis has long been dominated by the worst-case perspective. Minimax lower bounds for regret in Markov Decision Processes (MDPs) establish the minimum amount of data required to perform well in any environment. While mathematically rigorous, this approach often ignores the reality of modern AI development: practitioners rarely start from scratch. Whether through "sim-to-real" transfers in robotics or utilizing clinical trial data in healthcare, agents often have access to external predictions about the optimal policy.

Noah Golowich and Ankur Moitra address a critical gap in this paradigm: How can an RL algorithm leverage these predictions to surpass minimax limits when the advice is good, without sacrificing safety when the advice is flawed? Their work moves beyond worst-case design to provide a "best-of-both-worlds" guarantee for tabular Q-learning.

The Learning-Augmented Framework

The authors introduce a model where an agent is provided with a set of predicted Q-values, $\tilde{Q}$. The goal is to design an algorithm that satisfies two properties:

  1. Consistency: If the advice is helpful, the regret should be significantly lower than the standard minimax bound.
  2. Robustness: If the advice is arbitrary or even malicious, the algorithm must still achieve sublinear regret, ensuring it eventually learns the optimal policy regardless of the initial hint.

Distillation and the Fooling Set

To quantify "good advice," the paper defines a condition called distillation. A prediction is considered a distillation if, for every state, there is at least one near-optimal action that the prediction does not significantly underestimate. This ensures the advice "points" toward a high-reward path, even if it is inaccurate in other regions of the state-action space.

The complexity of the learning task then becomes a function of the fooling set ($F$). This set comprises the state-action pairs where the advice is grossly inaccurate—either by overestimating a suboptimal action or deviating significantly from the true optimal value. The central thesis is that an agent should only have to "pay" for the parts of the environment where the advice fails.

The QLearningPreds Algorithm

The proposed algorithm, QLearningPreds, modifies episodic Q-learning by integrating a two-phase strategy at the state level:

  1. Exploration Phase: The agent utilizes a standard Upper Confidence Bound (UCB) approach to build confidence intervals for rewards and transitions.
  2. Constrained Exploitation Phase: Once the agent reaches a specific confidence threshold for a state, it switches to using the advice $\tilde{Q}$. However, it does so cautiously, only trusting the advice within the bounds of its learned confidence intervals.

This state-specific switching is a key innovation. Unlike simpler problems where an agent might choose to trust advice globally, QLearningPreds can decide to trust a simulator for one task (e.g., walking) while ignoring it for another (e.g., navigating obstacles) based on empirical evidence.

Theoretical Results

The paper provides rigorous mathematical proofs for the performance of QLearningPreds in tabular, finite-horizon episodic MDPs:

  • Consistency (Good Advice): When the advice is an $\epsilon$-approximate distillation, the regret is bounded by approximately $\tilde{O}(\sqrt{|F| \cdot T H^5})$. This is a major improvement over the standard $\tilde{O}(\sqrt{SAT H^2})$ bound whenever the fooling set $|F|$ is smaller than the total state-action space $|SA|$.
  • Robustness (Bad Advice): For any arbitrary advice, the regret is guaranteed to be at most $\tilde{O}(\sqrt{TSAH^{10}/\lambda})$, where $\lambda$ is a user-defined trade-off parameter. This ensures the agent never suffers catastrophic failure due to poor predictions.
  • Gap-based Improvements: In environments with large gaps between optimal and sub-optimal actions, the algorithm can achieve logarithmic regret in $T$, further demonstrating the power of well-integrated advice.

Discussion and Future Directions

This research demonstrates that it is possible to break through theoretical RL barriers by incorporating external knowledge. The most striking insight is the localization of regret: the agent's performance is tied to the errors in the advice, not the total complexity of the environment.

However, several challenges remain. The current results are limited to the tabular setting, where states and actions are discrete. Extending these proofs to continuous state spaces or function approximation (Deep RL) is a necessary next step for practical deployment. Additionally, the trade-off parameter $\lambda$ currently requires manual tuning; future work may focus on adaptively setting this parameter across multiple episodes to optimize the balance between consistency and robustness automatically.

Summary updated

BibTeX
@inproceedings{golowich2022can,
  author = {Noah Golowich and Ankur Moitra},
  title = {{Can Q-learning be Improved with Advice?}},
  booktitle = {Conference on Learning Theory},
  year = {2022},
  url = {https://openreview.net/forum?id=GXyuBxWzMp2},
}
Figure