Class RetrievalAugmentationAdvisor
java.lang.Object
org.springframework.ai.rag.advisor.RetrievalAugmentationAdvisor
- All Implemented Interfaces:
Advisor,BaseAdvisor,CallAdvisor,StreamAdvisor,org.springframework.core.Ordered
Advisor that implements common Retrieval Augmented Generation (RAG) flows using the
building blocks defined in the
org.springframework.ai.rag package and following
the Modular RAG Architecture.- Since:
- 1.0.0
- Author:
- Christian Tzolov, Thomas Vitale
- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsFields inherited from interface org.springframework.ai.chat.client.advisor.api.Advisor
DEFAULT_CHAT_MEMORY_PRECEDENCE_ORDERFields inherited from interface org.springframework.ai.chat.client.advisor.api.BaseAdvisor
DEFAULT_SCHEDULERFields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE -
Method Summary
Modifier and TypeMethodDescriptionafter(ChatClientResponse chatClientResponse, @Nullable AdvisorChain advisorChain) Logic to be executed after the rest of the advisor chain is called.before(ChatClientRequest chatClientRequest, @Nullable AdvisorChain advisorChain) Logic to be executed before the rest of the advisor chain is called.builder()intgetOrder()reactor.core.scheduler.SchedulerScheduler used for processing the advisor logic when streaming.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.springframework.ai.chat.client.advisor.api.BaseAdvisor
adviseCall, adviseStream, getName
-
Field Details
-
DOCUMENT_CONTEXT
- See Also:
-
-
Method Details
-
builder
-
before
public ChatClientRequest before(ChatClientRequest chatClientRequest, @Nullable AdvisorChain advisorChain) Description copied from interface:BaseAdvisorLogic to be executed before the rest of the advisor chain is called.- Specified by:
beforein interfaceBaseAdvisor
-
after
public ChatClientResponse after(ChatClientResponse chatClientResponse, @Nullable AdvisorChain advisorChain) Description copied from interface:BaseAdvisorLogic to be executed after the rest of the advisor chain is called.- Specified by:
afterin interfaceBaseAdvisor
-
getScheduler
public reactor.core.scheduler.Scheduler getScheduler()Description copied from interface:BaseAdvisorScheduler used for processing the advisor logic when streaming.- Specified by:
getSchedulerin interfaceBaseAdvisor
-
getOrder
public int getOrder()- Specified by:
getOrderin interfaceorg.springframework.core.Ordered
-