Package org.springframework.ai.chat.client.advisor
@NonNullApi
@NonNullFields
package org.springframework.ai.chat.client.advisor
Provides classes for advising chat clients.
-
ClassDescriptionAbstract class that serves as a base for chat memory advisors.Abstract builder for
AbstractChatMemoryAdvisor
.Implementation of theCallAroundAdvisorChain
andStreamAroundAdvisorChain
.Returns a new list of content (e.g list of messages of list of documents) that is a subset of the input list of contents and complies with the max token size constraint.Memory is retrieved added as a collection of messages to the promptMemory is retrieved added into the prompt's system text.Context for the question is retrieved from a Vector Store and added to the prompt's user text.Advisor that implements common Retrieval Augmented Generation (RAG) flows using the building blocks defined in theorg.springframework.ai.rag
package and following the Modular RAG Architecture.ACallAroundAdvisor
andStreamAroundAdvisor
that filters out the response if the user input contains any of the sensitive words.A simple logger advisor that logs the request and response messages.Memory is retrieved from a VectorStore added into the prompt's system text.