langchain
77235bbe - propogate kwargs to cls in OpenSearchVectorSearch (#3416)

Commit
2 years ago
propogate kwargs to cls in OpenSearchVectorSearch (#3416) kwargs shoud be passed into cls so that opensearch client can be properly initlized in __init__(). Otherwise logic like below will not work. as auth will not be passed into __init__ ```python docsearch = OpenSearchVectorSearch.from_documents(docs, embeddings, opensearch_url="http://localhost:9200") query = "What did the president say about Ketanji Brown Jackson" docs = docsearch.similarity_search(query) ``` Co-authored-by: EC2 Default User <ec2-user@ip-172-31-28-97.ec2.internal>
Author
Parents
Loading