langchain.vectorstores.llm_rails.LLMRails¶
class langchain.vectorstores.llm_rails.LLMRails(datastore_id: Optional[str] = None, api_key: Optional[str] = None)[source]¶
Implementation of Vector Store using LLMRails (https://llmrails.com/).
.. rubric:: Example
from langchain.vectorstores import LLMRails
vectorstore = LLMRails(
    api_key=llm_rails_api_key,
    datastore_id=datastore_id
)
Initialize with LLMRails API.
Attributes
embeddings
Access the query embedding object if available.
Methods
__init__([datastore_id, api_key])
Initialize with LLMRails API.
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.
afrom_documents(documents, embedding, **kwargs)
Return VectorStore initialized from documents and embeddings.
afrom_texts(texts, embedding[, metadatas])
Return VectorStore initialized from texts and embeddings.
amax_marginal_relevance_search(query[, k, ...])
Return docs selected using the maximal marginal relevance.
amax_marginal_relevance_search_by_vector(...)
Return docs selected using the maximal marginal relevance.
as_retriever(**kwargs)
Return VectorStoreRetriever initialized from this VectorStore.
asearch(query, search_type, **kwargs)
Return docs most similar to query using specified search type.