UniAlignment: Semantic Alignment for Unified Image Generation, Understanding, Manipulation and Perception

Xinyang Song, Libin Wang, Weining Wang, Shaozhen Liu, Dandan Zheng, Jingdong Chen, Qi Li, Zhenan Sun

TL;DR

UniAlignment is a unified multimodal framework that uses a single, lightweight 2-billion parameter Diffusion Transformer (DiT) to handle image generation, understanding, editing, and perception. By introducing dual-stream semantic alignment strategies, it achieves state-of-the-art performance and significantly faster inference speeds (generating images in ~2 seconds) compared to much larger, fragmented architectures.

What Problem Does This Paper Address?

Current AI models for "doing everything" with images usually fall into two camps, both with flaws. Autoregressive (AR) models (like those based on LLMs) are great at following complex instructions but struggle with fine-grained visual details because they treat images as discrete tokens. Diffusion models excel at high-fidelity pixels but often lack deep semantic "understanding," leading to "hallucinations" where the model ignores parts of a prompt.

Furthermore, many "unified" models are actually "Frankenstein" architectures—they glue together a Vision-Language Model (VLM) for understanding and a Diffusion model for generation. This leads to redundant parameters, computational inefficiency, and "task interference," where learning to describe an image actually hurts the model's ability to generate one.

Methods

The authors propose UniAlignment, which unifies these tasks within a single DiT backbone using a dual-stream diffusion strategy:

  1. Continuous Stream: Handles image generation and manipulation using flow matching.
  2. Discrete Stream: Handles text-based understanding (like captioning) via masked token prediction.

To bridge the gap between these two streams, they introduce two novel alignment mechanisms:

  • Cross-modal Semantic Alignment: A contrastive loss function that forces the output embeddings of the image and text branches to be similar for matching pairs. This ensures the "generator" and the "understanders" are conceptually aligned.
  • Intrinsic-modal Semantic Alignment: The authors noticed that standard text encoders (T5) and image encoders (VAE) are trained independently and don't "talk" to each other well. They use a pretrained vision-language encoder (Qwen2.5-VL-7B) to provide "semantic targets" for the DiT’s intermediate layers, effectively teaching the model high-level visual-linguistic concepts during the denoising process.

The model is trained in a progressive multi-stage fashion, starting with massive image-text pairs and moving to multi-task joint training (editing, perception, etc.) to prevent "catastrophic forgetting."

Datasets

The model was trained on a mix of public and internal data:

  • Training: Text-to-Image 2M (Jacky Hate), 10M curated internal samples, and various specialized datasets for editing and perception (e.g., MagicBrush, GEdit-Bench).
  • Evaluation: Standard benchmarks like GenEval, DPG-Bench (for T2I), and MMB/MMMU (for understanding).
  • New Benchmark: The authors introduced SemGen-Bench, specifically designed to test models on complex, long-form instructions (200+ tokens) and multi-turn image editing. It categorizes tasks into T2I-Long, T2I-Sem, Edit-Multi, and Edit-Sem.

Key Insights and Ideas

  • Efficiency via Shared Weights: By using a single DiT for both generation and understanding, the model remains lightweight (2B parameters) while outperforming models with 7B or 12B parameters.
  • Solving the "Semantic Gap": The most important "aha moment" is that simply training on both tasks isn't enough; you need explicit alignment losses (Cross-modal and Intrinsic) to stop the different tasks from fighting each other for the model's "brain space."
  • Inference Speed: Because UniAlignment doesn't rely on a heavy VLM "connector" during inference, it is roughly 10x to 20x faster than competitors like UniWorld or OmniGen2, clocking in at 2 seconds per image.

Key Results

  • Text-to-Image: On the DPG-Bench (which tests dense prompts), UniAlignment scored 85.64, outperforming SD3-Medium (84.08) and OmniGen2 (83.57).
  • Image Editing: It achieved the highest "Semantic Consistency" score on GEdit-Bench, proving it follows editing instructions more faithfully than specialized editing models.
  • SemGen-Bench: In the authors' new, more difficult benchmark, UniAlignment consistently took the top spot in instruction consistency and perceptual quality, especially in the "Long-form" and "Multi-turn editing" categories.
  • Speed: UniAlignment generates images in 2 seconds, compared to 21 seconds for UniWorld-V1 and 37 seconds for OmniGen2.

Limitations and Future Work

While UniAlignment is highly efficient, the authors note that it is built upon the SD 3.0 backbone, inheriting some of its base characteristics. The paper does not extensively discuss its performance on video generation or extremely high-resolution tasks (beyond 512x512). Future work likely involves scaling the architecture to larger parameter counts to see if the "alignment" benefits continue to scale, and extending the unified framework to temporal data (video).

Summary updated

BibTeX
@inproceedings{song2026unialignment,
  author = {Xinyang Song and Libin Wang and Weining Wang and Shaozhen Liu and Dandan Zheng and Jingdong Chen and Qi Li and Zhenan Sun},
  title = {{UniAlignment: Semantic Alignment for Unified Image Generation, Understanding, Manipulation and Perception}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2026},
  doi = {10.1609/aaai.v40i11.37868},
}
Figure