TL;DR
FUSED is a unified framework for detecting and localizing AI-generated image inpainting by dynamically balancing low-level forensic traces and high-level semantic context. By replacing rigid global image fusion with a token-level, sparsely-gated Mixture-of-Experts (MoE) architecture, FUSED achieves state-of-the-art generalization across unseen AI generators and remains robust even when global generator shortcuts are completely removed.
What Problem Does This Paper Address?
While fully synthetic AI image generation is easy to talk about, localized image manipulation—specifically AI-powered inpainting—poses a much stealthier threat. Inpainting models modify only a specific region of an image (e.g., adding, removing, or replacing an object) while leaving the surrounding authentic pixels intact.
Current forensic detectors suffer from two major flaws when tackling this problem:
- Over-reliance on global shortcuts: Many models cheat by latching onto global artifacts left by the generator across the entire image canvas, such as Variational Autoencoder (VAE) spectral traces. If an intervention removes these background artifacts, the performance of standard detectors collapses.
- Poor generalization: Low-level forensic features (like pixel noise or compression anomalies) localize edits well but fail to generalize to new, unseen AI generators. Conversely, high-level semantic features generalize well but lack the precision to pinpoint exactly where an edit occurred.
Prior attempts to combine these two types of evidence use a single, global blend for the entire image. FUSED addresses this gap by arguing that because inpainting is inherently local, the mixture of forensic and semantic evidence must be resolved adaptively, token by token.
Methods
FUSED (Forensic–Semantic Unified Sparse-Expert Detector) splits the processing labor into two distinct streams before combining them adaptively:
- The Forensic Branch: Uses a trainable SparseViT architecture. By restricting self-attention to sparse, non-adjacent token groups, it suppresses high-level semantic content and surfaces content-independent, low-level manipulation anomalies.
- The Semantic Branch: Uses a frozen CLIP-ConvNeXt-XXL model to extract stable, object-level context that remains invariant across different generative models.
- Token-Adaptive MoE Fusion: Instead of globally blending these features, FUSED flattens both streams into token sequences and passes them through a sparsely-gated Mixture-of-Experts (MoE) layer. For each individual token, a linear router selects the top $k=2$ most relevant experts (out of $E=8$ SwiGLU experts). This allows the model to dynamically prioritize forensic or semantic signals depending on the local image region.
- Segmentation Bridge: To ensure that localization requirements guide the fusion process, a convolutional decoder jointly processes the forensic map and the post-fusion semantic tokens to output the final pixel-level tampering mask.
The network is trained end-to-end using a multi-task loss combining classification, localization (BCE), edge-weighted boundary loss, MoE load-balancing, and a token diversity penalty.
Datasets
The authors evaluated FUSED across several rigorous cross-generator and out-of-distribution (OOD) benchmarks:
- OpenSDID: Trained solely on the Stable Diffusion 1.5 (SD1.5) split. Evaluated on in-domain (SD1.5) and four unseen generators: SD2.1, SDXL, SD3, and Flux.1.
- AutoSplice & CocoGlide: Held-out benchmarks utilizing pixel-space editors (DALL-E 2 and GLIDE) that do not introduce global latent-VAE artifacts, testing true localized anomaly detection.
- INP-X: A paired dataset (using Kandinsky 2.2, OpenJourney, and SD1.4) designed to isolate shortcut reliance by providing versions of images with the global VAE artifact present (INP) and completely stripped away (INP-X).
- So-Fake-Set & So-Fake-OOD: Used for large-scale multi-generator training and testing against contemporary commercial engines like GPT-4o and Ideogram 3.0.
Key Insights and Ideas
- Token-Level Adaptivity is Key: Global fusion applies the same weights to background pixels as it does to edited pixels. FUSED's region-adaptive MoE routing allows the model to alter its strategy dynamically across the image canvas (e.g., relying on semantics to understand object boundaries and forensics to spot synthesis artifacts).
- Defeating the VAE Shortcut: By forcing the model to succeed on pixel-space datasets where no global VAE trace exists, the authors prove that FUSED actually inspects the manipulated region itself rather than relying on global image-wide tells.
- Complementary Strengths: Ablation studies revealed that removing the frozen semantic branch caused the steepest drop in performance, proving that high-level context provides a vital anchor for cross-generator generalization.
Key Results
FUSED established a new state-of-the-art in both image-level detection and pixel-level localization:
- Unseen Generators: On the OpenSDID benchmark, FUSED achieved the highest average localization (44.5 IoU / 55.3 F1) and detection (88.0 F1), showing its largest performance margins on the most advanced, distant generators like Flux.1 and SD3.
- Zero-Shot Transfer: When transferred directly to AutoSplice, FUSED more than doubled the localization performance of previous methods, achieving a pixel F1 of 51.4 compared to the next best baseline (CAT-Net at 33.1).
- Robustness to Degradation: FUSED maintained its performance edge on unseen generators even when subjected to heavy post-processing like Gaussian blur and aggressive JPEG compression.
Limitations and Future Work
Despite its strengths, the authors highlight a few remaining challenges:
- Residual Shortcut Sensitivity: While FUSED handles artifact removal better than any baseline, its accuracy still drops by 12.5 points on the INP-X dataset when global VAE traces are removed, indicating it still partially relies on global shortcuts.
- The Small-Edit Challenge: Localization accuracy drops significantly when the inpainted region covers less than 2% of the total image area.
- Scope of Manipulation: This work focuses exclusively on generation-based inpainting. Extending token-adaptive MoE architectures to traditional image tampering techniques (like copy-move or splicing) remains an open avenue for future research.
Summary updated