langchain.vectorstores.epsilla.Epsilla¶
class langchain.vectorstores.epsilla.Epsilla(client: Any, embeddings: Embeddings, db_path: Optional[str] = '/tmp/langchain-epsilla', db_name: Optional[str] = 'langchain_store')[source]¶
Wrapper around Epsilla vector database.
As a prerequisite, you need to install pyepsilla package
and have a running Epsilla vector database (for example, through our docker image)
See the following documentation for how to run an Epsilla vector database:
https://epsilla-inc.gitbook.io/epsilladb/quick-start
Parameters
client (Any) – Epsilla client to connect to.
embeddings (Embeddings) – Function used to embed the texts.
db_path (Optional[str]) – The path where the database will be persisted.
Defaults to “/tmp/langchain-epsilla”.
db_name (Optional[str]) – Give a name to the loaded database.
Defaults to “langchain_store”.
Example
from langchain.vectorstores import Epsilla
from pyepsilla import vectordb
client = vectordb.Client()
embeddings = OpenAIEmbeddings()
db_path = "/tmp/vectorstore"
db_name = "langchain_store"
epsilla = Epsilla(client, embeddings, db_path, db_name)
Initialize with necessary components.
Attributes
embeddings
Access the query embedding object if available.
Methods
__init__(client, embeddings[, db_path, db_name])
Initialize with necessary components.
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)