--- license: openrail language: - en - ko - es - pt - fr pipeline_tag: text-to-speech tags: - coreml - ios - macos - tts - supertonic - mlprogram library_name: coremltools --- # Supertonic-3 CoreML CoreML ML Program exports of **Supertonic 3** for macOS and iOS. ## Variants | Directory | Quantization | Total size | |---|---|---| | `models/coreml/` | fp32 (all 4 graphs) | ~197 MB | | `models/coreml_int8_both/` | fp32 `duration_predictor`+`text_encoder`, int8 `vector_estimator`+`vocoder` | ~111 MB | ## Layout ``` models/ coreml/ # fp32 reference duration_predictor_mlprogram.mlpackage text_encoder_mlprogram.mlpackage vector_estimator_mlprogram.mlpackage vocoder_mlprogram.mlpackage coreml_int8_both/ # production-recommended variant ... resources/ voice_styles/ # 10 voice JSONs (M1-M5, F1-F5) onnx/ tts.json unicode_indexer.json LICENSE README.md UPSTREAM.md ``` ## Pipeline The four graphs are wired the same as the upstream Supertonic-3 ONNX: `text_processor → duration_predictor → text_encoder → vector_estimator (denoising loop) → vocoder`. Use `resources/voice_styles/.json` to load `style_dp` (8x16) and `style_ttl` (50x256). `resources/onnx/tts.json` carries the model config (sample rate, base chunk size, chunk compress factor, latent dim) needed at runtime. `resources/onnx/unicode_indexer.json` holds the multilingual tokenization tables for the v3 Unicode processor. ## Quantization details - Method: `coremltools.optimize.coreml.linear_quantize_weights` - Mode: `linear_symmetric` - Bits: 8 - Granularity: `per_channel` - Weight threshold: 2048 - Applied to: `vector_estimator`, `vocoder` - Skipped: weights containing inf/-inf are passed through unquantized (small subset) Sizes after quantization: - `vector_estimator`: 127.3 MB → 65.3 MB - `vocoder`: 48.3 MB → 24.3 MB ## Acknowledgments - Original ONNX models, voice styles, and config: [Supertone/supertonic-3](https://huggingface.co/Supertone/supertonic-3) - CoreML conversion pipeline: adapted from [Nooder/supertonic-2-coreml](https://github.com/Nooder/supertonic-2-coreml) See `UPSTREAM.md` for full provenance.