langchain.vectorstores.hologres.HologresWrapper

class langchain.vectorstores.hologres.HologresWrapper(connection_string: str, ndims: int, table_name: str)[source]

Hologres API wrapper.

Initialize the wrapper.

Parameters
  • connection_string – Hologres connection string.

  • ndims – Number of dimensions of the embedding output.

  • table_name – Name of the table to store embeddings and data.

Methods

__init__(connection_string, ndims, table_name)

Initialize the wrapper.

create_table([drop_if_exist])

create_vector_extension()

get_by_id(id)

insert(embedding, metadata, document[, id])

query_nearest_neighbours(embedding, k[, filter])

__init__(connection_string: str, ndims: int, table_name: str) None[source]

Initialize the wrapper.

Parameters
  • connection_string – Hologres connection string.

  • ndims – Number of dimensions of the embedding output.

  • table_name – Name of the table to store embeddings and data.

create_table(drop_if_exist: bool = True) None[source]
create_vector_extension() None[source]
get_by_id(id: str) List[Tuple][source]
insert(embedding: List[float], metadata: dict, document: str, id: Optional[str] = None) None[source]
query_nearest_neighbours(embedding: List[float], k: int, filter: Optional[Dict[str, str]] = None) List[Tuple[str, str, float]][source]