ChatCompletionFunctionCall class sealed
Deprecated in favor of tool_choice
.
Controls which (if any) function is called by the model.
none
means the model will not call a function and instead generates a message.
auto
means the model can pick between generating a message or calling a function.
Specifying a particular function via ChatCompletionFunctionCallOption forces the model to call that
function.
none
is the default when no functions are present. auto
is the default if functions are present.
- Implementers
- Annotations
-
- @freezed
Constructors
-
ChatCompletionFunctionCall.fromJson(Map<
String, dynamic> json) -
Object construction from a JSON representation
factory
- ChatCompletionFunctionCall.function(ChatCompletionFunctionCallOption value)
-
No Description
constfactory
- ChatCompletionFunctionCall.mode(ChatCompletionFunctionCallMode value)
-
none
means the model will not call a function and instead generates a message.auto
means the model can pick between generating a message or calling a function.constfactory
Properties
Methods
-
map<
TResult extends Object?> ({required TResult mode(ChatCompletionFunctionCallEnumeration value), required TResult function(ChatCompletionFunctionCallChatCompletionFunctionCallOption value)}) → TResult -
inherited
-
mapOrNull<
TResult extends Object?> ({TResult? mode(ChatCompletionFunctionCallEnumeration value)?, TResult? function(ChatCompletionFunctionCallChatCompletionFunctionCallOption value)?}) → TResult? -
inherited
-
maybeMap<
TResult extends Object?> ({TResult mode(ChatCompletionFunctionCallEnumeration value)?, TResult function(ChatCompletionFunctionCallChatCompletionFunctionCallOption value)?, required TResult orElse()}) → TResult -
inherited
-
maybeWhen<
TResult extends Object?> ({TResult mode(ChatCompletionFunctionCallMode value)?, TResult function(ChatCompletionFunctionCallOption value)?, required TResult orElse()}) → TResult -
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
Serializes this ChatCompletionFunctionCall to a JSON map.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
when<
TResult extends Object?> ({required TResult mode(ChatCompletionFunctionCallMode value), required TResult function(ChatCompletionFunctionCallOption value)}) → TResult -
inherited
-
whenOrNull<
TResult extends Object?> ({TResult? mode(ChatCompletionFunctionCallMode value)?, TResult? function(ChatCompletionFunctionCallOption value)?}) → TResult? -
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited