Skip to content

Conversation

@julianmi
Copy link
Contributor

@julianmi julianmi commented Dec 4, 2025

Change the default HNSW hierarchy from NONE to GPU to enable search with Hnswlib. Searching an HNSW index built with HnswHierarchy::NONE using Hnswlib fails with a segmentation fault. This change should go into 25.12 to prevent such issues and improve the interoperability between cuVS and Hnswlib.

Copy link
Contributor

@tfeher tfeher left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks Julian for fixing this, LGTM!

@tfeher tfeher added improvement Improves an existing functionality non-breaking Introduces a non-breaking change labels Dec 4, 2025
@divyegala
Copy link
Member

@tfeher this is a breaking change, and it's also missing an update to the C API default.

Copy link
Member

@divyegala divyegala left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of a segmentation fault, can you put an error checker to fail gracefully if user tries to search a NONE hierarchy HNSW index?

@tfeher tfeher added breaking Introduces a breaking change and removed non-breaking Introduces a non-breaking change labels Dec 4, 2025
@julianmi
Copy link
Contributor Author

julianmi commented Dec 4, 2025

@tfeher this is a breaking change, and it's also missing an update to the C API default.

I have changed the C API default as well.

Instead of a segmentation fault, can you put an error checker to fail gracefully if user tries to search a NONE hierarchy HNSW index?

Sorry to not me more specific. Our internal search works but a separate search with Hnswlib fails. Changing the default would enable the interoperability out of the box.

@tfeher
Copy link
Contributor

tfeher commented Dec 4, 2025

@tfeher this is a breaking change

Thanks @divyegala for catching my mistake. Indeed, users might be relying on the default value, so this is a breaking change. I have updated the labels.

@julianmi julianmi changed the base branch from release/25.12 to main December 4, 2025 11:57
@julianmi julianmi requested review from a team as code owners December 4, 2025 11:57
@julianmi julianmi requested a review from AyodeAwe December 4, 2025 11:57
@julianmi julianmi requested a review from a team as a code owner December 4, 2025 18:11
@divyegala divyegala removed request for a team December 15, 2025 18:06
@divyegala divyegala removed the request for review from a team December 15, 2025 18:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaking Introduces a breaking change improvement Improves an existing functionality

Projects

Development

Successfully merging this pull request may close these issues.

4 participants