Question about Vector Search Behavior with and without Radius in Milvus #47774
-
|
Dear Milvus Team, First of all, thank you for the great work you are doing on Milvus. We really appreciate the platform and the flexibility it provides for vector search. I am trying to better understand how vector search behaves internally in two slightly different scenarios, and I would be very grateful if you could help clarify this. We are using COSINE metric and experimenting with two cases: What we observe is that the results differ significantly between these two cases — even when the radius value is set to a very small threshold. It feels like the search behavior itself changes. We would really appreciate a more detailed explanation of how these two modes differ internally, as this impacts how we tune our search thresholds and ranking logic. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
Thank you for your question. When radius is not specified, the search behaves as a standard ANN Top-K search. Range search and Top-K search are fundamentally different. They follow different execution paths internally, so it is expected that results may differ even when the radius is set to a very small value. Range search prioritizes distance ordering (nearest to farthest) within the specified threshold. To guarantee this behavior, the algorithm may skip certain candidates during traversal. As a result, its behavior is not equivalent to applying a simple post-filter on Top-K results. Additionally, please note that Zilliz Cloud includes index-level optimizations beyond the open-source Milvus defaults. In practice, you can often reduce discrepancies between Top-K and range search results by increasing search parameters (e.g., ef, nprobe, etc.), which improves recall. |
Beta Was this translation helpful? Give feedback.
Thank you for your question.
When radius is not specified, the search behaves as a standard ANN Top-K search.
Range search and Top-K search are fundamentally different. They follow different execution paths internally, so it is expected that results may differ even when the radius is set to a very small value.
Range search prioritizes distance ordering (nearest to farthest) within the specified threshold. To guarantee this behavior, the algorithm may skip certain candidates during traversal. As a result, its behavior is not equivalent to applying a simple post-filter on Top-K results.
Additionally, please note that Zilliz Cloud includes index-level optimizations beyond the open-source Mil…