add pgvecto_rs support and upgrade SQLAlchemy (#3833)

This commit is contained in:
Jyong 2024-04-29 11:58:17 +08:00 • committed by GitHub
commit 3e9dbe3e0a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
26 changed files with 584 additions and 220 deletions

View file

@ -235,7 +235,7 @@ class RelytVector(BaseVector):
docs = []
for document, score in results:
score_threshold = kwargs.get('score_threshold') if kwargs.get('score_threshold') else 0.0
if score > score_threshold:
if 1 - score > score_threshold:
docs.append(document)
return docs