File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -1023,7 +1023,7 @@ pub enum ToolChoice {
1023
1023
///
1024
1024
/// `none` is the default when no tools are present. `auto` is the default if tools are present."
1025
1025
enum ToolTypeDeserializer {
1026
- /// `none` means the model will not call any tool and instead generates a message .
1026
+ /// None means `null` was passed in the JSON, and the default choice is applied based on the presence of tools .
1027
1027
Null ,
1028
1028
1029
1029
/// `auto` means the model can pick between generating a message or calling one or more tools.
@@ -1038,7 +1038,7 @@ enum ToolTypeDeserializer {
1038
1038
impl From < ToolTypeDeserializer > for ToolChoice {
1039
1039
fn from ( value : ToolTypeDeserializer ) -> Self {
1040
1040
match value {
1041
- ToolTypeDeserializer :: Null => ToolChoice :: NoTool ,
1041
+ ToolTypeDeserializer :: Null => ToolChoice :: Auto ,
1042
1042
ToolTypeDeserializer :: String ( s) => match s. as_str ( ) {
1043
1043
"none" => ToolChoice :: NoTool ,
1044
1044
"auto" => ToolChoice :: Auto ,
You can’t perform that action at this time.
0 commit comments