[GH-ISSUE #17316] issue: Text-to-Speech broken after latest update when using local TTS provider via OpenAI engine #72842

Closed
opened 2026-05-13 05:01:37 -05:00 by GiteaMirror · 3 comments
Owner

Originally created by @robertbeckey on GitHub (Sep 9, 2025).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/17316

Check Existing Issues

  • I have searched for any existing and/or related issues.
  • I have searched for any existing and/or related discussions.
  • I am using the latest version of Open WebUI.

Installation Method

Docker

Open WebUI Version

v0.6.27

Ollama Version (if applicable)

No response

Operating System

Windows 11

Browser (if applicable)

Brave

Confirmation

  • I have read and followed all instructions in README.md.
  • I am using the latest version of both Open WebUI and Ollama.
  • I have included the browser console logs.
  • I have included the Docker container logs.
  • I have provided every relevant configuration, setting, and environment variable used in my setup.
  • I have clearly listed every relevant configuration, custom setting, environment variable, and command-line option that influences my setup (such as Docker Compose overrides, .env values, browser settings, authentication configurations, etc).
  • I have documented step-by-step reproduction instructions that are precise, sequential, and leave nothing to interpretation. My steps:
  • Start with the initial platform/version/OS and dependencies used,
  • Specify exact install/launch/configure commands,
  • List URLs visited, user input (incl. example values/emails/passwords if needed),
  • Describe all options and toggles enabled or changed,
  • Include any files or environmental changes,
  • Identify the expected and actual result at each stage,
  • Ensure any reasonably skilled user can follow and hit the same issue.

Expected Behavior

In previous versions, text-to-speech generated correctly using the following options:
Text-to-Speech Engine: OpenAI
API base URL: http://host.docker.internal:8880/v1
API key: not-needed
TTS Voice: af_heart
TTS Model: kokoro
Response splitting: Punctuation

This would connect up to a kokoro-fastapi Docker container for local TTS and worked great.

Actual Behavior

Now, the Read Aloud button produces the following pop-up error many times in Open WebUI:
External: 404, message='Not Found', url='http://host.docker.internal:8880/audio/speech'

In the kokoro-fastapi container logs, the following error is posted:
"POST /audio/speech HTTP/1.1" 404 Not Found

Steps to Reproduce

Already described

Logs & Screenshots

Already described

Additional Information

No response

Originally created by @robertbeckey on GitHub (Sep 9, 2025). Original GitHub issue: https://github.com/open-webui/open-webui/issues/17316 ### Check Existing Issues - [x] I have searched for any existing and/or related issues. - [x] I have searched for any existing and/or related discussions. - [x] I am using the latest version of Open WebUI. ### Installation Method Docker ### Open WebUI Version v0.6.27 ### Ollama Version (if applicable) _No response_ ### Operating System Windows 11 ### Browser (if applicable) Brave ### Confirmation - [x] I have read and followed all instructions in `README.md`. - [x] I am using the latest version of **both** Open WebUI and Ollama. - [x] I have included the browser console logs. - [x] I have included the Docker container logs. - [x] I have **provided every relevant configuration, setting, and environment variable used in my setup.** - [x] I have clearly **listed every relevant configuration, custom setting, environment variable, and command-line option that influences my setup** (such as Docker Compose overrides, .env values, browser settings, authentication configurations, etc). - [x] I have documented **step-by-step reproduction instructions that are precise, sequential, and leave nothing to interpretation**. My steps: - Start with the initial platform/version/OS and dependencies used, - Specify exact install/launch/configure commands, - List URLs visited, user input (incl. example values/emails/passwords if needed), - Describe all options and toggles enabled or changed, - Include any files or environmental changes, - Identify the expected and actual result at each stage, - Ensure any reasonably skilled user can follow and hit the same issue. ### Expected Behavior In previous versions, text-to-speech generated correctly using the following options: Text-to-Speech Engine: OpenAI API base URL: http://host.docker.internal:8880/v1 API key: not-needed TTS Voice: af_heart TTS Model: kokoro Response splitting: Punctuation This would connect up to a kokoro-fastapi Docker container for local TTS and worked great. ### Actual Behavior Now, the Read Aloud button produces the following pop-up error many times in Open WebUI: External: 404, message='Not Found', url='http://host.docker.internal:8880/audio/speech' In the kokoro-fastapi container logs, the following error is posted: "POST /audio/speech HTTP/1.1" 404 Not Found ### Steps to Reproduce Already described ### Logs & Screenshots Already described ### Additional Information _No response_
GiteaMirror added the bug label 2026-05-13 05:01:37 -05:00
Author
Owner

@98h398hrpohpoai commented on GitHub (Sep 9, 2025):

Same. PWA shows the api no longer passing the /v1 endpoint, but rather /audio/speech (without v1)

Edit: Here's the reference for it: https://github.com/open-webui/open-webui/pull/17061#issuecomment-3249144572

<!-- gh-comment-id:3271992003 --> @98h398hrpohpoai commented on GitHub (Sep 9, 2025): Same. PWA shows the api no longer passing the /v1 endpoint, but rather /audio/speech (without v1) Edit: Here's the reference for it: https://github.com/open-webui/open-webui/pull/17061#issuecomment-3249144572
Author
Owner

@98h398hrpohpoai commented on GitHub (Sep 9, 2025):

This quick fix worked for me (I'm dumb, don't assume this won't break other stuff--I have no idea):
Remove the leading slash from the relative path of the join statement outlined below.

url=urljoin(
    request.app.state.config.TTS_OPENAI_API_BASE_URL,
    "/audio/speech",

to

url=urljoin(
    request.app.state.config.TTS_OPENAI_API_BASE_URL,
    "audio/speech",

In line 342 of open_webui/routers/audio.py

Also ensure the base tts URL ends with a slash (because we can't use a leading slash in the join function) e.g. https://tts.localhost/v1/

This is the LLM-provided guidance.

Base:
https://tts.localhost/v1
Relative path:
"/audio/speech"
Since the second argument starts with a leading slash (/audio/speech), urljoin discards everything after the “network location” (https://tts.localhost) and replaces it with /audio/speech.

That’s why /v1 disappears.
<!-- gh-comment-id:3272602761 --> @98h398hrpohpoai commented on GitHub (Sep 9, 2025): This quick fix worked for me (I'm dumb, don't assume this won't break other stuff--I have no idea): Remove the leading slash from the relative path of the join statement outlined below. ``` url=urljoin( request.app.state.config.TTS_OPENAI_API_BASE_URL, "/audio/speech", ``` to ``` url=urljoin( request.app.state.config.TTS_OPENAI_API_BASE_URL, "audio/speech", ``` In line 342 of open_webui/routers/audio.py --- Also ensure the base tts URL ends with a slash (because we can't use a leading slash in the join function) e.g. https://tts.localhost/v1/ This is the LLM-provided guidance. ``` Base: https://tts.localhost/v1 Relative path: "/audio/speech" Since the second argument starts with a leading slash (/audio/speech), urljoin discards everything after the “network location” (https://tts.localhost) and replaces it with /audio/speech. That’s why /v1 disappears. ```
Author
Owner

@tjbck commented on GitHub (Sep 10, 2025):

Reverted with 8339f59cdf

<!-- gh-comment-id:3274233009 --> @tjbck commented on GitHub (Sep 10, 2025): Reverted with 8339f59cdfc63f2d58c8e26933d1bf1438479d75
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#72842