pub struct ToolSpec {
pub name: String,
pub description: String,
pub input: ToolInputFormat,
}Expand description
A provider-neutral tool spec: name + description + args JSON Schema.
This is the wire-agnostic representation a harness pack produces (from a
Registry) and a Provider wire maps onto its own tool format (e.g. Anthropic’s
{name, description, input_schema} vs OpenAI’s {type:"function", function:{…}}).
It lives in locode-protocol because both locode-tools (which builds it) and
locode-provider (which consumes it via ConversationRequest) need it, and the
dependency graph forbids provider → tools.
Fields§
§name: StringThe model-facing wire name (the harness pack’s name for the tool).
description: StringThe tool description offered to the model.
input: ToolInputFormatHow the tool’s input is specified to the model (ADR-0003 amendment
2026-07-19; replaces the bare parameters: Value).
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ToolSpec
impl<'de> Deserialize<'de> for ToolSpec
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
impl StructuralPartialEq for ToolSpec
Auto Trait Implementations§
impl Freeze for ToolSpec
impl RefUnwindSafe for ToolSpec
impl Send for ToolSpec
impl Sync for ToolSpec
impl Unpin for ToolSpec
impl UnsafeUnpin for ToolSpec
impl UnwindSafe for ToolSpec
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