spring-projects / spring-ai

An Application Framework for AI Engineering
https://docs.spring.io/spring-ai/reference/index.html
Apache License 2.0
3.32k stars 850 forks source link

Modular RAG: Orchestration and Post-Retrieval #1767

Closed ThomasVitale closed 1 day ago

ThomasVitale commented 2 days ago

Pre-Retrieval:

Retrieval:

Post-Retrieval:

Orchestration:

Generation:

Advisor:

Relates to #gh-1603

markpollack commented 1 day ago

I had to add

<dependency>
    <groupId>io.micrometer</groupId>
    <artifactId>context-propagation</artifactId>
    <scope>test</scope>
</dependency>

to the spring-ai-integration-test to avoid classdef not found . I would have thought it would come transitively.

markpollack commented 1 day ago

This test didn't pass in the maven build in the terminal, but does in the IDE.

[ERROR] org.springframework.ai.integration.tests.client.advisor.RetrievalAugmentationAdvisorIT.ragWithTranslation -- Time elapsed: 2.402 s <<< FAILURE!
java.lang.AssertionError: 

Expecting actual:
  "Anacletus og Birbas eventyr finder sted i de skotske højland."
to contain:
  "Highlands"
 (ignoring case)
    at org.springframework.ai.integration.tests.client.advisor.RetrievalAugmentationAdvisorIT.ragWithTranslation(RetrievalAugmentationAdvisorIT.java:131)
    at java.base/java.lang.reflect.Method.invoke(Method.java:569)
    at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
    at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)

seems like the model sometimes doesn't follow instructions?

markpollack commented 1 day ago

merged in d759fb294bac1a811283d4a620fa0d15c66409d8 Will see how well the CI handles the test.