Nested Attention: Semantic-aware Attention Values for Concept Personalization

Or Patashnik, Rinon Gal, Daniil Ostashev, Sergey Tulyakov, Kfir Aberman +1 more
1/2/2025
cs.CVcs.GRcs.LG

No official code found. Best implementation: snap-research/NestedAttention (25 stars, last commit 2025-08-04).

Abstract

Personalizing text-to-image models to generate images of specific subjects across diverse scenes and styles is a rapidly advancing field. Current approaches often face challenges in maintaining a balance between identity preservation and alignment with the input text prompt. Some methods rely on a single textual token to represent a subject, which limits expressiveness, while others employ richer representations but disrupt the model's prior, diminishing prompt alignment. In this work, we introduce Nested Attention, a novel mechanism that injects a rich and expressive image representation into the model's existing cross-attention layers. Our key idea is to generate query-dependent subject values, derived from nested attention layers that learn to select relevant subject features for each region in the generated image. We integrate these nested layers into an encoder-based personalization method, and show that they enable high identity preservation while adhering to input text prompts. Our approach is general and can be trained on various domains. Additionally, its prior preservation allows us to combine multiple personalized subjects from different domains in a single image.

View on arXivView PDF

Code Implementations(1)

Official implementation for "Nested Attention: Semantic-aware Attention Values for Concept Personalization" [SIGGRAPH 2025]

252CSS, HTMLJan 2, 20251 years ago

Similar Papers

Cite this paper

@article{patashnik2025nested,
  title  = {Nested Attention: Semantic-aware Attention Values for Concept Personalization},
  author = {Or Patashnik and Rinon Gal and Daniil Ostashev and Sergey Tulyakov and Kfir Aberman and Daniel Cohen-Or},
  year   = {2025},
  eprint = {2501.01407},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2501.01407v1}
}

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

Discussion