1c01213 feat: support both string and JSON object formats for OpenAI TTS voice parameter
📊 Changes
1 file changed (+15 additions, -1 deletions)
View changed files
📝backend/open_webui/routers/audio.py (+15 -1)
📄 Description
This pull request introduces support for both string and JSON object formats for the voice parameter in the OpenAI TTS implementation.
Previously, the system only accepted a simple string for the voice setting, which limited compatibility with services requiring more complex configurations, such as Vertex AI TTS using the LiteLLM proxy.
With this update, the code now attempts to parse the TTS_VOICE configuration value. If it can be successfully parsed as a JSON object, it will be used as such; otherwise, the original string value will be utilized.
🔄 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/11737
**Author:** [@roeizavida](https://github.com/roeizavida)
**Created:** 3/16/2025
**Status:** ❌ Closed
**Base:** `dev` ← **Head:** `feat/tts-voice-json`
---
### 📝 Commits (1)
- [`1c01213`](https://github.com/open-webui/open-webui/commit/1c012133c0588e09f39c65f380742e446dc5aff2) feat: support both string and JSON object formats for OpenAI TTS voice parameter
### 📊 Changes
**1 file changed** (+15 additions, -1 deletions)
<details>
<summary>View changed files</summary>
📝 `backend/open_webui/routers/audio.py` (+15 -1)
</details>
### 📄 Description
This pull request introduces support for both string and JSON object formats for the voice parameter in the OpenAI TTS implementation.
Previously, the system only accepted a simple string for the voice setting, which limited compatibility with services requiring more complex configurations, such as Vertex AI TTS using the LiteLLM proxy.
With this update, the code now attempts to parse the TTS_VOICE configuration value. If it can be successfully parsed as a JSON object, it will be used as such; otherwise, the original string value will be utilized.
---
<sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
📋 Pull Request Information
Original PR: https://github.com/open-webui/open-webui/pull/11737
Author: @roeizavida
Created: 3/16/2025
Status: ❌ Closed
Base:
dev← Head:feat/tts-voice-json📝 Commits (1)
1c01213feat: support both string and JSON object formats for OpenAI TTS voice parameter📊 Changes
1 file changed (+15 additions, -1 deletions)
View changed files
📝
backend/open_webui/routers/audio.py(+15 -1)📄 Description
This pull request introduces support for both string and JSON object formats for the voice parameter in the OpenAI TTS implementation.
Previously, the system only accepted a simple string for the voice setting, which limited compatibility with services requiring more complex configurations, such as Vertex AI TTS using the LiteLLM proxy.
With this update, the code now attempts to parse the TTS_VOICE configuration value. If it can be successfully parsed as a JSON object, it will be used as such; otherwise, the original string value will be utilized.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.