moeru-ai/airi · error
Invalid or missing transcription model. Please configure a v
Error message
Invalid or missing transcription model. Please configure a valid model in the provider settings.
What it means
The openai-compatible transcription page validates the resolved model before calling hearingStore.transcription: modelToUse comes from providerConfig.model, falling back to the reactive model.value, and must pass isValidTranscriptionModel(). That validator accepts known transcription models (whisper-*, gpt-4o-*-transcribe) and custom names, but rejects obvious chat models (names containing 'gpt-4' without 'transcribe'/'whisper'). The error means the resolved model was empty or classified as a chat model.
Source
Thrown at packages/stage-pages/src/pages/settings/providers/transcription/openai-compatible-audio-transcription.vue:89
// Check if API key is configured
const apiKeyConfigured = computed(() => !!providers.value[providerId]?.apiKey)
// Generate transcription
async function handleGenerateTranscription(file: File) {
const provider = await providersStore.getProviderInstance<TranscriptionProviderWithExtraOptions<string, any>>(providerId)
if (!provider)
throw new Error('Failed to initialize transcription provider')
// Get provider configuration
const providerConfig = providerStore.getProviderConfig(providerId)
// Get model from configuration or use the reactive model value
const modelToUse = providerConfig.model as string | undefined || model.value
// Validate model - throw error if no valid model configured
if (!modelToUse || !isValidTranscriptionModel(modelToUse)) {
throw new Error(`Invalid or missing transcription model. Please configure a valid model in the provider settings.`)
}
return await hearingStore.transcription(
providerId,
provider,
modelToUse,
file,
'json',
)
}
// Use the composable to get validation logic and state
const {
t,
router,
providerMetadata,
isValidating,
isValid,View on GitHub (pinned to 677329427f)
Solutions
- Open provider settings and pick a valid transcription model (whisper-1, gpt-4o-transcribe, gpt-4o-mini-transcribe, or your endpoint's whisper-compatible name), then save.
- If your endpoint uses a custom transcription model name, ensure it does not contain 'gpt-4' without also containing 'transcribe' or 'whisper'.
- Persist an explicit default model in the provider's default config so modelToUse is never empty.
- Check onMounted's auto-reset (line 172) ran — an invalid persisted model should be reset to 'whisper-1'; if it did not, clear the stored model value and re-select.
Example fix
// before
const modelToUse = providerConfig.model as string | undefined || model.value
if (!modelToUse || !isValidTranscriptionModel(modelToUse)) {
throw new Error(`Invalid or missing transcription model. Please configure a valid model in the provider settings.`)
}
// after — fall back to whisper-1 and warn instead of hard-failing
const modelToUse = providerConfig.model as string | undefined || model.value || 'whisper-1'
if (!isValidTranscriptionModel(modelToUse)) {
throw new Error(`Invalid transcription model "${modelToUse}". Choose a transcription model (e.g. whisper-1) in provider settings.`)
} Defensive patterns
Strategy: validation
Validate before calling
const modelToUse = providerConfig.model as string | undefined || model.value
if (!modelToUse || !isValidTranscriptionModel(modelToUse)) {
// block generation and prompt model selection; do not call hearingStore.transcription
} Type guard
function isValidTranscriptionModel(modelName: string | undefined | null): boolean {
if (!modelName)
return false
if (VALID_TRANSCRIPTION_MODELS.includes(modelName))
return true
if (modelName.includes('gpt-4') && !modelName.includes('transcribe') && !modelName.includes('whisper'))
return false
return true
} Try / catch
try {
await handleGenerateTranscription(file)
}
catch (error) {
if (errorMessageFrom(error).includes('Invalid or missing transcription model')) {
// focus the model selector in provider settings
}
throw error
} Prevention
- Validate the model in the settings form on save, not only at generation time.
- Default the openai-compatible provider to 'whisper-1' so modelToUse is never empty.
- Re-run the onMounted auto-reset check after programmatic config changes.
When it happens
Trigger: providerConfig.model and model.value are both empty (no model ever selected/saved), or the saved model is something like 'gpt-4o' / 'gpt-4-turbo' which fails the chat-model rejection branch at openai-compatible-audio-transcription.vue:155.
Common situations: User previously saved a chat model on a shared openai-compatible provider config; a fresh install where no default model is set for the openai-compatible provider (unlike the official page it has no hardcoded fallback here); custom endpoint exposing only chat models; stale persisted model value from an older config layout.
Related errors
- Failed to initialize transcription provider
- Failed to initialize transcription provider
- [Hearing] Confidence filter is enabled but the provider did
- Web Speech API is not available in this environment. It requ
- MiMo transcription failed: ${response.status} ${response.sta
AI-assisted analysis of moeru-ai/airi@677329427f (2026-08-18).
Data as JSON: /api/errors/37138966813cda71.
Report an issue: GitHub.