Class GoogleGenAiChatOptions
java.lang.Object
org.springframework.ai.google.genai.GoogleGenAiChatOptions
- All Implemented Interfaces:
org.springframework.ai.chat.prompt.ChatOptions,org.springframework.ai.model.ModelOptions,org.springframework.ai.model.tool.StructuredOutputChatOptions,org.springframework.ai.model.tool.ToolCallingChatOptions
public class GoogleGenAiChatOptions
extends Object
implements org.springframework.ai.model.tool.ToolCallingChatOptions, org.springframework.ai.model.tool.StructuredOutputChatOptions
Options for the Google GenAI Chat API.
- Since:
- 1.0.0
- Author:
- Christian Tzolov, Thomas Vitale, Grogdunn, Ilayaperumal Gopinathan, Soby Chacko, Dan Dobrin
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classstatic enum -
Field Summary
Fields inherited from interface org.springframework.ai.model.tool.ToolCallingChatOptions
DEFAULT_TOOL_EXECUTION_ENABLED -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuilder()copy()booleanstatic GoogleGenAiChatOptionsfromOptions(GoogleGenAiChatOptions fromOptions) getModel()List<org.springframework.ai.tool.ToolCallback>getTopK()getTopP()inthashCode()voidsetAutoCacheThreshold(Integer autoCacheThreshold) voidsetAutoCacheTtl(Duration autoCacheTtl) voidsetCachedContentName(String cachedContentName) voidsetCandidateCount(Integer candidateCount) voidsetFrequencyPenalty(Double frequencyPenalty) voidsetGoogleSearchRetrieval(Boolean googleSearchRetrieval) voidsetIncludeExtendedUsageMetadata(Boolean includeExtendedUsageMetadata) voidsetIncludeThoughts(Boolean includeThoughts) voidsetInternalToolExecutionEnabled(Boolean internalToolExecutionEnabled) voidvoidsetMaxOutputTokens(Integer maxOutputTokens) voidsetMaxTokens(Integer maxTokens) voidvoidsetOutputSchema(String jsonSchemaText) voidsetPresencePenalty(Double presencePenalty) voidsetResponseMimeType(String mimeType) voidsetResponseSchema(String responseSchema) voidsetSafetySettings(List<GoogleGenAiSafetySetting> safetySettings) voidsetStopSequences(List<String> stopSequences) voidsetTemperature(Double temperature) voidsetThinkingBudget(Integer thinkingBudget) voidsetThinkingLevel(GoogleGenAiThinkingLevel thinkingLevel) voidsetToolCallbacks(List<org.springframework.ai.tool.ToolCallback> toolCallbacks) voidsetToolContext(Map<String, Object> toolContext) voidsetToolNames(Set<String> toolNames) voidvoidvoidsetUseCachedContent(Boolean useCachedContent) toString()
-
Constructor Details
-
GoogleGenAiChatOptions
public GoogleGenAiChatOptions()
-
-
Method Details
-
builder
-
fromOptions
-
getStopSequences
- Specified by:
getStopSequencesin interfaceorg.springframework.ai.chat.prompt.ChatOptions
-
setStopSequences
-
getTemperature
- Specified by:
getTemperaturein interfaceorg.springframework.ai.chat.prompt.ChatOptions
-
setTemperature
-
getTopP
- Specified by:
getTopPin interfaceorg.springframework.ai.chat.prompt.ChatOptions
-
setTopP
-
getTopK
- Specified by:
getTopKin interfaceorg.springframework.ai.chat.prompt.ChatOptions
-
setTopK
-
getCandidateCount
-
setCandidateCount
-
getMaxTokens
- Specified by:
getMaxTokensin interfaceorg.springframework.ai.chat.prompt.ChatOptions
-
setMaxTokens
-
getMaxOutputTokens
-
setMaxOutputTokens
-
getModel
- Specified by:
getModelin interfaceorg.springframework.ai.chat.prompt.ChatOptions
-
setModel
-
getResponseMimeType
-
setResponseMimeType
-
getResponseSchema
-
setResponseSchema
-
getToolCallbacks
- Specified by:
getToolCallbacksin interfaceorg.springframework.ai.model.tool.ToolCallingChatOptions
-
setToolCallbacks
- Specified by:
setToolCallbacksin interfaceorg.springframework.ai.model.tool.ToolCallingChatOptions
-
getToolNames
- Specified by:
getToolNamesin interfaceorg.springframework.ai.model.tool.ToolCallingChatOptions
-
setToolNames
- Specified by:
setToolNamesin interfaceorg.springframework.ai.model.tool.ToolCallingChatOptions
-
getInternalToolExecutionEnabled
- Specified by:
getInternalToolExecutionEnabledin interfaceorg.springframework.ai.model.tool.ToolCallingChatOptions
-
setInternalToolExecutionEnabled
- Specified by:
setInternalToolExecutionEnabledin interfaceorg.springframework.ai.model.tool.ToolCallingChatOptions
-
getFrequencyPenalty
- Specified by:
getFrequencyPenaltyin interfaceorg.springframework.ai.chat.prompt.ChatOptions
-
getPresencePenalty
- Specified by:
getPresencePenaltyin interfaceorg.springframework.ai.chat.prompt.ChatOptions
-
setFrequencyPenalty
-
setPresencePenalty
-
getThinkingBudget
-
setThinkingBudget
-
getIncludeThoughts
-
setIncludeThoughts
-
getThinkingLevel
-
setThinkingLevel
-
getIncludeExtendedUsageMetadata
-
setIncludeExtendedUsageMetadata
-
getCachedContentName
-
setCachedContentName
-
getUseCachedContent
-
setUseCachedContent
-
getAutoCacheThreshold
-
setAutoCacheThreshold
-
getAutoCacheTtl
-
setAutoCacheTtl
-
getGoogleSearchRetrieval
-
setGoogleSearchRetrieval
-
getSafetySettings
-
setSafetySettings
-
getLabels
-
setLabels
-
getToolContext
- Specified by:
getToolContextin interfaceorg.springframework.ai.model.tool.ToolCallingChatOptions
-
setToolContext
- Specified by:
setToolContextin interfaceorg.springframework.ai.model.tool.ToolCallingChatOptions
-
getOutputSchema
- Specified by:
getOutputSchemain interfaceorg.springframework.ai.model.tool.StructuredOutputChatOptions
-
setOutputSchema
- Specified by:
setOutputSchemain interfaceorg.springframework.ai.model.tool.StructuredOutputChatOptions
-
equals
-
hashCode
public int hashCode() -
toString
-
copy
- Specified by:
copyin interfaceorg.springframework.ai.chat.prompt.ChatOptions
-