All Classes and Interfaces

Class
Description
Abstract class that serves as a base for chat memory advisors.
Abstract builder for AbstractChatMemoryAdvisor.
Abstract StructuredOutputConverter implementation that uses a pre-configured DefaultConversionService to convert the LLM output into the desired type format.
Abstract implementation of the EmbeddingModel interface that provides dimensions calculation caching.
AbstractFilterExpressionConverter is an abstract class that implements the FilterExpressionConverter interface.
The AbstractMessage class is an abstract implementation of the Message interface.
Abstract StructuredOutputConverter implementation that uses a pre-configured MessageConverter to convert the LLM output into the desired type format.
Abstract base class for VectorStore implementations that provides observation capabilities.
 
Deprecated.
Use ToolCallingManager instead.
Abstract base builder implementing common builder functionality for VectorStore.
The data of the chat client request that can be modified before the execution of the ChatClient's call method
Builder for AdvisedRequest.
The data of the chat client response that can be modified before the call returns.
Builder for AdvisedResponse.
Parent advisor interface for all advisors.
Context used to store metadata for chat client advisors.
The type of the advisor.
Interface for an ObservationConvention for chat client advisors.
AI Advisor observation documentation.
High cardinality key names.
Low cardinality key names.
Collection of attribute keys used in AI observations (spans, metrics, events).
Collection of event names used in AI observations.
Collection of metric attributes used in AI observations.
Enumeration of metric names used in AI observations.
Metadata associated with an AI operation (e.g.
Builder for AiOperationMetadata.
Types of operations performed by AI systems.
Collection of systems providing AI functionality.
Utility methods for creating native runtime hints.
Types of tokens produced and consumed in an AI operation.
Some model providers API leverage short-lived api keys which must be renewed at regular intervals using another credential.
Lets the generative know the content was generated as a response to the user.
 
 
Represents a response returned by the AI.
Metadata associated with an audio transcription result.
Options for audio transcription.
Represents an audio transcription prompt for an AI model.
A response containing an audio transcription result.
Metadata associated with an audio transcription response.
Base advisor that implements common aspects of the CallAroundAdvisor and StreamAroundAdvisor, reducing the boilerplate code needed to implement an advisor.
Contract for batching Document objects so that the call to embed them could be optimized.
An implementation of StructuredOutputConverter that transforms the LLM output to a specific object type using JSON schema.
Around advisor that wraps the ChatModel#call(Prompt) method.
The Call Around Advisor Chain is used to invoke the next Around Advisor in the chain.
The Categories class represents a set of categories used to classify content.
 
This class represents the scores for different categories of content.
 
Client to perform stateless requests to an AI Model, using a fluent API.
 
A mutable builder for creating a ChatClient.
 
 
 
Specification for a prompt system.
 
 
 
Callback interface that can be used to customize a ChatClient.Builder.
An ObservationFilter to include the chat prompt content in the observation.
Context used to store metadata for chat client workflows.
 
Interface for an ObservationConvention for chat client workflows.
Documented conventions for chat client observations.
 
 
Represents the metadata associated with the generation of a chat response.
 
The ChatMemory interface represents a storage for chat conversation history.
 
An ObservationFilter to include the chat completion content in the observation.
Handler for including the chat completion content in the observation as a span event.
Marker interface, to be used to store info on the model such as the current context length.
Handler for generating metrics from chat model observations.
Utilities to process the prompt and completion content in observations for chat models.
Context used to store metadata for chat model exchanges.
 
Interface for an ObservationConvention for chat model exchanges.
Documented conventions for chat model observations.
Events for chat model operations.
High-cardinality observation key names for chat model operations.
Low-cardinality observation key names for chat model operations.
An ObservationFilter to include the chat prompt content in the observation.
Handler for including the chat prompt content in the observation as a span event.
ModelOptions representing the common options that are portable across different chat models.
Builder for creating ChatOptions instance.
A PromptTemplate that lets you specify the role as a string should the current implementations and their roles not suffice for your needs.
The chat completion (e.g.
 
Models common AI provider metadata returned in an AI response.
 
Uses a large language model to compress a conversation history and a follow-up query into a standalone query that captures the essence of the conversation.
 
Combines documents retrieved based on multiple queries and from multiple data sources by concatenating them into a single collection of documents.
Data structure that contains content and metadata.
Converts the Document text and metadata into an AI, prompt-friendly text representation.
ContentFormatTransformer processes a list of documents by applying a content formatter to each document.
Augments the user query with contextual data from the content of the provided documents.
 
Default implementation of the AdvisorObservationConvention.
 
The default implementation of ChatClient as created by the ChatClient.Builder.build() } method.
 
 
 
 
 
 
 
 
DefaultChatClientBuilder is a builder class for creating a ChatClient.
Default conventions to populate observations for chat client workflows.
Default implementation of ChatGenerationMetadata.
 
Default conventions to populate observations for chat model operations.
Default implementation for the ChatOptions.
Implementation of ChatOptions.Builder to create DefaultChatOptions.
Deprecated.
Use specific builder for the type of tool you need, e.g.
Default implementation of ContentFormatter.
 
Default conventions to populate observations for embedding model operations.
Deprecated.
Use specific builder for the type of tool you need, e.g.
Deprecated.
Deprecated.
Deprecated.
Default conventions to populate observations for image model operations.
Default implementation of ToolCallingChatOptions.
Default implementation of ToolCallingChatOptions.Builder.
Default implementation of ToolCallingManager.
 
A default implementation of ToolCallResultConverter.
Default implementation of ToolDefinition.
 
Default implementation of ToolExecutionExceptionProcessor.
 
Default implementation of ToolExecutionResult.
 
Default implementation of ToolMetadata.
 
Default implementation of the Usage interface.
Default conventions to populate observations for vector store operations.
A ToolCallbackResolver that delegates to a list of ToolCallbackResolver instances.
A document is a container for the content and metadata of a document.
 
A component for compressing the content of each document to reduce noise and redundancy in the retrieved information, addressing challenges such as "lost-in-the-middle" and context length restrictions from the model.
EmbeddingModel is a generic interface for embedding models.
Represents a request to embed a list of documents.
A component for combining documents retrieved based on multiple queries and from multiple data sources into a single collection of documents.
Common set of metadata keys used in Documents by DocumentReaders and VectorStores.
A component for ordering and ranking documents based on their relevance to a query to bring the most relevant documents to the top of the list, addressing challenges such as "lost-in-the-middle".
 
Component responsible for retrieving Documents from an underlying data source, such as a search engine, a vector store, a database, or a knowledge graph.
A component for removing irrelevant or redundant documents from a list of retrieved documents, addressing challenges such as "lost-in-the-middle" and context length restrictions from the model.
 
Write a list of Document instances.
Represents a single embedding vector.
EmbeddingModel is a generic interface for embedding models.
Description of an embedding model.
Handler for generating metrics from embedding model observations.
Context used to store metadata for embedding model exchanges.
 
Interface for an ObservationConvention for embedding model exchanges.
Documented conventions for embedding model observations.
High-cardinality observation key names for embedding model operations.
Low-cardinality observation key names for embedding model operations.
Options for embedding models.
Builder for EmbeddingOptions.
Request to embed a list of input instructions.
Embedding response object.
Common AI provider metadata returned in an embedding response.
Metadata associated with the embedding result.
 
 
Utility methods for embedding related operations.
 
A RateLimit implementation that returns zero for all property getters
A EmpytUsage implementation that returns zero for all property getters
An ObservationHandler that logs errors using a Tracer.
Represents an evaluation request, which includes the user's text, a list of content data, and a chat response.
 
 
A utility to reformat extracted text content before encapsulating it in a Document.
The Builder class is a nested static class of ExtractedTextFormatter designed to facilitate the creation and customization of instances of ExtractedTextFormatter.
Implementation of Evaluator used to evaluate the factual accuracy of Large Language Model (LLM) responses against provided context.
Writes the content of a list of Documents into a file.
Portable runtime generative for metadata filter expressions.
Triple that represents and filter boolean expression as left type right.
Filter expression operations.
Represents expression grouping (e.g.
String identifier representing an expression key.
Mark interface representing the supported expression types: Filter.Key, Filter.Value, Filter.Expression and Filter.Group.
Represents expression value constant or constant array.
DSL builder for Filter.Expression instances.
 
Converters a generic, portable Filter.Expression into a VectorStore specific expression language format.
Parse a textual, vector-store agnostic, filter expression language into Filter.Expression.
 
 
 
Helper class providing various boolean transformation.
This class provides an empty implementation of FiltersListener, which can be extended to create a listener which only needs to handle a subset of the available methods.
This class provides an empty implementation of FiltersVisitor, which can be extended to create a visitor which only needs to handle a subset of the available methods.
 
This interface defines a complete listener for a parse tree produced by FiltersParser.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
This interface defines a complete generic visitor for a parse tree produced by FiltersParser.
Implementations of this interface provides instructions for how the output of a language generative should be formatted.
Deprecated.
in favor of ToolCallback.
Deprecated.
Use specific builder for the type of tool you need, e.g.
 
Function invoking builder interface.
Method invoking builder interface.
Describes the type of the schema used to describe the input parameters of the function.
Deprecated.
Deprecated.
Use ToolCallingManager instead.
Helper used to provide only the function definition, without the actual function call implementation.
Deprecated.
Builder for creating FunctionCallingOptions instance.
Deprecated.
 
A ToolCallback implementation to invoke functions as tools.
 
Represents a response returned by the AI.
The Generation class represents a response from a moderation process.
Interface for generating unique document IDs.
 
 
 
 
 
Context used to store metadata for image model exchanges.
 
Interface for an ObservationConvention for image model exchanges.
Documented conventions for image model observations.
Events for image model operations.
High-cardinality observation key names for image model operations.
Low-cardinality observation key names for image model operations.
An ObservationFilter to include the image prompt content in the observation.
ImageOptions represent the common options, portable across different image generation models.
 
 
The image completion (e.g.
Represents metadata associated with an image response.
The InMemoryChatMemory class is an implementation of the ChatMemory interface that represents an in-memory storage for chat conversation history.
Utility methods for Jackson.
A SHA-256 based ID generator that returns the hash as a UUID.
 
Utilities to perform parsing operations between JSON and Java.
A class that reads JSON documents and converts them into a list of Document objects.
Utilities to generate JSON Schemas from Java types and method signatures.
Options for generating JSON Schemas.
Estimates the number of tokens in a given text or message using the JTokkit encoding library.
Keyword extractor that uses generative to extract 'excerpt_keywords' metadata field.
 
 
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.
Deprecated.
Only to help moving away from AbstractToolCallSupport.
 
StructuredOutputConverter implementation that uses a DefaultConversionService to convert the LLM output into a List instance.
Utility class that provides predefined SLF4J Marker instances used in logging operations within the application.
StructuredOutputConverter implementation that uses a pre-configured MappingJackson2MessageConverter to convert the LLM output into a java.util.Map<String, Object> instance.
The Media class represents the data and metadata of a media attachment in a message.
Builder class for Media.
Common media formats.
 
The Message interface represents a message that can be sent or received in a chat application.
Helper that for streaming chat responses, aggregate the chat response messages into a single AssistantMessage.
 
Memory is retrieved added as a collection of messages to the prompt
 
Enumeration representing types of Messages in a chat application.
 
Deprecated.
in favor of MethodToolCallback.
A ToolCallback implementation to invoke methods as tools.
 
A ToolCallbackProvider that builds ToolCallback instances from Tool-annotated methods.
 
Model<TReq extends ModelRequest<?>,TRes extends ModelResponse<?>>
The Model interface provides a generic API for invoking AI models.
Describes an AI model's basic characteristics.
Context used when sending a request to a machine learning model and waiting for a response from the model provider.
Interface representing the customizable options for AI model interactions.
Utility class for manipulating ModelOptions objects.
Interface representing a request to an AI model.
Interface representing the response received from an AI model.
This interface provides methods to access the main output of the AI model and the metadata associated with this result.
Generate metrics about the model usage in the context of an AI operation.
The Moderation class represents the result of a moderation process.
 
An interface that represents metadata associated with the results of a moderation generation process.
Represents a single message intended for moderation, encapsulating the text content.
The ModerationModel interface defines a generic AI model for moderation.
Represents the options for moderation.
A builder class for creating instances of ModerationOptions.
Represents a prompt for moderation containing a single message and the options for the moderation model.
Represents a response from a moderation process, encapsulating the moderation metadata and the generated content.
Defines the metadata associated with a moderation response, extending a base response interface.
Represents the result of a moderation process, indicating whether content was flagged, the categories of moderation, and detailed scores for each category.
 
Uses a large language model to expand a query into multiple semantically diverse variations to capture different perspectives, useful for retrieving additional contextual information and increasing the chances of finding relevant results.
 
 
This implementation of ApiKey indicates that no API key should be used, e.g.
Utility methods for String parsing.
Converts Filter.Expression into Pinecone metadata filter expression format.
Converts Filter.Expression into test string format.
The Prompt class represents a prompt used in AI model requests.
Assertion utility class that assists in validating arguments for prompt-related operations.
Memory is retrieved added into the prompt's system text.
 
Abstract Data Type (ADT) modeling metadata gathered by the AI during request processing.
Abstract Data Type (ADT) modeling filter metadata for all prompts sent during an AI request.
 
 
 
 
 
Represents a query in the context of a Retrieval Augmented Generation (RAG) flow.
 
A component for augmenting an input query with additional data, useful to provide a large language model with the necessary context to answer the user query.
A component for expanding the input query into a list of queries, addressing challenges such as poorly formed queries by providing alternative query formulations, or by breaking down complex problems into simpler sub-queries.
A component for transforming the input query to make it more effective for retrieval tasks, addressing challenges such as poorly formed queries, ambiguous terms, complex vocabulary, or unsupported languages.
Context for the question is retrieved from a Vector Store and added to the prompt's user text.
 
A random ID generator that returns a UUID.
Abstract Data Type (ADT) encapsulating metadata from an AI provider's API rate limits granted to the API key in use and the API key's current balance.
 
Miscellaneous Resource utility methods.
Represents a Model response that includes the entire response along withe specified response entity type.
Interface representing metadata associated with an AI model's response.
Interface representing metadata associated with the results of an AI model.
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.
 
Uses a large language model to rewrite a user query to provide better results when querying a target system, such as a vector store or a web search engine.
 
A CallAroundAdvisor and StreamAroundAdvisor that filters out the response if the user input contains any of the sensitive words.
 
The type of schema to generate for a given Java type.
Similarity search request.
SearchRequest Builder.
A simple implementation of ApiKey that holds an immutable API key value.
A simple logger advisor that logs the request and response messages.
SimpleVectorStore is a simple implementation of the VectorStore interface.
 
 
An immutable Content implementation representing content, metadata, and its embeddings.
Converts Filter.Expression into SpEL metadata filter expression format.
 
Types of Spring AI constructs which can be observed.
JSON Schema Generator Module for Spring AI.
Options for customizing the behavior of the module.
A Spring ApplicationContext-based implementation that provides a way to retrieve a bean from the Spring context and wrap it into a ToolCallback.
 
A simple implementation of ToolCallbackProvider that maintains a static array of FunctionCallback objects.
A ToolCallbackResolver that resolves tool callbacks from a static registry.
Around advisor that runs around stream based requests.
The StreamAroundAdvisorChain is used to delegate the call to the next StreamAroundAdvisor in the chain.
 
The StreamingModel interface provides a generic API for invoking an AI models with streaming response.
Converts the (raw) LLM output into a structured responses of type.
Title extractor with adjacent sharing that uses generative to extract 'section_summary', 'prev_section_summary', 'next_section_summary' metadata fields.
 
A message of the type 'system' passed as input.
 
 
A DocumentReader that reads text from a Resource.
 
Token count based strategy implementation for BatchingStrategy.
Estimates the number of tokens in a given text or message.
A TextSplitter that splits text into chunks of a target size in tokens.
 
Marks a method as a tool in Spring AI.
Represents a tool whose execution can be triggered by an AI model.
Provides ToolCallback instances for tools defined in different sources.
A resolver for ToolCallback instances.
Provides ToolCallback instances for tools defined in different sources.
A set of options that can be used to configure the interaction with a chat model, including tool calling.
A builder to create a ToolCallingChatOptions instance.
Service responsible for managing the tool calling process for a chat model.
A functional interface to convert tool call results to a String that can be sent back to the AI model.
Represents the context for tool execution in a function calling scenario.
Definition used by the AI model to determine when and how to call the tool.
An exception thrown when a tool execution fails.
A functional interface to process a ToolExecutionException by either converting the error message to a String that can be sent back to the AI model or throwing an exception to be handled by the caller.
The result of a tool execution.
Metadata about a tool specification and execution.
Marks a tool argument.
The ToolResponseMessage class represents a message with a function content in a chat application.
 
Registers runtime hints for the tool calling APIs.
Miscellaneous tool utility methods.
Utilities to prepare and process traces for observability.
Uses a large language model to translate a query to a target language that is supported by the embedding model used to generate the document embeddings.
 
A utility class that provides methods for resolving types and classes related to functions.
Abstract Data Type (ADT) encapsulating metadata on the usage of an AI provider's API per AI request.
An utility class to provide support methods handling Usage.
A message of the type 'user' passed as input Messages with the user role are from the end-user or developer.
The VectorStore interface defines the operations for managing and querying documents in a vector database.
Builder interface for creating VectorStore instances.
Memory is retrieved from a VectorStore added into the prompt's system text.
 
Retrieves documents from a vector store that are semantically similar to the input query.
Collection of attribute keys used in vector store observations (spans, metrics, events).
Utilities to process the query content in observations for vector store operations.
Context used to store metadata for vector store operations.
 
 
A ObservationConvention for VectorStoreObservationContext.
Documented conventions for vector store observations.
High-cardinality observation key names for vector store operations.
Low-cardinality observation key names for vector store operations.
Collection of event names used in vector store observations.
Collection of systems providing vector store functionality.
An ObservationFilter to include the Vector Store search response content in the observation.
Handler for including the query response content in the observation as a span event.
Types of similarity metrics used in vector store operations.