- Sync
- Async
Parameters
file(Union[str, bytes, BinaryIO, Path]): File to ingest (path string, bytes, file object, or Path)filename(str, optional): Name of the filemetadata(Dict[str, Any], optional): Optional metadata dictionaryrules(List[RuleOrDict], optional): Optional list of rules to apply during ingestion. Can be:MetadataExtractionRule: Extract metadata using a schemaNaturalLanguageRule: Transform content using natural language
use_colpali(bool, optional): Whether to use ColPali-style embedding model to ingest the file (slower, but significantly better retrieval accuracy for images). Defaults to True.
Returns
Document: Metadata of the ingested document
Examples
- Sync
- Async

