Papers
Topics
Authors
Recent
2000 character limit reached

Proximity Graph-based ANN Indices

Updated 26 December 2025
  • Proximity graph-based ANN indices are data structures that use directed graphs and robust pruning methods to enable efficient similarity searches in high dimensions.
  • They address dynamic update challenges by applying in-place update protocols like IP-DiskANN, which streamline insertions and deletions while preserving high recall.
  • Empirical evaluations confirm that these indices achieve stable query latency and superior performance for billion-scale datasets compared to traditional batch-based methods.

A proximity graph–based Approximate Nearest Neighbor (ANN) index is a data structure for high-dimensional similarity search relying on a graph in which vertices correspond to data vectors and directed edges encode neighborhood relations that enable fast greedy, beam, or best-first search for nearest neighbor queries. Such indices underpin database, information retrieval, recommendation, and retrieval-augmented-generation (RAG) systems where efficient, robust, and updatable vector search is required. Proximity graph indices dominate ANN benchmarks, especially for billion-scale datasets. An important technical challenge arises in streaming scenarios: vectors are inserted and deleted at high rates, but proximity graphs are typically singly-linked (out-neighbors only), which complicates deletions. State-of-the-art algorithms—including FreshDiskANN's batched consolidation and the IP-DiskANN "in-place" update scheme—address this with distinct graph maintenance protocols that balance recall, update speed, and latency (Xu et al., 19 Feb 2025).

1. Fundamental Principles of Proximity Graph-Based ANN Indices

Proximity graph construction involves representing the data set PP as directed graph G(P,E)G(P,E), where each vector is linked to a small set of neighbors chosen via prune procedures merging proximity and diversity. This ensures that a greedy or beam search from a fixed start node ss reliably traverses the graph towards data points close to the query qq using a limited number of distance computations. The key properties demanded are:

  • Connectivity: The graph should minimize diameter while preserving reachability for all queries.
  • Neighbor selection: Each node pp selects up to RR out-neighbors via "RobustPrune" or similar, balancing closeness and diversity.
  • Search complexity: Proper pruning yields O(logN)O(\log N) or O(Nρ)O(N^\rho) query complexity, translating to a few hundred distance computations per query at scale.

Graph-based indices such as HNSW (Hierarchical Navigable Small World) and DiskANN instantiate these principles with single or multi-layer structures, supporting efficient in-place insertions. Deletions, however, are problematic due to the singly-linked nature—no easy access to in-neighbors—necessitating specialized update logic (Xu et al., 19 Feb 2025).

2. Dynamic Update Challenges: Insertions and Deletions

Formal metrics define the performance of an ANN index:

  • Recall@k: At query time tt, given the true top-k neighbors GG and algorithm output AA, recall@k is GA/k|G \cap A| / k.
  • Query latency: Measured in time per query or QPS.
  • Update throughput: Number of insertions/deletions per second, or per-update cost.

Insertion is straightforward—running a GreedySearch plus RobustPrune attaches a new point in O(lb+R2)O(l_b + R^2) distance computations. By contrast, deletion requires not only removing a node pp, but repairing the graph so that each in-neighbor remains connected to the remaining subgraph via efficient rewiring, without visiting all O(R2)O(R^2) possible edge pairs. Batched consolidation (as in FreshDiskANN) marks deleted vertices, periodically consolidating by replacing edges to deleted nodes and pruning, amortizing cost but introducing latency spikes and recall oscillation (Xu et al., 19 Feb 2025).

3. In-Place Graph Maintenance and Update Protocols

IP-DiskANN introduces a scheme to efficiently handle streaming insertions and deletions directly, eschewing batch consolidation for purely in-place updates:

  • Insertion: The procedure runs GreedySearch to collect candidate neighbors, executes RobustPrune to select up to RR out-neighbors, and rewires as required. Each updated node pruned if the maximum degree is exceeded.

1
2
3
4
5
6
7
function Insert(G, x_p, l_b, R, α):
    V  GreedySearch(G, x_p, 1, l_b).visited
    N_out(p)  RobustPrune(p, V, R, α)
    for v in N_out(p):
        add edge vp
        if |N_out(v)|>R:
            N_out(v)  RobustPrune(v, N_out(v), R, α)

  • Deletion: IP-DiskANN re-approximates in-neighbors of pp by GreedySearch on xpx_p, then rewires each with only a small constant cc edges, not the full R2R^2, and prunes to cap out-degrees.

