Article sections
What is a vision foundation model?Do not confuse the model family with the task outputHow does CLIP work?What are DINO and DINOv3 used for?Differences between SAM 2, SAM 3, and SAM 3.1What is promptable segmentation?Grounding DINO and open-vocabulary detectionChoosing between zero-shot, few-shot, and fine-tuningLimitations of visual question answering with VLMsFoundation model licensing and data privacyLatency, hardware, and low-memory operationHow should prompt and description stability be tested?Numerical example: the true cost of an off-the-shelf modelA brief comparison of model familiesHybrid architectures combining foundation and task-specific modelsPrompt stability and version managementEvaluating zero-shot performance correctlyData privacy, edge deployment, and audit trailsProblems encountered when customizing through fine-tuningThe final engineering framework for choosing a model familyFrequently asked questionsImage sourcesSAM 2/3/3.1, DINOv3, CLIP, Grounding DINO, zero-shot, and vision-language models; limitations in industrial use. This guide considers the assumptions behind each method, the conditions under which it can be used, reasons for failure, and practical decision points in the field.
What is a vision foundation model?
Short answer: A foundation model for vision (vision foundation model) is a family of models pretrained on large-scale, usually highly diverse data that can be transferred to classification, retrieval, segmentation, or other visual tasks. CLIP brings text and image representations into a shared space for comparison; DINOv3 produces self-supervised visual features; and the SAM family focuses on object segmentation using prompts. These models do not perform the same task, and none of their outputs should automatically be treated as a correct quality decision on a production line.
It is tempting to show a photograph of a metal part and ask, 'Is there a scratch?' However, this question assumes that the model inherently knows the defect's physical definition, tolerance, and visual detectability. Foundation models can offer strong pretraining and flexible use, but their suitability under real field conditions must be demonstrated through dedicated tests.
Do not confuse the model family with the task output
The core idea behind using CLIP is to compare the similarity between images and text descriptions. The strength of a model such as DINOv3 lies in extracting transferable features from images. SAM 2 uses prompts to select objects through masks in images and video; SAM 3 offers an approach to finding and segmenting matching objects using short textual concepts and visual examples as well. Newer versions such as SAM 3.1 include refinements aimed at video tracking efficiency.
It is incorrect to present all of these as 'AI understands everything in an image.' CLIP similarity does not give the width of a specific defect in millimeters. A SAM mask does not automatically know the quality acceptance boundary for a defect. A DINOv3 representation should not be expected to produce an accept/reject decision directly without a task head built on top of it. The technical output of each model must be explicitly defined.
How does CLIP work?
CLIP is known for learning proximity between visual and language representations using images and their associated text. The embeddings of an image and several text descriptions can be compared, and the description with the highest similarity can be selected. This approach enables classification-like predictions for certain class lists without additional supervised training.
However, a CLIP score is generally not a directly calibrated probability of a defect. The choice of wording can change the result. For example, related descriptions such as 'damaged metal,' 'shiny metal,' 'scratched surface,' and 'normal machining mark' can produce different similarity rankings. This is a limitation of the open-ended representation-matching objective rather than simply a misunderstanding of the physical defect.
What are DINO and DINOv3 used for?
The DINO family stands out for its approach to visual representation learning. DINOv3 aims to produce detailed, transferable visual features through large-scale self-supervised training. These features can be used in classification heads, dense prediction tasks, or similarity-based systems. Leveraging strong pretraining is particularly important from an engineering perspective when labeled data is scarce.
Nevertheless, the quality of a transferable representation must be tested in the target domain. Images involving different material reflections, very small defects in high-resolution imagery, monochrome sensors, or different wavelengths may differ substantially from general visual pretraining data. 'DINOv3 eliminates the need for fine-tuning' is not a universal rule: a small adapter may suffice for some targets, while others require extensive fine-tuning.
Differences between SAM 2, SAM 3, and SAM 3.1
SAM 2 supports selecting an object in an image using prompts such as points, boxes, or masks, and tracking the same object with a mask throughout a video. SAM 3 extends the ability to find, segment, and track all instances of a concept defined in text. As of 2026, SAM 3.1 is a newer member of the family, offering updates to processing efficiency, particularly for multi-object tracking. The weights, API, and licensing terms of the version to be used must be verified separately.
This evolution does not mean 'unlimited production inspection with zero data.' Providing the text prompt 'screw' may be easy, but the system must separately check whether every screw is in the correct mounting location. Even if a segmentation mask looks correct, it does not determine the physical tolerance for a repairable defect.
What is promptable segmentation?
Promptable segmentation generates a mask using cues supplied by a user or another system. These prompts can be a point, a box, an example object, or a text description. This allows the model to be used without conventional fully labeled training for every new object category. In annotation workflows in particular, it can make it easy for an operator to isolate an object.
However, the more ambiguous the prompt, the more ambiguous the output may be. The concept 'scratch' can be confused with a polishing mark. The prompt 'metal part' may produce a single mask for two overlapping parts. If a mask output is needed for production, the reference object to be indicated and the expected mask boundary must be defined beforehand.

