Skip to content
// ai glossary

What is an embedding in AI? Simple guide

A list of numbers that represents the meaning of a piece of text, so a computer can compare meanings. Used in search and RAG.

Last reviewed

In plain English

An embedding is a list of numbers that represents the meaning of a piece of text. Texts with similar meaning get similar numbers, so a computer can measure how close two ideas are even when they use different words.

A simple example

Picture a map where every phrase has a position. "Car", "automobile" and "vehicle" sit close together. "Banana" is far away. An embedding is like the coordinates of a phrase on that map, only with hundreds or thousands of numbers instead of two, so it can capture many shades of meaning at once.

Because of this, a search for "how do I get my money back?" can find a page titled "Refund policy", even though the two share no words.

Where you meet embeddings

  • Search that understands meaning, not only keywords.
  • Recommendations, such as finding articles similar to the one you are reading.
  • Question-answering over documents, where the system finds the right passage before the AI writes a reply. This is the idea behind RAG.
  • Grouping and de-duplicating large amounts of text.

The numbers are usually stored in a vector database, which is built to find the closest matches fast.

Common mix-ups

  • An embedding is not a summary. It is numbers for comparing meaning, and you cannot read them.
  • Embeddings are made by a model. Different embedding models give different numbers, so you cannot mix them.
  • Close is not always correct. The nearest match is the most similar text, which may still not answer the question.
  • Vector databaseA database that stores embeddings so you can quickly find text with similar meaning. Common in RAG apps.
  • RAG (retrieval-augmented generation)A method where the AI first searches your documents for relevant information, then uses it to write the answer. Reduces made-up facts.
  • ModelThe trained AI 'brain' that produces outputs. Companies release different models with different strengths and prices.