Skip to main content

validate_tool_args

Function validate_tool_args 

Source
pub fn validate_tool_args(
    tool_name: &str,
    schema: &Value,
    args: &Value,
) -> ArgValidation
Expand description

Validate args against schema, the exact parameter schema advertised to the model for tool_name.

Value::Null arguments are treated as {}: providers substitute an empty object when a model omits tool input entirely, and a null reaching here means the same “no arguments” - not a JSON null argument object.