Package org.springframework.ai.mistralai
Class MistralAiChatOptions
java.lang.Object
org.springframework.ai.mistralai.MistralAiChatOptions
- All Implemented Interfaces:
ChatOptions
,FunctionCallingOptions
,ModelOptions
- Since:
- 0.8.1
- Author:
- Ricken Bazolo, Christian Tzolov
-
Nested Class Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic MistralAiChatOptions.Builder
builder()
Function Callbacks to be registered with the ChatClient.getModel()
getTools()
getTopK()
getTopP()
void
setFunctionCallbacks
(List<FunctionCallback> functionCallbacks) Set the Function Callbacks to be registered with the ChatClient.void
setFunctions
(Set<String> functions) Set the list of function names from the ChatClient registry to be used in the next chat completion requests.void
setMaxTokens
(Integer maxTokens) void
void
setRandomSeed
(Integer randomSeed) void
setResponseFormat
(MistralAiApi.ChatCompletionRequest.ResponseFormat responseFormat) void
setSafePrompt
(Boolean safePrompt) void
setTemperature
(Float temperature) void
void
setTools
(List<MistralAiApi.FunctionTool> tools) void
void
-
Constructor Details
-
MistralAiChatOptions
public MistralAiChatOptions()
-
-
Method Details
-
builder
-
getModel
-
setModel
-
getMaxTokens
-
setMaxTokens
-
getSafePrompt
-
setSafePrompt
-
getRandomSeed
-
setRandomSeed
-
getResponseFormat
-
setResponseFormat
-
setTools
-
getTools
-
setToolChoice
-
getToolChoice
-
getTemperature
- Specified by:
getTemperature
in interfaceChatOptions
-
setTemperature
-
getTopP
- Specified by:
getTopP
in interfaceChatOptions
-
setTopP
-
getTopK
- Specified by:
getTopK
in interfaceChatOptions
-
setTopK
-
getFunctionCallbacks
Description copied from interface:FunctionCallingOptions
Function Callbacks to be registered with the ChatClient. For Prompt Options the functionCallbacks are automatically enabled for the duration of the prompt execution. For Default Options the FunctionCallbacks are registered but disabled by default. You have to use "functions" property to list the function names from the ChatClient registry to be used in the chat completion requests.- Specified by:
getFunctionCallbacks
in interfaceFunctionCallingOptions
- Returns:
- Return the Function Callbacks to be registered with the ChatClient.
-
setFunctionCallbacks
Description copied from interface:FunctionCallingOptions
Set the Function Callbacks to be registered with the ChatClient.- Specified by:
setFunctionCallbacks
in interfaceFunctionCallingOptions
- Parameters:
functionCallbacks
- the Function Callbacks to be registered with the ChatClient.
-
getFunctions
- Specified by:
getFunctions
in interfaceFunctionCallingOptions
- Returns:
- List of function names from the ChatClient registry to be used in the next chat completion requests.
-
setFunctions
Description copied from interface:FunctionCallingOptions
Set the list of function names from the ChatClient registry to be used in the next chat completion requests.- Specified by:
setFunctions
in interfaceFunctionCallingOptions
- Parameters:
functions
- the list of function names from the ChatClient registry to be used in the next chat completion requests.
-