Skip to main content

klieo_tools/
lib.rs

1#![deny(missing_docs)]
2#![deny(rust_2018_idioms)]
3#![deny(rustdoc::broken_intra_doc_links)]
4
5//! Tool dispatch utilities for the klieo agent framework.
6//!
7//! Provides [`ChainedInvoker`], a [`klieo_core::ToolInvoker`] impl
8//! that:
9//! - Looks up tools by name in a registered set.
10//! - Validates JSON arguments against the tool's declared `json_schema`
11//!   before invocation (rejects malformed model output early).
12//! - Wraps each invocation in a `tokio::time::timeout` so a hung tool
13//!   cannot stall the runtime indefinitely.
14//!
15//! Tools themselves can be hand-rolled `impl Tool` types or generated
16//! by the `#[tool]` macro shipped in `klieo-macros` (Plan #4).
17
18pub mod validation;
19pub use validation::validate_args;
20
21pub mod invoker;
22pub use invoker::ChainedInvoker;
23pub use invoker::InvokerError;