Files
Trading_Studio/scripts/generate_voice_presets.sh
T
dekun eb71e28427 Add local GPU preset voices with dropdown selection.
Generate ChatTTS sample_random_speaker presets without cloud APIs; choose clone or preset in synthesize UI.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-12 17:28:17 +08:00

17 lines
591 B
Bash
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#!/usr/bin/env bash
# 生成本地 GPU 预设音色(ChatTTS 内置说话人,无需 API
# 用法: bash scripts/generate_voice_presets.sh
set -euo pipefail
ROOT="$(cd "$(dirname "$0")/.." && pwd)"
VENV_PY="${ROOT}/venv/bin/python"
if [[ ! -x "${VENV_PY}" ]]; then
echo "[ERROR] 未找到 venv,请先 bash deploy.sh deps"
exit 1
fi
echo "[INFO] 正在生成 ChatTTS 预设音色(本地 GPU..."
"${VENV_PY}" "${ROOT}/scripts/generate_voice_presets.py"
echo "[OK] 预设音色已写入 ${ROOT}/voices/presets/"
echo "[OK] 在 Web UI「配音合成」处可从下拉框选择"