{"record":{"id":"8cca5ca84060517b","repo":"tinyhumansai/openhuman","slug":"invalid-arguments-for-memory-vector-search-e","errorCode":null,"errorMessage":"invalid arguments for memory_vector_search: {e}","messagePattern":"invalid arguments for memory_vector_search: (.+?)","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/openhuman/memory/tools/search/vector_search.rs","lineNumber":100,"sourceCode":"                    \"description\": \"Minimum cosine similarity threshold (default 0.3).\"\n                },\n                \"limit\": {\n                    \"type\": \"integer\",\n                    \"minimum\": 1,\n                    \"maximum\": 50,\n                    \"description\": \"Max results to return (default 10).\"\n                },\n                \"diverse\": {\n                    \"type\": \"boolean\",\n                    \"description\": \"Apply MMR diversity to reduce redundancy among results (default false).\"\n                }\n            }\n        })\n    }\n\n    async fn execute(&self, args: serde_json::Value) -> anyhow::Result<ToolResult> {\n        let parsed: Args = serde_json::from_value(args)\n            .map_err(|e| anyhow::anyhow!(\"invalid arguments for memory_vector_search: {e}\"))?;\n\n        if parsed.query.trim().is_empty() {\n            return Err(anyhow::anyhow!(\n                \"memory_vector_search: query cannot be empty\"\n            ));\n        }\n\n        let limit = parsed.limit.clamp(1, 50);\n        let min_score = parsed.min_score.unwrap_or(0.3);\n\n        log::debug!(\n            \"[tool][memory_vector_search] query_len={} source_kind={:?} window={:?} min_score={} limit={} diverse={}\",\n            parsed.query.len(),\n            parsed.source_kind,\n            parsed.time_window_days,\n            min_score,\n            limit,\n            parsed.diverse,","sourceCodeStart":82,"sourceCodeEnd":118,"githubUrl":"https://github.com/tinyhumansai/openhuman/blob/749120085864ce16e0f273c7b86fac7740b39c5b/src/openhuman/memory/tools/search/vector_search.rs#L82-L118","documentation":"The `memory_vector_search` arguments failed serde deserialization into the tool's typed `Args` struct. The schema is descriptive, not enforced by JSON Schema itself — the Rust parse is the real gate — so this fires on wrong types (query not a string, limit outside 1–50 declared bounds at the type level, min_score not a number) or unexpected fields, with `{e}` naming the exact mismatch.","triggerScenarios":"Thrown at src/openhuman/memory/tools/search/vector_search.rs:100 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Match every argument's type to the schema: query as string, limit as integer 1–50, min_score as number, diverse as boolean","Read the serde error `{e}` — it names the field and the expected type","Drop unknown fields not present in the schema"],"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"}