LCG: Long-Context Consistent Image Generation with Sparse Relational Attention

Zihao Wang, Yijia Xu, Haoze Zheng, Xuran Ma, Haokun Gui +1 more
6/24/2026
cs.CVcs.AI

No confident code implementation found for this paper. 1 possible match can be shown below.

Abstract

Recent image generation models achieve impressive quality in single-image synthesis, but often fail to maintain consistency across sequential outputs, as required in comics, storyboards, and visual narratives. We propose Long-Context Generation (LCG), a framework for long-context multi-image text-to-image generation, to improve consistency and scalability in long-context multi-image generation.

Show full abstract

LCG employs the Sparse Relational Attention (SRA) mechanism to selectively attend to core features across extended visual contexts, ensuring that the propagation of semantic and layout information remains computationally tractable. To enforce semantic alignment, we introduce the Routing Consistency Constraint (RCC), which leverages identity-aware masks to align structural patterns across generation branches, effectively mitigating drift in appearance even in complex multi-character scenes. To support training and evaluation in this setting, we construct the Long-Context Consistency Dataset (LCCD), a large-scale synthetic dataset comprising character-centric multi-image sequences spanning varied situational contexts. LCCD contains 600K training sequences and a separate 1K test set, with each sequence containing 6 to 20 images. The experiments demonstrate that LCG outperforms the compared baselines in prompt alignment and character consistency for long-context image generation, including multi-character scenes.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. 1 weaker match is hidden by default — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{wang2026lcg,
  title  = {LCG: Long-Context Consistent Image Generation with Sparse Relational Attention},
  author = {Zihao Wang and Yijia Xu and Haoze Zheng and Xuran Ma and Haokun Gui and Harry Yang},
  year   = {2026},
  eprint = {2606.26171},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2606.26171v1}
}

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/2606.26171.svg)](https://codeofpaper.com/paper/2606.26171)

Discussion