Grounding DINO and open-vocabulary detection
Grounding DINO is an open-vocabulary detection approach that aims to locate objects in an image based on language input. For example, it can help search for objects using phrases such as 'metal bolt' or 'red cap' without being tied to a predefined fixed class list. This provides flexibility in data collection and prototyping.
However, linguistic similarity is not production accuracy. The phrase 'red ring' may also match a metal surface with a reddish reflection. Even when an object's geometric location is found correctly, its identity as the correct part number must be verified separately. In applications where false positives are costly, open-vocabulary output should be compared with a supervised model specialized for the domain and rule-based checks.
Choosing between zero-shot, few-shot, and fine-tuning
A zero-shot scenario uses pretraining without directly labeled examples for the target task. Few-shot adaptation uses a small number of target labels or examples. Fine-tuning updates model weights with new data; it can use lightweight adapters or full weight updates. The choice depends not only on the amount of data, but also on licensing, latency, labeling cost, and acceptance risk.
For example, promptable segmentation may be suitable for helping a quality specialist quickly generate sample masks. But if those masks are expected to support millimeter-level measurements, consistent labels, calibration, and task-specific model tuning may be needed. An interactive annotation tool is not the same as a fully automated quality control system.
Limitations of visual question answering with VLMs
Vision-language models (VLMs) can interpret images and text together. Possible production applications include describing product photographs, reviewing incidents, or generating helpful notes for operators. However, a model's ability to write a fluent explanation does not mean that it correctly counts small defects or extracts accurate measurements. Numerical results, particularly for critical tolerance checks, must come from the measurement system.
A vision-language model may hallucinate objects, count incorrectly, or describe an invisible component as present. In such cases, the model's response must not be connected directly to a production sorting command. Defined uncertainty handling, a verification layer, and human oversight when needed are required.
Foundation model licensing and data privacy
The license for model weights, the software code license, and the terms of use for training data are not the same thing. Some models can be used in commercial products, while others may impose additional conditions. When processing through a cloud API, sending production images to an external service has data privacy and contractual implications. Exporting images from a restricted-access factory may violate corporate policy even when it is technically possible.
The license version must be recorded when selecting a model. New weights for a popular model may be released under a different license. A very large foundation model can also increase local hardware costs. The claim that 'an off-the-shelf model eliminates training costs' fails to account for inference, adaptation, and maintenance costs.
Latency, hardware, and low-memory operation
Running a large backbone at full resolution on every frame may fail to keep up with line speed. A hybrid system can be designed if the task only requires a specific region or less frequent reanalysis. For example, a fast classical algorithm can locate the product, while the foundation model is invoked only for uncertain examples. This can reduce overall inference costs, but the latency and error probability of the two-stage decision must be measured separately.
Quantization, model partitioning, and lighter adapters may help. However, these operations can affect output scores and, in particular, fine mask details. The reduced model must undergo the same quality acceptance process as the original. In production, the most important measures are not FLOPs alone, but p95/p99 end-to-end latency on the actual device and the duration of stable operation.
How should prompt and description stability be tested?
Results can be compared using different synonymous prompts for the same object. Text such as 'bolt,' 'screw,' and 'metal fastener' may target the same physical object, yet the model's output can vary. The effects of language choice, word order, and context must be documented. Maintaining stable quality control criteria becomes harder in systems where users can freely change prompts.
A single good screenshot is not sufficient testing. Prompt variations, box and mask stability, and false alarm frequency must be measured across separate production batches and different lighting conditions. If necessary, prompts should be fixed in the versioned product configuration.

