GoogleChatModelOptions class

Options to pass into the Google Generative AI Chat Model.

You can find a list of available models here.

Inheritance
Annotations
  • @immutable

Constructors

GoogleChatModelOptions({String? model, double? temperature, double? topP, int? topK, int? candidateCount, int? maxOutputTokens, List<String>? stopSequences, String? responseMimeType, Map<String, dynamic>? responseSchema, List<ChatGoogleGenerativeAISafetySetting>? safetySettings, int? thinkingBudgetTokens, Set<GoogleServerSideTool>? serverSideTools, GoogleFunctionCallingMode? functionCallingMode, List<String>? allowedFunctionNames})
Creates a new chat google generative ai options instance.
const

Properties

allowedFunctionNames List<String>?
A set of function names that limits which functions the model can call.
final
candidateCount int?
Number of generated responses to return. This value must be between 1 and 8, inclusive. If unset, this will default to 1.
final
functionCallingMode GoogleFunctionCallingMode?
Controls how the model decides when to call functions.
final
hashCode int
The hash code for this object.
no setterinherited
maxOutputTokens int?
The maximum number of tokens to include in a candidate. If unset, this will default to output_token_limit specified in the Model specification.
final
model String?
The model to use (e.g. 'gemini-1.5-pro').
final
responseMimeType String?
Output response mimetype of the generated candidate text.
final
responseSchema Map<String, dynamic>?
Output response schema of the generated candidate text. Following the JSON Schema specification.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
safetySettings List<ChatGoogleGenerativeAISafetySetting>?
A list of unique ChatGoogleGenerativeAISafetySetting instances for blocking unsafe content.
final
serverSideTools Set<GoogleServerSideTool>?
The server-side tools to enable.
final
stopSequences List<String>?
The set of character sequences (up to 5) that will stop output generation. If specified, the API will stop at the first appearance of a stop sequence. The stop sequence will not be included as part of the response.
final
temperature double?
The temperature to use.
final
thinkingBudgetTokens int?
Optional token budget for thinking.
final
topK int?
The top K value to use.
final
topP double?
The top P value to use.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited