Skip to main content

Posts

Showing posts with the label Vertex AI Vector Search

Fixing Low Recall & Latency in Vertex AI Vector Search with Filtering

  You have ingested ten million vector embeddings into Google Cloud’s Vertex AI Vector Search. Your similarity search works perfectly for broad queries. However, as soon as you apply strict business logic—like filtering for "red shoes" that are "in stock" and "under $100"—your results vanish. You receive zero results, or worse, irrelevant results, even though you know the items exist in your database. This is the classic  HNSW "Broken Graph" problem . It is the single most common reason for low recall in production vector search systems. When metadata filtering is mishandled, the Approximate Nearest Neighbor (ANN) algorithm cannot traverse the graph to find the valid nodes. This guide details exactly why this happens mechanically and provides the production-grade Python code required to implement native filtering correctly in Vertex AI to restore 100% recall without destroying latency. The Root Cause: Why Filters Break HNSW Graphs To fix the prob...