[PR #21824] feat: add Gladia.io as a Speech-to-Text provider #49342

Open
opened 2026-04-30 01:38:58 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/open-webui/open-webui/pull/21824
Author: @jqueguiner
Created: 2/24/2026
Status: 🔄 Open

Base: devHead: feat/gladia-stt-provider


📝 Commits (1)

  • 6b28d10 feat: add Gladia.io as a Speech-to-Text provider

📊 Changes

4 files changed (+170 additions, -1 deletions)

View changed files

📝 backend/open_webui/config.py (+6 -0)
📝 backend/open_webui/main.py (+3 -0)
📝 backend/open_webui/routers/audio.py (+150 -0)
📝 src/lib/components/admin/Settings/Audio.svelte (+11 -1)

📄 Description

Pull Request Checklist

  • Target branch: Verify that the pull request targets the dev branch.
  • Description: Provided below.
  • Changelog: Provided below.
  • Documentation: To be added in Open WebUI Docs Repository (https://github.com/open-webui/docs/pull/1110).
  • Dependencies: No new dependencies. Uses existing requests and mimetypes libraries.
  • Testing: Manually tested with a running Docker container — Gladia STT engine option appears in Admin Settings > Audio, API key can be configured, and audio transcription works via the 3-step Gladia v2 workflow.
  • Agentic AI Code: This PR has gone through human review and manual testing.
  • Code review: Self-reviewed, follows existing STT provider patterns (Deepgram, Azure, Mistral).
  • Design & Architecture: Follows the existing conditional dispatch pattern in transcription_handler().
  • Git Hygiene: Single atomic commit, rebased on dev.
  • Title Prefix: feat:

Changelog Entry

Description

Integrates Gladia.io as a new Speech-to-Text (STT) engine option in Open WebUI. Gladia provides high-accuracy, multilingual transcription via their pre-recorded API (v2). This follows the same provider pattern as existing STT engines (OpenAI, Deepgram, Azure, Mistral).

The implementation uses Gladia's 3-step async transcription workflow:

  1. Upload audio file to POST /v2/upload
  2. Initiate transcription via POST /v2/pre-recorded
  3. Poll for results via GET {result_url} until completion

Added

  • Gladia STT engine option (gladia) in the Speech-to-Text engine dropdown
  • AUDIO_STT_GLADIA_API_KEY environment variable and PersistentConfig for API key storage
  • Gladia API key input field in Admin Settings > Audio when Gladia engine is selected
  • Full transcription handler with file upload, transcription initiation, polling, and transcript extraction
  • Language passthrough support for Gladia transcriptions
  • Error handling consistent with other STT providers

Changed

  • STTConfigForm model extended with GLADIA_API_KEY field
  • Audio config GET/POST endpoints return and accept Gladia API key
  • transcription_handler() extended with gladia engine branch

Deprecated

  • None

Removed

  • None

Fixed

  • None

Security

  • API key stored via PersistentConfig (same pattern as other providers)
  • API key input uses SensitiveInput component in the frontend

Breaking Changes

  • None

Additional Information

  • Gladia API documentation: https://docs.gladia.io/api-reference/v2
  • Files modified:
    • backend/open_webui/config.py — Added AUDIO_STT_GLADIA_API_KEY PersistentConfig
    • backend/open_webui/main.py — Added import and app state initialization
    • backend/open_webui/routers/audio.py — Added Gladia to STTConfigForm, config endpoints, and transcription handler
    • src/lib/components/admin/Settings/Audio.svelte — Added Gladia option and API key settings UI

Screenshots or Videos

  • Gladia appears as an option in Admin Panel > Settings > Audio > Speech-to-Text Engine dropdown
  • When selected, an API Key input field is shown for configuring the Gladia API key
    image
image

Contributor License Agreement

By submitting this pull request, I confirm that I have read and fully agree to the Contributor License Agreement (CLA), and I am providing my contributions under its terms.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/open-webui/open-webui/pull/21824 **Author:** [@jqueguiner](https://github.com/jqueguiner) **Created:** 2/24/2026 **Status:** 🔄 Open **Base:** `dev` ← **Head:** `feat/gladia-stt-provider` --- ### 📝 Commits (1) - [`6b28d10`](https://github.com/open-webui/open-webui/commit/6b28d1074ae05bad18c9cf2990aba4b37194cdb0) feat: add Gladia.io as a Speech-to-Text provider ### 📊 Changes **4 files changed** (+170 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `backend/open_webui/config.py` (+6 -0) 📝 `backend/open_webui/main.py` (+3 -0) 📝 `backend/open_webui/routers/audio.py` (+150 -0) 📝 `src/lib/components/admin/Settings/Audio.svelte` (+11 -1) </details> ### 📄 Description # Pull Request Checklist - [x] **Target branch:** Verify that the pull request targets the `dev` branch. - [x] **Description:** Provided below. - [x] **Changelog:** Provided below. - [x] **Documentation:** To be added in Open WebUI Docs Repository (https://github.com/open-webui/docs/pull/1110). - [x] **Dependencies:** No new dependencies. Uses existing `requests` and `mimetypes` libraries. - [x] **Testing:** Manually tested with a running Docker container — Gladia STT engine option appears in Admin Settings > Audio, API key can be configured, and audio transcription works via the 3-step Gladia v2 workflow. - [x] **Agentic AI Code:** This PR has gone through human review and manual testing. - [x] **Code review:** Self-reviewed, follows existing STT provider patterns (Deepgram, Azure, Mistral). - [x] **Design & Architecture:** Follows the existing conditional dispatch pattern in `transcription_handler()`. - [x] **Git Hygiene:** Single atomic commit, rebased on `dev`. - [x] **Title Prefix:** `feat:` # Changelog Entry ### Description Integrates [Gladia.io](https://gladia.io) as a new Speech-to-Text (STT) engine option in Open WebUI. Gladia provides high-accuracy, multilingual transcription via their pre-recorded API (v2). This follows the same provider pattern as existing STT engines (OpenAI, Deepgram, Azure, Mistral). The implementation uses Gladia's 3-step async transcription workflow: 1. **Upload** audio file to `POST /v2/upload` 2. **Initiate** transcription via `POST /v2/pre-recorded` 3. **Poll** for results via `GET {result_url}` until completion ### Added - Gladia STT engine option (`gladia`) in the Speech-to-Text engine dropdown - `AUDIO_STT_GLADIA_API_KEY` environment variable and PersistentConfig for API key storage - Gladia API key input field in Admin Settings > Audio when Gladia engine is selected - Full transcription handler with file upload, transcription initiation, polling, and transcript extraction - Language passthrough support for Gladia transcriptions - Error handling consistent with other STT providers ### Changed - `STTConfigForm` model extended with `GLADIA_API_KEY` field - Audio config GET/POST endpoints return and accept Gladia API key - `transcription_handler()` extended with `gladia` engine branch ### Deprecated - None ### Removed - None ### Fixed - None ### Security - API key stored via PersistentConfig (same pattern as other providers) - API key input uses `SensitiveInput` component in the frontend ### Breaking Changes - None --- ### Additional Information - Gladia API documentation: https://docs.gladia.io/api-reference/v2 - Files modified: - `backend/open_webui/config.py` — Added `AUDIO_STT_GLADIA_API_KEY` PersistentConfig - `backend/open_webui/main.py` — Added import and app state initialization - `backend/open_webui/routers/audio.py` — Added Gladia to STTConfigForm, config endpoints, and transcription handler - `src/lib/components/admin/Settings/Audio.svelte` — Added Gladia option and API key settings UI ### Screenshots or Videos - Gladia appears as an option in Admin Panel > Settings > Audio > Speech-to-Text Engine dropdown - When selected, an API Key input field is shown for configuring the Gladia API key <img width="1010" height="785" alt="image" src="https://github.com/user-attachments/assets/b3ec8563-aea1-4190-a2f9-aa372228e46b" /> <img width="1313" height="512" alt="image" src="https://github.com/user-attachments/assets/f615054f-e473-4d55-82d6-abed37749f4e" /> ### Contributor License Agreement By submitting this pull request, I confirm that I have read and fully agree to the [Contributor License Agreement (CLA)](https://github.com/open-webui/open-webui/blob/main/CONTRIBUTOR_LICENSE_AGREEMENT), and I am providing my contributions under its terms. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-30 01:38:58 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#49342