AI Newsway
Back to glossary

Vector Search

Data

Vector Search is a retrieval method that finds results by meaning rather than by matching words, comparing the distance between numeric embeddings of the query and the stored items. An embedding model turns text, an image, or audio into a list of numbers positioned so that similar content sits close together, and the search returns the nearest neighbors by cosine similarity or a related metric. This is why a query for "how do I cancel my plan" can surface a document titled "ending your subscription" even with no shared keywords. Exact nearest-neighbor search is too slow at scale, so systems use approximate algorithms such as HNSW or IVF, trading a little recall for large speed gains. Implementations range from the pgvector extension inside PostgreSQL to dedicated engines like Pinecone, Qdrant, and Weaviate, and Elasticsearch and OpenSearch now support vector fields alongside their text indexes. Vector search is the retrieval half of RAG, feeding relevant passages to a language model. The pitfall is dropping keyword search entirely: embeddings blur exact identifiers such as product codes, error numbers, and names, so most production systems run hybrid search and combine both rankings.