Autoregressive (AR) image generators are powerful in principle but inflexible in practice: training with a fixed raster-scan order hardcodes a single factorization of the image distribution into the model, leaving it unable to inpaint, outpaint, or edit at inference time. Existing solutions, including the modern discrete-diffusion family, train from scratch on a mixture of token orderings, paying roughly 3x the compute of standard raster-scan training; discrete diffusion further sacrifices compatibility with the AR inference ecosystem (KV caching, vLLM) by construction. We argue that this cost is unnecessary. A pretrained raster-scan AR model has already learned the joint distribution over image tokens; what it lacks is not knowledge but the ability to express that knowledge through non-sequential conditional pathways. We propose a recipe for adapting pretrained raster-scan models into any-order generators using two components: future-aware positional embeddings that resolve a target-position identifiability problem at negligible overhead, and an ordering curriculum that traces a stable optimization path from the pretrained solution to a good any-order basin. Applied to four base models across two architectures and two scales (LlamaGen-L/XL, RAR-L/XL), the recipe substantially outperforms MaskGIT on ImageNet inpainting (FID 6.21 vs. 10.44) and outpainting, is competitive with MAR-L, trades a 1.2-1.9 increase in class-conditional FID for this flexibility, and costs 13-33% additional compute beyond pretraining, while leaving the standard AR inference stack untouched. Inpainting, outpainting, and editing, our results suggest, need not be added to autoregressive image models. They can be unlocked from the ones that exist. Code is available at https://github.com/Ordered-AR/unlockedadaptation.
Figures & tables
Figure 1: A single autoregressive image model, adapted from a pretrained raster-scan generator, performs inpainting (left), region-conditioned editing (center), and outpainting (right) without task-specific training, sampler modification, or auxiliary networks. The “Pretrained (raster)” column shows the same LlamaGen-L [ 1 ] model from which our model is adapted, prompted to perform the same tasks under the natural raster-scan generation procedure. Failure modes in this column reflect the structural incapacity of fixed-order AR models to condition on non-contiguous context, not weak performance at a shared task. After adaptation (“Ours”), the same weights produce coherent results across all three capabilities, varying only in which tokens are observed at inference time. Quantitative comparisons against MaskGIT [ 2 ] on inpainting and outpainting are reported in Section 4 .
Type
Model
#Para.
FID ↓
IS ↑
Precision ↑
Recall ↑
Steps
Diffusion
ADM [ 40 ]
554M
4.59
186.70
0.82
0.523
250
LDM-4 [ 43 ]
400M
3.60
247.7
–
–
250
DiT-XL [ 37 ]
675M
2.27
278.2
0.83
0.57
250
Bi-directional AR
MaskGIT-re [ 2 ]
227M
6.80
214.0
0.82
0.51
8
TiTok-S-128 [ 44 ]
287M
1.97
281.8
–
–
64
Causal AR
VAR [ 4 ]
600M
2.57
302.6
0.83
0.56
10
Table 1: Class-conditional generation on ImageNet 256×256 . Our adapted models (rows marked Ours ) trade a 1.17 – 1.93 FID increase relative to the pretrained raster-scan baselines they are adapted from for full any-order capability (Section 4.3 ). ∗ Reported by the original paper.
Figure 2: Class-conditional generation after adaptation, further accelerated by parallel decoding. Top: pretrained LlamaGen-L (raster). Middle: our adapted model with sequential decoding. Bottom: our adapted model with parallel decoding (64 steps, 4× fewer forward passes).
Model
Total epochs
Pretrained + adapted ↓
Random init ↓
LlamaGen-L
400 ( 300+100 )
4.24
5.60
LlamaGen-XL
125 ( 100+25 )
3.91
4.81
Table 2: Value of pretraining: FID at matched total epochs with the same architecture and curriculum.
Figure 5
Inpainting
Outpainting
Method
FID ↓
IS ↑
Prec. ↑
Rec. ↑
FID ↓
IS ↑
Prec. ↑
Rec. ↑
MaskGIT (cosine)
10.44
116.2
0.680
0.575
12.17
107.0
0.664
0.631
MaskGIT (Halton)
7.82
123.5
0.581
0.575
7.91
119.1
0.691
0.612
MAR-L
6.63
134.2
0.696
0.598
6.86
127.2
0.736
0.649
Ours
6.21
157.0
0.710
0.598
5.84
159.4
0.720
0.637
Table 3: Inpainting and outpainting on ImageNet 256×256 , evaluated on 50,000 samples with TF-Inception. Inpainting uses center masks; outpainting extends a centered 128×128 crop to full resolution. Lower is better for FID; higher for IS, Precision, Recall.
Method
LPIPS ↓
PSNR ↑
SSIM ↑
MaskGIT (cosine)
0.234
19.20±3.60
0.484±0.21
MaskGIT (Halton)
0.196
18.20±3.50
0.452±0.23
MAR-L
0.174
20.15±4.60
0.550±0.20
Ours
0.125
24.65±3.34
0.682±0.17
Table 4: Reference-based completion metrics. LPIPS: random region covering 30 – 50% of 5,000 held-out images. PSNR/SSIM (mean ± std): generated region of the 50,000 center-mask inpainting examples.
Variant
FID ↓
IS ↑
Prec. ↑
Rec. ↑
No curriculum ( α=1 from step 0 )
5.86
191.27
0.78
0.51
Ours (linear curriculum)
4.24
231.62
0.83
0.52
Table 5: Effect of the ordering curriculum on LlamaGen-L. Adapting with α=1 from step zero (no curriculum) leaves the model in a partially adapted state across all metrics; the linear curriculum used in our main results recovers the gap.
Method
Train cost
Any-order
KV cache
vLLM
LlamaGen pretraining [ 1 ] (raster only)
1×
✗
✓
✓
RandAR [ 18 ] (from scratch)
3×
✓
✓
✗
RAR [ 5 ] (from scratch)
4×
✗
✓
✓
Discrete diffusion [ 2 ]
3×
✓
✗
✗
Ours (LlamaGen-XL + adaptation)
1.25×
✓
✓
✓
Table 6: Training and inference compatibility relative to standard AR pretraining. Our adaptation recipe achieves any-order generation at ≈1.25× the cost of standard pretraining (LlamaGen-XL), while preserving compatibility with the AR inference ecosystem.
Generation steps
576
192
128
64
FID ↓
3.91
4.12
4.81
5.03
Table 7: Parallel decoding on LlamaGen-XL: generation steps vs. class-conditional FID.
Appendix figures & tables1 asset
Supplementary material from the paper’s appendix.
Appendix
LlamaGen-L
LlamaGen-XL
RAR-L
RAR-XL
Optimization
Optimizer
AdamW
AdamW
AdamW
AdamW
(β1,β2)
(0.9,0.95)
(0.9,0.95)
(0.9,0.95)
(0.9,0.95)
Weight decay
0.05
0.05
0.05
0.05
Base learning rate
1×10−4
1×10−4
5×10−5
5×10−5
Embedding-table LR multiplier
10×
10×
10×
10×
Appendix
Table 8: Adaptation hyperparameters by base model. Notation matches Section 3 .