Jargonautica
Classical Machine Learning

Contrastive Learning

Learning by comparison rather than by labels. Show the system two versions of the same thing and two different things, and train it to pull the matching pair together and push the others apart. It is how most modern embedding models are built, and why they capture similarity so well.

Technical view

Trains representations using positive pairs, typically augmentations of the same item or genuinely matched items, against negatives, with objectives such as InfoNCE or triplet loss. Performance depends heavily on negative sampling strategy and batch size, since in-batch negatives are the usual source. It underpins sentence and image embedding models, and joint image-text training, and is the practical bridge between self-supervised learning and retrieval.


Part of AI Terminology Index, section: Classical Machine Learning.

How it connects

Contrastive Learning links to 6 other terms. The faint lines are links between those terms. See it in the full graph.

EmbeddingsEmbeddingsSemantic SearchSemantic SearchJoint EmbeddingJoint EmbeddingSelf-supervised LearningSelf-supervised Lea…Mutual InformationMutual InformationData AugmentationData AugmentationContrastive Learning