---
title: Embedding — AI Glossary
description: An embedding is a dense vector of numbers that represents text, images, or other data in a continuous space where semantic similarity corresponds to geometric closeness. Items with related meaning map to nearby vectors, letting systems compare, cluster, and retrieve content by measuring distances between embeddings.
canonical: https://prompeteer.ai/glossary/embedding
---

# Embedding

An embedding is a dense vector of numbers that represents text, images, or other data in a continuous space where semantic similarity corresponds to geometric closeness. Items with related meaning map to nearby vectors, letting systems compare, cluster, and retrieve content by measuring distances between embeddings.

## Definition

Embeddings turn discrete inputs such as words, sentences, or documents into fixed-length numeric vectors learned so that meaning is captured by position in the vector space. Similarity is typically measured with cosine similarity or Euclidean distance, which is why embeddings underpin semantic search, clustering, recommendation, and retrieval-augmented generation.

Dedicated embedding models produce these vectors for downstream use, distinct from the generative model that writes text. In retrieval pipelines, documents are embedded ahead of time and stored in a vector database; at query time the query is embedded and the nearest document vectors are returned.

## Sources

- [OpenAI — Embeddings guide](https://platform.openai.com/docs/guides/embeddings)
- [Mikolov et al. (2013), Efficient Estimation of Word Representations in Vector Space](https://arxiv.org/abs/1301.3781)

## Related terms

- [vector-database](https://prompeteer.ai/glossary/vector-database)
- [semantic-search](https://prompeteer.ai/glossary/semantic-search)
- [retrieval-augmented-generation](https://prompeteer.ai/glossary/retrieval-augmented-generation)
- [reranking](https://prompeteer.ai/glossary/reranking)
