Files
Athena-Deck/docs/maintenance/tts-e2e-2026-10-26

TTS path investigation — 26 October 2026

Confirmed failure, independently of the Mac client

A KIT/LiteLLM reply completed normally and its complete 2,212-character text was present in the owning Hermes session. The requesting profile correctly inherited the managed Athena STT/TTS routes. Hermes' actual installed SentenceChunker and speech normalizer retained the reply as 21 nonempty speech fragments.

The original first Qwen request completed with 3.44 seconds of audio. The next request began producing PCM in about 0.60 seconds but was cancelled after 38.6 seconds. Cancellation alone did not identify the original cause.

A controlled replay from the NAS, using the real installed Hermes OpenAIStreamer and existing scoped credentials, reproduced the second-fragment failure without a Mac or a new LLM call. A 92-character fragment kept producing near-silent PCM: 73.04 seconds had arrived when the test's own 75-second limit closed its request. Five-second windows after the opening had signed-16 RMS around 2–15, rather than useful speech. Local STT of a short opening crop recognized only the introductory two words; the complete long, mostly silent recording was rejected as silence. This is not evidence of a network buffer dropping the remainder of the written answer.

Native sampling comparison

The deployed qwen_native_worker.py explicitly forced do_sample=False for both quantizations. The pinned native CPU binding 0.4.2 / ABI 5 defaults to do_sample=True, temperature 0.9, top-k 50, top-p 1.0 and repetition penalty 1.05.

An isolated CPU process reused the existing Q4 talker, Q8 codec and Anna reference without changing or unloading production workers. It had a four-GiB memory cap, two-CPU quota, low priority, no GPU and a four-minute lifetime. The comparative runs used the same 256-token limit; an own-test-only five-second near-silence guard stopped bad output. These resource-limited timings are not production throughput benchmarks.

Native setting Seed Audio duration Outcome
Greedy 42 6.16 s before guard Introductory words, then silence
Binding-default sampling 42 5.84 s All clause content recognized by local STT
Binding-default sampling 43 6.80 s All clause content recognized by local STT
Sampling, separate German technical control 42 5.04 s Complete; units and product names recognized
Sampling, following sentence 42 3.36 s Complete

Foreign product names/acronyms in the sampled original were imperfectly recognized by STT. This comparison establishes removal of the reproduced silence collapse; it does not prove exact pronunciation or universal freedom from synthesis errors.

A subsequent full test executed the actual candidate worker, not a substitute generator, and fed it all 21 Hermes-normalized fragments. All 21 completed, producing 148.80 seconds of audio. Native synthesis took 333.55 seconds under the deliberate two-CPU/low-priority diagnostic limit; this is not a real-time result for the production CPU policy. The transient process exited and its unit was independently confirmed inactive. Per-fragment results, summary, sampling comparison.

The combined recording was transcribed by the existing local Parakeet service, in two groups at existing fragment boundaries (87.92 and 60.88 seconds, below its 120-second upload limit). The 2,074-character transcript reached the final sentence. This verifies continuation through the whole synthesized reply, not verbatim identity: technical-name recognition/pronunciation and the sanitizer loss described below remain separate limitations. The first attempt to send the entire recording was cleanly rejected with HTTP 400 for the 120-second limit; no STT settings were changed to accommodate a diagnostic file.

Separate upstream text-loss finding

The installed Hermes normalizer deletes natural compounds such as 15-min-Takt and 24-Stunden-Betrieb: its dense-identifier heuristic treats a digit plus two hyphens as a machine identifier. The failure is reproducible with public, synthetic single-sentence inputs, before any TTS request. In the quoted reply, this explains the missing frequency phrase in the full candidate transcription. The native Q4 correction cannot recover text that was already deleted upstream.

This logic is part of upstream commit 9b761903b9, mirrored in the Python gateway and desktop TypeScript normalizers. The examined local source files are clean relative to their tracked Git versions. No published correction for these false positives was verified. No Hermes source, Mac source, skill or personality prompt was patched to hide this finding.

There is also an intentional mode difference in the inspected desktop source: explicit read-aloud sanitizes completed text on the client (including summarizing Markdown tables by their headers), whereas live conversation feeds raw deltas to the gateway's sentence normalizer. Neither behavior explains the reproduced second-fragment silent collapse, but a post-activation client test must identify which mode it exercises rather than treating them as interchangeable.

Scoped correction and deployment

Only the native Q4 worker switches to the pinned binding's normal sampling. Seed 42 remains fixed. The previously qualified, inactive Q8 route stays greedy; its checkpoint-specific onset profile is unchanged. No model weights, voice, codec, CPU allocation, Hermes profile, endpoint, Mac app or KIT model changes.

The normal installer already includes qwen_native_worker.py; a native Debian installation receives the correction through the same source file, using the existing pinned CPU environment. Refresh only an idle owned TTS worker, or restart its owning service in an authorized idle window. Keep the configured state/model/voice paths and service user. No Docker-only dependency was added to the worker or native installation requirements.

For today's existing Docker deployment, a thin image on the exact verified current base was built with only this worker replaced: athena-deck-standalone:tts-q4-sampling-20261026. No base/runtime/weight download or consolidation is needed. The running root filesystem is read-only, so an attempted atomic hot replacement failed before any production write. Independent readback confirmed unchanged live/canonical worker hashes, installation image, container start time and resident worker. Do not weaken the read-only filesystem or write into Docker overlay storage to bypass this.

Activation therefore required an authorized, normally recreated Deck container at idle, followed by restoration of the previous chat profile. Michael explicitly approved this idle restart. The correction is now active in the running read-only container and canonical native source, with identical worker SHA-256 8da80b84310cc5e32ee73595ef8cc8a2fefef0cd9a8cc621d7b8a21af7432fc3. All admitted API requests were allowed to drain first. The previous flash-next-strata-iq3-dual profile was restored and answered a bounded eight-token restore probe (four output tokens); the cold restore took 56.85 seconds. Profile, endpoint, reasoning, audio-residency and CPU-policy files remained unchanged. The new container is healthy and still has a read-only root filesystem.

The earlier attempted build using a bare image ID also failed before activation; the successful thin build uses the existing local tag after verifying it resolves to the running image ID.

Actual unchanged Mac-client acceptance

The existing final answer was selected in the unchanged Hermes Mac 0.22.5 app and its real read-aloud button used. The normal remote-gateway path produced 21 successful TTS requests, zero cancellations and zero failures. Total audio was 123.52 seconds, generation time 115.50 seconds, and the request span including gaps was 120.11 seconds. This single run was slightly faster than real time; it is not a guarantee under concurrent load. First PCM per request ranged from 0.242 to 0.598 seconds. The app visibly entered Vorlesen stoppen and then returned to normal Vorlesen when the reply drained.

The shorter duration than the raw-fragment candidate follows the desktop's additional speech sanitization, including its intentional table-header summary. The explicit read-aloud test is not relabelled as a live-conversation trace. Michael then confirmed both complete audible read-aloud and working Live Talk with the KIT bot. A separate new live-turn trace was not captured, so the live conversation acceptance is the human confirmation rather than an independently counted second set of requests. Sanitized activation and acceptance.

The shared Hermes fleet audit passed again after activation: 280/280 checks, 13 profiles, zero failures. Neither Hermes nor a Mac app was restarted or patched. The transient candidate processes exited and were confirmed inactive.

Validation and remaining acceptance

  • Fifty existing targeted tests passed: native Qwen, Pocket protocol/routing, audio policy, German speech normalization and endpoint enhancer.
  • A broader run had one existing STT-fixture failure: test_audio_residency.test_stt_reuses_cpu_server_until_stop lacks the model fixture key now required by stt.start. Neither that test nor stt.py was changed. Do not report the broader 52-test run as passing.
  • Existing local STT successfully transcribed the control and comparison audio.
  • Actual Mac client and gateway both display 0.22.5. The Mac's installed speak-stream path accepts incremental text and schedules signed-16 PCM at the gateway's announced sample rate. No Mac files were edited.
  • A whole explicit read-aloud reply through the unchanged Mac app and its remote audio path passed after activation, separately from the isolated native test.
  • Human acceptance confirms audibility and Live Talk. Physical waveform capture, controlled microphone barge-in and stress testing were not performed. No claim that crackles or every possible conversation interruption is fixed.

Generated audio, the quoted private reply and raw diagnostic outputs stay in the task's own work/test folders, outside Git. No production transcript corpus, private prompt, key, voice reference, weight or VPN material is included here. Only Athena Deck was recreated after explicit approval at idle. No Hermes/VPN container or host was restarted.

Primary references

The behavior/signature comparison used the installed 0.4.2 binding and Hermes source, rather than assuming upstream main matches the deployed build.