Skip to main content

classify_tool_response

Function classify_tool_response 

Source
pub fn classify_tool_response(body: Option<&str>) -> Option<FailureClass>
Expand description

Classify a tool-call response that failed acceptance: no tool call → NoToolCall, wrong name → InvalidToolName, unparsable/wrong arguments → InvalidToolArguments, more than one call → DuplicateToolCall, malformed envelope → InvalidJson/InvalidChatCompletionShape. None means the response is a valid single get_project_sentinel(scope=provider-conformance) call - FailureClass::Unknown must never be conflated with “valid”.