langchain
262d4cb9 - Use embedding instead of embedding function in ElasticVectorStore (#1692)

Commit
2 years ago
Use embedding instead of embedding function in ElasticVectorStore (#1692) While it might be a bit more restrictive, I find that using the Embedding interface as an input for the vector store creation is better than an embedding function because we can use bulk requests and possibly the retry logic if needed. I have seen that some vector store implementations use Embedding while others use embedding function so I don't know what is the criteria to have one or the other, in my opinion they should all just be Embedding or have a way more complex embedding function that accepts multiple texts instead of one by one. --------- Co-authored-by: Bernat Felip <bernat.felip@rea.ch>
Parents
Loading