Manuscript Offprint

arXiv:2610.03068

Where to Look Is Not How to Fix: Pre-Denoising Diagnostics and Modality-Dependent Control in Diffusion Composition

Fangzheng Wu, Brian Summa

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

Understanding compositional failures in text-to-image diffusion requires identifying both where stress is detectable and how intervention changes the output. We study these questions through a controlled anchor–stress protocol that jointly evaluates text-encoder diagnostics and denoiser interventions. We introduce a text-only Compositional Stress Index (CSI), which separates common from rare compositions across SD1.5, SDXL, and the SD3 text path and provides an upstream diagnostic coordinate. A matched six-prompt localization study links intervention location to distinct outcomes: residual-minimizing embedding adapters improve representation fit, while downstream cross-attention intervention increases color hit rate (CHR) by 0.0272. Across SD1.5 and SDXL denoiser blocks, the largest positive signed diagnostic-accessibility mean occurs at the deep encoder, whereas selective boost has its largest positive mean CHR response at decoder blocks. Selective subtraction and broad ablation reveal further modality- and architecture-dependent responses, including a substantial CHR decrease when SDXL decoder cross-attention is broadly ablated. We find a diagnosis-control dissociation under our controlled attribute-object composition setting: compositional defects are diagnosable before denoising, but the representation coordinate that exposes risk is not necessarily the coordinate or modality that improves generation.

1 Introduction

Text-to-image diffusion models [12, 26, 29] have achieved remarkable generation quality but remain brittle on semantically rare attribute–object compositions [14, 36]: a model that reliably generates “a red car” may fail on “a blue pizza” or “a glass cat,” producing the wrong color, material, or texture. Two threads of work address this. Inference-time methods—Attend-and-Excite [4], SynGen [28], StructureDiffusion [8], Divide-and-Bind [19], and attention-map-controlled synthesis [35]—modify denoiser cross-attention so that attribute tokens better bind to the correct object regions, typically aggregating corrections across all layers. A second line of work studies the upstream text-conditioning pathway, asking whether compositional failures originate in representation geometry [3, 17] or in misalignment between the embedding objective and the denoiser’s binding readout [22, 37]. Implicit in both threads is an assumption: the pipeline location where a compositional defect is most detectable is also the location where it is most effectively correctable. We test this relationship by comparing diagnostic readouts and intervention responses at distinct pipeline sites.

Our central finding is a site–modality dissociation: compositional stress has an upstream diagnostic signature, while intervention responses depend jointly on pipeline location and the type of edit. In the 40th Conference on Neural Information Processing Systems (NeurIPS 2026).

tested UNets, the deep encoder has the largest positive signed diagnostic-accessibility mean, whereas decoder blocks have the largest positive mean response to selective boost. This motivates treating diagnosis and intervention as distinct empirical questions: where to look is not how to fix.

To make this concrete, consider modern text-to-image diffusion pipelines [7, 26, 27, 29, 30]. A text encoder first produces conditioning embeddings, which are then consumed by a denoising backbone to guide generation. In the UNet-based Stable Diffusion family, including SD1.5 and SDXL [26, 29], these conditioning embeddings are injected through cross-attention layers distributed across encoder, middle, and decoder blocks [11, 29, 33]. This architecture provides multiple internal sites at which a compositional failure may be readable, and multiple sites at which an intervention may affect the output. We use this UNet hierarchy for our block-level localization experiments, while also testing the representation-side diagnostic on an additional non-UNet text-to-image pipeline, namely Stable Diffusion 3 [7]. Our question is therefore: at which sites can compositional failures be detected, and at which can they be fixed—and does detection at a site imply fixability there?

Table 1 maps this dissociation across three pipeline sites; rows correspond to sites, columns distinguish diagnostic readout from intervention outcomes. We present the evidence in two parts, corresponding to two regions of the pipeline.

Upstream: diagnosis and repair at the text encoder (Table 1, row 1). If a text encoder processes “a blue pizza” compositionally, the full-prompt representation should be roughly recoverable from the separate representations of “blue,” “pizza,” and the surrounding context. A large deviation from this component-based reconstruction indicates that the full prompt is not factorizing into its parts. We call this deviation a non-factorization residual and aggregate it into a Compositional Stress Index (CSI), where higher CSI indicates stronger departure from compositional factorization. Within a deliberately controlled anchor-stress setting that pairs common and rare attribute-object compositions while holding the object and context fixed, CSI separates the two groups perfectly (area under the receiver operating characteristic curve, ROC-AUC=1.0) across SD1.5, SDXL, and the SD3 text path, and provides a diagnostic coordinate for the subsequent intervention analyses. We use the text-only CSI component for the pre-denoising interpretation (Appendix B).

This diagnostic coordinate lets us examine how representation changes relate to output changes. We train low-rank adapters to move stress embeddings toward anchor-like structure and compare their responses with denoiser-side cross-attention intervention. The adapters improve representation fit. On a matched six-prompt localization subset, downstream intervention increases CHR by 0.0272, while embedding intervention decreases it. The comparison connects intervention location to distinct representation and image-level outcomes under the tested objectives ( §5§5).

Downstream: per-block modality decomposition inside the denoiser (Table 1, rows 2–3). This representation–output comparison motivates the downstream question: once text conditioning is read out by the denoiser, which internal sites are diagnostic, and which are causally controllable? For UNet-based SD1.5 and SDXL, we compare block groups spanning the deep encoder, middle block, and decoder, using three intervention modalities: selective boosting, selective zeroing, and broad cross-attention ablation. We quantify denoiser-side readout by diagnostic accessibility (DA), a block-level measure of how well cross-attention patterns separate anchor from stress prompts during baseline generation. The results reveal a second dissociation, now within the denoiser: D2 has the largest positive signed DA mean, while decoder blocks have the largest positive mean CHR response to selective boosting. Broad ablation produces a different, architecture-dependent profile, with a substantial CHR decrease at SDXL U0 and at early SD1.5 encoder blocks. These profiles characterize how intervention responses vary with both where an edit is applied and how it modifies cross-attention ( §6§6).

Contributions. (1) Under the tested intervention families, we uncover a diagnosis–control dissociation in text-to-image diffusion: the site where compositional stress is most readable is not necessarily the site where intervention is most effective. (2) We further decompose this dissociation under the tested intervention families, showing that selective token edits and broad cross-attention ablations have different site profiles across deep encoder and decoder blocks. (3) We introduce text-only CSI as a pre-denoising stress coordinate and evaluate it across SD1.5, SDXL, and the SD3 text path under the controlled anchor–stress protocol. (4) Under the tested intervention families, we connect representation and output responses through a matched localization study: residual-minimizing adapters

Table 1: Diagnostic readouts and observed intervention responses across pipeline sites. Entries summarize measured profiles rather than significance decisions; effect sizes, uncertainty, and statistical tests are reported in Sections 5–6. DA peaks refer to signed means.

Pipeline siteDiagnostic readoutTargeted editsBroad ablation
Text encoderResidual signalResidual reduction—
Deep encoderPositive DA peakSmall CHR changesArchitecture-dependent
DecoderSmaller signed DAPeak mean boost CESDXL U0: decrease

improve embedding fit, while downstream intervention increases CHR on the selected six-prompt subset.

References (35)