- introduce copy() method to the ChatOptions.
- make sure that the DefaultChatClientRequestSpec takes a copy of the input chat options to prevent multation.
- add a OpenAiChatClientMultipleFunctionCallsIT to reproduce the problem and verify the solution.
Resolves#1064
* Remove inheritance from HashMap
* No more subclasses per model provider
* Builder class for ChatResponse
* Fix the AbstractResponseMetadata#AI_METADATA_STRING parameter order
* ChatResponseMetadata ignore Null values.
- re-assign the model on withSystemInstruction return.
- deprecate the gemini-pro-vision model and replace the default model to gemin-pro-1.5
- update docs.
- improve system message handling implementation.
Resolves#1030
Co-authored-by: Christian Tzolov <ctzolov@vmware.com>
- Moves these from free-text key/value pairs to interface
- Enables programmatic use for evaluation and observability
Signed-off-by: Thomas Vitale <ThomasVitale@users.noreply.github.com>
- Add ToolCall to AssistantMessage.
- Rename FunctionMessage to ToolResponseMessage and add id and name fields.
- Refactor OpenAiChatModel's function calling handling.
- Prompt copy now copies the AssistantMessage and ToolResponseMessage contents.
Other ChatModel implementations to adopt these changes in subsequent commits
- add new spring-ai-vertex-ai-embedding project.
- add VertexAiTextEmbeddingModel and VertexAiMultimodalEmbeddingMode with related options configuration classes.
- add ITs
- add auto-configuraiton and boot starters.
- register to BOM.
- add documentation.
- add multimodal embedding documentation
- extend the Embedding metdata so that it can keep references to the source document's data, Id, mediatype
Resolves#1013
Related to #1009
- add dedicated groq chat page in the documentation.
Explain how to re-configure the OpenAI client for accessing the Groq chat completion endpoint.
- Doc: order the Chat and Embedding items in alphabetical order
- Add Groq ITs.
Resolves#996
- add StreamEven API domain model for reliably parsing stream events.
- add StreamHelper#mergeToolUseEvents to aggregate partial tool use jsons into a list of ContentBlocks.
- add StreamHelper#eventToChatCompletionResponse to convert Flux<StreamEvents> into Flux<ChatCompletionResponse>.
- Rename MediaContent -> ContentBlock, RequestMessage -> AnthropicMessage, ChatCompletion -> ChatCompletionResponse.
- Improve tests and docs.
* Extend ChatResponseMetadata for Anthropic (blocking, streaming)
* Add ChatResponseMetadata for Mistral AI (blocking)
* Extend ChatResponseMetadata for OpenAI (blocking)
* Deprecate gpt-4-vision-preview and replace its usage in tests because OpenAI rejects the calls (see: https://platform.openai.com/docs/deprecations)
Fixes gh-936
Signed-off-by: Thomas Vitale <ThomasVitale@users.noreply.github.com>
- OpenAiApi: add StreamingOptions class and ChatCompletionRequest#streamingOptions field.
- add OpenAiChatOption#withStreamingUsage(boolean) to set/unset the StreamingOptions.
- add a boolean (get/set)StreamUsage() to OpenAiChatOptions that internally set the SstreamOptions.
Later allows the "spring.ai.openai.chat.options.stream-usage" property.
- update the OpenAI property documentation.
Co-authored-by: Christian Tzolov <ctzolov@vmware.com>
- upadate bedrockruntime version to 2.26.7 and align it with aws sdk dependecy.
- minor ITs configuration, consistency and statbility fixes
Use the EnvironmentVariableCredentialsProvider instead of the Profile credential provider.
- update the Bedrock getting started documentation.
- update the Genemi Prerequisites docs.
- Added additional support for ZhiPuAi models including vision model GLM-4V
- Default model changed to GLM_4_Air and update documentation
- Added additional unit and integration tests
- Add documentation for vision model