AI Term

HNSW (Hierarchical Navigable Small World)

1 min read

What it is: A graph-based algorithm that organizes vectors in multiple layers, like a highway system for finding similar vectors.

How it works:

  • Creates a multi-level graph where each vector connects to its nearest neighbors
  • Top layers have fewer nodes but longer connections (like highways)
  • Bottom layers have more nodes with local connections (like city streets)
  • Search starts at the top layer and navigates down to find the closest match

Why it matters: Very fast and accurate for similarity search, especially with millions of vectors. Used by many modern vector databases.

Real-world analogy: Like using Google Maps - you start with major highways to get to the right area, then use local streets to find the exact address.

← Back to Glossary
EUMade in Europe

Chat with 20+ AI Models in one App.

Use Claude, ChatGPT, Gemini alongside EU-hosted models and many more.

Get the App:

Download on the App StoreGet it on Google Play