Find answers from the community

Updated last year

Do the CRUD methods on VectorStoreIndex

At a glance
Do the CRUD methods on VectorStoreIndex not support a PGVectorStore?
L
e
10 comments
It does as far as I know -- delete is done by "ref_doc_id" tho
I keep getting an "Error occured on delete of document. ID: 0. Error: %d format: a number is required, not str". And I am using the newer method calls like delete_ref_doc(ref_doc_id=doc_id)
ref_doc_id takes a string...
Uhhh lemme check the delete method
same thing happens for all of them... refresh etc...
Maybe if you have a more complete traceback I could track it down. But the delete method is dead simple

https://github.com/run-llama/llama_index/blob/8d2ad8ba9cecf250e501587ff1e8541cc5bf6725/llama_index/vector_stores/postgres.py#L585
Refresh won't work without some extra TLC to work as intended (it requires enabling/using the docstore, which is disabled for most vectordb integrations)

Otherwise, it will just always insert duplicates
If I use the simple vec store same code works fine... I'll create simple example using the pgvec example code and see if I get the same thing. The delte does look straightforward... πŸ˜•
simple example works. it's me. somehow. thanks anyway. :thankyou50:
Add a reply
Sign up and join the conversation on Discord