Skip to content

speech: Drama 3's voices through speech_voices.zig, and sampling defaults through parseFrom - #4609

Merged
ashhart merged 3 commits into
ashhart:mainfrom
BobClawblaw:speech-route-neutral
Nov 23, 2026
Merged

ashhart merged 3 commits into
ashhart:mainfrom
BobClawblaw:speech-route-neutral

Conversation

@BobClawblaw

Copy link
Copy Markdown
Contributor

The speech-route extraction asked for on #3615, option (a): a voices holder and parseFrom, with Drama 3 as the only user.

What changes

  • server/speech_voices.zig (new): the server's voices load at startup (start) and list on /v1/voices (listing) through this one file. server.zig and routes.zig call it; the lines it holds are the ones server.zig had, unchanged.
  • server/speech_sampling.zig: parse becomes parseFrom(base, max_top_k), and parse calls it with Drama 3's defaults and its ceiling of 64, so the request fields, the defaults, and every message (top_k must be an integer from 1 through 64) are the same.
  • server/speech_sampling_test.zig: one test for parseFrom: a caller's defaults are kept for fields a request omits, and top_k past the ceiling is refused with that ceiling in the message.

No request field, plan field, family entry or Drama behaviour changes. ZONOS3's fields and family entry come with #3720, which I will rebase onto this once it lands.

Drama 3 A/B, served replies

The same requests to tensorfold-native serve built from main and from this branch, two server starts each, every speech request sent twice per start (8 replies per request; /v1/voices once per start, 4), compared by SHA-256:

Request Mac (M5 Ultra, Metal), main b112ad68c GB10 (CUDA, sm_121), main ab2c3b27a
whole WAV, seed 7 8 of 8 identical 8 of 8 identical
streamed PCM, seed 7 8 of 8 identical 8 of 8 identical
plain, no seed 8 of 8 identical 8 of 8 identical
sampled: temperature 0.8, top_p 0.9, top_k 30, seed 11 8 of 8 identical 8 of 8 identical
top_k 64, seed 3, PCM 8 of 8 identical 8 of 8 identical
top_k 65 (400) 8 of 8 identical 8 of 8 identical
top_k 0 (400) 8 of 8 identical 8 of 8 identical
GET /v1/voices 4 of 4 identical 4 of 4 identical

The GB10 run is of this commit before its rebase onto b112ad68c (the rebase was clean; main had changed server.zig, routes.zig and speech.zig elsewhere). Both refusals answer {"error": {"message": "top_k must be an integer from 1 through 64", "type": "invalid_request_error"}} on both builds. No server log names a leak or a panic.

Checks (Linux x86_64, on this branch at b112ad68c)

The no-GPU workflow's zig steps: test-host-a, test-host-b, test, test-golden, test-kernel-contract, test-gradient-serving test-qwen-serving-host test-glm-pdl-scan, test-server-security test-pull-security, fuzz-cortheon and check-release-paths pass; zig fmt --check is clean and the lean check reports 0 new. The macOS and Metal workflow jobs were not run locally.

ashhart and others added 3 commits November 23, 2026 15:43
…ults through parseFrom

The server's voices load at startup and list on /v1/voices through one file, speech_voices.zig, and
speech_sampling.parse becomes parseFrom with Drama 3's defaults and its top-k ceiling of 64. Drama 3 is the only
user: its defaults, ceiling, messages, behaviour and refusals are unchanged.
@ashhart
ashhart force-pushed the speech-route-neutral branch from 7a56a16 to 39c4b5d Compare November 23, 2026 15:43
@ashhart
ashhart merged commit b969d8d into ashhart:main Nov 23, 2026
@ashhart

ashhart commented Nov 23, 2026

Copy link
Copy Markdown
Owner

Thank you @BobClawblaw. This is merged into main with your commits under your own name, so you're listed as a TensorFold contributor. It ships in the next release, credited to you in the changelog and the release notes.

ashhart added a commit that referenced this pull request Nov 23, 2026
ashhart added a commit to garvrao80/TensorFold that referenced this pull request Nov 23, 2026
ashhart added a commit to timmyit/TensorFold that referenced this pull request Nov 23, 2026
ashhart added a commit that referenced this pull request Nov 23, 2026
ashhart added a commit to akol1/TensorFold that referenced this pull request Nov 23, 2026
ashhart added a commit that referenced this pull request Nov 23, 2026
BobClawblaw added a commit to BobClawblaw/TensorFold that referenced this pull request Nov 23, 2026
…eply options, reruns, the Drama 3 A/B, the shared code left

Main's reply options (24-bit and float WAV, FLAC, sample_rate, stereo) apply to ZONOS3's whole replies.
The port-side checks, the repo checks and the Drama 3 A/B were run again on main 281d81b; the reader
and WAV moves left the shared-code list with ashhart#3719, and the voices holder and parseFrom with ashhart#4609.
BobClawblaw added a commit to BobClawblaw/TensorFold that referenced this pull request Nov 24, 2026
…eply options, reruns, the Drama 3 A/B, the shared code left

Main's reply options (24-bit and float WAV, FLAC, sample_rate, stereo) apply to ZONOS3's whole replies.
The port-side checks, the repo checks and the Drama 3 A/B were run again on main 281d81b; the reader
and WAV moves left the shared-code list with ashhart#3719, and the voices holder and parseFrom with ashhart#4609.
ashhart pushed a commit to BobClawblaw/TensorFold that referenced this pull request Nov 24, 2026
…eply options, reruns, the Drama 3 A/B, the shared code left

Main's reply options (24-bit and float WAV, FLAC, sample_rate, stereo) apply to ZONOS3's whole replies.
The port-side checks, the repo checks and the Drama 3 A/B were run again on main 281d81b; the reader
and WAV moves left the shared-code list with ashhart#3719, and the voices holder and parseFrom with ashhart#4609.
ashhart pushed a commit to BobClawblaw/TensorFold that referenced this pull request Nov 24, 2026
…eply options, reruns, the Drama 3 A/B, the shared code left

Main's reply options (24-bit and float WAV, FLAC, sample_rate, stereo) apply to ZONOS3's whole replies.
The port-side checks, the repo checks and the Drama 3 A/B were run again on main 281d81b; the reader
and WAV moves left the shared-code list with ashhart#3719, and the voices holder and parseFrom with ashhart#4609.
ashhart pushed a commit that referenced this pull request Nov 25, 2026
…tions, reruns, the Drama 3 A/B, the shared code left

Main's reply options (24-bit and float WAV, FLAC, sample_rate, stereo) apply to ZONOS3's whole replies.
The port-side checks, the repo checks and the Drama 3 A/B were run again on main 281d81b; the reader
and WAV moves left the shared-code list with #3719, and the voices holder and parseFrom with #4609.
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