Embedding
A vector representation of text such that semantically similar inputs land near each other.
By Kunj ShahEntry last reviewedmethod
What it implies
The same model must produce embeddings for documents and queries, or the space is meaningless. The failure mode to know about: embeddings are bad at exact tokens (part numbers, error codes, names), because `ERR-4421` and `ERR-4412` really are nearly the same thing. Users type exact tokens constantly.
Related terms
- Hybrid searchCombining lexical retrieval (BM25) with vector retrieval, so exact matches and semantic matches are both found.
- Vector indexAn approximate structure, usually HNSW or an IVF variant, that finds nearest neighbours without scanning every vector.
- ChunkingSplitting documents into retrievable pieces, which is where RAG quality is mostly won and lost.