Run more texts through the embeddings and add to the vectorstore.
add_texts(
self,
texts: Iterable[str],
metadatas: Optional[List[Dict[Any, Any]]] = None,
ids: Optional[List[str]] = None,
refresh_indices: bool = True,
create_index_if_not_exists: bool = True,
bulk_kwargs: Optional[Dict] = None,
**kwargs: Any = {}
) -> List[str]| Name | Type | Description |
|---|---|---|
texts* | Iterable[str] | Iterable of strings to add to the vectorstore. |
metadatas | Optional[List[Dict[Any, Any]]] | Default: NoneOptional list of metadatas associated with the texts. |
ids | Optional[List[str]] | Default: NoneOptional list of ids to associate with the texts. |
refresh_indices | bool | Default: TrueWhether to refresh the Elasticsearch indices after adding the texts. |
create_index_if_not_exists | bool | Default: TrueWhether to create the Elasticsearch index if it doesn't already exist. |
*bulk_kwargs | Optional[Dict] | Default: NoneAdditional arguments to pass to Elasticsearch bulk.
|