Long-Term Exploration in Persistent MDPs

Leonid Ugadiarov, Alexey Skrynnik, Aleksandr I. Panov · DOI

TL;DR

This paper introduces RbExplore, a novel long-term exploration algorithm for reinforcement learning agents in environments with sparse rewards and large state spaces. By formalizing resettable environments as "persistent MDPs" and employing state-space clustering, RbExplore enables agents to efficiently revisit and explore previously encountered states, outperforming existing curiosity-driven methods on the challenging Prince of Persia game.

What Problem Does This Paper Address?

Reinforcement learning (RL) agents often struggle in environments with sparse rewards and vast state spaces. In such scenarios, exploration – the process of discovering new states and their associated rewards – becomes a critical bottleneck. Traditional exploration methods can be inefficient, wasting computational resources on irrelevant areas or failing to revisit crucial states, especially in "hard-exploration" tasks. This is particularly problematic in environments where agents cannot easily reset to previous states, a common limitation in real-world robotics or complex simulations. The paper aims to address this by developing a method that facilitates more systematic and long-term exploration, even in the absence of explicit rewards or domain-specific knowledge.

Methods

The core of the proposed solution is the RbExplore algorithm, which introduces two key innovations:

  • Persistent Markov Decision Processes (pMDPs): The authors formalize resettable environments as pMDPs. This concept allows agents to "roll back" to previously visited states, a crucial capability for long-term exploration. This is distinct from standard MDPs where an episode typically ends and a new one begins from an initial state.
  • State Space Clustering with a Graph Representation: RbExplore builds a clustered representation of visited states. A similarity model (a neural network trained with binary cross-entropy) is used to determine how similar two states are, based on their proximity within trajectories. These clusters are then organized into a directed graph of clusters. This graph allows the agent to navigate and prioritize exploration based on cluster visit statistics, effectively creating a memory of explored regions.
  • Novelty Detection: A Random Network Distillation (RND) module is employed to identify novel states, which are then used to generate additional training data for the similarity model, further improving its accuracy.
  • Rollback-Explore (RbExplore) Algorithm: The algorithm iteratively generates exploration trajectories by sampling clusters from the graph, rolling back to those states, and running an exploration policy. New states encountered are used to update the similarity model and the cluster graph.

Datasets

The primary environment used for evaluation is the Prince of Persia game. This is presented as a challenging benchmark for hard-exploration tasks due to its large state space, sparse rewards, and complex level design. The authors specifically test RbExplore on the first three levels of the game. No new datasets were introduced; instead, the focus was on evaluating the algorithm's performance in a demanding existing environment.

Key Insights and Ideas

  • The power of revisiting states: The paper highlights that enabling agents to systematically revisit and explore previously encountered states (via pMDPs and cluster graphs) is crucial for long-term exploration in complex environments.
  • Clustering as a memory mechanism: Organizing visited states into clusters and representing them as a graph provides a structured way for agents to remember and navigate the state space, overcoming the intractability of storing every visited state.
  • Leveraging similarity for exploration: Using a learned similarity model to group states allows the agent to generalize exploration efforts and understand which regions of the state space are "close" or "distant."
  • Domain-agnostic exploration: RbExplore's approach, particularly its reliance on learned similarity and novelty detection rather than hand-crafted features, makes it applicable to a wider range of environments without requiring domain-specific knowledge.

Key Results

On the challenging Prince of Persia game, RbExplore demonstrated strong performance:

  • Level 1: RbExplore significantly outperformed state-of-the-art curiosity methods like ICM and RND, visiting all possible rooms.
  • Levels 2 & 3: While RND and ICM showed slightly better performance on Level 2 due to their focus on local exploration, RbExplore achieved comparable results to RND on Level 3 and significantly outperformed ICM.
  • Ablation Studies: Disabling key components of RbExplore (cluster merging or full trajectory prefix for negative examples) led to a noticeable decrease in performance, underscoring the importance of each element.

Limitations and Future Work

  • Limitations: The paper acknowledges that on levels 2 and 3 of Prince of Persia, none of the algorithms were able to visit all rooms within the given steps. The authors note that RND and ICM sometimes perform better on these levels due to their focus on local exploration. The agent's observation in Prince of Persia doesn't always indicate if it's carrying a sword, which is a specific environmental challenge addressed by starting the agent with a sword on level 1.
  • Future Work: The authors suggest that combining RbExplore's exploration capabilities with exploitation strategies that also utilize pMDPs is a promising direction for future research. This could lead to more complete RL solutions that can effectively learn policies in complex, long-horizon tasks.

Summary updated

BibTeX
@inproceedings{ugadiarov2021long,
  author = {Leonid Ugadiarov and Alexey Skrynnik and Aleksandr I. Panov},
  title = {{Long-Term Exploration in Persistent MDPs}},
  booktitle = {MICAI},
  year = {2021},
  doi = {10.1007/978-3-030-89817-5\_8},
}
Figure