pub trait PolicyEngine:
Send
+ Sync
+ 'static {
// Required method
fn evaluate(&self, tool_name: &str, args: &Value) -> PolicyOutcome;
}Expand description
Trait for evaluating tool call policies.
Implementations can check tool names, arguments, user permissions, rate limits, etc.
Required Methods§
Sourcefn evaluate(&self, tool_name: &str, args: &Value) -> PolicyOutcome
fn evaluate(&self, tool_name: &str, args: &Value) -> PolicyOutcome
Evaluate whether a tool call should be allowed.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".