AI AOI Software · 2026-09-27

Capsule Multi-Defect Self-Training: Detection Rate & Leakage Reduction

DaoAI AI AOI software system's application in pharmaceutical capsule multi-defect self-training, achieving breakthroughs in high detection rates and low leakage rates.

Back to Insights
Capsule Multi-Defect Self-Training: Detection Rate & Leakage Reduction
AI AOI Software · DaoAI AI vision

DaoAI AI AOI software system (featuring visual foundation model for feature recognition, 5-minute 0-code automatic programming with one good sample, APDT positive/few-shot learning with 1-20 good samples, semantic false positive filtering, and SDK/API/Docker 100% on-premise private deployment) leverages its advanced visual foundation models and few-shot learning capabilities in pharmaceutical capsule production lines. It has reduced the leakage rate for various minor surface defects on capsules from a conventional 1.5% to below 0.3% in actual production line applications, while increasing the detection rate to over 99.7%, significantly improving product quality and compliance.

99.7%Detection Rate
<0.3%Leakage Rate
-90%False Positive Rate

The pharmaceutical manufacturing industry demands extremely stringent quality control, as even minor defects can compromise drug safety and efficacy, leading to severe compliance risks and market trust crises. Particularly in capsule production, various surface defects such as scratches, dents, deformations, color variations, and foreign objects can emerge at every stage from filling to packaging. Traditional inspection methods often rely on manual visual inspection or rule-based machine vision systems. However, faced with high-speed production lines and massive quantities of capsules, manual inspection is inefficient and prone to fatigue, leading to fluctuating detection rates. Traditional machine vision systems, on the other hand, require tedious programming and parameter adjustments for each defect pattern, and have limited ability to recognize diverse and minute deformations, making it difficult to achieve high-precision, low-leakage comprehensive coverage. In this context, efficient, accurate, and adaptive intelligent inspection of various capsule defects has become a key factor for pharmaceutical companies to enhance their core competitiveness.

Pain Points: Why This Hurdle Is Difficult to Overcome

In capsule multi-defect detection, pharmaceutical manufacturers face multiple challenges. Firstly, **high leakage rates** are common; traditional manual inspection on high-speed lines typically results in a leakage rate of 1.5% to 2.5% for subtle defects like micron-sized scratches or minor dents, severely impacting batch quality. Secondly, **false positive rates are high**, where traditional rule-based machine vision systems often misclassify normal capsule textures, reflections, or slight batch variations as defects. Production line data indicates that hundreds of capsules require manual re-inspection per hour, increasing labor costs and downtime. Furthermore, **lengthy changeover programming** is a major issue; when switching to different capsule colors, sizes, or dosages, traditional machine vision systems require hours or even days of reprogramming and parameter calibration, significantly slowing down production rhythm. Additionally, **defect types are diverse and difficult to enumerate**, with dozens or even hundreds of different defect forms possible during capsule production, some of which are highly similar, making effective differentiation and learning challenging for traditional methods. Echoing current industry trends, such as multi-model collaborative scheduling to improve inspection efficiency and accuracy in apparel manufacturing, capsule inspection also faces the challenge of effectively handling varied defect patterns, which traditional single-rule models struggle to address.

The root cause of these difficulties lies in the inherent characteristics of capsule products and the complexity of the inspection environment. Capsule surfaces are mostly curved, prone to reflections and shadows, posing challenges for image acquisition. Subtle differences in color and gloss between different capsule batches can increase background interference. Although pharmaceutical cleanroom environments are excellent, high-speed moving capsules may exhibit jitter during image capture, affecting image quality. Traditional rule-based AOI, relying on feature points, edge detection, or grayscale thresholds, struggles to adapt to this complex and variable environment and cannot learn generalizable defect patterns from a small number of defect samples. Manual visual inspection, limited by human eye resolution and fatigue over long working hours, cannot guarantee consistency and reliability.

Technical Principles

The DaoAI AI AOI software system fundamentally changes the paradigm of capsule defect detection through its unique technical architecture. Its core lies in the **feature recognition capability of its visual foundation model**. Unlike traditional AOI which relies on engineers to manually define feature extraction rules, the visual foundation model embedded in the micro-chain DaoAI AI AOI system, pre-trained on vast industrial image data, can automatically and deeply understand and extract semantic features from capsule images. Whether it's subtle scratches, irregular dents, or foreign particles, the model can identify them as meaningful 'anomaly' patterns. This general feature recognition capability allows the system to identify new defects that were not explicitly programmed, significantly enhancing the robustness of detection.

