Skip to content

fix(core): use Heap::emplace in groupby/bf search - #633

Open
JalinWang wants to merge 1 commit into
alibaba:mainfrom
JalinWang:codex/fix-heap-invariants
Open

fix(core): use Heap::emplace in groupby/bf search#633
JalinWang wants to merge 1 commit into
alibaba:mainfrom
JalinWang:codex/fix-heap-invariants

Conversation

@JalinWang

@JalinWang JalinWang commented Jul 30, 2026

Copy link
Copy Markdown
Collaborator

Replace inherited std::vector::emplace_back calls with ailego::Heap::emplace. Heap::emplace maintains heap ordering and enforces capacity limits; emplace_back bypassed both, breaking best-first candidate traversal and allowing group heaps to grow without bound.

Also correct DiskANN initial group seeding to insert into the group heap.

@JalinWang JalinWang changed the title Fix heap invariants in group search Use Heap::emplace to preserve heap invariants and limits Jul 30, 2026
@JalinWang JalinWang changed the title Use Heap::emplace to preserve heap invariants and limits fix(core): use Heap::emplace in groupby/bf search Jul 30, 2026
@JalinWang
JalinWang marked this pull request as ready for review July 30, 2026 06:17
@JalinWang
JalinWang requested a review from richyreachy as a code owner July 30, 2026 06:17
@JalinWang
JalinWang requested review from egolearner and iaojnh July 30, 2026 07:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant