# CLIP (model)

> Canonical: https://skillalmanac.com/glossary/clip-model | Last verified: 2026-11-24 | Index status: index-eligible

CLIP is a neural network from OpenAI that learns visual concepts from natural language supervision. It can be applied to a visual classification benchmark by simply providing the names of the categories, without optimizing for that benchmark.

Also called: CLIP, OpenAI CLIP, CLIP AI, CLIP model, Contrastive Language-Image Pre-training, contrastive language image pretraining.

## In plain language

CLIP is an AI model from OpenAI that connects pictures and words. It was trained on 400 million pairs of an image and its text, collected from the internet, learning which caption goes with which image. To sort photos into categories you provide the category names, such as a photo of a dog and a photo of a cat, and CLIP checks which description is more likely to be paired with each image. This lets you try new categories without collecting labeled examples for them. OpenAI reports that it struggles with tasks such as counting objects in an image, and that how the classes are designed can heavily influence both performance and bias.

## Technical definition

CLIP (Contrastive Language-Image Pre-training) is described in the paper Learning Transferable Visual Models From Natural Language Supervision. Its proxy training task, per OpenAI's announcement of January 5, 2021, is: given an image, predict which of a set of 32,768 randomly sampled text snippets was actually paired with it. The Hugging Face documentation says CLIP uses an image encoder and a text encoder, both projected to a latent space with the same number of dimensions, and their dot product gives a similarity score. For classification, each category name is written as a text description, and the description more likely to be paired with the image is chosen.

## How it shows up when you use agents

The Hugging Face Transformers documentation shows a pipeline with the task zero-shot-image-classification, the checkpoint openai/clip-vit-base-patch32 and a candidate_labels list such as a photo of a cat, a photo of a dog and a photo of a car. The documentation also says you can find all the original CLIP checkpoints under the OpenAI organization.

OpenAI reports that CLIP's zero-shot classifiers can be sensitive to wording or phrasing and sometimes require trial and error prompt engineering to perform well. It also reports that the way classes are designed can heavily influence both model performance and model biases. Related entries: [multimodal AI](/glossary/multimodal-ai) and [embedding](/glossary/embedding).

## Worked example: similarity is not a probability

Consider chosen unit-length vectors for a toy illustration: an image vector `(1, 0)`, a text vector `(0.8, 0.6)` for “a photo of a cat,” and `(0.6, 0.8)` for “a photo of a dog.” Their dot products with the image vector are 0.8 and 0.6, so ranking by this similarity selects the cat description. A similarity of 0.8 does not by itself mean an 80% probability that the image contains a cat.

These vectors are invented to demonstrate matching, not extracted from CLIP, and no image model was run. Actual CLIP scores depend on the encoders, normalization, scaling and candidate descriptions; this arithmetic says nothing about accuracy on real images.

## Common confusions

- **CLIP versus generating images.** CLIP's training task is to predict which text snippet was paired with an image. It is trained on matching, not on producing images. For models that make images from text, see [text-to-image](/glossary/text-to-image).
- **Zero-shot versus verified.** The abstract says zero-shot transfer is often competitive with a fully supervised baseline. OpenAI also reports poor generalization to images not covered in CLIP's pre-training dataset. See [zero-shot learning](/glossary/zero-shot-learning).
- **CLIP the model versus the objective.** OpenAI notes that ConVIRT studied the same contrastive objective used for CLIP, in the field of medical imaging.

## Worked examples in this catalogue

### [Codex](https://skillalmanac.com/tools/codex)

```
Hypothetical prompt: Prepare, but do not run, a Python example following Hugging Face's CLIP pipeline: task zero-shot-image-classification, checkpoint openai/clip-vit-base-patch32, and candidate_labels a photo of a cat, a photo of a dog and a photo of a car.
```

Status: illustrative example from the item's own documentation, not executed for this page.

What you see: An illustrative coding-agent task preparing the documented image-and-text classification pipeline; no code execution or model result is claimed.

Why it exercises the concept: The image is compared with candidate descriptions, making CLIP's image-text matching task concrete. The coding agent prepares the code; CLIP would perform the classification if it were run.

## Related terms

- [Multimodal AI](https://skillalmanac.com/glossary/multimodal-ai.md)
- [Computer vision](https://skillalmanac.com/glossary/computer-vision.md)
- [Embedding](https://skillalmanac.com/glossary/embedding.md)
- [Zero-shot learning](https://skillalmanac.com/glossary/zero-shot-learning.md)
- [Pretraining](https://skillalmanac.com/glossary/pretraining.md)

## Sources

- [Learning Transferable Visual Models From Natural Language Supervision](https://arxiv.org/abs/2103.00020), arXiv (Radford et al.) (accessed 2026-11-24)
- [CLIP: Connecting text and images](https://openai.com/index/clip/), OpenAI (accessed 2026-11-24)
- [CLIP (Transformers documentation)](https://huggingface.co/docs/transformers/model_doc/clip), Hugging Face (accessed 2026-11-24)

Definitions are written by Skill Almanac from the sources above and checked against them on 2026-11-24. [Glossary index](https://skillalmanac.com/glossary.md).
