Spatial Reasoning and Structural Planning for Diffusion Models

This direction is no longer present in the current build. Its last version stays readable and citable here.

Version 1 of 141 papers44 conceptsfrozen 2026-10-04

Modern text-to-image models can generate breathtaking visuals, yet they frequently stumble on the simplest logical requests. Ask for "a cat to the left of a bowl," and you might get a cat, a bowl, or even a cat inside a bowl—but rarely the precise spatial arrangement you requested. This "compositionality gap" reveals a fundamental disconnect: while diffusion models excel at texture and object recognition, they lack an inherent understanding of spatial logic and numerical constraints.

As Jaemin Cho and colleagues demonstrate in DALL-EVAL, there is a persistent decoupling between visual fidelity and logical reasoning. Scaling models improves their "artistry" but does not inherently fix their inability to count to three or distinguish "left" from "right."

The Planning Deficit

The core of the problem lies in the architecture. Standard diffusion models map text prompts directly to pixels in a single, continuous process. There is no intermediate stage where the model "decides" where objects should go before it starts painting them. Without this structural blueprint, the model relies on surface-level pattern matching, which often leads to "attribute bleeding" (e.g., a yellow book becoming red because a red car is nearby) or incorrect object counts.

To bridge this gap, researchers are moving toward a "divide and conquer" approach: using Large Language Models (LLMs) as architects and diffusion models as the construction crew.

LLMs as Visual Architects

LLMs possess a latent understanding of spatial relationships and logic that diffusion models lack. By prompting an LLM to act as a "visual planner," researchers can generate an explicit layout before the image generation begins.

In LayoutGPT, Weixi Feng and team show that LLMs can translate text prompts into structured 2D or 3D layouts, often formatted as CSS code or bounding boxes. This provides the diffusion model with a clear "map" of where to place specific entities. Similarly, Hao Tian introduced Generation Chain-of-Thought (GoT) in GoT: Unleashing Reasoning Capability of Multimodal Large Language Model for Visual Generation and Editing, which forces the model to generate a semantic-spatial reasoning chain—including coordinates—before triggering the pixels.

By separating the reasoning (where things go) from the rendering (what things look like), these frameworks significantly reduce attribute binding errors and improve spatial fidelity.

Inference-Time Self-Correction

Another emerging strategy is to allow the model to "think" and "reflect" on its own output during the generation process. If a model generates an image that misses a requested object, it should be able to identify that mistake and correct it.

Le Zhuo and others proposed ReflectionFlow in From Reflection to Perfection, a framework that scales inference-time compute by allowing models to iteratively self-correct. This mirrors the "System 2" thinking in humans—slowing down to double-check if the output matches the instructions. Yuanhuiyi Lyu explores a similar concept with Understanding-in-Generation (UiG) in Understanding-in-Generation: Reinforcing Generative Capability of Unified Model via Infusing Understanding into Generation, where the model acts as its own critic to ensure the final image aligns with the prompt's nuances.

Learning from Mistakes through Feedback Loops

Beyond planning and reflection, researchers are developing ways to bake spatial awareness directly into the training process.

One intuitive approach is Iterative Prompt Relabeling (IPR), introduced by Xinyan Chen in Learning from Mistakes. Instead of discarding "failed" generations where the model swapped object positions, the researchers use an object detection model to relabel the image with what was actually generated. Fine-tuning the model on these "corrected" labels teaches it the true meaning of spatial descriptors.

For more complex alignment, Bohan Wang and colleagues proposed Selftok-Zero in Selftok-Zero: Reinforcement Learning for Visual Generation via Discrete and Autoregressive Visual Tokens. By treating image generation as a sequence of discrete tokens, they apply Reinforcement Learning (RL) to reward the model for following dense semantic constraints, effectively bringing the "RLHF" success of language models to the visual domain.

The Path Forward: From Pixels to World Models

The shift from direct generation to structured planning suggests that the next generation of visual AI will not just be better "painters," but better "thinkers." As Feng Han notes in UniREditBench, the primary bottleneck in complex tasks like image editing is no longer pixel quality, but the model's internal reasoning capability and its "world model."

By integrating LLM-based planning, iterative reflection, and feedback-driven training, the field is moving toward systems that understand the physical and logical constraints of the scenes they create.

Papers in this version

History & citationVersion 1 · 2026-10-04

No longer present in the current build · Permanent link

View frozen version 1

Cite this direction

Latest version (a living page):

@misc{lacuna_spatial_reasoning_and_structural_plannin_decdbd2a,
  title = {Spatial Reasoning and Structural Planning for Diffusion Models},
  author = {{Lacuna}},
  howpublished = {Lacuna research direction},
  year = {2026},
  url = {https://lacuna.tiptreesystems.com/direction/spatial-reasoning-and-structural-planning-for-diffusion-models/rdr_decdbd2af6624294a1e0f8187a8e13f1},
  note = {Latest version of a living research direction; cite a version for a fixed text. Accessed 2026-11-24},
}

This exact version (version 1, frozen text):

@misc{lacuna_spatial_reasoning_and_structural_plannin_decdbd2a_v1,
  title = {Spatial Reasoning and Structural Planning for Diffusion Models},
  author = {{Lacuna}},
  howpublished = {Lacuna research direction},
  year = {2026},
  url = {https://lacuna.tiptreesystems.com/direction/spatial-reasoning-and-structural-planning-for-diffusion-models/rdr_decdbd2af6624294a1e0f8187a8e13f1/v/1},
  note = {Version 1, frozen 2026-10-04. Accessed 2026-11-24},
}