bug: /v2/settings/providers catalog ignores isAvailableBy
Describe the bug
The v2 provider catalog at /v2/settings/providers lists every registered provider definition and never checks isAvailableBy. Providers gated to a specific runtime still appear in the add menu.
Steps to reproduce
- Open
/v2/settings/providersin the web build (stage-web). - Open the add menu in the provider pane.
- Observe providers that cannot run on this surface, for example
NVIDIAorApp (Local).
Evidence
packages/stage-pages/src/pages/v2/settings/providers.vue
- Lines 24-29:
availableProvidersmapslistProviders()directly. - Line 95: the add menu renders that list and calls
handleAdd(provider.id).
packages/stage-ui/src/libs/providers/providers/registry.ts
- Lines 54-58:
listProviders()returns the raw registry, sorted by order and name. It never consultsisAvailableBy.
Providers gated by isAvailableBy:
nvidia—isStageTamagotchiapple-speech—isAppleSpeechAvailableapp-local-audio-speech—isStageTamagotchiapp-local-audio-transcription—isStageTamagotchibrowser-local-audio-speech—isBrowserAndMemoryEnoughbrowser-local-audio-transcription— always hidden, see #2297 item 6
Current behavior
A user can add a provider that the rest of the app then hides. packages/stage-ui/src/stores/providers/provider.ts:959-965 filters the provider list with await isAvailableBy(), so the configured entry never appears in the module provider pickers.
Expected behavior
The v2 catalog should only offer providers that are available on the current surface.
Notes
listProviders() is synchronous and is also consumed outside the settings pages. isAvailableBy is asynchronous. Centralizing provider visibility likely needs an API decision rather than a local filter inside providers.vue.
Source: moeru-ai/airi