What are embeddings?
How computers turn meaning into numbers, so they can tell that 'refund' and 'money back' mean the same thing.
Search for “money back” and a good help centre still finds the article titled “Refund policy”, even though the words don’t match. The trick behind that is embeddings.
A way of turning text into a list of numbers that captures its meaning, so a computer can measure how similar two pieces of text are.
A map of ideas. Every word or sentence gets a location. Things with similar meanings sit close together: “puppy” near “dog”, “refund” near “money back”, and both far away from “password reset”.
How it works
- 01Text
- 02Embedding model
- 03List of numbers
- 04Compare distances
Those numbers are coordinates. Plot them and words with similar meanings land near each other.
Measuring similarity
Once text is turned into numbers, a computer can check how close two meanings are.
- Can I get a refund?Very close
- My order arrived damagedSomewhat related
- How do I reset my password?Not related
Where you’ll find them
- Smarter search: finding results by meaning, not just matching words.
- Recommendations: “people who liked this also liked…”
- Grouping: sorting thousands of support tickets by topic automatically.
- RAG: finding the right documents to give an AI before it answers. See RAG.
Embeddings are usually stored in a vector database, which is built to search millions of them quickly.
A common misunderstanding
“The computer understands meaning like we do.” It doesn’t. Embeddings capture patterns in how words are used together. That’s enough to be very useful, but it isn’t human understanding.
Online shops use embeddings so a search for “running shoes” also finds products listed as “trainers”, even though the words do not match.