Create a list of Document objects from a list of json objects (dict).
create_documents(
self,
texts: list[dict[str, Any]],
convert_lists: bool = False,
ensure_ascii: bool = True,
metadatas: list[dict[Any, Any]] | None = None
) -> list[Document]| Name | Type | Description |
|---|---|---|
texts* | list[dict[str, Any]] | A list of JSON data to be split and converted into documents. |
convert_lists | bool | Default: FalseWhether to convert lists to dictionaries before splitting. |
ensure_ascii | bool | Default: TrueWhether to ensure ASCII encoding in the JSON strings. |
metadatas | list[dict[Any, Any]] | None | Default: NoneOptional list of metadata to associate with each document. |