zeroclaw-labs/zeroclaw · warning · DiagItem
{label}: no model configured
Error message
{label}: no model configured What it means
check_config_semantics warns when a provider profile has no `model` configured. Without a model name on the profile, requests routed through it cannot resolve a concrete model and will fail or behave unexpectedly downstream.
Source
Thrown at crates/zeroclaw-runtime/src/doctor/mod.rs:1164
}
// API key presence
if family != "ollama" {
if entry.api_key.as_deref().is_some() {
items.push(DiagItem::ok(cat, format!("{label}: API key configured")));
} else {
items.push(DiagItem::warn(
cat,
format!("{label}: no api_key set (may rely on env vars or model_provider defaults)"),
));
}
}
// Model configured
if let Some(model) = entry.model.as_deref() {
items.push(DiagItem::ok(cat, format!("{label}: model: {model}")));
} else {
items.push(DiagItem::warn(cat, format!("{label}: no model configured")));
}
// A missing value remains unknown until this profile is selected;
// zero is explicitly invalid because it leaves recovery with no
// usable model-context budget.
match entry.context_window {
Some(0) => items.push(DiagItem::error(
cat,
crate::i18n::get_required_cli_string_with_args(
"cli-doctor-context-window-zero",
&[("provider_ref", &label)],
),
)),
Some(context_window) => items.push(DiagItem::ok(
cat,
crate::i18n::get_required_cli_string_with_args(
"cli-doctor-context-window-ok",
&[View on GitHub (pinned to 88bb9c8533)
Solutions
- Set `model` on the provider profile to a concrete model name (e.g. `gpt-4o-mini` or the local model id)
- If model routes are meant to override the model, still set a safe default on the profile
- Re-run `zeroclaw doctor` to confirm the profile reports `model: ...` as ok
Example fix
# before [providers.openai] family = "openai" api_key = "sk-..." # after [providers.openai] family = "openai" api_key = "sk-..." model = "gpt-4o-mini"
Defensive patterns
Strategy: validation
Validate before calling
import tomllib
cfg = tomllib.load(open('zeroclaw.toml', 'rb'))
for name, p in cfg.get('providers', {}).items():
assert p.get('model'), f'{name}: no model configured' Prevention
- Always set a default model when creating a provider profile
- Lint provider entries (model present) in config review before deploy
When it happens
Trigger: A providers entry with an api_key but no `model` field; doctor prints `{label}: no model configured` during any diagnostic run.
Common situations: Profiles created with only auth in mind, expecting routes to supply the model; config migration dropping a renamed field; multi-model setups missing the default.
Related errors
- model route "{}" has empty model
- model route "{}" uses invalid model_provider "{}": {}
- embedding route "{}" uses invalid model_provider "{}": {}
- agent "{name}" uses invalid model_provider "{provider_ref}":
- config section `{$path}` is malformed and was reset to defau
AI-assisted analysis of zeroclaw-labs/zeroclaw@88bb9c8533 (2026-08-23).
Data as JSON: /api/errors/f884357d2901bd6f.
Report an issue: GitHub.