langchain
langchain copied to clipboard
PGVector is Lacking Basic Features
Feature request
PGVector lacks Upsert and deletion capabilities.
I have to custom create this functionality.
Motivation
I want to use PGVector because it's easy to implement and I don't require to deal with DB vector providers.
Your contribution
If you deem this useful I will try propose a pull request.
Answer generated by a 🤖
Answer
That's great to hear that you're interested in contributing to LangChain! Your proposed feature request to add Upsert and deletion capabilities to PGVector sounds like a valuable addition. It would definitely enhance the functionality and usability of the framework.
I encourage you to go ahead and create a pull request with your proposed changes. The maintainers will review your contribution and provide feedback. Thank you for your willingness to contribute and help improve LangChain!
This response is meant to be useful, save you time, and share context. It is not meant to be a precise solution, but rather a starting point for your own research.
Help me be more useful! Please leave a 👍 if this is helpful and 👎 if it is irrelevant.
+1 !
That's not the only thing lacking in Langchain. There have been issues reported with using pgvector and HuggingFace (or really anything not OpenAI) embeddings for months now that have gotten zero response. There have been multiple PRs to fix, and they have been ignored and allowed to bit-rot.
Even more basic feature is, I have my table to store embeddings setup and migrated using Django. And I have custom schema, it just doesn't support custom schema. So I am effectively writing this part of indexing in my table all by myself.
I would also like to set the PG schema to use. Basically add __table_args__ = {'schema': 'vectorstore'}
to the base DB model BaseModel
. This way, schema mapping can be used when creating connection by passing
execution_options={
"schema_translate_map": {"vectorstore", "my_schema"}
}
So that all doesn't just go into the default "public" schema.
Hi, @notchatbot! I'm Dosu, and I'm here to help the LangChain team manage their backlog. I wanted to let you know that we are marking this issue as stale.
From what I understand, you requested the addition of Upsert and deletion capabilities to PGVector. You mentioned that you are willing to contribute by proposing a pull request if the feature is deemed useful. The maintainers will review your contribution once you create the pull request.
I also noticed that other users have raised concerns about other lacking features and issues with using pgvector and HuggingFace embeddings.
Before we close this issue, we wanted to check with you if it is still relevant to the latest version of the LangChain repository. If it is, please let us know by commenting on the issue. Otherwise, feel free to close the issue yourself or it will be automatically closed in 7 days.
Thank you for your understanding and contribution!
@nb-programmer can you pls elaborate the solution a little more? Or any doc from where I can refer this?
Your help will be highly appreciated 👍