[Feature] timestamps for TTS via a forced-aligner pooling (#4795)
Signed-off-by: wjinxu <1299461899@qq.com> Co-authored-by: xurui <xurui1@modelbest.onaliyun.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
28 files changed
+850
-627
No files matched your search
@@ -161,10 +161,12 @@ class OpenAICreateSpeechRequest(BaseModel):
|
||||
word_timestamps: bool = Field(
|
||||
default=False,
|
||||
description=(
|
||||
"When true, the server runs a shared forced aligner alongside the streamed "
|
||||
"audio and emits per-chunk word timestamps. Requires the server to be "
|
||||
"launched with --forced-aligner pointing at an aligner model. No effect "
|
||||
"when streaming is off."
|
||||
"When true, non-streaming responses carry per-word timestamps in the "
|
||||
"X-Word-Timestamps header (JSON list of {word, start_ms, end_ms}, "
|
||||
"ASCII-escaped; replaced by X-Word-Timestamps-Omitted past 4 KB). "
|
||||
"Requires the server to be launched with --forced-aligner (400 otherwise). "
|
||||
"Not supported with stream=true; for streaming use the WebSocket "
|
||||
"/v1/audio/speech/stream path."
|
||||
),
|
||||
)
|
||||
|
||||
|
||||
Reference in new issue
Block a user