tinyhumansai/openhuman · error

call_memory_agent: `query` is required

Error message

call_memory_agent: `query` is required

What it means

call_memory_agent's execute_with_context found no "query" string in the tool args. The sub-agent dispatch cannot start without a natural-language brief, so this guard fires before any registry or context lookup.

Source

Thrown at src/openhuman/memory/agent/tools.rs:112

    fn is_concurrency_safe(&self, _args: &serde_json::Value) -> bool {
        true
    }

    async fn execute(&self, args: serde_json::Value) -> anyhow::Result<ToolResult> {
        self.execute_with_context(args, ToolCallOptions::default(), None)
            .await
    }

    async fn execute_with_context(
        &self,
        args: serde_json::Value,
        _options: ToolCallOptions,
        tool_context: Option<&ToolExecutionContext>,
    ) -> anyhow::Result<ToolResult> {
        let query = args
            .get("query")
            .and_then(|v| v.as_str())
            .ok_or_else(|| anyhow::anyhow!("call_memory_agent: `query` is required"))?;

        let context = args.get("context").and_then(|v| v.as_str());

        let max_turns = args
            .get("max_turns")
            .and_then(|v| v.as_u64())
            .map(|v| v.clamp(1, 20) as usize);

        let is_async = args.get("async").and_then(|v| v.as_bool()).unwrap_or(false);

        let parent = current_parent();
        if parent.is_none() {
            return Ok(ToolResult::error(
                "call_memory_agent: no parent agent context — this tool must be \
                 called from within an agent turn."
                    .to_string(),
            ));
        }

View on GitHub (pinned to 7491200858)

Solutions

  1. Include a non-empty "query" string describing what the memory agent should do
  2. Check the tool call was not truncated, dropping trailing arguments
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at src/openhuman/memory/agent/tools.rs:112 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/cb3e25cf64ac9382. Report an issue: GitHub.