diff options
| author | historia <historiavg@proton.me> | 2026-09-02 18:20:14 -0400 |
|---|---|---|
| committer | historia <historiavg@proton.me> | 2026-09-02 18:20:14 -0400 |
| commit | f14b80f6b42a0d0891718eb6284336b1694795cf (patch) | |
| tree | 124e470824aecef8033a2ca9b39c87b0b2b345ee /app/backends/sglomni | |
| parent | 717a3dc112519ae7cf39a212a4e3ec9e1ba17f28 (diff) | |
| download | tts-audiobook-generator-f14b80f6b42a0d0891718eb6284336b1694795cf.tar.gz | |
fix: ZONOS2 only generating 1024 tokens max
Diffstat (limited to 'app/backends/sglomni')
| -rw-r--r-- | app/backends/sglomni/catalog.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/app/backends/sglomni/catalog.py b/app/backends/sglomni/catalog.py index c89e865..5ff0c81 100644 --- a/app/backends/sglomni/catalog.py +++ b/app/backends/sglomni/catalog.py @@ -60,6 +60,16 @@ class ModelEntry: fp8_moe: bool = False fp8_min_compute_capability: Optional[Tuple[int, int]] = None bf16_config: Optional[str] = None + # max_new_tokens sent with every /v1/audio/speech request (None = send + # nothing and leave the server default in charge). Zonos2's AR engine + # defaults to 1024 audio frames (44100 Hz / 512 hop = 86.13 fps), which + # caps one request at ~12 s of speech and silently truncates longer + # text. 12288 frames (~143 s) covers a full 250-word CHUNK_SIZE + # sub-chunk (~8600 frames) and stays under the KV-pool admission check + # on every GPU that can host the model (all are >= 24 GB with + # >= 28083-token pools; the scheduler rejects prompt + max_new_tokens + # above it, and zonos2 requests are not auto-clamped). + max_new_tokens: Optional[int] = None # The Qwen3-TTS CustomVoice speaker table — the same built-in speakers the @@ -197,6 +207,7 @@ ENTRIES: Tuple[ModelEntry, ...] = ( fp8_moe=True, fp8_min_compute_capability=(8, 9), bf16_config="zonos2_bf16.yaml", + max_new_tokens=12288, ), ) |