In practical applications, the DaoAI AI AOI software system employs an **APDT positive/few-shot learning mechanism**. This means that when switching production lines, only 1–20 high-quality good capsule images are needed, and the system can complete automatic programming and model training within 5 minutes. By learning from these good samples, the model can construct the feature distribution of 'normal' capsules, identifying any region deviating from this distribution as a defect. This contrasts sharply with traditional methods (e.g., rule-based AOI requiring complex rule writing for each defect type, or traditional deep learning needing thousands of defect samples for training). Furthermore, DaoAI AI AOI's **semantic false positive filtering function** can further distinguish between normal textures, reflections, and other 'non-defect' features from actual defects, significantly reducing the false positive rate. For instance, in one case, this system reduced false positives caused by reflections by 85%, effectively alleviating the burden of manual re-inspection. The DaoAI World model, serving as a unified foundation, further enhances this semantic understanding and cross-scenario generalization, ensuring stable model performance under different batches and lighting conditions.

Typical Application Scenarios

  • **Capsule Surface Scratch Detection:** The DaoAI AI AOI system accurately identifies micron-level scratches on capsules during production and transfer. The challenge lies in scratches often being tiny and similar to capsule surface textures, making traditional methods prone to leakage. The system distinguishes real damage from background noise through feature recognition.
  • **Capsule Dent and Deformation Detection:** For slight dents, flattening, or irregular deformations that may occur during capsule drying or encapsulation, the DaoAI AI AOI software system precisely judges based on local deformation features in the image. The difficulty is that these deformations are often irregular and vary in degree, making it hard for traditional threshold methods to set a unified standard.
  • **Capsule Color Difference and Foreign Object Detection:** Whether it's uneven capsule body color or tiny foreign objects (like fibers, dust) attached to the surface, DaoAI AI AOI can efficiently detect them. The challenge is that color differences can be very subtle, and foreign objects vary in shape. The system achieves this through pixel-level semantic analysis and color space modeling.
  • **Capsule Breakage and Leakage Detection:** For capsule integrity issues such as shell rupture or loose seams leading to powder leakage, the system identifies signs of edge integrity and powder spillage. The difficulty is that the amount of powder leakage can be minimal and breakage points hidden, requiring high-resolution images and fine feature extraction.
  • **Capsule Printing Defect Detection:** For batch numbers, specifications, and other printed content on the capsule surface, the system can detect defects such as blurry, missing, misaligned, or double-printed text. The challenge lies in the variety of fonts and sizes, and potentially low contrast with background colors. DaoAI AI AOI performs verification through character recognition and pattern matching.

Deployment Case

A mid-sized pharmaceutical plant, specializing in various capsule drug formulations, processes millions of capsules daily. Before integrating the DaoAI AI AOI software system, the plant primarily relied on manual visual inspection and some traditional rule-based AOI equipment for quality control. Production line data indicated that due to the wide variety of capsule types and complex defect patterns, the average leakage rate for manual inspection was around 1.8%, increasing during night shifts or periods of worker fatigue. Concurrently, traditional rule-based AOI had a high false positive rate of 8%–10%, requiring 3–4 skilled workers per shift to spend up to 4 hours on manual re-inspection, severely impacting production efficiency and labor costs. Furthermore, each product changeover required at least 5 hours for traditional AOI programming and debugging, leading to significant production downtime losses.

After the deployment of the DaoAI AI AOI software system, this pharmaceutical plant’s capsule multi-defect detection rate increased to over 99.7%, and the leakage rate was suppressed to below 0.3%, achieving a significant upgrade in quality control.

