NVIDIA / NVIDIA/cuvs

[BUG] Low recall with CAGRA when sparsity or dimensionality is high

Open
#761 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Cuda
Stars
854
Forks
236
Avg merge
3d 3h
Merged PRs (30d)
62

Description

Describe the bug
Low recall with CAGRA when sparsity or dimensionality (n_cols) is high.

Steps/Code to reproduce bug
run_filtered_search_test
Execute this test against n_cols 1024 and sparsity > 0.95

Expected behavior
The recall should be > 0.7

Environment details (please complete the following information):

  • Environment location: Docker, Azure A100
  • Method of RAFT install: conda, Docker
    • docker pull rapidsai/base:25.04a-cuda12.8-py3.12

Additional context
I created a 3 Million vector 1024 dimension embedding from texts for building a RAG system.
I created a bitset to ensure that RAG queries are relevant. However, it started to perform poorly on recall. There were cases where without bitset the passages were relevant.
I think it is due to high dimensionality and high sparsity. Any ways to circumvent this?

P.S The recall is better in 25.04 over 25.02 as far as I tested.

Image

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with python/cuvs/cuvs/tests/test_cagra.py at run_filtered_search_test and reproduce the issue using n_cols 1024 and sparsity >0.95. Compare filtered-search recall against the expected value above 0.7, then trace the CAGRA path involved; done means the regression or limitation is addressed and the test meets the stated recall expectation.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
search
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.