Numerical example: the true cost of an off-the-shelf model
Suppose a line captures 10 products per second. If a large model processing every image has an end-to-end latency of 180 ms, a single processing channel can handle approximately 5.6 images per second, even before queuing and variable latency are considered. Two parallel channels or a faster model are needed. Alternatively, a lightweight first-stage filter could process 10 products per second, with the large model applied only to the 8% of examples flagged as suspicious.
However, the real risk in this design is how many critical defects are among the 92% not sent to the large model. Misses by the lightweight filter limit the overall system's recall. The computational gain is only validated by demonstrating acceptable error costs and measuring actual latency.
A brief comparison of model families
| Model family | Primary output/purpose | Industrial opportunity | Limitation |
|---|---|---|---|
| CLIP | Image-text similarity | Free-form descriptive search, prototyping | Score is not a probability of physical quality |
| DINOv3 | Visual features | Transfer with few labels, visual representation | May require a task head/adaptation |
| SAM 2 | Visually prompted masks, video | Annotation and video segmentation | Not designed for text-based concept search |
| SAM 3/3.1 | Detection, masks, and tracking through concept prompts | Flexible prototyping | Field testing required for critical acceptance decisions |
| Grounding DINO | Text-conditioned boxes | Localization with an open class list | Domain-specific accuracy must be measured |
Hybrid architectures combining foundation and task-specific models
Running a foundation model on every image can be computationally expensive. Instead, a lightweight model for a specific task can process all images, while the foundation model assists only with uncertain examples. For example, a fast detector locates all products, while SAM-based segmentation runs only on products requiring detailed measurement of a defect area. This can reduce overall costs, but if the first stage misses a critical defect, the second stage cannot help.
Another architecture extracts features from a foundation model and trains a lighter task head. Representations such as those from DINOv3 can be frozen, and a small classifier or anomaly score can be learned from those features. Such a system may still need to run the entire model continuously, although the number of trainable parameters may be small. Training cost and inference cost are different concepts.
When validating a hybrid design, component-level and end-to-end performance must be measured separately. Saying 'the foundation model is reliable' does not mean that the entire chain will be reliable. Thresholds, prompts, the task head, and the final decision logic must be tested together.
Prompt stability and version management
The choice of short text prompts can affect the results. Descriptions such as 'defect,' 'scratch,' and 'tiny scratch on polished metal' can cause the model to select different objects or regions. Prompts that affect product quality decisions should not be left to arbitrary user input. Approved prompts must be stored with the product configuration and model version.
A prompt need not be text alone. Visual inputs such as boxes, points, example images, and masks also play an important role in the SAM family. A change in the point marked by an operator can change the model's mask. This variability may be acceptable for interactive annotation, but requires tighter control in fully automated measurement.
During a version update, the same prompt must not be assumed to find a similar object in the new model. Backbones, detection heads, and training data can change within foundation model families. Previous acceptance photographs must be rerun through the new version, and differences in masks and boxes must be examined in physical terms.
Evaluating zero-shot performance correctly
Zero-shot evaluation can mean making predictions without labeled training examples from the target task. However, similar objects may have appeared in the large pretraining dataset. Claims such as 'the model has never seen an object like this' therefore generally require evidence. Zero-shot results may also depend on which text prompts are used and which classes appear in the candidate list.
If a class is very similar to other candidate classes, the ranking may change. High accuracy with a single prompt combination is therefore insufficient. Result stability can be measured using synonyms, different languages, and different lighting conditions. A model's open-vocabulary capability does not mean that it inherently knows physical quality standards.
Particular care is needed when interpreting a classification similarity score as an anomaly score for unknown defects. CLIP similarity may be high while the identified defect is incorrect. A foundation model's output must not be turned into an acceptance criterion without validation on field data.
Data privacy, edge deployment, and audit trails
When a cloud-based visual API is used, a company's production images, product geometries, or serial numbers may be sent to an external system. This must be evaluated against privacy, contractual, and data retention policies. Running a model locally can reduce this risk, but the model weights' license, device security, and maintenance processes still require attention.
Deterministic, traceable processing is extremely valuable in production. Which prompt did the model use, which version ran, what score and mask were produced, and which rule determined the quality decision? Recording this information allows an incorrect decision to be investigated later. In some VLM systems, the randomness of free-text generation and its elaborate explanations can make reproducible analysis of the same error difficult. Structured, verifiable output should be preferred for critical decisions whenever possible.
A model released as open source must not be assumed to be royalty-free and unrestricted in every setting. Code, weight, and data licenses must be reviewed separately. Selling a product to a customer and deploying a model as a hosted service may be subject to different terms of use. The release date and version must be taken into account.
Problems encountered when customizing through fine-tuning
Fine-tuning an entire large model on a small number of labeled industrial images can lead to overfitting and high computational costs. A lightweight adapter or linear probe on a frozen backbone can be tried. Conversely, inadequate backbone representations may require more extensive adaptation, particularly for domains such as narrowband sensors and microscopic surfaces. There is no single correct fine-tuning strategy.
With a small dataset, general recipes for which layers to unfreeze or which learning rate to use have limited value. Controlled experiments are needed. Comparisons must use the same train/test split, augmentation policy, and latency limit. An architecture requiring fewer training epochs does not imply that it will require less maintenance in the field.
Fine-tuning may also reduce a model's general capabilities. Performance may improve on a new product while deteriorating on older product variants. Tests across multiple variants and regression checks against the previous acceptance set are therefore necessary.
The final engineering framework for choosing a model family
A decision to use a foundation model should be evaluated through these questions: Is the required output a mask, a box, an embedding, or text? What is the per-image latency limit? How variable are camera and lighting conditions? How many labeled examples are available? How many pixels does the physical defect occupy? What are the licensing and data privacy constraints? What are the production and safety costs of an incorrect decision?
The answers prevent 'the newest model' from becoming the automatic choice. In some cases, SAM speeds up an operator's annotation, while a lighter U-Net is used in production. In others, DINOv3 is only a feature extractor, with separate rules making the quality decision. In yet others, CLIP is used to develop a retrieval prototype, but the final threshold is validated with a task-specific classifier.
The value of a foundation model lies not in being a single magical system, but in providing reusable representations and a flexible starting point for different tasks. Production reliability, by contrast, comes from controllable data, an understanding of technical limitations, and measurable acceptance criteria.
Advanced engineering details to consider in the field
The difference between a foundation model and a production model
A foundation model may have learned general representations from extremely broad visual distributions. A production system, however, needs deterministic decisions for a specific defect, reproducible outputs, and a traceable version. Prompt changes, model updates, and threshold differences can affect production outcomes. Foundation model output is therefore often a starting point for generating candidate masks or features rather than a direct rejection signal. Optical limitations still apply to subtle defects: a larger model cannot recover information that is not visible in the pixels. Engineering evaluation cannot be separated from data quality and the cost of decisions.
Actual defect segmentation with SAM
The SAM family can generate segmentation masks from interactive prompts, but it must not be assumed to know automatically that a mask represents a 'defective region.' Correctly segmenting a part's entire surface is different from identifying fine scratches within it. Even in systems that accept concept prompts, such as SAM 3, material-specific unacceptable microdefects may not be expressible through general concepts. Using these systems as annotation assistants can reduce labeling costs, but a quality specialist must review the final masks. Comparative experiments are misleading unless the prompt and model version are held fixed.
CLIP and the limitations of text matching
Models such as CLIP associate images and text in a shared representation space. Comparing scores for descriptions such as 'scratched metal' and 'clean metal' can provide a rough starting point without training. However, the length of the text options and the choice of words can change the results. Zero-shot classification is not a directly measured probability of a defect. Language representations may be inadequate for ambiguous or production-specific terminology. Variants of text prompts must be evaluated on a fixed validation set before being adopted as a standard decision policy in production.
Model licensing, data privacy, and system architecture
For general-purpose models, application licensing, checkpoint access, and commercial usage terms vary from model to model. Cloud-based image processing may require sending production drawings, serial numbers, or customer products to an external service. Local deployment, on the other hand, brings GPU memory requirements and responsibility for updates. Comparisons must consider not just model accuracy, but also data processing agreements, behavior during network outages, and version management. The current license terms must be checked separately before publication or commercialization. Open weights do not mean that a model can be used in every context without restrictions.
Application scenario: from a general-purpose model to production inspection
Suppose a SAM-like system successfully generates masks for parts. This output can reduce an operator's labeling time, but scratch severity cannot be measured from the mask alone. A second task layer, material-defect labels, and a physical rejection standard are needed. Mask stability is tested separately when the prompt, model version, and test image change. The final system is defined together with its model card, decision threshold, and operating procedure for handling errors.
Field testing checklist
- Has it been documented which tests remain independent across products, shifts, and image acquisition conditions?
- Has a distinction been made between failures that can be corrected by the algorithm alone and those requiring optical or process changes?
- Has it been verified that the model score does not replace the physical acceptance criterion?
- Are input resolution, model version, threshold, and operating hardware held fixed in the experiment records?
- Are illustrative visuals clearly distinguished from actual measured model results?
- Are false rejects, missed defects, latency, and reinspection workload reported separately?
Frequently asked questions
Can SAM directly detect industrial defects?
SAM helps generate masks. The defect definition, product tolerance, and decision threshold must be established separately; a mask output alone is not a quality decision.
Does DINOv3 remove the need to train a model?
DINOv3 provides pretrained features. Depending on the target task, a head, adapter, or fine-tuning may still be necessary.
Is a CLIP score a true probability?
Generally not. Without calibration, image-text similarity must not be interpreted as the probability of a physical defect.
What is the main difference between SAM 3 and SAM 2?
SAM 2 supports visually prompted masks and video tracking. SAM 3 extends concept-based detection and segmentation with text and example prompts; SAM 3.1 introduces further performance refinements.
Which foundation model is suitable for an edge device?
There is no universal choice. Model size, runtime, GPU/CPU memory, licensing, and target latency must be evaluated on the actual hardware.
References and image provenance
Technical references and original publications are listed below. Photographs used in the visual examples are genuine CC0/public-domain images; transformations made for comparison are explained. The diagrams are original designs. Illustrative examples are not presented as trained-model performance.
Image sources and illustration note
The example photographs come from the scikit-image sample data collection. Added boxes, masks, synthetic defects, and heatmaps are demonstrations explaining the concepts; they are not outputs of a trained model or validated performance results. The technical diagrams are original drawings included in this package.