Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to do a "where embedding is within some distance" query with Kysely and pgvector? #24

Closed
lancejpollard opened this issue Jul 17, 2024 · 1 comment

Comments

@lancejpollard
Copy link

lancejpollard commented Jul 17, 2024

Hello there! Super excited to try using this for dictionary definitions! Wanted to cross-post How to do Vector Embedding query in Kysely/PostgreSQL with pgvector? here to see if you had any ideas. Thanks so much for your time.

@ankane ankane closed this as completed in e745334 Jul 17, 2024
@ankane
Copy link
Member

ankane commented Jul 17, 2024

Hi @lancejpollard, you can use where(cosineDistance('embedding', [1, 2, 3]), '<', 0.1).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants