Preferential Temporal Difference Learning

Nishanth Anand, Doina Precup

Abstract

Temporal-Difference (TD) learning is a general and very useful tool for estimating the value function of a given policy, which in turn is required to find good policies. Generally speaking, TD learning updates states whenever they are visited. When the agent lands in a state, its value can be used to compute the TD-error, which is then propagated to other states. However, it may be interesting, when computing updates, to take into account other information than whether a state is visited or not. For example, some states might be more important than others (such as states which are frequently seen in a successful trajectory). Or, some states might have unreliable value estimates (for example, due to partial observability or lack of data), making their values less desirable as targets. We propose an approach to re-weighting states used in TD updates, both when they are the input and when they provide the target for the update. We prove that our approach converges with linear function approximation and illustrate its desirable empirical behaviour compared to other TD-style methods.

Introduction

In standard Reinforcement Learning (RL), Temporal Difference (TD) learning updates the value estimate of every state an agent visits. However, not all states are created equal. In many real-world scenarios—or when using function approximation—some states are "aliased" (look the same but lead to different outcomes) or "noisy" due to partial observability.

Updating these unreliable states can "poison" the value estimates of reliable, fully observable states through a process called bootstrapping. Standard methods like TD($\lambda$) try to mitigate this using eligibility traces, but they still treat all states as valid update targets. This paper addresses two main challenges: efficient temporal credit assignment and preventing error propagation from poorly generalized states to the rest of the value function.

Preferential Temporal Difference Learning

The authors introduce Preferential Temporal Difference (PTD) learning. The core innovation is a state-dependent preference function, $\beta(s) \in [0, 1]$, which enables two key mechanisms:

  • Selective Updating: If $\beta(s)$ is low, the algorithm performs a smaller update (or none at all) for that state, focusing the "learning budget" on informative states.
  • Modified Bootstrapping: Crucially, PTD doesn't just stop updating a state; it also stops using that state as a bootstrapping target for previous states. Instead, it "skips" the low-preference state and looks further ahead in the trajectory to find a more reliable state to bootstrap from.

This dual role of $\beta(s)$—modulating both the update and the target—is what allows the authors to prove convergence with linear function approximation, a feat that is notoriously difficult for algorithms that use state-dependent bootstrapping.

Experimental Evaluation

The algorithm was evaluated on several benchmarks, including a 19-state Random Walk and custom "Delayed Effect MDPs" (corridor tasks). In these corridor tasks, an agent passes through a sequence of identical-looking states before reaching a goal, testing the algorithm's ability to handle aliasing.

Delayed Effect MDP tasks (Task 1 and Task 2) used to evaluate handling of aliased states in corridors.

Key Results and Discussion

PTD demonstrates significant advantages in stability and efficiency. Unlike TD($\lambda$), which is highly sensitive to the learning rate ($\alpha$) and often exhibits sharp "U-curves" where slight parameter changes lead to massive error, PTD remains stable across a wide range of learning rates.

Comparison of Mean RMSE over 10 episodes for Emphatic TD, Preferential TD, and TD(λ) across various learning rates.

In corridor tasks, PTD maintained low error regardless of length by "preferring" fully observable states at the ends. In non-linear grid tasks with limited neural network capacity, PTD outperformed other methods by prioritizing critical information. Furthermore, in control tasks like Cartpole, PTD achieved performance on par with standard TD while only updating and bootstrapping from roughly 5% of the states visited.

Conclusion and Future Work

PTD provides a stable middle ground between TD($\lambda$) and Emphatic TD (ETD) by using state-dependent weights rather than trajectory-dependent ones. Future work includes automatically learning the preference function $\beta(s)$ from data, extending the framework to off-policy learning, and developing formal convergence proofs for non-linear function approximation.

Summary updated

BibTeX
@inproceedings{anand2021preferential,
  author = {Nishanth Anand and Doina Precup},
  title = {{Preferential Temporal Difference Learning}},
  booktitle = {International Conference on Machine Learning},
  year = {2021},
  url = {https://openreview.net/forum?id=bheU-KAfED},
}
Figure