Skip to content

feat(java): expose prefilter parameter to support vector search with fragments#6040

Merged
Xuanwo merged 3 commits intolance-format:mainfrom
nyl3532016:main
Mar 6, 2026
Merged

feat(java): expose prefilter parameter to support vector search with fragments#6040
Xuanwo merged 3 commits intolance-format:mainfrom
nyl3532016:main

Conversation

@nyl3532016
Copy link
Copy Markdown
Contributor

In lance-spark, distributed vector queries rely on fragmentScanner. When a specific fragment is targeted, prefilter must be set to true to ensure correct execution. This change exposes the variable through JNI to enable this functionality.

@github-actions github-actions Bot added enhancement New feature or request java labels Feb 27, 2026
@nyl3532016
Copy link
Copy Markdown
Contributor Author

@jackye1995 Hi, could you please take a look at this PR when you have a moment? This pr is for lance-format/lance-spark#189

@nyl3532016
Copy link
Copy Markdown
Contributor Author

Hi, @jackye1995 It’s a relatively short diff. so it shouldn't take much of your time. Could you please give it a quick review when you're free.Thank you!

Copy link
Copy Markdown
Collaborator

@Xuanwo Xuanwo left a comment

Choose a reason for hiding this comment

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

Thank you for working on this!

@nyl3532016 nyl3532016 requested a review from Xuanwo March 5, 2026 03:50
@nyl3532016
Copy link
Copy Markdown
Contributor Author

@Xuanwo Thanks for the review. I've fixed the flaky UTs

@Xuanwo Xuanwo merged commit 2524246 into lance-format:main Mar 6, 2026
7 checks passed
hamersaw added a commit to lance-format/lance-spark that referenced this pull request Mar 30, 2026
When performing vector queries, if a specific fragment is targeted,
prefilter must be set to true to ensure correct execution.
Vector queries are pushed down to shards for execution, but the returned
Top-K results consist of K × number of shards records, which require
manual processing by the business layer.
#189 
[lance-pr](lance-format/lance#6040)

---------

Co-authored-by: niuyulin <niuyulin@chinamobile.com>
Co-authored-by: Daniel Rammer <hamersaw@protonmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request java

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants