Module key_value_store (0.6.0)

API documentation for key_value_store module.

Classes

BigtableByteStore

BigtableByteStore(
    engine: langchain_google_bigtable.engine.BigtableEngine,
    instance_id: str,
    table_id: str,
    column_family: str = "kv",
    column_qualifier: bytes = b"val",
    app_profile_id: typing.Optional[str] = None,
)

LangChain Key-value store implementation for Google Cloud Bigtable, supporting both sync and async methods using BigtableEngine.

Modules Functions

init_key_value_store_table

init_key_value_store_table(
    instance_id: str,
    table_id: str,
    project_id: typing.Optional[str] = None,
    client: typing.Optional[google.cloud.bigtable.client.Client] = None,
    column_families: typing.List[str] = ["kv"],
) -> None

Create a table for saving of LangChain Key-value pairs.

Parameters
Name Description
instance_id str

The Instance ID for the table to be created for.

table_id str

The Table ID for the table.

column_families Optional[List[str]]

The column families for the new table.

Exceptions
Type Description
I raises ValueError if a table with the given table_id already exists.: