arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2607.02338cs.DBcs.CLcs.IRcs.LG
收藏

具有精度保证的HNSW:基于图Spanner的技术报告

Graph-Based Nearest-Neighbor Search with Recall Guarantees Using Graph Spanners

University of Toronto(多伦多大学);The University of Texas At Arlington(德克萨斯大学阿灵顿分校);IIT Bombay(博扬理工学院)

Minghao Li, Raghav Mittal, Sanjivni Rana, Suraj Shetiya, Gautam Das, Nick Koudas

AI总结:

提出Certify-then-Rectify框架,结合HNSW的快速启发式搜索与精确检索的严格性,通过无分布统计认证和极值理论估计图拉伸因子,实现平均速度与最坏情况正确性。

摘要:

分层可导航小世界(HNSW)图因其对数复杂度和强大的经验性能而成为行业标准。然而,HNSW依赖于贪婪图遍历,这是一种没有理论正确性保证的启发式方法。在本文中,我们提出了一种新颖的“认证-然后-纠正”框架,弥合了启发式搜索的速度与精确检索的严谨性之间的差距。我们的方法不是丢弃HNSW,而是首先采用无分布统计认证器,以最小的开销动态评估标准HNSW搜索的质量。如果认证表明检索到的邻居质量较低,该框架安全地升级到严格的精确恢复算法。为了使这种精确恢复在计算上可行,我们将HNSW图重新解释为几何spanner,并利用极值理论随机估计其最大经验拉伸因子。这使我们能够在数学上限制真实最近邻的最大距离。在基准数据集上的广泛评估表明,我们的分层框架提供了HNSW的平均情况速度,同时确保了精确搜索的最坏情况正确性,并优于其他适用方法。

英文摘要:

Graph-based indexes such as Hierarchical Navigable Small World (HNSW) graphs make nearest-neighbor retrieval efficient, but a high average recall can hide queries whose results fall below an application's quality requirement. We introduce Certify-then-Rectify (CTR), which returns an initial graph-search result when a calibrated rule accepts it and searches for missing neighbors otherwise. The recovery search reuses the existing graph and the distances already evaluated by the initial search. To determine how far this search should proceed, we relate metric distances to graph-path lengths through graph stretch. We develop Stretch-Bounded Expansion from Query (SBE-Q), together with Metric Bound Verification (MBV) to prune unnecessary work, and estimate its budget from paths to the fraction of true neighbors needed for the requested recall. Finite-sample tolerance bounds support this recall-aligned estimate; paths recorded during proposal recovery offer a conservative alternative to separate shortest-path computations. Independent tests certify initial acceptance and recovery outcomes, giving an end-to-end population recall guarantee even when the estimated stretch does not cover every relevant path. If recovery cannot be certified, rejected queries use exact scan. Experiments on HNSW compare five stretch estimators, assess recovery efficiency, and evaluate compliance and throughput on databases of up to 100 million vectors. CTR is not specific to HNSW, and we also evaluate it on another graph index.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