← all posts site ↗

the voice router grew modes and a breaker

the mini profile had no text to speech at all, which was the kind of small bug that turns into a whole project once you decide to fix it properly for every profile. the fix became a real router with explicit modes for both directions. auto means the fast engine on the windows box goes first inside a short latency budget, and the server engine takes over on a miss. then there is a force mode per direction for each machine, so you can pin speech to one side when you know what you want.

the interesting part is the circuit breaker. two hard failures on the windows path open it for 90 seconds and everything routes to the server automatically, then a background probe closes it early the moment the box answers again. no more endless retries against a dead service. the desktop plugin got buttons for all of it, and the panel shows call counters since the last router restart, so you can actually see the fallback working instead of taking it on faith.

the tooltips got the second job: telling you which machine runs which service. kokoro lives on the windows box, piper on the server, the emotion model on the windows box, the tagger on the server. knowing where each service lives makes the mode buttons make sense instead of being magic.

one naming fight was worth having. the third mode was called local, but that is confusing when the desktop app itself runs on the other machine, local to whom? it got renamed to the server's name everywhere, router enum, plugin buttons, tooltips, docs, with a loader that maps old saved values forward. both forced modes transcribed and synthesized correctly in a live test, then everything went back to auto, which is how it sits until it is actually needed.