diff --git a/melo-test/Dockerfile b/melo-test/Dockerfile index 3fd238f..42ee983 100644 --- a/melo-test/Dockerfile +++ b/melo-test/Dockerfile @@ -28,6 +28,10 @@ COPY requirements.txt . RUN pip install --upgrade pip setuptools wheel \ && pip install -r requirements.txt +# unidic 사전 데이터 (~250MB). MeloTTS 가 한국어만 써도 임포트 시점에 +# 일본어 MeCab Tagger 를 무조건 초기화하므로 생략 불가. +RUN python -m unidic download + COPY . . EXPOSE 7860 diff --git a/melo-test/README.md b/melo-test/README.md index 609ec73..10f249a 100644 --- a/melo-test/README.md +++ b/melo-test/README.md @@ -40,7 +40,13 @@ source .venv/bin/activate # Windows: .venv\Scripts\activate pip install --upgrade pip setuptools wheel pip install -r requirements.txt -# 3. 실행 +# 3. unidic 사전 데이터 다운로드 (~250MB, 한 번만) +# 한국어만 써도 MeloTTS 가 임포트 시점에 일본어 MeCab Tagger 를 +# 무조건 초기화하므로 이 단계가 필수입니다. 생략하면 서버 시작 시 +# "no such file or directory: ...\unidic\dicdir\mecabrc" 로 죽음. +python -m unidic download + +# 4. 실행 python server.py # 포트 변경: PORT=8000 python server.py ``` @@ -108,6 +114,10 @@ Content-Type: application/json 한국어 발음이 깨짐 → 입력에 영문/이모지가 섞이면 운율이 어색해질 수 있음. 디스코드 봇 통합 단계에서 `TTSClient.textReplace` 같은 사전 치환을 그대로 활용. +`RuntimeError: Failed initializing MeCab` / `no such file or directory: ...\unidic\dicdir\mecabrc` +→ `unidic` 사전 데이터 미다운로드. 가상환경 활성화 상태에서 `python -m unidic download` 실행 후 재시작. + 한국어만 써도 MeloTTS 가 임포트 시점에 일본어 모듈을 강제 로딩하기 때문에 이 단계는 필수. + ## 디스코드 봇 연동 (테스트 성공 후) MeloTTS 서버를 LAN(예: 시그니처 서버 옆)에 띄우고,