--- license: mit language: - en base_model: - black-forest-labs/FLUX.1-Kontext-dev pipeline_tag: text-to-image library_name: diffusers tags: - art ---

ContextGen: Contextual Layout Anchoring
for Identity-Consistent Multi-Instance Generation

Ruihang Xu, Dewei Zhou, Fan Ma, Yi Yang
ReLER, CCAI, Zhejiang University

GitHub Code Project Page Paper Dataset Code

Teaser Image

ContextGen is a novel framework that uses user-provided reference images to generate image with multiple instances, offering layout control over their positions while guaranteeing identity preservation.

## 🚀 Usage Please refer to our [GitHub Repository](https://github.com/nenhang/ContextGen) for detailed instructions on how to use ContextGen. ## 📭 Citation If you find ContextGen helpful to your research, please consider citing our paper: ```bibtex @article{xu2025contextgencontextuallayoutanchoring, title={ContextGen: Contextual Layout Anchoring for Identity-Consistent Multi-Instance Generation}, author={Ruihang Xu and Dewei Zhou and Fan Ma and Yi Yang}, year={2025}, eprint={2510.11000}, archivePrefix={arXiv}, primaryClass={cs.CV}, url={https://arxiv.org/abs/2510.11000}, } ```