pub struct ToolAnnotations {
pub destructive_hint: Option<bool>,
pub idempotent_hint: Option<bool>,
pub open_world_hint: Option<bool>,
pub read_only_hint: Option<bool>,
pub title: Option<String>,
}Expand description
Additional properties describing a Tool to clients. NOTE: all properties in ToolAnnotations are hints. They are not guaranteed to provide a faithful description of tool behavior (including descriptive properties like title). Clients should never make tool use decisions based on ToolAnnotations received from untrusted servers.
JSON schema
{
"description": "Additional properties describing a Tool to clients.\n\nNOTE: all properties in ToolAnnotations are **hints**.\nThey are not guaranteed to provide a faithful description of\ntool behavior (including descriptive properties like title).\n\nClients should never make tool use decisions based on ToolAnnotations\nreceived from untrusted servers.",
"type": "object",
"properties": {
"destructiveHint": {
"description": "If true, the tool may perform destructive updates to its environment.\nIf false, the tool performs only additive updates.\n\n(This property is meaningful only when readOnlyHint == false)\n\nDefault: true",
"type": "boolean"
},
"idempotentHint": {
"description": "If true, calling the tool repeatedly with the same arguments\nwill have no additional effect on its environment.\n\n(This property is meaningful only when readOnlyHint == false)\n\nDefault: false",
"type": "boolean"
},
"openWorldHint": {
"description": "If true, this tool may interact with an \"open world\" of external\nentities. If false, the tool's domain of interaction is closed.\nFor example, the world of a web search tool is open, whereas that\nof a memory tool is not.\n\nDefault: true",
"type": "boolean"
},
"readOnlyHint": {
"description": "If true, the tool does not modify its environment.\n\nDefault: false",
"type": "boolean"
},
"title": {
"description": "A human-readable title for the tool.",
"type": "string"
}
}
}Fields§
§destructive_hint: Option<bool>If true, the tool may perform destructive updates to its environment. If false, the tool performs only additive updates. (This property is meaningful only when readOnlyHint == false) Default: true
idempotent_hint: Option<bool>If true, calling the tool repeatedly with the same arguments will have no additional effect on its environment. (This property is meaningful only when readOnlyHint == false) Default: false
open_world_hint: Option<bool>If true, this tool may interact with an “open world” of external entities. If false, the tool’s domain of interaction is closed. For example, the world of a web search tool is open, whereas that of a memory tool is not. Default: true
read_only_hint: Option<bool>If true, the tool does not modify its environment. Default: false
title: Option<String>A human-readable title for the tool.
Trait Implementations§
Source§impl Clone for ToolAnnotations
impl Clone for ToolAnnotations
Source§fn clone(&self) -> ToolAnnotations
fn clone(&self) -> ToolAnnotations
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ToolAnnotations
impl Debug for ToolAnnotations
Source§impl Default for ToolAnnotations
impl Default for ToolAnnotations
Source§fn default() -> ToolAnnotations
fn default() -> ToolAnnotations
Source§impl<'de> Deserialize<'de> for ToolAnnotations
impl<'de> Deserialize<'de> for ToolAnnotations
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>,
Auto Trait Implementations§
impl Freeze for ToolAnnotations
impl RefUnwindSafe for ToolAnnotations
impl Send for ToolAnnotations
impl Sync for ToolAnnotations
impl Unpin for ToolAnnotations
impl UnwindSafe for ToolAnnotations
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
clone_to_uninit)