Modeling the Mistakes of Boundedly Rational Agents Within a Bayesian Theory of Mind

Arwa Alanqary, Gloria Z. Lin, Joie Le, Tan Zhi-Xuan, Vikash K. Mansinghka, Joshua B. Tenenbaum

TL;DR

Traditional Bayesian Theory of Mind (BToM) models assume that people infer others' goals by viewing them as rational, optimal planners. This paper introduces a hierarchical BToM framework that models agents as boundedly rational probabilistic programs capable of making mistakes at three distinct levels: goals, plans, and actions. By accounting for these human-like fallibilities, the model closely mirrors how real humans infer intentions from suboptimal or failed behavior.

What Problem Does This Paper Address?

When we watch someone accidentally lock themselves out of their house or misspell a word while stacking letter blocks, we don't immediately assume they wanted to be locked out or intended to invent a new word. Humans intuitively understand that others are fallible and make mistakes.

However, computational models of computational psychology—specifically Bayesian Theory of Mind (BToM)—have traditionally struggled with this. Most BToM frameworks model agents as nearly optimal planners. When they do account for mistakes, they rely on "Boltzmann-distributed action noise," which treats every error as a low-level motor slip (a literal slip of the hand). This completely misses higher-level cognitive blunders, like short-sighted planning or temporary goal confusion. This paper bridges that gap by formalizing a multi-level model of bounded rationality.

Methods

The authors model agents and their environments as generative processes using probabilistic programs. Instead of assuming a single source of random noise, they introduce a hierarchy of three potential failure modes:

  1. Goal Mistakes (Temporary Goal Confusion): An agent might temporarily confuse their true goal with a semantically similar one (e.g., intending to spell "pear" but temporarily trying to spell "paer").
  2. Plan Mistakes (Resource-Bounded Planning): Instead of computing the optimal path across the entire state space, the agent uses a budget-constrained, noisy version of $A^*$ search to plan only a few steps ahead, executing partial plans and replanning as they go.
  3. Action Mistakes (Execution Errors): The classic "slip of the hand" where an agent occasionally executes a random action instead of the planned one.
Figure 1: A single realization of our boundedly rational agent model. At t=1, the agent samples a search budget η1 and searches for a plan p1 that is two actions long. At t=2, no additional planning needs to be done, so p2 is copied from p1, as denoted by the dashed lines. The agent then replans at t=3, sampling a new search budget η3 and an extended plan p3 with three more actions.

To infer goals from observed actions, the authors use Sequential Inverse Plan Search (SIPS), a sequential Monte Carlo algorithm that approximates the goal posterior over time. They compare their full model against "lesioned" versions (where specific mistake types are disabled) and a standard Boltzmann baseline model.

Datasets

The models were evaluated on two newly designed behavioral tracking domains with human participants recruited via Amazon Mechanical Turk:

  • Doors, Keys, & Gems: A gridworld puzzle where an agent must navigate a maze, collect keys, and unlock doors to reach colored gems. Trajectories were designed to trigger specific planning failures (e.g., myopically using up keys so that the goal gem becomes permanently unreachable).
  • Block Words: A domain based on Blocks World where an agent stacks lettered blocks to spell specific English words. This domain features a richer goal space, allowing the authors to test goal confusion (misspellings).

Human goal inferences were collected at specific "pause points" during animated videos of these tasks to serve as the ground-truth benchmark.

Key Insights and Ideas

  • Human Intuition is Hierarchical: Humans don't just see "noise"; they distinguish between a mistaken action (taking a wrong step and immediately correcting it) and a mistaken plan (walking all the way down a dead end before realizing a key was missed).
  • Optimality Models Fail on Failures: Standard Boltzmann models perform poorly when an agent makes an irreversible planning mistake. Because they assume the agent is rational, they shift goal probability away from the true goal toward whatever alternative is still physically possible, whereas humans recognize that the agent simply messed up.
  • Rationality is Resource-Bounded: Modeling agents as resource-rational (planning only a few steps ahead to save computation) naturally accounts for human-like myopic errors without sacrificing the overall structure of intentional behavior.

Key Results

The full model consistently outperformed the standard Boltzmann model and lesioned baselines in predicting human goal inferences:

  • Doors, Keys, & Gems: The full Plan & Action (PA) mistake model achieved a high overall correlation with human judgments ($r = 0.87 \pm 0.04$). Crucially, on trajectories involving irreversible planning failures, the full model achieved $r = 0.94$, whereas the P-lesioned model (no bounded planning) dropped to $r = 0.65$.
Figure 3: Results for the Doors, Keys & Gems domain. In (a), we show goal inferences of humans (avg., n=18, w. standard error), our model (PA) and the Boltzmann agent model for an illustrative trajectory. In (b), we compare human vs. model inferences across models (full model, lesioned models for plan/action mistakes, Boltzmann model) and stimulus types.
  • Block Words: The full Goal, Plan, & Action (GPA) model best explained human inferences ($r = 0.86 \pm 0.02$). When goal mistakes (misspellings) occurred, models that didn't account for goal confusion (like the Boltzmann or G-lesioned models) yielded poor inferences because they couldn't comprehend why an agent would stack blocks in a "suboptimal" order.

Limitations and Future Work

While this framework successfully models three core levels of human error, the authors note several areas for expansion:

  • Other Cognitive Biases: The current model does not account for other known human limitations, such as time inconsistency (procrastination), physical capability limits, or incorrect internal models of the environment.
  • Algorithmic Efficiency: It remains an open question how human observers perform these complex, hierarchical calculations so rapidly in real-time. Future work will explore whether approximate online inference algorithms can accurately model individual human cognitive constraints.

Summary updated

Abstract

When inferring the goals that others are trying to achieve, people intuitively understand that others might make mistakes along the way. This is crucial for activities such as teaching, offering assistance, and deciding between blame or forgiveness. However, Bayesian models of theory of mind have generally not accounted for these mistakes, instead modeling agents as mostly optimal in achieving their goals. As a result, they are unable to explain phenomena like locking oneself out of one's house, or losing a game of chess. Here, we extend the Bayesian Theory of Mind framework to model boundedly rational agents who may have mistaken goals, plans, and actions. We formalize this by modeling agents as probabilistic programs, where goals may be confused with semantically similar states, plans may be misguided due to resource-bounded planning, and actions may be unintended due to execution errors. We present experiments eliciting human goal inferences in two domains: (i) a gridworld puzzle with gems locked behind doors, and (ii) a block-stacking domain. Our model better explains human inferences than alternatives, while generalizing across domains. These findings indicate the importance of modeling others as bounded agents, in order to account for the full richness of human intuitive psychology.
BibTeX
@misc{alanqary2021modeling,
  author = {Arwa Alanqary and Gloria Z. Lin and Joie Le and Tan Zhi-Xuan and Vikash K. Mansinghka and Joshua B. Tenenbaum},
  title = {{Modeling the Mistakes of Boundedly Rational Agents Within a Bayesian Theory of Mind}},
  year = {2021},
  eprint = {2106.13249},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2106.13249},
}
Figure