fix(voice_worker): the v2 brain answers in the asker's language

v1's tts_engine default (English-only Piper) made the reply engine force
English, so Korean questions got English answers. The v2 brain speaks
through the worker's MeloTTS and chat answers are not spoken, so it runs
with tts_engine=melo; an output_language lock still wins.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
javis-bot
2026-11-12 09:16:34 +09:00
parent 9e75df266b
commit 9ff307d7fe
4 changed files with 35 additions and 3 deletions

View File

@@ -3,6 +3,7 @@ interface, so the worker logic is tested with a fake (voice_worker.spec.md, "His
from __future__ import annotations
import dataclasses
import sys
import threading
import time
@@ -121,7 +122,10 @@ class JarvisBrain:
from jarvis.config import load_settings
from jarvis.memory.db import Database
self.cfg = load_settings()
# v1's tts_engine names the v1 desktop voice (English-only Piper by default), which makes the
# engine lock replies to English. v2 speaks through the worker's TTS and chat answers are
# not spoken, so the brain answers in the asker's language (an OUTPUT_LANGUAGE lock still wins).
self.cfg = dataclasses.replace(load_settings(), tts_engine="melo")
self.db = Database(self.cfg.db_path, self.cfg.sqlite_vss_path)
self.language = language
self._memories: dict = {}