pub struct ToolAnnotations {
pub title: Option<String>,
pub read_only_hint: Option<bool>,
pub destructive_hint: Option<bool>,
pub idempotent_hint: Option<bool>,
pub open_world_hint: Option<bool>,
}
Expand description
Tool annotations structure (matches TypeScript ToolAnnotations) NOTE: all properties in ToolAnnotations are hints. They are not guaranteed to provide a faithful description of tool behavior. Clients should never make tool use decisions based on ToolAnnotations from untrusted servers.
Fields§
§title: Option<String>
A human-readable title for the tool
read_only_hint: Option<bool>
If true, the tool does not modify its environment. Default: false
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
Implementations§
Source§impl ToolAnnotations
impl ToolAnnotations
pub fn new() -> ToolAnnotations
pub fn with_title(self, title: impl Into<String>) -> ToolAnnotations
pub fn with_read_only_hint(self, read_only: bool) -> ToolAnnotations
pub fn with_destructive_hint(self, destructive: bool) -> ToolAnnotations
pub fn with_idempotent_hint(self, idempotent: bool) -> ToolAnnotations
pub fn with_open_world_hint(self, open_world: bool) -> ToolAnnotations
Trait Implementations§
Source§impl Clone for ToolAnnotations
impl Clone for ToolAnnotations
Source§fn clone(&self) -> ToolAnnotations
fn clone(&self) -> ToolAnnotations
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more