REPA-G: Test-Time Conditioning with Representation-Aligned Visual Features
Diffusion transformers trained with representation alignment (REPA) learn internal features that live in a DINOv2-like space. REPA-G uses that space at inference: pick feature tokens from any image, and steer the denoising toward them, with no additional parameters and no additional training.
While representation alignment with self-supervised models has been shown to improve diffusion model training, its potential for enhancing inference-time conditioning remains largely unexplored. We introduce Representation-Aligned Guidance (REPA-G), a framework that leverages these aligned representations, with rich semantic properties, to enable test-time conditioning from features in generation. By optimizing a similarity objective (the potential) at inference, we steer the denoising process toward a conditioned representation extracted from a pre-trained feature extractor.
Our method provides versatile control at multiple levels of granularity, ranging from patch-level matching via single patches to broad semantic guidance using global image feature tokens. We further extend this to multi-concept composition, allowing for the faithful combination of distinct concepts. REPA-G operates entirely at inference time with no additional training required, offering a flexible and precise alternative to often ambiguous text prompts or coarse class labels. Our approach achieves high-quality, diverse generations on ImageNet and COCO.
Representation-aligned guidance
REPA trains a flow model so that its layer-8 features, after a small projection, match a frozen encoder (DINOv2). At inference, REPA-G turns that alignment into a guidance signal: it measures how well the current features match the target tokens extracted from an anchor image, and adds the gradient of this potential to the score.
Conditioning granularity
The potential compares generated features with the anchor's features. We can condition on the full feature map, on a subset of it (a mask), or on its average, and this choice decides what the sample inherits from the anchor. Pick a mode to see which conditioning tokens are used and what the model generates.

Full feature map
For visualization only.
Properties of the representation space
Feature guidance needs two things: nearby embeddings must mean similar things, and similar embeddings must yield similar conditional densities. A vanilla SiT has neither. A REPA-trained SiT has both, before and after its projection head.
Euclidean embedding and feature interpolation
Single-source conditioning
REPA-G reads the model's own internal features, so they must be semantically organized. A SiT trained with the diffusion loss alone lacks such features: guidance degrades its samples. REPA and REPA-E obtain them through the alignment loss. REPA-G is not tied to REPA: it transfers directly to Self-Flow, which learns semantic features with a self-supervised teacher–student objective and no REPA loss.
Generalization beyond REPA-style models
Self-Flow never sees a REPA loss or an external encoder during training: a student predicts the representations of a teacher that receives a less noisy input. Its internal features end up semantic and robust to noise, and that is all REPA-G needs. Full-map guidance on Self-Flow brings FID from 35.51 to 5.49 with a DINOv2 similarity of 0.72 to the anchor, without changing anything in the method.
Multi-source composition
Two potentials are summed at every step: one on the anchor's full feature map, and a term pulling some patches toward a single background token. With selective patch alignment, the soft-max lets the model choose where the background goes.
Baselines, guidance scale and runtime
Comparison with TFG and IP-Adapter
TFG, adapted to feature guidance with DINOv2 as target predictor, must decode a clean estimate and backpropagate through the decoder, DINOv2 and the whole transformer; its samples carry heavy artefacts (FID 75–86). An IP-Adapter trained for 100k steps on REPA-E follows the anchor but keeps its layout less precisely and adds about 150M parameters.
Effect of the guidance scale
Runtime
Limitations
Strongly conflicting conditions remain hard: incompatible viewpoints or aspect ratios produce implausible blends, one source can dominate, and multi-source composition may need per-term tuning of λ. REPA-G also does not take structural inputs such as depth maps, edges or poses.
BibTeX
@inproceedings{sereyjol2026repag,
title = {{REPA-G}: Test-Time Conditioning with Representation-Aligned Visual Features},
author = {Sereyjol-Garros, Nicolas and Kirby, Ellington and Letzelter, Victor and Besnier, Victor and Samet, Nermin},
booktitle = {Advances in Neural Information Processing Systems (NeurIPS)},
year = {2026}
}
Acknowledgements: we acknowledge EuroHPC Joint Undertaking for awarding the project ID EHPC-REG-2024R02-234 access to Karolina, Czech Republic. The code builds on REPA-E and the ADM evaluation suite.








