Camel 4.23 packages document ingestion as a RAG pipeline
A new component and four Kamelets connect file, object-store and event sources to LangChain4j embedding stores, with explicit limits for production use.
Apache Camel 4.23 adds a reusable ingestion layer for retrieval-augmented generation instead of leaving every application to rebuild the same read, parse, split, embed and store sequence. The project’s engineering walkthrough introduces camel-langchain4j-ingest alongside four ingestion Kamelets that can assemble a knowledge base from a directory, an S3 bucket, a Kafka topic or another Camel consumer.
What changed
The new producer component accepts a message body, divides it into overlapping segments, creates embeddings in batches and writes them to a LangChain4j EmbeddingStore. Camel says the path works from the Java and YAML DSLs, Camel Main and Camel JBang, provided the embedding model and store are registered as beans.
Four Kamelets make the surrounding pipeline declarative: a directory source, Tika text extraction, Docling conversion and an ingestion sink. That puts common controls—including include and exclude patterns, minimum and maximum document sizes, document identifiers and media handling—into route configuration rather than bespoke ingestion code.
The component can also treat images, audio, video or PDFs as single media objects when the configured embedding model supports the content type. Camel notes that LangChain4j providers currently offer image embeddings, while audio requires a custom model.
Who should care
The change is useful to integration teams already using Camel as the boundary between file systems, object stores, messaging systems and application services. A route can now carry source-system metadata into the vector store, including pipeline and document identifiers that retrieval code can use for citations.
Camel Quarkus users get a staged path. The 3.x extension can define text-ingestion pipelines through application properties. Camel Quarkus 4.0.0, which is not yet released, is expected to compose the full component-and-Kamelet pipeline with parser, filtering and media options.
What to test first
The project labels the component and Kamelets Preview, and its own walkthrough identifies operational limits that matter before production use. The default in-memory file register holds 1,000 entries and resets on restart; teams with larger or durable collections should configure a persistent, appropriately sized idempotent repository. Removing a source document does not remove its vectors, and re-ingesting an updated document can leave old segments in place.
Source-specific defaults also need review. Camel calls out that the S3 consumer deletes objects unless deleteAfterRead=false is set, while redelivering sources such as Kafka need an idempotent repository to avoid duplicate writes. The practical first test is therefore not only whether retrieval works, but whether restart, update and deletion behavior matches the knowledge base’s lifecycle requirements.
sources
comments · 0