-
Notifications
You must be signed in to change notification settings - Fork 134
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
Upsert into vec0 tables? #127
Comments
@gospodinbodurov thanks for the report! Initially I though
But now I think that's outdated. Other docs mention a few other APIs that may help: So I'll try to include proper UPSERT support in an upcoming release! |
You are welcome. P.S. Not sure whether this is the right place for asking, but where I can find the different supported distance metrics? I guess at the moment cosine and l2 are the only ones? |
cosine, l1, and l2. is there any other you'd be interested in? |
At the moment I think the existing ones are good enough, but I am wondering how to use them - could not find their usage in the documentation. P.S. I plan integrating this project in our platform and that's the reason I am asking about the upsert functionality and what distance functions are supported. If upsert will not be supported I will rebuild the whole database from scratch during updates. |
docs are lacking but for vec0 tables you can specify a 'distance_metric=cosine' option after the vector column declaration, hoping to update the docs early next week with samples i'll also try to get upsert support soon! dont think it'll take too long but i won't be at a computer for a few more days |
I tried the following query:
INSERT INTO vec_items(rowid, embedding) VALUES (?, ?) ON CONFLICT(rowid) DO UPDATE SET embedding = excluded.embedding;
and got:
UPSERT not implemented for virtual table "vec_items"
Is upsert supported in some form?
The text was updated successfully, but these errors were encountered: