Skip to content

BM25 and Hybrid search with minimum_should_match#300

Merged
bevzzz merged 7 commits intomainfrom
feat/bm25-minimumShouldMatch
Jun 2, 2025
Merged

BM25 and Hybrid search with minimum_should_match#300
bevzzz merged 7 commits intomainfrom
feat/bm25-minimumShouldMatch

Conversation

@bevzzz
Copy link
Collaborator

@bevzzz bevzzz commented Jun 2, 2025

This PR adds an optional search operator argument to BM25 and Hybrid queries that provides the new minimum_should_match semantics.

collection.query.hybrid(..., { bm25Operator: BM25Operator.and({ minimumMatch: 5 })});

collection.query.bm25(..., { operator: BM25Operator.or({ minimumMatch: 3 })});

@bevzzz bevzzz requested a review from a team as a code owner June 2, 2025 09:11
Copy link

@orca-security-eu orca-security-eu bot left a comment

Choose a reason for hiding this comment

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

Orca Security Scan Summary

Status Check Issues by priority
Passed Passed Infrastructure as Code high 0   medium 0   low 0   info 0 View in Orca
Passed Passed SAST high 0   medium 0   low 0   info 0 View in Orca
Passed Passed Secrets high 0   medium 0   low 0   info 0 View in Orca
Passed Passed Vulnerabilities high 0   medium 0   low 0   info 0 View in Orca

@bevzzz bevzzz self-assigned this Jun 2, 2025
@bevzzz bevzzz requested a review from tsmith023 June 2, 2025 11:43
@bevzzz bevzzz merged commit 05aea41 into main Jun 2, 2025
27 of 28 checks passed
@bevzzz bevzzz deleted the feat/bm25-minimumShouldMatch branch June 2, 2025 13:01
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.

3 participants