Accelerating New Product Introduction for Visual Quality Inspection via Few-Shot Diffusion-Based Defect Synthesis
Serkan Hamdi Güğül, BS, Kemal Levi, PhD, Burak Acar, PhD · 2026
Read Accelerating New Product Introduction for Visual Quality Inspection via Few-Shot Diffusion-Based Defect Synthesis by Serkan Hamdi Güğül, BS, Kemal Levi, PhD, Burak Acar, PhD (2026) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2604-22850.txt.
Introduction
Güğül, Levi, and Acar present a few-shot generative framework that synthesizes defect images for factory visual inspection when new products arrive with almost no labeled defects. It separates defect shape from background look, learning defects by masked textual inversion, generating surface-aware examples, and blending them seamlessly. Synthetic data lifts detection accuracy in few-shot tests and sharply closes the gap when defects transfer to a new surface with no real target examples.
Catalog record
| CREATOR | Serkan Hamdi Güğül, BS, Kemal Levi, PhD, Burak Acar, PhD |
|---|---|
| YEAR | 2026 |
| COLLECTION | PAPERS |
| FORMAT | TXT |
| FILE SIZE | 28589 |
| LICENSE | http://creativecommons.org/licenses/by/4.0/ |
| RIGHTS | CC BY |
| SOURCE | arXiv |
Source: https://arxiv.org/abs/2604.22850
Browse the full library · About the Tower of Babel
Full text
The opening of the work, from the library's hosted text:
Accelerating New Product Introduction for Visual Quality Inspection via Few-Shot Diffusion-Based Defect Synthesis Serkan Hamdi Güğül, BS, Kemal Levi, PhD, Burak Acar, PhD Abstract Industrial visual inspection systems often suffer from a severe scarcity of labeled defect data, particularly during the early stages of New Product Introduction (NPI). This limitation hinders the deployment of robust supervised detectors precisely when automated quality control is most needed. We present an end-to-end generative framework for high-fidelity, few-shot defect synthesis that enables both in-domain augmentation and cross-domain transfer. Our approach disentangles defect morphology from background appearance by combining masked textual inversion for defect representation learning, noise-blended conditioned generation for surface-aware synthesis, and gradient-aware post-processing for seamless visual integration. We evaluate the framework in two practically relevant settings: few-shot data augmentation, where synthetic samples enrich a small set of real defects, and zero-shot adaptation, where defects learned from a source domain are transferred to a novel target surface without any real target-domain defect examples. Using RF-DETR as the downstream detector, we show that the proposed pipeline substantially narrows the domain gap on a private industrial dataset. In the few-shot setting, synthetic augmentation improves mAP from 78.8% to 83.3%. In the zero-shot setting, synthetic domain adaptation improves mAP from 65.0% to 85.1%. These results demonstrate that high-fidelity defect synthesis can meaningfully accelerate NPI by enabling effective inspection models before sufficient real defect data has been collected. Keywords Zero-Shot Domain Adaptation, Generative AI, Industrial Quality Control, Few-Shot Learning 1 Introduction The performance of modern computer vision systems depends heavily on the availability of large, diverse, and well-annotated datasets. While such datasets are common in general-purpose recognition problems, industrial quality inspection remains constrained by a persistent rare-event problem: the defects of greatest operational importance are, by definition, infrequent. Hairline scratches, punctures, folds, and related manufacturing anomalies may occur too rarely to support conventional supervised learning pipelines, especially during the early stages of a new production program. As a result, manufacturers often face a critical gap between the need for immediate inspection capability and the delayed availability of representative defect data. This challenge is particularly acute during New Product Introduction (NPI), where automated inspection systems are expected to operate under severe data scarcity. In such settings, standard augmentation strategies offer only limited benefit because they do not reproduce the structural and textural variability of real defects. What is needed is not merely more data, but realistic, task-relevant defect variation that preserves local morphology while adapting naturally to novel surfaces. Recent progress in generative modeling has opened a promising path toward this objective. Foundation models and diffusion-based generative methods have shown that synthetic data can enrich downstream learning; notably, Azizi et al. [ 2 ] demonstrated that augmenting real training sets with synthetic samples increased ResNet-50 [ 6 ] accuracy from 76.8% to 79.3% on ImageNet. While similar gains have been reported across various data-scarce environments [ 7 , 17 ] , more recent methods have adapted diffusion models for semantic editing, anomaly synthesis, and few-shot personalization [ 18 , 4 , 13 , 10 ] . However, industrial inspection imposes stricter requirements than generic image generation. In addition to visual plausibility, useful synthetic defects must exhibit accurate local structure, limited background leakage, and strong compatibility with diverse target materials and lighting conditions. To address these requirements, we present an end-to-end, example-driven generative pipeline for few-shot defect synthesis in industrial inspection. Our approach leverages latent diffusion models to separate the structural appearance of a defect from its original background, enabling realistic transfer to new surfaces using only three to five annotated reference examples. Specifically, we employ masked textual inversion to learn compact defect representations while suppressing background leakage, a noise-blending reverse diffusion process to generate defects conditioned on defect-free target surfaces, and a post-processing stage that aligns color, illumination, and local gradients to improve physical plausibility. The proposed framework is designed to support two deployment scenarios of high practical importance. In the first, synthetic images are used to augment a limited set of real defect samples in a few-shot regime. In the second, defect concepts learned from an existing source domain are transferred to a new target surface in a zero-shot setting, where no real target-domain defect samples are yet available. These settings directly reflect the operational needs of manufacturers seeking to reduce inspection latency during product launches and process transitions. Our contributions are threefold: • We introduce a unified generative pipeline tailored to industrial visual inspection that supports high-fidelity learning and synthesis of localized defects with minimal background contamination. • We demonstrate that the resulting synthetic data improves downstream defect detection in both few-shot and zero-shot settings, yielding substantial gains on a private industrial dataset. • We show that the framework is lightweight enough to support localized deployment on standard industrial workstations, making it relevant not only as a research concept but also as a practical tool for accelerating NPI. The remainder of the manuscript is organized as follows. Section 2 reviews the theoretical foundations of diffusion models and personalization methods. Section 3 describes the proposed generative pipeline. Sections 4 and 5 present qualitative and quantitative evaluations, respectively. Section 6 concludes with implications, limitations, and directions for future work. 2 Preliminaries 2.1 Latent Diffusion Models (LDMs) Early image generation attempts primarily utilized Generative Adversarial Networks (GANs) [ 5 ] and Variational Autoencoders (VAEs) [ 11 ] , which often faced trade-offs between training stability and high-frequency detail. To overcome the inherent trade-offs between training stability in GANs and sample fidelity in VAEs, Denoising Diffusion Probabilistic Models (DDPMs) [ 8 ] reframe image generation as an iterative denoising process. However, because DDPMs operate directly in pixel space, they remain computationally prohibitive for high resolution industrial textures. Our pipeline utilizes Latent Diffusion Models (LDMs) [ 15 ] , which perform the diffusion process within the compressed, lower dimensional latent space of a pretrained autoencoder. Given an encoder \mathcal{E} and decoder \mathcal{D} , the model operates on latents z=\mathcal{E}(x) , minimizing a denoising loss \mathcal{L}_{LDM} conditioned on a text prompt y via a cross-attention mechanism \tau_{\theta}(y) : \mathcal{L}_{LDM}=\mathbb{E}_{z,y,\epsilon,t}[\|\epsilon-\epsilon_{\theta}(z_{t},t,\tau_{\theta}(y))\|^{2}] (1) By shifting the computation to the latent space, we achieve a high fidelity synthesis engine that remains compatible with localized industrial workstations without requiring server-grade infrastructure. 2.2 Personalization Methods To steer the extensive prior knowledge of large-scale pre-trained models, personalization techniques learn novel concepts from a small reference set. Strategies like DreamBooth [ 16 ] fine-tune the entire network weights, while Low-Rank Adaptation (LoRA) [ 9 ] injects trainable low-rank decomposition matrices into the architecture. In this work, we adopt Textual Inversion [ 4 ] for its extreme modularity and structural fidelity. By optimizing a new word embedding v^{*} in the text encoder’s continuous space while keeping the generative model frozen, we reconstruct the reference images by minimizing: v^{*}=\arg\min_{v}\mathbb{E}_{z,\epsilon,t}[\|\epsilon-\epsilon_{\theta}(z_{t},t,\tau_{\theta}(S_{*}(v)))\|^{2}] (2) This allows our framework to represent unique defects as compact files (only takes a few KBs). This makes it possible to store and deploy many different defect types instantly without the storage overhead of duplicating large model weights. Crucially, synthetic images generated via this method preserve the subtle morphological features of the original real samples, making them highly effective for training downstream models for tasks such as defect detection. 2.3 Localized Defect Synthesis