mirror of
https://github.com/jamiepine/voicebox.git
synced 2026-09-18 06:10:43 -07:00
fix(backend): bundle unidic-lite for misaki Japanese G2P (#514)
fugashi (pulled in by misaki[ja]) needs a MeCab dictionary at runtime. The `unidic` package that ships today contains no data — it relies on `python -m unidic download` (~526MB), which isn't run by `just setup` and won't survive PyInstaller freezing. Switch to `unidic-lite`, which bundles a MeCab-compatible dict inside the wheel (~50MB). Collect its data files in build_binary.py so frozen builds also pick up the dicdir. Same failure mode and same fix shape as the existing en_core_web_sm pre-install.
This commit is contained in:
@@ -287,6 +287,12 @@ def build_server(cuda=False):
|
||||
"en_core_web_sm",
|
||||
"--hidden-import",
|
||||
"en_core_web_sm",
|
||||
# unidic-lite ships the MeCab dictionary used by fugashi (pulled in
|
||||
# by misaki[ja]). The dict lives in unidic_lite/dicdir/ and is
|
||||
# discovered via the package's DICDIR constant, so the data files
|
||||
# must be collected or Japanese Kokoro voices crash at runtime.
|
||||
"--collect-all",
|
||||
"unidic_lite",
|
||||
"--hidden-import",
|
||||
"loguru",
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user