| Crates.io | serdes-ai-tools |
| lib.rs | serdes-ai-tools |
| version | 0.1.2 |
| created_at | 2026-01-15 23:32:07.05749+00 |
| updated_at | 2026-01-23 16:43:26.752909+00 |
| description | Tool system for serdes-ai agents |
| homepage | |
| repository | https://github.com/janfeddersen-wq/serdesAI |
| max_upload_size | |
| id | 2047338 |
| size | 336,370 |
Tool system for serdes-ai agents
This crate provides the tool system for SerdesAI agents:
Tool trait for defining callable toolsToolDefinition for JSON schema-based tool descriptionsSchemaBuilder for easy parameter schema constructionToolReturn for structured tool responses[dependencies]
serdes-ai-tools = "0.1"
use serdes_ai_tools::{Tool, ToolDefinition, ToolReturn, ToolResult, SchemaBuilder};
struct MyTool;
impl Tool<()> for MyTool {
fn definition(&self) -> ToolDefinition {
ToolDefinition::new("my_tool", "Does something useful")
.with_parameters(
SchemaBuilder::new()
.string("input", "The input value", true)
.build()
.unwrap()
)
}
async fn call(
&self,
_ctx: &RunContext<()>,
args: serde_json::Value,
) -> ToolResult {
Ok(ToolReturn::text("Done!"))
}
}
This crate is part of the SerdesAI workspace.
For most use cases, you should use the main serdes-ai crate which re-exports these types.
MIT License - see LICENSE for details.