{"record":{"id":"e59a5632a095b11d","repo":"tinyhumansai/openhuman","slug":"invalid-arguments-for-memory-tree-search-entities","errorCode":null,"errorMessage":"invalid arguments for memory_tree_search_entities: {e}","messagePattern":"invalid arguments for memory_tree_search_entities: (.+?)","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/openhuman/memory/query/search_entities.rs","lineNumber":57,"sourceCode":"                            \"misc\", \"topic\"\n                        ]\n                    },\n                    \"description\": \"Optional kind filter — restrict to these entity kinds only.\"\n                },\n                \"limit\": {\n                    \"type\": \"integer\",\n                    \"minimum\": 0,\n                    \"description\": \"Max matches (default 5, clamped to 100).\"\n                }\n            },\n            \"required\": [\"query\"]\n        })\n    }\n\n    async fn execute(&self, args: serde_json::Value) -> anyhow::Result<ToolResult> {\n        log::debug!(\"[tool][memory_tree] search_entities invoked\");\n        let req: SearchEntitiesRequest = serde_json::from_value(args).map_err(|e| {\n            anyhow::anyhow!(\"invalid arguments for memory_tree_search_entities: {e}\")\n        })?;\n        // `kinds` is **not** validated here any more, and that is a deliberate\n        // move rather than an omission.\n        //\n        // Entity kinds are an open vocabulary on the wire (see\n        // `memory::api::provider::retrieval`): the engine's own `EntityKind` is\n        // `#[non_exhaustive]` and has grown twice, so a closed host-side copy\n        // would either reject a kind the engine understands or drift silently\n        // out of date. The driver owns the vocabulary and rejects an unknown\n        // kind with `Invalid`.\n        //\n        // The cost is real and worth naming: a bad `kinds` value used to fail\n        // without a workspace, and now needs a bound driver to fail. The\n        // alternative — duplicating an open vocabulary host-side — is the\n        // failure mode this contract was shaped to avoid.\n        let limit = req.limit.unwrap_or(5).min(100);\n        let guard = active_memory_guard()\n            .await","sourceCodeStart":39,"sourceCodeEnd":75,"githubUrl":"https://github.com/tinyhumansai/openhuman/blob/749120085864ce16e0f273c7b86fac7740b39c5b/src/openhuman/memory/query/search_entities.rs#L39-L75","documentation":"Argument-deserialization wrapper in the memory_tree_search_entities tool's execute: args failed to deserialize into the search request (e.g. `query` missing or non-string — the schema requires query, with optional kinds filter and limit). Generic sentinel; the serde message in `{e}` names the offending field.","triggerScenarios":"Thrown at src/openhuman/memory/query/search_entities.rs:57 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Include a non-empty \"query\" string","Check limit/kinds field types against the schema","Remove unknown fields"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"749120085864ce16e0f273c7b86fac7740b39c5b","analyzedAt":"2026-08-17T21:21:45.363Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}