A pharmaceutical inspector stands over a light table for eight hours and looks at pills. The batch is 200,000 tablets. Even at 99% attention, that's 2,000 units where the eye slipped. A chip on the edge that the coating hides. A hairline crack in a bilayer tablet that reads as the natural interface. A capsule with a translucent shell where the fill looks fine from one angle and hollow from another. And in the middle of it all, rule-based vision systems force pharma QA into an impossible choice: crank sensitivity up and destroy yield with false rejects, or ease it back and let borderline defects into the accepted stream. Both outcomes end the same way — a batch that either shouldn't have passed, or one that cost the company its margin. AI vision changes this trade-off entirely. Deep learning models trained on your specific tablet or capsule learn the difference between a natural coating gradient and a discoloration defect, between a bilayer interface and a hairline crack, between an engraved logo and a surface chip — and they do it at 300,000 tablets per hour with detection accuracy that exceeds manual inspection. iFactory Vision Defect Detection runs on your line, 100% inspection, every unit, every shift.
iFactory Vision Defect Detection
100% Tablet & Capsule Inspection at Line Speed — No More Sensitivity Trade-Off
Deep learning defect detection for chips, cracks, discoloration, dimensional deviations, print defects, and contamination. GMP-validated, PQ-supported, and trained on your product — not a generic library.
300K
tablets/hour throughput
100%
inspection, every unit
The Defect Catalog — What AI Vision Actually Catches
Oral solid dosage defects fall into six categories, each with its own visual signature. Rule-based systems handle some well and others badly. Deep learning handles all six — including the ones that used to require a human inspector's judgement call.
Category 01
Chips & Broken Edges
Missing corners on shaped tablets, edge chipping on coated tablets, half-grain and quarter-grain fragments, spalling along the score line
Deep learning distinguishes edge chips from natural bevels and manufactured grooves.
Category 02
Cracks & Splits
Capping cracks, lamination in bilayer tablets, hairline cracks under film coating, capsule shell splits, cap-body separation
Trained models tell a bilayer interface line apart from a genuine crack — where rules fail.
Category 03
Discoloration & Coating
Color non-uniformity, speckling, patchy coating, gloss variation, side stain, black spots, mottling on translucent shells
Learns your product's normal color envelope — no ambient-light drift false rejects.
Category 04
Dimensional Defects
Diameter deviation, thickness variation, weight-linked height drift, capsule length variance, deformed shapes, malformed units
Sub-millimeter measurement per unit — trended against your validated specification.
Category 05
Print & Engraving
Missing print, printing bleed, poor engraving, misregistered logos, illegible identification, VCR character mismatch
OCR + deep learning on curved surfaces — reads legibility on round tablets reliably.
Category 06
Contamination & Foreign Objects
Foreign object adhesion, cross-contamination units, mixed tablets from prior campaign, hair or fiber inclusion, coating drop residue
Highest patient-safety category. Anomaly detection flags anything outside learned normal.
The Sensitivity Trade-Off — Why Rule-Based Vision Fails Pharma
Every QA director has faced this graph. Turn sensitivity up on rule-based vision and the false reject rate climbs — sometimes to 1–2% on high-value formulations, destroying yield on batches worth millions. Turn it down and defects slip through. Deep learning breaks the curve entirely.
High sensitivity
Rule-Based, Cranked Up
Protects patient safety but destroys margin on high-value formulations. Millions of good units rejected per year.
Low sensitivity
Rule-Based, Eased Off
Yield restored but borderline chips, faint discoloration, and hairline cracks pass through to packaging.
Deep learning
iFactory AI Vision
Defects caught
Comprehensive
Model learns your product. Both patient safety and yield protected — no forced compromise.
The Inspection Pipeline — From Tablet on Belt to Reject Bin
This is what actually happens between the discharge chute and the packaging line. Each stage takes milliseconds. The full loop — image, classify, decide, reject — completes before the next tablet enters the frame.
01
Feed & Orient
Vibratory feeder singulates units onto inspection belt. No fixturing needed — the model handles random orientation.
02
Multi-Angle Imaging
4–6 camera views capture top, bottom, and side surfaces simultaneously. Backlighting for translucent capsules, diffuse for coated tablets.
03
Deep Learning Classify
Edge AI server runs CNN + anomaly detection per image set. Classification into good, defective, or uncertain — with defect category tag.
04
Reject Actuator
Air-blast or diverter fires on defect classification. Reject confirmed downstream by beam sensor for audit trail.
05
Batch Record + Trend
Every image archived with unit ID, defect class, timestamp. SPC on defect rate per batch. Full 21 CFR Part 11 audit trail.
Want to see your specific formulation running on iFactory Vision? Book a demo — bring 500 units and we'll train a pilot model in the session.
Why Deep Learning Wins on These Product Types
Certain formulations break rule-based vision entirely. Deep learning wins because it doesn't need pixel rules — it learns the pattern of "normal" for your product and flags what doesn't fit. These four product classes are where the difference is most visible.
Film-Coated Tablets
Coating gradients mimic defect signatures
Model learns natural gradient envelope. Only true coating imperfections flagged — not manufacturing gloss variation.
Bilayer Tablets
Interface lines read as cracks in rules
Trained to distinguish the intended layer boundary from lamination cracks and capping. Both layers assessed independently.
Soft Gel Capsules
Translucent shells hide fill anomalies
Segmentation model separates shell, fill, and background. Under-fill, air bubbles, and shell defects detected independently.
Modified-Release Tablets
Deliberate surface features hit thresholds
Learned features preserved. Only unintended defects flagged. Score lines, engravings, and coating windows recognized as normal.
GMP Validation — What iFactory Delivers Out of the Box
Pharma vision systems don't just have to work — they have to pass qualification. Every deployment ships with the validation package your QA and regulatory affairs teams need to file: URS, FS, DS, IQ, OQ, and full PQ challenge testing protocols.
URS / FS / DS
Requirements & Specification
User Requirements, Functional Spec, and Design Spec documents co-authored with your validation lead. Traceability matrix to acceptance criteria included.
IQ
Installation Qualification
Hardware install verified against DS. Serial numbers, calibration certificates, network topology, and power documentation captured.
OQ
Operational Qualification
System function verified across full parameter range. Alarm response, reject actuation, image capture rate, and user access controls tested and documented.
PQ
Performance Qualification
Challenge testing with artificially defected units at defined type, size, and frequency. Validates detection at or above specification across full throughput range.
The Business Case — What This Actually Delivers
Deep learning vision changes three numbers that show up on QA and Ops dashboards. Batch yield goes up because false rejects come down. Complaint rates fall because true defects don't slip through. And the release cycle shortens because 100% inspection with audit trail replaces sampled inspection with paper QA.
100%
Inspection coverage
every unit, every shift
<0.1%
False reject rate
from 1-2% baseline
21 CFR
Part 11 compliant
audit trail per unit
6-12
Week deployment
turnkey, PQ-supported
Ask the Vision AI on the OSD Line
QA Manager
Why did we see a spike in edge chip rejects on the 2 pm run of Product A?
iFactory Vision AI
Edge chip defects rose from 0.08% baseline to 0.42% between 14:12 and 14:47. All chips concentrated on the right shoulder of the tablet — signature matches punch tip wear on station 6 of the press. Recommend punch inspection at next changeover.
QA Manager
Send the defect gallery for the batch record.
iFactory Vision AI
Batch record generated with 847 defect images classified by category, unit-level audit trail, and PQ-linked acceptance criteria. Attached to lot B24-1109 in your DMS. Ready for QA release review.
Frequently Asked Questions
How is deep learning different from the vision system we already have?
Existing vision systems typically run on rules — pixel intensity thresholds, edge detection, blob analysis. Rules work when defects are visually simple and consistent. They fail on subtle defects like faint discoloration, coating gradients, bilayer interface lines, and print quality on curved surfaces. Deep learning trains on your actual product images and learns the pattern of "normal" plus each defect category — including the ones you'd previously call by hand. It runs alongside your existing system if needed, or replaces it entirely.
How many defect samples do we need to train the model?
For most product categories we start with 300–500 good units and 50–100 defect samples per category to build a working pilot model. Anomaly detection augments this — the model can flag units that don't match the normal pattern even without labeled examples. Continuous learning means as new defects appear on the line, they get added to the training set and the model improves. Full validation-grade models typically use 2,000–5,000 images per defect category.
Will this meet FDA and EMA validation requirements?
Yes. Every deployment includes the full validation package — URS, FS, DS, IQ, OQ, and PQ challenge testing with artificially defected units at defined type, size, and frequency. 21 CFR Part 11 compliance is built into the audit trail, user access controls, and electronic signature workflow. Our validation engineers work directly with your QA and regulatory affairs teams from URS through PQ approval. The system is GMP-compatible for both Annex 11 (EU) and Part 11 (US) environments.
What happens when we change the product formulation or introduce a new SKU?
New products get a new model. For minor formulation changes — coating color adjustment, print pattern update — we typically retrain the existing model with a smaller update batch and revalidate through a delta PQ. For entirely new SKUs, a fresh pilot model runs in weeks 1–3, followed by qualification runs and full PQ. The platform is designed for pharma product-change workflows — the AI is the tool, but the SOPs and change control wrap it just like any other qualified equipment.
What throughput can the system handle?
Up to 300,000 tablets per hour on a single line with multi-camera imaging. Capsule lines typically run 200,000–250,000 per hour depending on shape and orientation complexity. Blister-pack inspection runs at the packaging line speed — usually 400 packs per minute for a 10-pocket format. Edge AI hardware is sized for your specific throughput; no cloud dependency means no latency, and no batch record data leaves the plant unless you route it out deliberately.
Can we start with one product line before rolling out plant-wide?
Yes — pilots are the standard first step. Pick your highest-value product or the SKU with the worst rework/complaint history. We instrument that line, train the pilot model in weeks 4–8, run parallel operation against your existing inspection for baseline comparison, and finalize PQ by week 12. You get a documented per-SKU ROI before scaling. Adding subsequent lines is faster because the imaging, edge AI, and MES integration stacks are already validated.
Break the sensitivity trade-off.
See AI Vision Running on Your Own Tablet or Capsule
Bring 500 units of your highest-value product to the demo. We'll train a pilot model in the session, run live inspection against it, and show you the defect gallery, false reject profile, and batch record output your QA team would sign off on. Then we'll walk through the URS-to-PQ validation path — the same path we've run with pharma manufacturers on chip, crack, coating, dimensional, print, and contamination inspection.