zeroclaw-labs/zeroclaw · error · anyhow::Error
No configured model_providers — run `zeroclaw quickstart` to
Error message
No configured model_providers — run `zeroclaw quickstart` to set one up first
What it means
run_configured_models lists (and with --check verifies) the models declared under model_providers. When configured_model_entries returns an empty set there is nothing to show, so the command aborts and points at zeroclaw quickstart. Note the empty set also arises when a provider filter matches no configured alias, since the filter is applied before the emptiness check.
Source
Thrown at crates/zeroclaw-runtime/src/doctor/mod.rs:920
.collect()
}
/// Whether a configured model id appears verbatim in a provider's live catalog.
/// Pure — separated so the membership rule is explicit and unit-testable
/// without any network probe.
fn model_in_catalog(model: &str, catalog: &[String]) -> bool {
catalog.iter().any(|id| id == model)
}
pub async fn run_configured_models(
config: &Config,
provider_override: Option<&str>,
verify: bool,
) -> Result<()> {
let entries = configured_model_entries(config, provider_override);
if entries.is_empty() {
anyhow::bail!(
"No configured model_providers — run `zeroclaw quickstart` to set one up first"
);
}
if verify {
println!("🩺 ZeroClaw — Configured Models (--check)");
} else {
println!("🩺 ZeroClaw — Configured Models");
}
println!();
let mut ok = 0usize;
let mut warn = 0usize;
let mut error = 0usize;
for (provider_ref, model) in &entries {
println!(" [{}]", provider_ref);
View on GitHub (pinned to 88bb9c8533)
Solutions
- Run zeroclaw quickstart or add [model_providers.<alias>] entries
- If you passed a provider filter, verify the alias matches a configured key exactly
- Re-run the configured-models listing
Example fix
# zeroclaw.toml — before # (no model_providers section) # after [model_providers.openai] model = "gpt-4o" uri = "https://api.openai.com/v1" api_key = "sk-..."
Defensive patterns
Strategy: validation
Validate before calling
if config.providers.models.is_empty() {
anyhow::bail!("run `zeroclaw quickstart` or add [model_providers.<alias>] first");
}
zeroclaw_runtime::doctor::run_configured_models(&config, override.as_deref(), false).await?; Type guard
fn has_configured_model_entries(config: &zeroclaw_config::schema::Config, filter: Option<&str>) -> bool {
match filter.map(str::trim).filter(|f| !f.is_empty()) {
Some(f) => config.providers.models.contains_key(f),
None => !config.providers.models.is_empty(),
}
} Try / catch
if let Err(err) = zeroclaw_runtime::doctor::run_configured_models(&config, override.as_deref(), verify).await {
if err.to_string().contains("No configured model_providers") {
eprintln!("empty result — either no providers exist or the --provider alias matched none");
return Ok(());
}
return Err(err);
} Prevention
- When using a provider filter, confirm the alias exists first — a miss reports as 'no providers', not 'unknown provider'
- Bootstrap new environments with zeroclaw quickstart before running model tooling
When it happens
Trigger: Fresh install with no [model_providers.*] entries; or a provider override whose alias matches no configured provider key, making the filtered entry list empty.
Common situations: First run in a new container or data dir; a typo'd --provider alias producing a misleading "no providers" message instead of a not-found error.
Related errors
- No configured model_providers to probe — run `zeroclaw quick
- Model probe failed for target model_provider
- Model provider '{model_provider}' not found in config
- No configured model verified for target model_provider
- model route "{}" uses invalid model_provider "{}": {}
AI-assisted analysis of zeroclaw-labs/zeroclaw@88bb9c8533 (2026-08-23).
Data as JSON: /api/errors/64cca10f4143d8cf.
Report an issue: GitHub.