aboutsummaryrefslogtreecommitdiff
path: root/app/backends/sglomni
diff options
context:
space:
mode:
authorhistoria <historiavg@proton.me>2026-09-09 17:02:41 -0400
committerhistoria <historiavg@proton.me>2026-09-09 17:02:41 -0400
commit130dcd988e0554a6343c92fd45d808fd508789b3 (patch)
tree0162c1593eff0f9214f111f600f23efd624eb3c3 /app/backends/sglomni
parent71f2c85aa5ea2aa5fe5f31537f5979459e82fcdd (diff)
downloadtts-audiobook-generator-130dcd988e0554a6343c92fd45d808fd508789b3.tar.gz
fix: model-specific instructions support and set cfg-scale 4 for breeze automaticallyHEADmain
Diffstat (limited to 'app/backends/sglomni')
-rw-r--r--app/backends/sglomni/catalog.py16
1 files changed, 16 insertions, 0 deletions
diff --git a/app/backends/sglomni/catalog.py b/app/backends/sglomni/catalog.py
index 8bfb1fa..2452d82 100644
--- a/app/backends/sglomni/catalog.py
+++ b/app/backends/sglomni/catalog.py
@@ -52,6 +52,16 @@ class ModelEntry:
system_hint: Optional[str] = None # remediation when the binary is absent
speakers: Optional[Tuple[str, ...]] = None # preset voices (speaker)
supports_seed: bool = False # request-scoped seed accepted (Qwen3-TTS Base)
+ # Whether the model's serving pipeline consumes a separate
+ # "instructions" field alongside its normal voice conditioning
+ # (verified against the installed sglang_omni code, not assumed from
+ # the HTTP schema): Qwen3-TTS Base (clone + instruction conditioning
+ # in request_builders.py), Qwen3-TTS CustomVoice and VoiceDesign, and
+ # the MOSS v1.5 pair (reference + instruction in the user message).
+ # False would mean an instructions field is silently ignored (Higgs,
+ # Voxtral, fish, dots, ZONOS2 take none; fish's inline event tags
+ # belong in the text, not this field).
+ supports_instructions: bool = False
# NOTE(unverified upstream): only the two Base entries are known to
# accept a request-scoped seed (Voxtral rejects one outright); qwen's
# demo client does send seeds to the CustomVoice/VoiceDesign models,
@@ -161,6 +171,7 @@ ENTRIES: Tuple[ModelEntry, ...] = (
requires_reference=False,
extras=_QWEN_EXTRAS, system_dep="sox", system_hint=_SOX_HINT,
speakers=QWEN_CUSTOMVOICE_SPEAKERS,
+ supports_instructions=True,
notes="built-in speakers, lightest model",
),
ModelEntry(
@@ -172,6 +183,7 @@ ENTRIES: Tuple[ModelEntry, ...] = (
requires_reference=True,
extras=_QWEN_EXTRAS, system_dep="sox", system_hint=_SOX_HINT,
supports_seed=True,
+ supports_instructions=True,
notes="voice cloning from a reference clip",
),
ModelEntry(
@@ -183,6 +195,7 @@ ENTRIES: Tuple[ModelEntry, ...] = (
requires_reference=True,
extras=_QWEN_EXTRAS, system_dep="sox", system_hint=_SOX_HINT,
supports_seed=True,
+ supports_instructions=True,
notes="voice cloning, higher quality",
),
ModelEntry(
@@ -193,6 +206,7 @@ ENTRIES: Tuple[ModelEntry, ...] = (
capability=CAPABILITY_DESIGN,
requires_reference=False,
extras=_QWEN_EXTRAS, system_dep="sox", system_hint=_SOX_HINT,
+ supports_instructions=True,
notes="voice described by instructions",
),
ModelEntry(
@@ -229,6 +243,7 @@ ENTRIES: Tuple[ModelEntry, ...] = (
config="moss_tts.yaml",
capability=CAPABILITY_CLONE,
requires_reference=True,
+ supports_instructions=True,
notes="voice cloning from a reference clip",
),
ModelEntry(
@@ -238,6 +253,7 @@ ENTRIES: Tuple[ModelEntry, ...] = (
config="moss_tts_local.yaml",
capability=CAPABILITY_CLONE,
requires_reference=False,
+ supports_instructions=True,
notes="48 kHz, narration without a reference or cloning",
),
ModelEntry(