Skip to content

Commit f902229

Browse files
committed
Modular RAG - Query Analysis
Query Analysis * Introduce Query Analysis Module * Define QueryTransformer API and TranslationQueryTransformer implementation * Define QueryExpander API and MultiQueryExpander implementation * Support QueryTransformer in RetrievalAugmentationAdvisor (support for QueryExpander will be in the next PR together with the needed DocumentFuser API). Improvements * Refine Retrieval and Augmentation Modules for increased robustness * Expand test coverage for both modules * Define clone() method for ChatClient.Builder Tests * Introduce “spring-ai-integration-tests” for full-fledged integration tests * Add integration tests for RAG modules * Add integration tests for RAG advisor Relates to #gh-1603 Signed-off-by: Thomas Vitale <[email protected]>
1 parent 5100672 commit f902229

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

spring-ai-core/src/main/java/org/springframework/ai/chat/client/advisor/RetrievalAugmentationAdvisor.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ public RetrievalAugmentationAdvisor(List<QueryTransformer> queryTransformers, Do
8080
this.queryTransformers = queryTransformers;
8181
this.documentRetriever = documentRetriever;
8282
this.queryAugmentor = queryAugmentor != null ? queryAugmentor : ContextualQueryAugmentor.builder().build();
83-
this.protectFromBlocking = protectFromBlocking != null ? protectFromBlocking : false;
83+
this.protectFromBlocking = protectFromBlocking != null ? protectFromBlocking : true;
8484
this.order = order != null ? order : 0;
8585
}
8686

spring-ai-integration-tests/src/test/resources/application.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ spring:
33
web-application-type: none
44
ai:
55
openai:
6+
api-key: ${OPENAI_API_KEY}
67
chat:
78
options:
89
model: gpt-4o-mini

0 commit comments

Comments
 (0)