pub enum ToolChoiceParam {
ToolChoiceOptions(ToolChoiceOptions),
ToolChoiceAllowed(ToolChoiceAllowed),
ToolChoiceTypes(ToolChoiceTypes),
ToolChoiceFunction(ToolChoiceFunction),
ToolChoiceMcp(ToolChoiceMcp),
ToolChoiceCustom(ToolChoiceCustom),
SpecificApplyPatchParam(SpecificApplyPatchParam),
SpecificFunctionShellParam(SpecificFunctionShellParam),
}Expand description
How the model should select which tool (or tools) to use when generating
a response. See the tools parameter to see how to specify which tools
the model can call.
JSON schema
{
"description": "How the model should select which tool (or tools) to use when generating\na response. See the `tools` parameter to see how to specify which tools\nthe model can call.\n",
"oneOf": [
{
"$ref": "#/components/schemas/ToolChoiceOptions"
},
{
"$ref": "#/components/schemas/ToolChoiceAllowed"
},
{
"$ref": "#/components/schemas/ToolChoiceTypes"
},
{
"$ref": "#/components/schemas/ToolChoiceFunction"
},
{
"$ref": "#/components/schemas/ToolChoiceMCP"
},
{
"$ref": "#/components/schemas/ToolChoiceCustom"
},
{
"$ref": "#/components/schemas/SpecificApplyPatchParam"
},
{
"$ref": "#/components/schemas/SpecificFunctionShellParam"
}
]
}Variants§
ToolChoiceOptions(ToolChoiceOptions)
ToolChoiceAllowed(ToolChoiceAllowed)
ToolChoiceTypes(ToolChoiceTypes)
ToolChoiceFunction(ToolChoiceFunction)
ToolChoiceMcp(ToolChoiceMcp)
ToolChoiceCustom(ToolChoiceCustom)
SpecificApplyPatchParam(SpecificApplyPatchParam)
SpecificFunctionShellParam(SpecificFunctionShellParam)
Trait Implementations§
Source§impl Clone for ToolChoiceParam
impl Clone for ToolChoiceParam
Source§fn clone(&self) -> ToolChoiceParam
fn clone(&self) -> ToolChoiceParam
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ToolChoiceParam
impl Debug for ToolChoiceParam
Source§impl<'de> Deserialize<'de> for ToolChoiceParam
impl<'de> Deserialize<'de> for ToolChoiceParam
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<SpecificApplyPatchParam> for ToolChoiceParam
impl From<SpecificApplyPatchParam> for ToolChoiceParam
Source§fn from(value: SpecificApplyPatchParam) -> Self
fn from(value: SpecificApplyPatchParam) -> Self
Converts to this type from the input type.
Source§impl From<SpecificFunctionShellParam> for ToolChoiceParam
impl From<SpecificFunctionShellParam> for ToolChoiceParam
Source§fn from(value: SpecificFunctionShellParam) -> Self
fn from(value: SpecificFunctionShellParam) -> Self
Converts to this type from the input type.
Source§impl From<ToolChoiceAllowed> for ToolChoiceParam
impl From<ToolChoiceAllowed> for ToolChoiceParam
Source§fn from(value: ToolChoiceAllowed) -> Self
fn from(value: ToolChoiceAllowed) -> Self
Converts to this type from the input type.
Source§impl From<ToolChoiceCustom> for ToolChoiceParam
impl From<ToolChoiceCustom> for ToolChoiceParam
Source§fn from(value: ToolChoiceCustom) -> Self
fn from(value: ToolChoiceCustom) -> Self
Converts to this type from the input type.
Source§impl From<ToolChoiceFunction> for ToolChoiceParam
impl From<ToolChoiceFunction> for ToolChoiceParam
Source§fn from(value: ToolChoiceFunction) -> Self
fn from(value: ToolChoiceFunction) -> Self
Converts to this type from the input type.
Source§impl From<ToolChoiceMcp> for ToolChoiceParam
impl From<ToolChoiceMcp> for ToolChoiceParam
Source§fn from(value: ToolChoiceMcp) -> Self
fn from(value: ToolChoiceMcp) -> Self
Converts to this type from the input type.
Source§impl From<ToolChoiceOptions> for ToolChoiceParam
impl From<ToolChoiceOptions> for ToolChoiceParam
Source§fn from(value: ToolChoiceOptions) -> Self
fn from(value: ToolChoiceOptions) -> Self
Converts to this type from the input type.
Source§impl From<ToolChoiceTypes> for ToolChoiceParam
impl From<ToolChoiceTypes> for ToolChoiceParam
Source§fn from(value: ToolChoiceTypes) -> Self
fn from(value: ToolChoiceTypes) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ToolChoiceParam
impl RefUnwindSafe for ToolChoiceParam
impl Send for ToolChoiceParam
impl Sync for ToolChoiceParam
impl Unpin for ToolChoiceParam
impl UnsafeUnpin for ToolChoiceParam
impl UnwindSafe for ToolChoiceParam
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more