Beginner5 min read1 of 10

What Is Vector Search?

How machines find meaning by turning words into coordinates — and why search changed forever when they did.

What Is Vector Search?

Type "affordable smartphone" into a keyword search engine and it looks for documents containing exactly those words. It won't find an article about "cheap phones" — even though that's exactly what you meant.

Vector search solves this. Instead of matching strings, it matches meaning.

Text as coordinates

Every word, sentence, or document can be represented as a list of numbers — a vector — in a high-dimensional space. Vectors that share meaning cluster close together. Vectors with different meanings sit far apart.

Basic vector concepts — magnitude, direction, dot product

"affordable smartphone" → [0.23, -0.87, 0.41, ...] # 768 numbers "cheap phone" → [0.21, -0.84, 0.39, ...] # nearly identical "database indexing" → [0.94, 0.12, -0.73, ...] # completely different

The model that produces these vectors is called an embedding model. It's a neural network trained to place similar concepts near each other in that high-dimensional space.

The search operation

Once every document in your corpus has been embedded, a search becomes three steps:

  1. Embed the query text with the same model
  2. Find the vectors in your index nearest to the query vector
  3. Return those documents

This is k-Nearest Neighbor (kNN) search — finding the k closest points. Similarity is measured by a distance function (usually cosine similarity for text).

Why this matters in production

ScenarioKeyword failsVector succeeds
User types "fast phone"Misses "high-performance mobile"Finds it
Multi-language contentNeeds per-language logicLanguage-agnostic
Typos and paraphrasingReturns nothingFinds intent
Concepts, not terms"heart disease" misses "cardiac"Handles it

[Key Insight] Vector search doesn't replace keyword search — it complements it. For exact IDs, codes, or error strings, keyword still wins. The real power comes from combining both: hybrid search.

The 4-generation arc of search

Search engines have evolved through four clear stages:

  1. Keyword (BM25) — exact term matching, fast and interpretable, brittle on paraphrasing
  2. Semantic (Dense vectors) — embedding-based kNN, understands meaning and synonyms
  3. Hybrid — both signals combined, best quality across all query types (NDCG@10: 0.91)
  4. Agentic — systems that plan multi-step retrieval, decompose queries, reason over results

We're currently in the hybrid → agentic transition. Every production search system worth building today starts with hybrid.

What you'll learn in this series

  • How embeddings encode meaning into numbers
  • The three similarity metrics and when each one wins
  • How HNSW makes search fast at million-document scale
  • Dense, sparse, and hybrid search — built from scratch
  • How to measure and improve search quality

Start with embeddings next.