NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Contrastive Explanations of Plans through Model Restrictions

Benjamin Krarup, Senka Krivic, Daniele Magazzeni, Derek Long, Michael Cashmore, David E. Smith

Abstract

Explainable AI Planning (XAIP) often struggles to bridge the gap between complex algorithmic logic and human intuition. This paper presents a pragmatic, human-centric framework for XAIP that leverages the social nature of explanation. By focusing on contrastive questions—asking "Why action A instead of B?"—the authors propose a system that compiles user expectations into model restrictions. This allows for the iterative generation of hypothetical plans that help users reconcile their mental models with AI-generated solutions.

Introduction: The Contrastive Gap

In automated planning, a significant "mismatch" frequently occurs between the optimal plan proposed by an AI and the plan a human user expects. Traditional explanation methods typically fall into two categories: local descriptions of plan properties or global explanations of the entire planning model. However, social science research suggests that human explanation is fundamentally contrastive. Users do not simply want to know why a specific path was chosen; they want to know why the system did not take the "obvious" alternative they had in mind.

Existing approaches, such as Model Reconciliation, often assume the AI possesses perfect knowledge of the human's internal model—an assumption that rarely holds in practice. This research shifts the burden of explanation: it allows users to express their expectations as constraints, which the AI then uses to demonstrate the consequences of those choices through "foil" plans.

The XAIP-as-a-Service Framework

The researchers developed a four-stage iterative process designed to facilitate "plan negotiation" between the human and the AI. This workflow is designed to be planner-agnostic, acting as a wrapper around existing software like POPF or Metric-FF.

The iterative XAIP-as-a-Service workflow, from user question to contrastive explanation.
  1. Question Elicitation: The user identifies a discrepancy and asks a contrastive question (e.g., "Why is action A not used?").
  2. Model Restriction (Compilation): The system translates this natural or semi-structured question into a formal constraint using PDDL2.1 compilations. For instance, if a user asks why an action was omitted, the system generates a new version of the planning domain where that specific action must be performed.
  3. Hypothetical Plan Synthesis: A standard off-the-shelf planner solves the newly restricted model to produce a "Hypothetical Plan" (HPlan).
  4. Contrastive Visualization: The system displays the original plan and the HPlan side-by-side, highlighting differences in actions, timing, and costs to provide a clear visual explanation of the trade-offs involved.

Key Insights and Taxonomy

A central finding of the study is the 90% Rule: in initial user studies, 89.9% of questions asked by participants were contrastive in nature. This validates the framework's focus on "Why A rather than B?" over descriptive "What?" or "How?" questions.

To handle these queries systematically, the authors identified a Taxonomy of Doubt consisting of seven formal question types (FQ1-FQ7). These range from simple presence/absence of actions to complex temporal constraints.

Taxonomy of formal contrastive questions and their frequency in user studies.

Experimental Results

The framework was evaluated using both user studies (involving logistics and warehouse delivery domains) and performance benchmarks from the International Planning Competition (IPC).

  • Efficiency: Counter-intuitively, adding constraints often made problems easier to solve. The median increase in planning time for restricted models was less than 4 seconds, making the system viable for near-real-time interaction.
  • User Satisfaction: Participants using the full contrastive framework reported significantly higher explanation satisfaction scores compared to control groups who were shown alternative plans without highlighted differences.
  • Plan Steering: In complex domains, the iterative process allowed humans to "steer" the AI. In some cases, user-suggested constraints actually led to the discovery of higher-quality plans than the original automated output.

Conclusion and Future Work

While the framework successfully facilitates plan negotiation, several challenges remain. Currently, if a user's suggestion makes a goal impossible to reach, the system fails to explain why the alternative is unsolvable. Furthermore, while the system shows what changed, users often desire deeper causal logic (e.g., "Action A was avoided because it would deplete fuel required for the final goal"). Future work will focus on integrating natural language interfaces and providing deeper causal justifications for model restrictions.

Summary updated

BibTeX
@article{krarup2021contrastive,
  author = {Benjamin Krarup and Senka Krivic and Daniele Magazzeni and Derek Long and Michael Cashmore and David E. Smith},
  title = {{Contrastive Explanations of Plans through Model Restrictions}},
  journal = {J. Artif. Intell. Res.},
  year = {2021},
  doi = {10.1613/jair.1.12813},
}
Figure