tinyhumansai/openhuman · error · anyhow::Error
Missing 'agent' parameter
Error message
Missing 'agent' parameter
What it means
The delegate tool was invoked without an `agent` argument (absent, not a string, or blank after trim). This is a guard on the model's tool-call arguments before any sub-agent dispatch happens; the required keys `agent` and `prompt` are declared in the tool schema, so a well-formed caller never hits it.
Solutions
- Include an `agent` string parameter naming the sub-agent to delegate to
- Use a non-blank agent identifier registered in the agent registry
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at src/openhuman/agent/tools/delegate.rs:126 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of tinyhumansai/openhuman@7491200858 (2026-08-17).
Data as JSON: /api/errors/635881b1e9fc806e.
Report an issue: GitHub.
Appendix: source
Thrown at src/openhuman/agent/tools/delegate.rs:126
"type": "string",
"minLength": 1,
"description": "The task/prompt to send to the sub-agent"
},
"context": {
"type": "string",
"description": "Optional context to prepend (e.g. relevant code, prior findings)"
}
},
"required": ["agent", "prompt"]
})
}
async fn execute(&self, args: serde_json::Value) -> anyhow::Result<ToolResult> {
let agent_name = args
.get("agent")
.and_then(|v| v.as_str())
.map(str::trim)
.ok_or_else(|| anyhow::anyhow!("Missing 'agent' parameter"))?;
if agent_name.is_empty() {
return Ok(ToolResult::error("'agent' parameter must not be empty"));
}
let prompt = args
.get("prompt")
.and_then(|v| v.as_str())
.map(str::trim)
.ok_or_else(|| anyhow::anyhow!("Missing 'prompt' parameter"))?;
if prompt.is_empty() {
return Ok(ToolResult::error("'prompt' parameter must not be empty"));
}
let context = args
.get("context")
.and_then(|v| v.as_str())View on GitHub (pinned to 7491200858)