#[non_exhaustive]pub struct ToolConfig {
pub function_calling_config: Option<FunctionCallingConfig>,
pub retrieval_config: Option<RetrievalConfig>,
/* private fields */
}Expand description
Tool config. This config is shared for all tools provided in the request.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.function_calling_config: Option<FunctionCallingConfig>Optional. Function calling config.
retrieval_config: Option<RetrievalConfig>Optional. Retrieval config.
Implementations§
Source§impl ToolConfig
impl ToolConfig
pub fn new() -> Self
Sourcepub fn set_function_calling_config<T: Into<Option<FunctionCallingConfig>>>(
self,
v: T,
) -> Self
pub fn set_function_calling_config<T: Into<Option<FunctionCallingConfig>>>( self, v: T, ) -> Self
Sets the value of function_calling_config.
Sourcepub fn set_retrieval_config<T: Into<Option<RetrievalConfig>>>(
self,
v: T,
) -> Self
pub fn set_retrieval_config<T: Into<Option<RetrievalConfig>>>( self, v: T, ) -> Self
Sets the value of retrieval_config.
Trait Implementations§
Source§impl Clone for ToolConfig
impl Clone for ToolConfig
Source§fn clone(&self) -> ToolConfig
fn clone(&self) -> ToolConfig
Returns a copy of the value. Read more
1.0.0 · 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 ToolConfig
impl Debug for ToolConfig
Source§impl Default for ToolConfig
impl Default for ToolConfig
Source§fn default() -> ToolConfig
fn default() -> ToolConfig
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ToolConfigwhere
ToolConfig: Default,
impl<'de> Deserialize<'de> for ToolConfigwhere
ToolConfig: Default,
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 PartialEq for ToolConfig
impl PartialEq for ToolConfig
Source§impl Serialize for ToolConfig
impl Serialize for ToolConfig
impl StructuralPartialEq for ToolConfig
Auto Trait Implementations§
impl Freeze for ToolConfig
impl RefUnwindSafe for ToolConfig
impl Send for ToolConfig
impl Sync for ToolConfig
impl Unpin for ToolConfig
impl UnwindSafe for ToolConfig
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