Package org.springframework.ai.chat.client.advisor
@NullMarked
package org.springframework.ai.chat.client.advisor
Provides classes for advising chat clients.
-
ClassesClassDescriptionUtilities to work with advisors.A
CallAdvisorthat uses aChatModelto generate a response.AStreamAdvisorthat uses aChatModelto generate a streaming response.Default implementation for theBaseAdvisorChain.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 promptAn advisor that blocks the call to the model provider if the user input contains any of the sensitive words.A simple logger advisor that logs the request and response messages.Advisor that validates the structured JSON output of a chat client response against a JSON schema derived from the configured output type or a pre-supplied schema string.Builder forStructuredOutputValidationAdvisor.Deprecated, for removal: This API element is subject to removal in a future version.ToolCallAdvisor.Builder<T extends ToolCallAdvisor.Builder<T>>Deprecated, for removal: This API element is subject to removal in a future version.since 2.0.0 in favor ofToolCallingAdvisor.Builder.Recursive Advisor that disables the internal tool execution flow and instead implements the tool calling loop as part of the advisor chain.ToolCallingAdvisor.Builder<T extends ToolCallingAdvisor.Builder<T>>Builder for creating instances of ToolCallingAdvisor.
ToolCallingAdvisor.