Latent Plan Transformer for Trajectory Abstraction: Planning as Latent Space Inference

Deqian Kong, Dehong Xu, Minglu Zhao, Bo Pang, Jianwen Xie +4 more
2/3/2026

No official code found. Best implementation: mingluzhao/Latent-Plan-Transformer (21 stars, MIT, last commit 2024-12-01).

Abstract

In tasks aiming for long-term returns, planning becomes essential. We study generative modeling for planning with datasets repurposed from offline reinforcement learning. Specifically, we identify temporal consistency in the absence of step-wise rewards as one key technical challenge. We introduce the Latent Plan Transformer (LPT), a novel model that leverages a latent variable to connect a Transformer-based trajectory generator and the final return. LPT can be learned with maximum likelihood estimation on trajectory-return pairs. In learning, posterior sampling of the latent variable naturally integrates sub-trajectories to form a consistent abstraction despite the finite context. At test time, the latent variable is inferred from an expected return before policy execution, realizing the idea of planning as inference. Our experiments demonstrate that LPT can discover improved decisions from sub-optimal trajectories, achieving competitive performance across several benchmarks, including Gym-Mujoco, Franka Kitchen, Maze2D, and Connect Four. It exhibits capabilities in nuanced credit assignments, trajectory stitching, and adaptation to environmental contingencies. These results validate that latent variable inference can be a strong alternative to step-wise reward prompting.

View on arXivView PDF

Code Implementations(1)

MIT

Source code for "Latent Plan Transformer for Trajectory Abstraction: Planning as Latent Space Inference." In NeurIPS 2024

211PythonOct 18, 20241 years agoMIT

Similar Papers

Cite this paper

@article{kong2026latent,
  title  = {Latent Plan Transformer for Trajectory Abstraction: Planning as Latent Space Inference},
  author = {Deqian Kong and Dehong Xu and Minglu Zhao and Bo Pang and Jianwen Xie and Andrew Lizarraga and Yuhao Huang and Sirui Xie and Ying Nian Wu},
  year   = {2026},
  eprint = {2402.04647},
  archivePrefix = {arXiv},
  doi    = {10.52202/079017-3922},
  url    = {https://arxiv.org/abs/2402.04647},
  journal = {NEURIPS 2024 2024}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2402.04647.svg)](https://codeofpaper.com/paper/2402.04647)

Discussion