diff options
| author | soryu <soryu@soryu.co> | 2026-02-02 23:16:00 +0000 |
|---|---|---|
| committer | soryu <soryu@soryu.co> | 2026-02-02 23:16:00 +0000 |
| commit | 8361916ce67f3d2ba191ebf27cb50e79cb42e39c (patch) | |
| tree | 3a94ac3031aedf463fd8224e7c1f619b490840fe /makima/sh | |
| parent | 0f06a7f9968816e5e2553c4f1c2104f2fa504f96 (diff) | |
| download | soryu-8361916ce67f3d2ba191ebf27cb50e79cb42e39c.tar.gz soryu-8361916ce67f3d2ba191ebf27cb50e79cb42e39c.zip | |
Fix downloading too many models
Diffstat (limited to 'makima/sh')
| -rwxr-xr-x | makima/sh/download-models.sh | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/makima/sh/download-models.sh b/makima/sh/download-models.sh index b44e091..4f1bd77 100755 --- a/makima/sh/download-models.sh +++ b/makima/sh/download-models.sh @@ -131,9 +131,27 @@ download_chatterbox_tts() { echo "Downloading Chatterbox TTS models..." mkdir -p "$CHATTERBOX_MODEL_DIR" - # Download from ResembleAI/chatterbox-turbo-ONNX - echo "Downloading ResembleAI/chatterbox-turbo-ONNX..." - hf download ResembleAI/chatterbox-turbo-ONNX --local-dir "$CHATTERBOX_MODEL_DIR" + # Download only the required files from ResembleAI/chatterbox-turbo-ONNX + # (skip fp16, q4, q4f16, quantized variants to save ~4GB) + echo "Downloading ResembleAI/chatterbox-turbo-ONNX (standard precision only)..." + local tmpdir=$(mktemp -d) + hf download ResembleAI/chatterbox-turbo-ONNX \ + --include "onnx/speech_encoder.onnx" \ + --include "onnx/speech_encoder.onnx_data" \ + --include "onnx/embed_tokens.onnx" \ + --include "onnx/embed_tokens.onnx_data" \ + --include "onnx/language_model.onnx" \ + --include "onnx/language_model.onnx_data" \ + --include "onnx/conditional_decoder.onnx" \ + --include "onnx/conditional_decoder.onnx_data" \ + --include "tokenizer.json" \ + --local-dir "$tmpdir" + + # Move files to the model directory (flatten the onnx/ subdirectory) + mv "$tmpdir"/onnx/*.onnx "$CHATTERBOX_MODEL_DIR"/ + mv "$tmpdir"/onnx/*.onnx_data "$CHATTERBOX_MODEL_DIR"/ + mv "$tmpdir"/tokenizer.json "$CHATTERBOX_MODEL_DIR"/ + rm -rf "$tmpdir" echo "Chatterbox TTS models downloaded successfully" } |
