Skip to content

Conversation

mrocha51248
Copy link
Contributor

Motivation and Context (Why the change? What's the scenario?)

Since #684 The PostgresDbClient will fail to return results that match the minSimilarity requirement when multiple filters are used. This is due to how the WHERE clause is prepared: filter1 OR filter2 OR filter3 AND embedding <=> @embedding < @maxDistance which cannot work as expected since the AND operator takes precedence over the OR operator

High level description (Approach, Design)

Simply add parenthesis around the filters argument

@mrocha51248 mrocha51248 requested a review from dluc as a code owner April 29, 2025 08:46
@dluc dluc merged commit 10b4c60 into microsoft:main May 8, 2025
6 checks passed
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.

2 participants