Skip to main content

VoiceHub: A Unified Inference Interface for TTS Models

Project description

VoiceHub: A Unified Inference Interface for TTS Models

teaser

🛠️ Installation

uv venv --python 3.12
source .venv/bin/activate
uv pip install voicehub

📚 Usage

VoiceHub provides a simple, unified interface for working with various Text-to-Speech (TTS) models. Below are examples showing how to use different supported TTS models with the same consistent approach.

OrpheusTTS Model

from voicehub.automodel import AutoInferenceModel

model = AutoInferenceModel.from_pretrained(
    model_type="orpheustts",  # or "dia" or "vui"
    model_path="canopylabs/orpheus-3b-0.1-ft",
    device="cuda",
)

output = model("Hello, how are you today?", voice="tara", output_file="output.wav")

DiaTTS Model

from voicehub.automodel import AutoInferenceModel

model = AutoInferenceModel.from_pretrained(
    model_type="dia",  # or "dia" or "vui"
    model_path="dia/dia-100m-base.pt",
    device="cuda",
)

output = model(
    text="Hey, here is some random stuff, the text the less likely the model can cope!",
    output_file="output.wav",
)

VuiTTS Model

from voicehub.automodel import AutoInferenceModel

model = AutoInferenceModel.from_pretrained(
    model_type="vui",  # or "dia" or "vui"
    model_path="vui-100m-base.pt",
    device="cuda",
)

output = model(
    text="Hey, here is some random stuff, the text the less likely the model can cope!",
    output_file="output.wav",
)

🤗 Contributing

uv pip install pre-commit
pre-commit install
pre-commit run --all-files

📝 Acknowledgments

Project details


Download files

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

Source Distribution

voicehub-0.1.6.tar.gz (54.1 kB view details)

Uploaded Source

File details

Details for the file voicehub-0.1.6.tar.gz.

File metadata

  • Download URL: voicehub-0.1.6.tar.gz
  • Upload date:
  • Size: 54.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.16

File hashes

Hashes for voicehub-0.1.6.tar.gz
Algorithm Hash digest
SHA256 06708a817cec5bb09fefb59ef02aac7cfe7286576eac9183f6535e5093608687
MD5 ddd5980a18144aae51a1aa07847e36e1
BLAKE2b-256 fc55fcb78e0f8d0168b0bed2f3950a5274d3d5470c8a7e2af2d4838b34262252

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page