Manuscript Offprint

arXiv:2611.06838

Context-Aware Autoregressive Image Generation for Emerging Reasoning Properties

Jixuan Ying, Haoyu Liu, Timing Yang, Tingyu Zhu, Predrag Neskovic, Anand Bhattad, Cihang Xie, Zeyu Zheng, Alan Yuille, Feng Wang

Abstract

Autoregressive image generation has recently emerged as a competitive visual generation paradigm, yet its generation order is often predefined or heuristic, such as next-patch prediction, random-order prediction, or one-step generation for specific scales. We observe that these strategies can cause models to overlook important structural dependencies in images, thereby limiting both structural robustness and reasoning capability. In this work, we propose a context-aware autoregressive generation framework, where the model dynamically determines the next token location based on global context and current local information. Rather than following a fixed or random order, our method allows the generation process to adapt to image structure and semantic dependencies. Extensive experiments show that context-aware generation significantly improves structural robustness across different image AR paradigms, including masked autoregressive and scale-wise autoregressive models. Beyond quantitative improvements, we further observe emerging reasoning properties: the model can better understand complex semantic instructions and generate images that more faithfully follow the given guidance. These findings suggest that generation order is a critical yet underexplored factor in image autoregressive modeling, and that context-aware decoding can unlock stronger reasoning-aware visual generation capabilities. Code is available at https://github.com/Hpesojyjx/Saccades-AR.

1 Introduction

Inspired by the success of next-token prediction in natural language processing, recent years have witnessed a growing interest in autoregressive (AR) image generation. Early efforts directly transferred the language modeling recipe to visual generation by flattening 2D images, pixels, or discrete visual tokens into 1D sequences and modeling them with standard autoregressive Transformers, following a raster or otherwise fixed token order (Chen et al., 2020; Ramesh et al., 2021; Esser et al., 2021; Yu et al., 2022; Sun et al., 2024). While conceptually simple and scalable, this direct transfer is not perfectly aligned with the spatial nature of images. Unlike text, where the generation order often follows a natural linguistic progression, images contain dense 2D structures and long-range spatial dependencies that do not naturally conform to a single left-to-right sequence. As a result, fixed-order AR generation can easily underutilize important structural cues, leading to visible artifacts such as row-wise or column-wise misalignment, distorted object layouts, and weakened global coherence. To alleviate these limitations, subsequent works explored more flexible generation schemes, including masked generative modeling that predicts randomly masked tokens or iteratively refines token sets (Chang et al., 2022, 2023; Li et al., 2023, 2024c; Kim et al., 2025b), as well as

Preprint.

Prompt: "a photo of four vases"

Figure

Figure 1: Generation order shapes reasoning-like behaviors in autoregressive image generation. With random-order decoding (top), intermediate predictions remain scattered and incomplete, weakening feedback for counting (e.g., "four vases") and often causing over-generation. With context-aware location selection (bottom), the same model and seed tend to complete objects more coherently (roughly one-by-one) and stop adding new ones once the count is met.

scale-wise autoregressive generation that predicts visual tokens progressively from coarse to fine resolutions (Tian et al., 2024b; Ma et al., 2024; Han et al., 2025b), which reduce the rigidity of raster decoding and improve visual fidelity and structural stability.

Nonetheless, although random-order and scale-wise generation alleviate the structural distortion, the reasoning logic behind patch-level generation remains largely overlooked. For example, when humans draw an image patch by patch, they can usually decide where to draw next based on the existing context. This allows them to build a more coherent spatial organization and progressively reason over the partially completed content. In contrast, masked AR models generate patches in a random order, while scale-wise AR models generate all tokens within a given spatial scale in one step. Both strategies can easily miss an important intermediate reasoning process. We illustrate this issue with an intuitive example in Fig. 1, where the model is asked to generate four vases. In Case 2, when the model is allowed to determine the next prediction location according to context, an emerging reasoning behavior can be observed. The model generates the vases in an organized manner, roughly one by one, and obtains self-feedback during the generation process. For instance, before step 22, it has already generated three vases. In the following steps, the model appears to recognize that one vase is still missing, and completes the fourth vase by step 25. After the required count is satisfied, the remaining steps are mainly used to fill in the background. In contrast, in Case 1, the random-order AR model selects prediction locations randomly at each step. As a result, most objects remain incomplete during the intermediate generation process, making it difficult for the model to receive reliable feedback about the object count. Consequently, it keeps generating new vase-like regions and fails to align with the required number.

Motivated by this observation, we propose Saccade AR (SAR) 1^{1}, a simple yet surprisingly effective context-aware decoding strategy for AR image generation. In detail, at each decoding step, an AR model typically produces candidate predictions for all editable token positions, after which existing methods commit tokens according to a random, predefined, or scale-wise schedule. Instead, SAR ranks candidate token locations by their semantic relevance to the global context. Specifically, we measure the distance between each candidate token representation and the global conditioning signal, such as the class token in class-conditional generation or text embeddings in text-to-image generation, and prioritize locations from semantically close to semantically distant. In this way, SAR first generates regions that are strongly related to the global intent, and then fills in less critical details. SAR is training-free, lightweight, and broadly applicable. It can be plugged into pretrained AR image models at inference time without changing model parameters, and it introduces almost no additional computation because it only reorders which candidate predictions are committed. Moreover, SAR applies to different AR paradigms, including masked autoregressive models (MAR (Li et al., 2024c)) and scale-wise autoregressive models (VAR (Tian et al., 2024b)). Importantly, SAR does not change the model architecture or supervision; it changes the generation trajectory. Our central thesis is that this trajectory matters: when the model generates in a context-aware order, it can better exploit intermediate visual feedback and exhibit stronger structural robustness and reasoning-related instruction following.

1^{1}We call our method Saccade AR because it is inspired by saccadic eye movements in the human visual system, which actively choose where to fixate based on context when interpreting a visual scene.

Extensive experiments validate this hypothesis. On text-to-image benchmarks such as GenEval (Ghosh et al., 2023) and DPG-Bench (Hu et al., 2024), SAR consistently improves pretrained AR generators including MaskGen (Kim et al., 2025b) and Infinity (Han et al., 2025b), with especially clear gains on reasoning-related dimensions such as counting, relative positioning, and compositional instruction following. To further evaluate reasoning ability, we construct a long-prompt text-to-image benchmark involving complex combinations of object counts, spatial relations, and fine-grained attribute assignments. On this benchmark, SAR brings even larger improvements, supporting our claim that generation order is a critical factor behind the reasoning limitations of existing AR image models.

References (35)