Skip to content

Commit

Permalink
Improve AnalyticDB Vector Store implementation without affecting user (
Browse files Browse the repository at this point in the history
…#6086)

Hi there:

As I implement the AnalyticDB VectorStore use two table to store the
document before. It seems just use one table is a better way. So this
commit is try to improve AnalyticDB VectorStore implementation without
affecting user behavior:

**1. Streamline the `post_init `behavior by creating a single table with
vector indexing.
2. Update the `add_texts` API for document insertion.
3. Optimize `similarity_search_with_score_by_vector` to retrieve results
directly from the table.
4. Implement `_similarity_search_with_relevance_scores`.
5. Add `embedding_dimension` parameter to support different dimension
embedding functions.**

Users can continue using the API as before. 
Test cases added before is enough to meet this commit.
  • Loading branch information
wangxuqi authored Jun 17, 2023
1 parent cdd1d78 commit 444ca3f
Show file tree
Hide file tree
Showing 2 changed files with 147 additions and 188 deletions.
Loading

1 comment on commit 444ca3f

@vercel
Copy link

@vercel vercel bot commented on 444ca3f Jun 17, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

langchain – ./

langchain-git-master-langchain.vercel.app
python.langchain.com
langchain-langchain.vercel.app

Please sign in to comment.