Skip to content

Commit e70923c

Browse files
committed
fix(models): report local models as available in CLI list output (#92224)
The 'openclaw models list' command showed available: false for local Ollama models that were actually running and working. This happened because the availability check relied on provider auth (API keys) which local providers like Ollama don't use. Skip the auth-based availability fallback for models with a local baseUrl (localhost, 127.0.0.1, etc.) and report them as available whenever they are configured. Closes #92224
1 parent d481994 commit e70923c

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

src/commands/models/list.model-row.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,11 @@ export function toModelRow(params: {
5454
// Prefer model-level registry availability when present.
5555
// Fall back to provider-level auth heuristics only if registry availability isn't available,
5656
// or if the caller marks this as a synthetic/forward-compat model that won't appear in getAvailable().
57-
const available =
58-
availableKeys !== undefined && !allowProviderAvailabilityFallback
57+
// Local providers (Ollama, LM Studio, etc.) don't need API-key auth so they are always available
58+
// when configured (#92224).
59+
const available = local
60+
? true
61+
: availableKeys !== undefined && !allowProviderAvailabilityFallback
5962
? modelIsAvailable
6063
: modelIsAvailable || (params.hasAuthForProvider?.(model.provider) ?? false);
6164
const aliasTags = aliases.length > 0 ? [`alias:${aliases.join(",")}`] : [];

0 commit comments

Comments
 (0)