{"record":{"id":"752d28bf19ea5a8c","repo":"zeroclaw-labs/zeroclaw","slug":"memory-embedding-model-uses-hint-hint-but-no-m","errorCode":null,"errorMessage":"memory.embedding_model uses hint \"{hint}\" but no matching [[embedding_routes]] entry exists","messagePattern":"memory\\.embedding_model uses hint \"(.+?)\" but no matching \\[\\[embedding_routes\\]\\] entry exists","errorType":"console","errorClass":"DiagItem","httpStatus":null,"severity":"warning","filePath":"crates/zeroclaw-runtime/src/doctor/mod.rs","lineNumber":1306,"sourceCode":"                    \"embedding route \\\"{}\\\" has invalid dimensions=0\",\n                    route.hint\n                ),\n            ));\n        }\n    }\n\n    if let Some(hint) = config\n        .memory\n        .embedding_model\n        .strip_prefix(\"hint:\")\n        .map(str::trim)\n        .filter(|value| !value.is_empty())\n        && !config\n            .embedding_routes\n            .iter()\n            .any(|route| route.hint.trim() == hint)\n    {\n        items.push(DiagItem::warn(\n                cat,\n                format!(\n                    \"memory.embedding_model uses hint \\\"{hint}\\\" but no matching [[embedding_routes]] entry exists\"\n                ),\n            ));\n    }\n\n    // gateway.web_dist_dir: flag values that rely on shell expansion the\n    // gateway does not perform. Parallel check lives in\n    // `src/commands/self_test.rs::check_web_dist_dir`; keep the wording\n    // and predicate in sync.\n    check_web_dist_dir(config, items);\n\n    // Channel: at least one configured\n    let cc = &config.channels;\n    let has_channel = cc.channels().iter().any(|info| info.configured);\n\n    if has_channel {","sourceCodeStart":1288,"sourceCodeEnd":1324,"githubUrl":"https://github.com/zeroclaw-labs/zeroclaw/blob/88bb9c8533fc57ed7a03e36ca7c9ed2bf8336dcc/crates/zeroclaw-runtime/src/doctor/mod.rs#L1288-L1324","documentation":"A `zeroclaw doctor` warning from `check_config_semantics`: `memory.embedding_model` holds a non-empty hint string, but no `[[embedding_routes]]` entry has a matching `hint` (compared after trimming). The hint is meant to point at a route by name; with no match, memory cannot resolve which embedding route to use and would fall back or fail at runtime.","triggerScenarios":"Running `zeroclaw doctor`/`diagnose` when `memory.embedding_model` is set to a short alias (e.g. \"openai\") while every `[[embedding_routes]]` entry has a different `hint`, or no routes exist at all. Comparison is `route.hint.trim() == hint`.","commonSituations":"Renaming a route's `hint` without updating `memory.embedding_model`; typos or case differences between the two values; deleting a route but leaving the memory hint pointing at it.","solutions":["Add an `[[embedding_routes]]` entry whose `hint` exactly matches the value in `memory.embedding_model`.","Or correct `memory.embedding_model` to reference an existing route's `hint` (watch for typos and stray whitespace).","If you removed embedding routes on purpose, clear `memory.embedding_model` so it is empty rather than dangling.","Re-run `zeroclaw doctor` to verify the hint resolves."],"exampleFix":"# before\nmemory.embedding_model = \"openai\"   # no route with hint = \"openai\"\n\n[[embedding_routes]]\nhint = \"embed-main\"\nmodel_provider = \"openai\"\nmodel = \"text-embedding-3-small\"\n\n# after\nmemory.embedding_model = \"embed-main\"","handlingStrategy":"validation","validationCode":"let hint = config.memory.embedding_model.trim();\nif !hint.is_empty() {\n    assert!(\n        config.embedding_routes.iter().any(|r| r.hint.trim() == hint),\n        \"no [[embedding_routes]] entry with hint = \\\"{hint}\\\"\"\n    );\n}","typeGuard":"fn hint_resolves(hint: &str, route_hints: &[String]) -> bool {\n    hint.trim().is_empty()\n        || route_hints.iter().any(|h| h.trim() == hint.trim())\n}","tryCatchPattern":null,"preventionTips":["Define each hint once and reference it everywhere else; rename in one commit.","Add a config lint (doctor in CI) that fails on dangling memory.embedding_model references."],"tags":["config","memory","embeddings","doctor","dangling-reference","zeroclaw"],"backgroundTag":"dangling-config-reference","analyzedSha":"88bb9c8533fc57ed7a03e36ca7c9ed2bf8336dcc","analyzedAt":"2026-08-23T01:07:41.857Z","schemaVersion":2},"datasetVersion":"2026-08-23T08:06:27.607Z"}