Multi-intention Inverse Q-learning for Interpretable Behavior Representation

Hao Zhu, Brice De La Crompe, Gabriel Kalweit, Artur Schneider, Maria Kalweit, Ilka Diester, Joschka Boedecker

Abstract

In advancing the understanding of natural decision-making processes, inverse reinforcement learning (IRL) methods have proven instrumental in reconstructing animal's intentions underlying complex behaviors. Given the recent development of a continuous-time multi-intention IRL framework, there has been persistent inquiry into inferring discrete time-varying rewards with IRL. To address this challenge, we introduce the class of hierarchical inverse Q-learning (HIQL) algorithms. Through an unsupervised learning process, HIQL divides expert trajectories into multiple intention segments, and solves the IRL problem independently for each. Applying HIQL to simulated experiments and several real animal behavior datasets, our approach outperforms current benchmarks in behavior prediction and produces interpretable reward functions. Our results suggest that the intention transition dynamics underlying complex decision-making behavior is better modeled by a step function instead of a smoothly varying function. This advancement holds promise for neuroscience and cognitive science, contributing to a deeper understanding of decision-making and uncovering underlying brain mechanisms.

Introduction

Understanding the motivations behind animal behavior is a central goal of behavioral neuroscience. Inverse Reinforcement Learning (IRL) provides a mathematical framework to infer an agent's internal reward function from observed actions. However, biological agents are rarely driven by a single, static goal. A mouse navigating a maze may switch between foraging, exploring, or returning to a home base.

Traditional IRL methods often assume a stationary reward function. Recent "Dynamic IRL" (DIRL) approaches allow rewards to change, but typically model this evolution as a smooth, continuous process. This contradicts neuroscientific evidence suggesting that animals switch between discrete behavioral strategies. Hierarchical Inverse Q-learning (HIQL) addresses this by modeling behavior as a sequence of discrete latent intentions, allowing for sharp transitions and improved interpretability.

Methods: Hierarchical Inverse Q-learning

HIQL employs a two-layer hierarchical structure. The top layer is a Markov chain governing transitions between discrete hidden intentions ($\Lambda$). The bottom layer consists of intention-specific reward functions ($r$) that determine the agent's actions ($a$) in given states ($s$).

Graphical model of HIQL illustrating the dependencies between states, actions, and the latent intention process.

To learn these components without labeled data, HIQL uses an unsupervised Expectation-Maximization (EM) framework:

  1. Expectation Step: The Baum-Welch algorithm estimates the probability of each intention at every time step based on the current reward models.
  2. Maximization Step: The reward functions for each intention are updated using Inverse Q-Learning (IQL).

IQL is chosen for its computational efficiency and model-free nature, avoiding the need for a perfect transition model of the environment. This discrete switching mechanism allows HIQL to capture "step-function" changes in strategy that continuous models struggle to represent.

Results and Discussion

The framework was evaluated on a simulated 5x5 gridworld where an agent switches between a 'goal' seeking intention and an 'abandon' intention. HIQL (labeled as HIAVI in the results figures) significantly outperformed DIRL across several metrics.

Performance comparison on the gridworld benchmark showing log-likelihood, intention tracking, and reward recovery.

As shown in the results, HIQL achieves near-optimal log-likelihood and accurately tracks the ground truth intention switches, whereas DIRL's continuous assumptions lead to poor tracking and higher error in reward recovery (EVD).

Beyond simulations, HIQL was applied to real-world datasets, including mice in a 127-node labyrinth and a dynamic two-armed bandit task. In the labyrinth, the Bayesian Information Criterion (BIC) identified that two intentions (e.g., "thirsty" vs. "tired") provided the most parsimonious explanation of the data. In the bandit task, HIQL identified three distinct, biologically interpretable strategies: Exploitation, Disengaged, and Exploration.

Conclusion

HIQL demonstrates that animal decision-making is better characterized by discrete shifts in intention rather than smooth gradients. By combining hierarchical modeling with efficient inverse Q-learning, this approach provides a powerful tool for neuroscientists to uncover the latent structures of complex behavior. Future work will explore non-Markovian intention dynamics and non-parametric methods for automatically determining the number of latent states.

Summary updated

BibTeX
@article{zhu2024multi,
  author = {Hao Zhu and Brice De La Crompe and Gabriel Kalweit and Artur Schneider and Maria Kalweit and Ilka Diester and Joschka Boedecker},
  title = {{Multi-intention Inverse Q-learning for Interpretable Behavior Representation}},
  journal = {Accepted by TMLR},
  year = {2024},
  url = {https://openreview.net/forum?id=hrKHkmLUFk},
}
Figure