Spaces:
Build error
Build error
Commit History
-
Only serve the OpenAI-compatible endpoint with an API key
A server whose UI is protected some other way, such as a proxy that guards only Gradio's own endpoints, would have gained an open transcription endpoint just by updating. openai_api now defaults to null, which serves the endpoint only when an API key is set. true still serves it without a key, and false turns it off even with one.1929c74 -
Add an OpenAI-compatible transcription endpoint
app.py now also serves POST /v1/audio/transcriptions, so clients written for OpenAI or other Whisper servers can transcribe with this app. Gradio 3.38 is kept: launch() returns its FastAPI app, and the route is added to it before blocking. Every option of the Full tab can be sent as an extra form field named as in config.json5, which is how the OpenAI SDKs send extra_body. Options default to the config, except that audio is transcribed as sent (no VAD) and diarization is off. Requests run one at a time outside the UI's queue, delete their upload afterwards, and use their own diarization process, so a UI job can't stop it. The endpoint can require "Authorization: Bearer <key>", set with WHISPER_WEBUI_API_KEY, --api_key or api_key in config.json5, and can be disabled with --openai_api False.06a9401
-
Fix unit test
052fe7e
-
Support parallel execution of Silero VAD
c0e541b
-
Refactor pad and merge timestamps into one function
This also fixes a bunch of issues regarding when the timestamps should be merged.0cb931d
-
Fix unit test
25df8a0
-
Add a simple "VAD" alternative - periodic VAD
This is a very simple alternative to using Silero Vad, where every 5 minutes (0:00 - 5:00, 5:00 - 10:00, etc.) is marked as a "speech" segment, and whisper is then run on each segment individually. The upside is that all potential dialogue will be sent to Whisper for transcribing, but it is also more likely to get into an infinite sentence loop (although limited to each 5 minute segment). Creating an artifical break every 5 minutes may also break up a sentence accidentally, causing the sentence (or a word) to be incorrectly transcribed.bbbf06e