langgenius/dify · warning · SpeechToTextDisabledError
speech_to_text_disabled
speech_to_text_disabled
Error message
Speech to text is disabled.
What it means
HTTP 400 SpeechToTextDisabledError, raised by the STT endpoint. The effective application configuration has speech-to-text turned off (or the config is missing entirely). AudioService.transcript_asr checks the feature per app mode: for ADVANCED_CHAT/WORKFLOW it requires workflow.features_dict['speech_to_text']['enabled']; for legacy modes it requires app_model_config.speech_to_text_dict['enabled']; for AGENT apps it merges the agent soul features and requires the merged speech_to_text enabled. Any of these being absent/false raises SpeechToTextDisabledServiceError.
Source
Thrown at api/controllers/console/explore/audio.py:81
file=file,
session=db.session(),
end_user=None,
)
return response
except services.errors.app_model_config.AppModelConfigBrokenError:
logger.exception("App model config broken.")
raise AppUnavailableError()
except NoAudioUploadedServiceError:
raise NoAudioUploadedError()
except AudioTooLargeServiceError as e:
raise AudioTooLargeError(str(e))
except UnsupportedAudioTypeServiceError:
raise UnsupportedAudioTypeError()
except ProviderNotSupportSpeechToTextServiceError:
raise ProviderNotSupportSpeechToTextError()
except SpeechToTextDisabledServiceError:
raise SpeechToTextDisabledError()
except ProviderTokenNotInitError as ex:
raise ProviderNotInitializeError(ex.description)
except QuotaExceededError:
raise ProviderQuotaExceededError()
except ModelCurrentlyNotSupportError:
raise ProviderModelCurrentlyNotSupportError()
except InvokeError as e:
raise CompletionRequestError(e.description)
except ValueError as e:
raise e
except Exception as e:
logger.exception("internal server error.")
raise InternalServerError()
@console_ns.route(
"/installed-apps/<uuid:installed_app_id>/text-to-audio",
endpoint="installed_app_text",View on GitHub (pinned to ef8544b173)
Solutions
- Open the app in the studio, enable the Speech-to-Text feature, and republish (for workflow/advanced-chat) or save (for legacy chat/completion).
- For Agent apps, ensure the published Agent Soul has speech_to_text enabled, then republish.
- If the AppModelConfig row is missing, restore or recreate the app configuration.
- Confirm you are calling audio-to-text on an app that is actually meant to support voice input.
Defensive patterns
Strategy: validation
Validate before calling
// Only render the audio-upload control when the app's feature flags enable STT. if (app.features?.speech_to_text?.enabled) renderMicButton() else hideMicButton()
Try / catch
try { await postAudio(file) }
catch (e) { if (e.code === 400 && e.error_code === 'speech_to_text_disabled') disableMicButton() else throw e } Prevention
- Have app authors enable Speech-to-Text in the studio and republish before users rely on it.
- Gate the mic UI on the app's published features.speech_to_text.enabled flag.
- After republishing a workflow, confirm the speech_to_text feature survived the publish.
When it happens
Trigger: POST /console/explore/installed-apps/{id}/audio-to-text on an app whose STT feature flag is disabled; a workflow app with no 'speech_to_text' block in features_dict; a legacy app whose AppModelConfig row is missing or has speech_to_text_dict.enabled = false; a published Agent whose merged soul features disable STT.
Common situations: App author never enabled the Speech-to-Text toggle in the app studio; workflow was republished without the STT feature; app model config was corrupted/deleted; agent soul published without STT.
Related errors
- provider_not_support_speech_to_text
- provider_not_initialize
- provider_quota_exceeded
- model_currently_not_support
- completion_request_error
AI-assisted analysis of langgenius/dify@ef8544b173 (2026-08-12).
Data as JSON: /api/errors/6138f7fb6d9b4647.
Report an issue: GitHub.