Model reference · open weights

BlueMagpie-TTS

Audio OpenFormosa Text→speech 1 build Its own licence terms 705 dl/mo

BlueMagpie-TTS is an open-weight audio or speech model from OpenFormosa. BlueMagpie-TTS (BF16) weighs 7.8 GB; the smallest configuration that runs it is RTX 3060 12 GB.

For self-hosting, compare this build's requirements below with the GPU you plan to rent.

  • BlueMagpie-TTS is a text-to-speech model by OpenFormosa designed for Mandarin and mixed Mandarin/English speech synthesis.
  • It supports two generation modes, centroid-only and speaker-reference-audio-only, and is intended for research and evaluation.
  • The model uses an "other" license and requires reference audio or speaker centroids for voice cloning.

Summary of the OpenFormosa/BlueMagpie-TTS model card, 2026-11-24

What it is

Released byOpenFormosa
Released2026-06-22
VRAM7.8 GB for the weights

What it runs on

Memory and cards for BlueMagpie-TTS (BF16)

7.8 GBweights, file size
1.6 GBruntime overhead
CardOne streamMemory
RTX 3060 12 GBfits11.6 GB
RTX 4060 Ti 16 GBfits15.4 GB
RTX 3090 24 GBfits23.4 GB
RTX 4090 24 GBfits23.4 GB
RTX 5090 32 GBfits31.0 GB
L40S 48 GBfits44.0 GB
A100 80 GBfits78.2 GB
H100 80 GBfits78.1 GB
RTX PRO 6000 Blackwell 96 GBfits93.8 GB
DGX Spark (GB10) 128 GB unifiedfits107 GB
H200 141 GBfits138 GB
B200 180 GBfits176 GB

From the model card

What OpenFormosa says about BlueMagpie-TTS

Read the model card

BlueMagpie-TTS checkpoint for research and evaluation. The files in this Hub repository are the selected two-mode recovery release. Experimental branches are not promoted when they regress the production speaker-reference path.

This repository contains the inference artifact only: model weights, AudioVAE weights, tokenizer files, config, and usage documentation. It does not include optimizer state, scheduler state, training logs, private speaker registries, local configs, or training-data metadata.

Intended Use

  • Mandarin and mixed Mandarin/English text-to-speech evaluation.
  • Experiments with two mutually exclusive generation modes: centroid-only and speaker-reference-audio-only.
  • Do not redistribute the checkpoint or generated speech unless rights and consent are cleared for the intended use.

Install

git clone https://github.com/voidful/BlueMagpie-TTS
cd BlueMagpie-TTS
pip install -e ".[speaker]"
pip install soundfile

Quick Start

from huggingface_hub import snapshot_download
import soundfile as sf

from bluemagpie import BlueMagpieModel, speaker_embedding_from_wav

model_dir = snapshot_download("OpenFormosa/BlueMagpie-TTS")
model = BlueMagpieModel.from_local(model_dir, training=False, device="cuda")

reference_embedding = speaker_embedding_from_wav(
    "reference_speaker.wav", window_sec=3.0, hop_sec=1.5
)
audio = model.generate(
    target_text="這是 AI TTS code switching 測試。",
    speaker_centroid=reference_embedding,
    cfg_value=2.0,
    inference_timesteps=10,
    retry_badcase=False,
    stop_threshold=0.65,
    stop_consecutive=2,
)

sf.write("sample.wav", audio.detach().cpu().numpy(), model.sample_rate)

Interactive Demo Endpoint Profile

The hosted BlueMagpie-TTS Demo uses the same checkpoint weights with an inference-only endpoint guard. It starts with a 0.50 stop threshold, lowers the threshold only after 75% of the native-rate duration estimate, reaches 0.05 at 95%, and accepts one stop hit. Generation is still capped at the native-rate estimate plus one latent step. Playback pace is corrected only after generation has stopped, so pace control does not hold the model open and create extra speech.