With the assistance of the DaoAI technical team, the plant deployed the DaoAI AI AOI software system via Docker containerization on its production line industrial PCs, ensuring 100% on-premise private deployment and data security. Initially, for several typical capsule types, only 10-20 good samples of each were provided, and the DaoAI AI AOI system completed model training within 5 minutes. Post-deployment, actual measurements showed that the system's detection rate for core defects such as scratches, dents, and color differences consistently exceeded 99.7%, far surpassing manual inspection levels. Simultaneously, through semantic false positive filtering, production line data indicated that the false positive rate was reduced by over 90%, drastically cutting down the need for manual re-inspection. The 4 hours of re-inspection work previously required per shift now only takes 30 minutes. This means that after the system's launch, the plant saved approximately 3.5 man-hours of re-inspection time per shift, potentially saving millions of RMB annually in labor costs. More importantly, product changeover time was reduced from 5 hours to less than 5 minutes, greatly enhancing the flexibility and efficiency of the production line.

DaoAI Solutions and Products

The core solution provided by DaoAI to this pharmaceutical plant is its AI AOI software system. This system is built upon its powerful **visual foundation model**, enabling deep feature understanding and pattern recognition for capsule images. In practical implementation, we first seamlessly integrated the DaoAI AI AOI software system into the customer's existing production line vision equipment and industrial control systems through flexible methods like SDK/API/Docker, ensuring 100% on-premise private deployment with no data leaving the factory. For self-training on various capsule defects, the DaoAI AI AOI software system employs a unique **APDT positive/few-shot learning strategy**. This means customers do not need to invest significant time and resources to collect and label vast numbers of defect samples; by simply providing a small number (1–20) of good product images, the system can quickly learn the 'normal' state and automatically identify any deviations from this normal pattern as defects. This 'learning from good' training model greatly simplifies the model deployment and maintenance process, allowing customers to respond quickly to market demands and flexibly adjust production plans.

During the model deployment and optimization phase, the DaoAI AI AOI software system also leverages its **semantic false positive filtering** capability to effectively distinguish between normal reflections, textural variations on the capsule surface, and actual defects, further improving detection accuracy and reducing the burden of manual re-inspection. Furthermore, we can combine the DaoAI World model to achieve deeper cross-scenario generalization and continuous learning, allowing the model to continuously iterate and optimize from feedback in actual production. The implementation of this solution not only significantly improved the customer's inspection efficiency and accuracy but also delivered tangible business value to the pharmaceutical company by substantially reducing leakage and false positive rates. This includes enhanced product quality compliance, reduced production costs, and shortened time-to-market for new products. For instance, through the DaoAI AI AOI software system, the pharmaceutical plant reduced its annualized manual re-inspection costs by millions of RMB, and its product qualification rate significantly improved, mitigating recall risks.

FAQ

How does the DaoAI AI AOI software system achieve high detection rates and low leakage rates in capsule defect inspection?

The DaoAI AI AOI software system achieves deep feature recognition of capsule images through its visual foundation model, capable of identifying minute and diverse defects. Combined with APDT few-shot learning, it requires only a small number of good samples to quickly train the model. Furthermore, semantic false positive filtering accurately distinguishes real defects from background noise, thereby increasing the detection rate to over 99.7% and reducing the leakage rate to below 0.3%.

What deployment options does the DaoAI AI AOI software system support, and how is data security ensured?

The DaoAI AI AOI software system supports various flexible deployment methods, including SDK/API/Docker, enabling 100% on-premise private deployment. This means all inspection data and model training processes occur on the customer's local servers, with data never leaving the factory. This strictly adheres to the compliance requirements of the pharmaceutical industry, ensuring the highest level of data security and privacy protection.

What initial investment is required to deploy the DaoAI AI AOI software system, and how can cost-effectiveness be evaluated?

The initial investment for deploying the DaoAI AI AOI software system primarily depends on the customer's existing hardware configuration, integration requirements, and desired inspection functionalities. Cost-effectiveness should be evaluated by considering multiple dimensions, such as labor cost savings (e.g., reduced re-inspection hours), improved product quality (e.g., reduced recall risks due to lower leakage rates), and increased production efficiency (e.g., shortened changeover times). We recommend scheduling an expert consultation to receive a customized solution and detailed cost-benefit analysis.

Related Cases

Full solution for this scenario: the full inspection solution for AI AOI Software

This article was generated by AI. Customer cases are simulated scenarios based on real product capabilities and figures are illustrative; see product pages for official benchmarks.

Book a Demo / Get a Quote View AI AOI Software solutions