1
2
3
4
5
6
7
8
9
10
11
12
13
function Delete(G, p, l_d, k, c, α, R):
    (Visited, Candidates)  GreedySearch(G, x_p, k, l_d)
    N'_in(p) ← {z ∈ Visited : p ∈ N_out(z)}
    for z in N'_in(p):
        C_z  top-c closest points to x_z among Candidates
        N_out(z)  (N_out(z)  C_z) \ {p}
    for w in N_out(p):
        C_w  top-c closest points to x_w among Candidates
        for y in C_w:
            add edge yw
    remove vertex p from G
    for any v whose out-degree > R:
        N_out(v)  RobustPrune(v, N_out(v), R, α)
With parameters ld=128,k=50,c=3,α=1.2l_d=128, k=50, c=3, α=1.2, the per-deletion complexity is O(ld+cRlogR)O(l_d + cR\log R), dramatically reducing update overhead compared to batch-based approaches.

Additionally, IP-DiskANN performs lightweight consolidation: after a threshold (e.g., 20% deletions), a scan strips out-edges to deleted nodes, with no pruning or distance computation. This ensures query stability by removing dangling pointers (Xu et al., 19 Feb 2025).

4. Theoretical and Empirical Evaluation

Theoretical analysis demonstrates that in-place deletion maintains expected connectivity: rewiring neighbors and out-neighbors through candidate selection preserves graph structure and high recall. Empirical benchmarks—using 100D MSTuring and 768D Wikipedia embeddings—show:

  • Recall stability: IP-DiskANN maintains recall within ±0.2% of static indices over long update streams; FreshDiskANN's recall dips before consolidation batches and recovers.
  • Query/update efficiency: IP-DiskANN matches or slightly exceeds FreshDiskANN in recall (up to +2.3%), with 10–30% faster deletions. HNSW update costs increase rapidly at large scale (O(R3)O(R^3)).
  • Regimes: In all runbooks, in the SlidingWindow setting for 10M points, IP-DiskANN achieves Recall@10 ≈ 94.8% (deletion 1.11s, insertion 1.46s) vs FreshDiskANN's 94.4% (deletion 1.7s, insertion 1.45s) and HNSW's 91.8% (per-step update+query ≈ 4s).
  • Trade-offs: IP-DiskANN's per-delete cost slightly exceeds insertion, but the algorithm entirely avoids periodic O(N)O(N) consolidations.

5. Architectural and Algorithmic Guidelines

Use in-place IP-DiskANN when supporting workflows with high-rate mixed insert/delete patterns on dataset scales >107>10^7 where stable latency and consistent resource utilization are essential. Latency-sensitive deployments benefit from the elimination of periodic rebuild spikes. Batched consolidation (FreshDiskANN) or static rebuild remains preferable only under low deletion rates (<5%<5\%) or if delete bursts are rare and idle consolidation windows are available.

Practical tuning recommendations include setting cc (extra edge copies) in the range 2–5 and ldl_d (delete beam size) between 100–200 to balance recall and latency, performing lightweight consolidation at 10–20% delete thresholds, and monitoring recall drift, which remains within 0.5% of static recall using IP-DiskANN indefinitely.

Other approaches have investigated incremental proximity graph maintenance via explicit reverse graphs to ease in-neighbor identification and facilitate efficient local/global graph repair (GlobalReconnect strategies) (Xu et al., 2022). Theoretical works have established that only direct neighbors of a deleted node require edge updates, matching the locality exploited by IP-DiskANN (Xu et al., 2022). Monotonic relative neighborhood graphs (MRNG) provide foundational understanding of searchability and minimality in graph-based indices and have inspired generalized pruning procedures for balancing degree and navigability (Zhu et al., 2021). Further refinements—such as fast index construction via iterative prune-and-search strategies employing angle-based pruning and adaptive refinement—offer scalability improvements and search guarantees (Yang et al., 2024).

7. Summary

Proximity graph-based ANN indices, as represented by the IP-DiskANN framework, offer high-recall, low-latency, scalable vector search with robust support for streaming insertions and deletions. By shifting from batch-based consolidation to efficient in-place updates, these indices maintain stable query performance and resource efficiency, making them the leading solution for high-throughput, dynamic ANN search and retrieval systems (Xu et al., 19 Feb 2025).

Whiteboard

Topic to Video (Beta)

Follow Topic

Get notified by email when new papers are published related to Proximity Graph-based ANN Indices.