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

Add support for Python 3.11 and Ubuntu for SQLite #4263

Open
franciscojavierarceo opened this issue Jun 10, 2024 · 2 comments
Open

Add support for Python 3.11 and Ubuntu for SQLite #4263

franciscojavierarceo opened this issue Jun 10, 2024 · 2 comments
Labels
kind/feature New feature or request

Comments

@franciscojavierarceo
Copy link
Member

Is your feature request related to a problem? Please describe.
Can't run sqlite_vec on 3.11 or non-Darwin OS.

Describe the solution you'd like
Able to run sqlite vector search on Linux and not limited to 3.11

Describe alternatives you've considered
N/A

Additional context
#4209

@franciscojavierarceo franciscojavierarceo added the kind/feature New feature or request label Jun 10, 2024
@asg017
Copy link

asg017 commented Jun 10, 2024

@franciscojavierarceo I think this is because there's a SQLite bug on version < 3.41 on LIMIT ? clauses on virtual tables. In a lot of sqlite-vec docs the example KNN query is:

select 
  rowid, 
  distance
from vec_example
where column match ?
order by distance
limit 100

But this query won't work on SQLite version < 3.41, which is causing this bug.

The workaround is to provide the limit as a WHERE clause like so:

select 
  rowid, 
  distance
from vec_example
where column match ?
  and k = 100
order by distance

I'll be sure to document this more - tbh I might not even show the LIMIT 100 variant anymore, since many people are stuck on old SQLite versions in practice

@franciscojavierarceo
Copy link
Member Author

Thanks!

FYI, I just added support for sqlite_vec in Feast here: #4176

Thank you for this package!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants