Approximation Algorithms for Diversity-Aware -Nearest Neighbor Search
Abstract
As a fundamental computational primitive, Nearest Neighbor Search (NNS) retrieves the most relevant objects for a given query, underpinning a vast array of applications like image search, retrieval-augmented generation (RAG), and recommendation systems. However, traditional NNS schemes neglect diversity awareness, thereby suffering from severe redundancy and near-duplicate results. To tackle this limitation, diversity-aware -nearest neighbor search (DNNS) has been extensively studied. Despite these efforts, state-of-the-art DNNS methods still struggle with compromised result quality, efficiency bottlenecks, or inflexible trade-offs between relevance and diversity. To address these limitations, we study a DNNS formulation that linearly combines the relevance and diversity terms in a unified objective function, with a controllable parameter to adjust their relative importance. We prove that the problem is NP-hard and that, unless , no polynomial-time algorithm can approximate it with a factor of for any . Then, we propose a linear scan-based algorithm, threshold-greedy scan (TGS), for DNNS with a -approximation for any fixed . Furthermore, we integrate the threshold-greedy principle with graph-based indexes for NNS and propose multi-threshold graph search (MTGS), which achieves a -approximation under a shortcut-reachability assumption on the graph. Finally, we conduct extensive experiments on four real-world datasets. The results demonstrate that TGS achieves the best result quality for DNNS in almost all cases. Meanwhile, MTGS runs over two orders of magnitude faster than TGS and improves upon state-of-the-art DNNS baselines in both result quality and search efficiency.
Then back it, or bet against it.
Related papers
Open the market on this paper to see 7 more related papers.