Skip to content

fix(supertonic): honor voice preset sent as a request option - #302

Merged
0xShug0 merged 1 commit into
0xShug0:mainfrom
drzsdrtfg:fix/supertonic-voice-option
Aug 24, 2026
Merged

fix(supertonic): honor voice preset sent as a request option#302
0xShug0 merged 1 commit into
0xShug0:mainfrom
drzsdrtfg:fix/supertonic-voice-option

Conversation

@drzsdrtfg

Copy link
Copy Markdown
Contributor

Summary

The WebUI voice picker for Supertonic 3 (defined in webui/configs/model_params.json) lets you choose one of 10 presets (M1–M5, F1–F5) and sends that choice as a plain request option (options.voice). However, SupertonicSession::generation_options_from_request only read the structured request.voice.speaker.cached_voice_id field and otherwise used the load-time default M1. The picker appeared to do nothing — output was always M1.

Fix

In src/models/supertonic/session.cpp, read the voice (or supertonic.voice) request option as a fallback when no structured cached_voice_id is present. The structured field keeps precedence; unknown ids are still rejected downstream by the voice-style loader (runtime.cpp -> require_file("voice_style_<id>.json")).

Verification workflow

WebUI → Supertonic 3 → voice = F1/M3/etc → synthesize → output now matches the selected preset. The UI already sends options.voice (requestOptions merges advancedValues), so no frontend change is required.

The WebUI supertonic voice picker (webui/configs/model_params.json) sends
the selected preset as a plain request option (options.voice), but
SupertonicSession::generation_options_from_request only read the
structured request.voice.speaker.cached_voice_id and otherwise fell back
to the load-time default M1, so the picker had no effect.

Read the 'voice' / 'supertonic.voice' option as a fallback. The
structured cached_voice_id still takes precedence; unknown ids are
rejected downstream by the voice-style loader.
@drzsdrtfg

Copy link
Copy Markdown
Contributor Author

Code and PR assisted and written by DeepSeekv4 flash and ox alpha through cline

@0xShug0
0xShug0 merged commit 4ec485d into 0xShug0:main Aug 24, 2026
6 checks passed
@0xShug0

0xShug0 commented Aug 24, 2026

Copy link
Copy Markdown
Owner

@drzsdrtfg Thank you for the fix! PR validated and merged.

@drzsdrtfg
drzsdrtfg deleted the fix/supertonic-voice-option branch August 24, 2026 23:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants