fileSupplier is a Spring Function Catalog function that watches a directory for new files, emits their bytes, and passes them to the next function in a composed pipeline. section 4.3.1 section 4.3.2
Configure fileSupplier as the ingestion stage of a reactive document loader:
- Add the Spring Functions Catalog file-supplier dependency; its bean is autoconfigured in the application context. section 4.3.1
- Set file.supplier.directory to the directory that receives incoming files, such as /var/dropoff. section 4.3.2
- Use file.supplier.filename-regex to accept only desired formats, such as PDF, DOCX, and plain-text files. section 4.3.2
- Compose fileSupplier with documentReader, splitter, titleDeterminer, and vectorStoreConsumer using a pipe-delimited function definition. section 4.3.2
Directory-to-vector-store loader
A loader can watch /var/dropoff, select files matching .*\.(pdf|docx|txt), and emit a Flux<byte[]> to a TikaDocumentReader. The reader produces Documents, a splitter creates chunks, and a vector-store consumer persists them. section 4.3.2 section 4.3.3
spring.cloud.function.definition=\ fileSupplier|\ documentReader|\ splitter|\ titleDeterminer|\ vectorStoreConsumer
Inspect the complete pipe-delimited definition connecting fileSupplier to document parsing, splitting, title determination, and vector-store persistence. section 4.3.2
