langchain_community.vectorstores.baiducloud_vector_search.BESVectorStore¶
class langchain_community.vectorstores.baiducloud_vector_search.BESVectorStore(index_name: str, bes_url: str, user: Optional[str] = None, password: Optional[str] = None, embedding: Optional[Embeddings] = None, **kwargs: Optional[dict])[source]¶
Baidu Elasticsearch vector store.
Example
from langchain_community.vectorstores import BESVectorStore
from langchain_community.embeddings.openai import OpenAIEmbeddings
embeddings = OpenAIEmbeddings()
vectorstore = BESVectorStore(
    embedding=OpenAIEmbeddings(),
    index_name="langchain-demo",
    bes_url="http://localhost:9200"
)
Parameters
index_name – Name of the Elasticsearch index to create.
bes_url – URL of the Baidu Elasticsearch instance to connect to.
user – Username to use when connecting to Elasticsearch.
password – Password to use when connecting to Elasticsearch.
from (More information can be obtained) – 
https – //cloud.baidu.com/doc/BES/s/8llyn0hh4
Attributes
embeddings
Access the query embedding object if available.
Methods
__init__(index_name, bes_url[, user, ...])
aadd_documents(documents, **kwargs)
Run more documents through the embeddings and add to the vectorstore.
aadd_texts(texts[, metadatas])
Run more texts through the embeddings and add to the vectorstore.
add_documents(documents, **kwargs)
Run more documents through the embeddings and add to the vectorstore.
add_texts(texts[, metadatas])
Run more texts through the embeddings and add to the vectorstore.
adelete([ids])
Delete by vector ID or other criteria.