Filtered-DiskANN delivers up to 7.5x higher query throughput than IVF inline-filtering at 90% recall@10 and preserves 90%+ recall down to 10^-6 label specificity by making Vamana graph construction label-aware. In a two-week live A/B test on a sponsored search engine across 47 geographical ad regions, replacing post-filtered vector retrieval with its FilteredVamana index raised ad clicks by 34.61% (p = 0.03) and revenue by 48.95% (p = 0.009), with rare regions under 1% of index share jumping 70.67% in clicks and 79.77% in revenue.

Gollapudi et al. (Microsoft and Microsoft Research, WWW ‘23) built two algorithms on top of DiskANN (FilteredVamana for streaming inserts and StitchedVamana for batch indexing) because filtering only at query time breaks graph navigation whenever eligible nodes are sparse.

  • Real-world speedups (90% recall@10): On DANN (3.3M points, 47 labels), FilteredVamana runs 3x faster and StitchedVamana runs 7.5x faster than 4,096-cluster FAISS-IVF inline processing (2.5x and 6x on Prep).
  • Extreme selectivity survival: On Turing (2.6M points, 3,070 filters, specificity down to 7.7e-6), both reach 90%+ recall@10, while post- and inline-filtering drop nearly 1,000x in QPS and stall on recall.
  • Low unfiltered penalty: On unfiltered queries at 95% recall@10 (Prep and DANN), StitchedVamana retains 0.9x and FilteredVamana 0.8x of standard Vamana QPS.
  • SSD scale: Placing the graph in DiskANN’s hybrid DRAM-SSD engine scales to 28 million DANN points on a single local SSD at thousands of QPS and 90%+ recall@10.
Query throughput speedup over IVF inline-processing at 90% recall@10 (higher is better)
Evaluated on Azure E64dsv4 (48 threads) against 4,096-cluster IVF inline-processing on DANN (3.3M pts, 47 filters) and Prep (1M pts, 47 filters)
StitchedVamana (batch, DANN / Prep)7.5x / 6.0x
FilteredVamana (streaming, DANN / Prep)3.0x / 2.5x
IVF inline-processing baseline (4,096 clusters)1.0x baseline

Source: Gollapudi et al. (2023), Sections 5.3.2 and 5.3.3 (Figures 2 and 3).

How It Works

Standard post-filtering searches an unfiltered HNSW or Vamana graph and discards non-matching candidates afterward, which misses eligible points when filters are selective. Pre-filtering via an inverted index (as in Weaviate or Milvus) still leaves queries stranded if standard geometric edges bypass eligible nodes, while building one index per label explodes storage when each point carries dozens of overlapping labels (8.84 filters/point on Prep).

Both algorithms replace standard Vamana pruning (RobustPrune) with FilteredRobustPrune: a directed edge (a, c) is pruned in favor of (a, b) only when alpha * d(b, c) <= d(a, c) and F_a ∩ F_c ⊆ F_b. That third condition guarantees shortcut nodes keep all shared filter labels, preserving navigable subgraphs inside one shared index. At query time, FilteredGreedySearch starts from a load-balanced per-filter medoid (FindMedoid) and pushes only out-neighbors matching the query label.

  • FilteredVamana: Inserts points incrementally, running FilteredGreedySearch over the new point’s labels and pruning both out-edges and overflowing back-edges on the fly (L = 90, R = 96).
  • StitchedVamana: Builds a compact per-label Vamana graph (R_small = 32, L_small = 100) for every label, takes the union of all edges, and prunes each vertex down to R_stitched = 64 (alpha = 1.2) with FilteredRobustPrune.
Index build time vs. query throughput: FilteredVamana vs. StitchedVamana
FilteredVamana (streaming)

Builds ~3x faster (DANN 159.8s, Prep 66.6s, Turing 103.4s), handles live insertions, and stays stable under shuffled labels.

StitchedVamana (batch)

Slower offline build (DANN 469.9s, Prep 222.6s, Turing 295.9s) but ~2x higher QPS at 90% recall@10.

Milvus & FAISS-HNSW

Similar build times (153.6s to 158.6s on DANN), but Milvus stayed under 300 QPS even at 48 threads.

Source: Gollapudi et al. (2023), Table 2 and Sections 5.4, A.2.

Key Findings

Across Turing, Prep, and DANN, StitchedVamana consistently doubles FilteredVamana’s QPS at 90% recall because stitching full per-label subgraphs lets FilteredRobustPrune choose from a richer candidate pool before bounding out-degree. Conversely, FilteredVamana builds roughly 3x faster and barely lost throughput when the authors randomly shuffled labels on Prep to destroy vector-label correlation, whereas StitchedVamana slowed down on the shuffled corpus.

Compared against NHQ-KGraph on five semi-synthetic NHQ datasets (which effectively partition points into 12 disjoint labels), both Vamana variants delivered an order of magnitude higher QPS at 100% recall, even in build-time-normalized runs.

Caveats and Builder Takeaway

  • Filter expressiveness limits: The algorithms natively support single-label exact match and OR disjunctions (by querying each label and merging results by distance). Multi-label AND conjunctions, continuous range filters, and SQL predicates remain open problems, and the label vocabulary must fit in the low thousands.
  • Streaming deletions untested: While FilteredVamana supports incremental insertions cleanly, full dynamic deletions (as in FreshDiskANN) are left to future work.
  • Authorization safety: When labels represent ACLs or tenant boundaries, the serving tier must still verify eligibility before returning results, especially if approximate or hybrid fallback paths run alongside FAISS or post-filters.

Pick StitchedVamana for static or nightly-rebuilt catalogs chasing maximum QPS, and FilteredVamana when your index ingests live updates or sees shifting attribute distributions.