EN
AI glossary

What Is an Embedding?

Term3 min readUpdated July 7, 2026

In short

An embedding is a way of turning a piece of content - a word, a sentence, an image, a chunk of code - into a list of numbers (a vector) that captures its meaning, so a computer can compare meanings mathematically. Content that means similar things ends up with vectors that sit close together, and unrelated content ends up far apart. That is the whole trick: once meaning is a set of coordinates, "find the most relevant passage" becomes "find the nearest vectors", which a machine can do instantly across millions of items. Embeddings are the quiet engine behind semantic search, recommendations, clustering and, above all, retrieval-augmented generation (RAG).

How an embedding captures meaning

An embedding model reads your input and outputs a fixed-length vector, often a few hundred to a few thousand numbers. It was trained so that inputs used in similar contexts get similar vectors, so "car" and "automobile" land near each other while "car" and "banana" do not. You never read the numbers yourself; you compare them.

  • Input: any text, image or code snippet you want to make searchable by meaning.
  • Output: a vector - a fixed-length list of numbers - that represents that meaning.
  • Compare: closeness between two vectors (cosine similarity) tells you how related the inputs are.

Embeddings and RAG

Embeddings are what make RAG possible. You embed each chunk of your documents once and store the vectors in a vector database. At query time you embed the user question with the same model, find the nearest chunk vectors, and hand those chunks to the language model as context. Because the match is by meaning and not exact keywords, a question phrased differently from the source text still retrieves the right passage.

Where embeddings are used

Beyond RAG, embeddings power semantic search (results ranked by meaning, not keywords), recommendations ("more like this"), deduplication, clustering and classification. For builders the practical point is that a single embedding step converts messy human content into something you can search, group and reason over reliably, which is why almost every AI feature that touches your own data starts by embedding it.

Frequently asked questions

Next step

Ready to put AI to work as a real workflow?

Start with the foundations course, keep your progress locally and sync everything to your free account whenever you like.