API glossary

Vector embeddings

A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

A vector embedding (or just an embedding) is a list of numbers that represents the meaning of a piece of data (such as text, image, or audio) as a point in a high-dimensional space. An embedding model produces these vectors so that items with similar meaning land close together, which lets software compare meaning by measuring distance between vectors rather than matching words.

In short: an embedding is a numeric representation of meaning. Essentially, a vector where similar things sit close together, so machines can compare by meaning instead of by exact words.

How vector embeddings work

The point is to convert meaning into coordinates that can be compared:

  1. Train a model: An embedding model learns, from large amounts of data, to map inputs to vectors so that related inputs produce nearby vectors.
  2. Encode the input: The model converts a piece of text or an image into a fixed-length vector, often hundreds or thousands of numbers long. Fixed length makes comparisons straightforward when vectors come from the same embedding space (typically the same model/version and compatible preprocessing), even if the original inputs had different lengths.
  3. Position by meaning: Each dimension captures some abstract feature of the input. Individual dimensions are rarely interpretable in isolation, but together they place the item in a space where proximity reflects similarity.
  4. Compare: Similarity between two items is measured with a metric such as cosine similarity; the closer the vectors, the more alike the meanings.

The defining idea is that an embedding turns meaning into position: once data is embedded, an abstract question like “what is similar to this?” becomes a concrete distance calculation a computer can do quickly.

Vector embeddings vs. tokens and keywords

  • Tokenization splits text into discrete units for a model to process; an embedding converts text (whether a word, sentence, or whole passage) into a continuous vector that captures meaning. Tokenization deals with pieces of text and structure; embeddings deal with meaning.
  • Keyword representations track which exact words appear; embeddings capture what the text is about, so paraphrases that share no words can still land close together.
  • An embedding is the representation; a vector database is the system capable of storing and searching those embeddings.

Where vector embeddings are used

  • Semantic search: Embedding queries and documents is what lets semantic search match by meaning rather than keywords.
  • RAG and vector databases: Embedded chunks are stored in a vector database and retrieved by similarity to ground an LLM’s answer.
  • Recommendations and clustering: Nearby embeddings reveal similar products, related content, or natural groupings in data.
  • Search relevance: Embeddings are one common mechanism behind neural ranking and semantic relevance in search APIs. Depending on the system, ranking can combine embeddings with other signals, but the core idea remains matching results to intent by meaning, not exact wording.

Vector embeddings are a core representation in modern AI search. They turn words and images into something a machine can compare, cluster, and retrieve by meaning.

Embedding model, vector database, semantic search, cosine similarity, tokenization, retrieval-augmented generation (RAG), retrieval score, dimensionality, large language model (LLM).