Usage
Parameters
files
(List[Union[str, bytes, BinaryIO, Path]]): List of files to ingest (path strings, bytes, file objects, or Path objects)metadata
(Dict[str, Any] | List[Dict[str, Any]], optional): Metadata to apply to the files. Can be either:- A single dict to apply to all files
- A list of dicts, one per file (must match the length of
files
)
rules
(List, optional): Rules to apply during ingestion. Can be either:- A single list of rules to apply to all files
- A list of rule lists, one per file
use_colpali
(bool, optional): Whether to use ColPali-style embedding model. Defaults to True.parallel
(bool, optional): Whether to process files in parallel. Defaults to True.
Returns
An object containing:documents
: List of successfully ingested Document objectserrors
: List of errors encountered during ingestion (each error is a dict with ‘filename’ and ‘error’ keys)