{"record":{"id":"d55475133f00eca7","repo":"zeroclaw-labs/zeroclaw","slug":"embedding-route-has-empty-model","errorCode":null,"errorMessage":"embedding route \"{}\" has empty model","messagePattern":"embedding route \"(.+?)\" has empty model","errorType":"console","errorClass":"DiagItem","httpStatus":null,"severity":"warning","filePath":"crates/zeroclaw-runtime/src/doctor/mod.rs","lineNumber":1279,"sourceCode":"        }\n    }\n\n    // Embedding routes validation\n    for route in &config.embedding_routes {\n        if route.hint.trim().is_empty() {\n            items.push(DiagItem::warn(cat, \"embedding route with empty hint\"));\n        }\n        if let Some(reason) = embedding_provider_validation_error(&route.model_provider) {\n            items.push(DiagItem::warn(\n                cat,\n                format!(\n                    \"embedding route \\\"{}\\\" uses invalid model_provider \\\"{}\\\": {}\",\n                    route.hint, route.model_provider, reason\n                ),\n            ));\n        }\n        if route.model.trim().is_empty() {\n            items.push(DiagItem::warn(\n                cat,\n                format!(\"embedding route \\\"{}\\\" has empty model\", route.hint),\n            ));\n        }\n        if route.dimensions.is_some_and(|value| value == 0) {\n            items.push(DiagItem::warn(\n                cat,\n                format!(\n                    \"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","sourceCodeStart":1261,"sourceCodeEnd":1297,"githubUrl":"https://github.com/zeroclaw-labs/zeroclaw/blob/88bb9c8533fc57ed7a03e36ca7c9ed2bf8336dcc/crates/zeroclaw-runtime/src/doctor/mod.rs#L1261-L1297","documentation":"A `zeroclaw doctor` warning from `check_config_semantics`: an `[[embedding_routes]]` entry has a `model` value that is empty after trimming. The route cannot build embedding requests without a model identifier, so memory/embedding features would fail at request time even though the config still loads. Doctor reports it per route, identified by its `hint`.","triggerScenarios":"Running `zeroclaw doctor` (or the `diagnose` API, or any config-validation test) against a config where an `[[embedding_routes]]` table has `model = \"\"`, a whitespace-only model, or omits `model` entirely (serde default fills it with an empty string).","commonSituations":"Hand-written or templated zeroclaw.toml where the model key was forgotten; copy-pasted route stubs with placeholder values; refactors that renamed the field; a leftover route kept around after switching `model_provider = \"none\"`.","solutions":["Set `model` on the offending route to a real embedding model id, e.g. `model = \"text-embedding-3-small\"` for the `openai` provider.","If the route is unused, delete the whole `[[embedding_routes]]` block instead of leaving an empty stub.","Re-run `zeroclaw doctor` and confirm the `embedding route \"<hint>\" has empty model` warning is gone before starting the daemon."],"exampleFix":"# before (zeroclaw.toml)\n[[embedding_routes]]\nhint = \"openai\"\nmodel_provider = \"openai\"\nmodel = \"\"\n\n# after\n[[embedding_routes]]\nhint = \"openai\"\nmodel_provider = \"openai\"\nmodel = \"text-embedding-3-small\"\ndimensions = 1536","handlingStrategy":"validation","validationCode":"// Pre-flight before starting the daemon or shipping config\nfor route in &config.embedding_routes {\n    assert!(\n        !route.model.trim().is_empty(),\n        \"embedding route \\\"{}\\\" needs a non-empty model\",\n        route.hint\n    );\n}","typeGuard":"fn embedding_model_is_set(model: &str) -> bool {\n    !model.trim().is_empty()\n}","tryCatchPattern":null,"preventionTips":["Generate zeroclaw.toml via quickstart/tooling instead of hand-writing route tables.","Never leave placeholder empty strings for required route fields; delete unused routes.","Run `zeroclaw doctor` in CI on every config change so empty models never reach production."],"tags":["config","embeddings","doctor","toml","zeroclaw"],"backgroundTag":"config-validation-failed","analyzedSha":"88bb9c8533fc57ed7a03e36ca7c9ed2bf8336dcc","analyzedAt":"2026-08-23T01:07:41.857Z","schemaVersion":2},"datasetVersion":"2026-08-23T08:06:27.607Z"}