jamesnetherton commented on PR #9133:
URL: https://github.com/apache/camel-quarkus/pull/9133#issuecomment-5631348174

   Thanks @JiriOndrusek. Digging into your points turned up more than a missing 
warning, so here's a proposal before I push anything.
   
   What changed my view:
   
   - Before this PR, the zero-config augmentor fired on "≥1 `EmbeddingStore` + 
≥1 `EmbeddingModel` bean" in any app using one of the six extensions that 
depend on `support-langchain4j`. Apart from ingest, none of them fill a store, 
so RAG could switch on without being asked for.
   - `langchain4j-ingest` is a legitimate bridge user. It fills stores through 
CDI beans without the embeddingstore component, and its docs promise the 
bridge. You're right on the agent nit too: 
`AgentConfiguration.withRetrievalAugmentor` exists. I'll fix the PR text.
   
   Proposal:
   
   1. **All RAG code stays in `langchain4j-embeddingstore`, auto-detection 
included and unchanged.** Scoped to extensions that fill stores, zero-config is 
what a user adding them expects, the same model as Easy RAG. An AI service can 
opt out with `@RegisterAiService(retrievalAugmentor = 
RegisterAiService.NoRetrievalAugmentorSupplier.class)`, which I'll document.
   2. **`langchain4j-ingest` depends on `langchain4j-embeddingstore`**, so 
ingest apps keep the bridge exactly as in 3.39.0. The cost is 
`camel-langchain4j-embeddingstore` and `langchain4j-embeddings` on ingest's 
classpath.
   3. **Nothing RAG-related goes back into `support-langchain4j`.** Detecting 
the bridge's absence there needs a copy of the bean census, the Easy RAG check 
and the config prefix, which puts back the code this PR removes.
   4. **Who changes:** apps on chat/agent/tools/web-search/embeddings without 
embeddingstore or ingest. Zero-config ones stop receiving an augmentor over a 
store no Camel component wrote to. Ones configuring `rag.*` get Quarkus's 
unrecognized-key warning, and the migration guide tells them to add 
embeddingstore.
   
   Does that address your concern? The part I'd most like your view on is 4: 
whether the unrecognized-key warning plus the guide is enough there.
   
   *This review was generated by an AI agent and may contain inaccuracies. 
Please verify all suggestions before applying.*
   
   *Claude Code on behalf of James Netherton*
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to