This interactive policy is intentionally separate from the reproducible offline evaluation default of stop_threshold=0.65 and stop_consecutive=2. Neither policy uses retry selection or best-of-N reranking in its standard path.

Hosted Speaker B Embedding

The hosted Space keeps Speaker A as the default and loads its fixed Speaker B voice from checkpoints/speaker_b_embedding.pt. The artifact is a 192-dimensional, L2-normalized embedding extracted from the clean Speaker B reference set. Its payload uses the bluemagpie-speaker-embedding-v1 format and includes speaker_id="female_voice", generation_seed=56789, and the Space runtime profile speaker_projector_scale=1.125.

The deployed Space pins model revision 6f7cab914a1e27c56b504ec663c0144dc25cc0a3 and validates the embedding SHA-256 e9556e14723c140985a104c1659d1ff8a5078d2fa28ce2fb756f04906641a8a7 at startup. Each text chunk is generated exactly once with retry_badcase=False; the request path does not run ASR, speaker verification, candidate reranking, or output-validation retries.

import os
import torch

payload = torch.load(
    os.path.join(model_dir, "checkpoints", "speaker_b_embedding.pt"),
    map_location="cpu",
    weights_only=True,
)
speaker_b = torch.nn.functional.normalize(payload["embedding"].float(), dim=0)

audio = model.generate(
    target_text="今天的會議改到下午三點。",
    speaker_centroid=speaker_b,
    cfg_value=2.0,
    inference_timesteps=10,
    retry_badcase=False,
    stop_threshold=0.65,
    stop_consecutive=2,
)

generation_seed and speaker_projector_scale are metadata for the hosted Space's fixed Speaker B runtime profile; speaker_projector_scale is not a public generate() keyword argument.

Conditioning Modes

# centroid-only
audio = model.generate(
    target_text="今天的會議改到下午三點。",
    speaker_centroid=centroid_tensor,
    cfg_value=2.0,
    inference_timesteps=10,
    stop_threshold=0.65,
    stop_consecutive=2,
)

# speaker-reference-audio-only: extract once; no transcript required
reference_embedding = speaker_embedding_from_wav(
    "reference_speaker.wav", window_sec=3.0, hop_sec=1.5
)
audio = model.generate(
    target_text="今天的會議改到下午三點。",
    speaker_centroid=reference_embedding,
    cfg_value=2.0,
    inference_timesteps=10,
    stop_threshold=0.65,
    stop_consecutive=2,
)

Only use reference audio or speaker centroids from speakers you have permission to synthesize. Reference clips should be at least 3 seconds. The speaker-reference-audio-only mode uses one window-averaged speaker embedding for the full request and does not require a reference transcript. Raw reference tokens remain a separately evaluated research path.

Long Text

Use the CLI for long-form synthesis. It preserves punctuation, reuses one speaker embedding for every chunk, applies punctuation-aware pauses, and can set a minimum duration from the target speaking rate:

python scripts/generate_tts.py \
  --checkpoint /path/to/model-snapshot \
  --mode speaker-reference-audio-only \
  --speaker-reference-wav /path/to/rights-cleared-reference.wav \
  --reference-audio-conditioning speaker-embedding \
  --text-file long_text.txt \
  --chunk-chars 80 \
  --min-chunk-chars 12 \
  --target-chars-per-sec 4.0 \
  --stop-threshold 0.65 \
  --stop-consecutive 2 \
  --crossfade-ms 80 \
  --chunk-rms-match-db 4 \
  --chunk-edge-fade-ms 80 \
  --continuation-context-sec 0 \
  --no-retry-badcase \
  --out long.wav

Quality-First Short and Medium Text

The optional offline quality path generates multiple candidates and uses ASR plus speaker verification to select one. It is slower than ordinary generation and does not change the checkpoint weights:

python scr

Quoted from the model card on Hugging Face. The full card is behind the Hugging Face link above.

© 2026 AxForge · EU-hosted AI infrastructure Pricing Docs Trust Privacy Terms