Skip to main content
donglao-tts — angular horizontal singing crocodile logo

donglao-tts

Reference-voice text-to-speech with a simple Python API.

Research/pre-1.0 release. APIs may change between versions. Use reference voices only with the speaker's permission.

Recommended Python API

uv add donglao-tts

# Or with pip
python -m pip install donglao-tts
from donglao_tts import DongLaoTTS

tts = DongLaoTTS.from_pretrained("DongLao/DongLao-TTS")

waveform = tts.generate(
    "Xin chào mọi người, đây là Đông Lào TTS.",
    reference_audio="reference.wav",
    reference_text="Exact transcript of the speech in reference.wav.",
    output_path="output.wav",
)

print(tts.revision)
print(tts.sample_rate)
print(tuple(waveform.shape))

The first call downloads the model, tokenizer, and bundled MOSS codec. CUDA is selected when available; otherwise the model runs on CPU. Reuse the loaded tts object for subsequent calls.

For reproducible use, pin a tested model commit:

tts = DongLaoTTS.from_pretrained(
    "DongLao/DongLao-TTS",
    revision="6ba3003ccb8d938c2a725a4117084492909c9419",
    device="cuda",
)

Generation controls are available when needed:

waveform = tts.generate(
    "Text to synthesize.",
    reference_audio="reference.wav",
    reference_text="Exact reference transcript.",
    output_path="output.wav",  # optional
    max_frames=200,
    temperature=1.0,
    top_k=0,
)

The returned waveform is a CPU PyTorch tensor with shape [channels, samples].

Runtime requirements

  • Python >=3.10,<3.11
  • Linux x86-64
  • PyTorch and TorchAudio >=2.8.0,<3
  • CUDA-capable GPU recommended; CPU inference is supported

Reference audio

Use a clean, consented recording containing one speaker. reference_text must match the spoken content exactly. Avoid music, overlapping speakers, clipping, long silence, and heavy reverb.

Verify the installation

donglao-smoke-test-hub \
  --repo-id DongLao/DongLao-TTS \
  --device cpu

For an end-to-end test, also pass --ref-audio, --ref-text, --target-text, and --output.

Responsible use

Obtain consent before using a voice, disclose synthetic audio when appropriate, and protect reference recordings and transcripts. Do not use the package for impersonation, fraud, harassment, or bypassing voice authentication.

Links

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

donglao_tts-0.1.5.tar.gz (409.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

donglao_tts-0.1.5-py3-none-any.whl (76.3 kB view details)

Uploaded Python 3

File details

Details for the file donglao_tts-0.1.5.tar.gz.

File metadata

  • Download URL: donglao_tts-0.1.5.tar.gz
  • Upload date:
  • Size: 409.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for donglao_tts-0.1.5.tar.gz
Algorithm Hash digest
SHA256 e7bfa1ef49d034c98af6af6ea09783c29183c6750e1ad26d4217d64f14f11e63
MD5 3f2b3dab63e39fbd587571c9a8fd84b0
BLAKE2b-256 18860bfd1e9393b5a18a1a0a0f81fbc8937cd581910bd3ada34ee8cf4d1590fa

See more details on using hashes here.

Provenance

The following attestation bundles were made for donglao_tts-0.1.5.tar.gz:

Publisher: release.yml on DongLaoAI/donglao-tts

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file donglao_tts-0.1.5-py3-none-any.whl.

File metadata

  • Download URL: donglao_tts-0.1.5-py3-none-any.whl
  • Upload date:
  • Size: 76.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for donglao_tts-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 340bfd1d6eb424fd363ef4c5b35e9f5cf9bfbcdc6651a977e4f91547186030a0
MD5 61066d4b1b04dfe3a9079ffef9dbe2cf
BLAKE2b-256 ba3b7f4cd1ac602a214839bf5382b1190eaeca902b81b7612333b6faa63e2c4f

See more details on using hashes here.

Provenance

The following attestation bundles were made for donglao_tts-0.1.5-py3-none-any.whl:

Publisher: release.yml on DongLaoAI/donglao-tts

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.1.7

2 files

0.1.6

2 files

This release

0.1.5 This release

2 files

0.1.4

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page