🔊 Instalação do Piper TTS no Windows — Guia Passo a Passo
-
️ O que é o Piper TTS?Piper é um motor de texto-para-fala (TTS) rápido, neural e totalmente local — não envia seus dados para a nuvem. Ele usa o espeak-ng para fonemização e roda em qualquer lugar: Windows, Linux e macOS.
Suporta +40 idiomas, incluindo Português do Brasil (pt_BR), com vozes de alta qualidade.
Instalação no Windows1️⃣ Instalar Python 3.9+
Baixe o Python mais recente em python.org/downloads.
️ Importante: Durante a instalação, marque a opção "Add Python to PATH".
2️⃣ Instalar o Piper
Abra o Command Prompt ou PowerShell e execute:
pip install piper-tts
3️⃣ Baixar uma voz
python -m piper.download_voicesIsso lista todas as vozes disponíveis. Para baixar uma voz específica (ex: português brasileiro):
python -m piper.download_voices pt_BR-edresson-mediumOutras vozes disponíveis:
Idioma Comando
Português (BR)pt_BR-edresson-medium
Inglês (US)en_US-lessac-medium
Inglês (UK)en_GB-alan-medium
Espanholes_ES-sharvard-medium
Francêsfr_FR-siwis-medium
Alemãode_DE-eva-medium-x
4️⃣ Testar a Voz
python -m piper -m pt_BR-edresson-medium -f teste.wav -- "Olá! Esta é uma mensagem de teste do Piper TTS."Para ouvir diretamente pelos alto-falantes (precisa do ffplay

python -m piper -m pt_BR-edresson-medium -- "Olá, mundo!"
5️⃣ Usar a API Python
import wave from piper import PiperVoice, SynthesisConfig # Carregar a voz voice = PiperVoice.load("caminho/para/pt_BR-edresson-medium.onnx") # Sintetizar with wave.open("saida.wav", "wb") as wav_file: voice.synthesize_wav("Bem-vindo ao Piper TTS!", wav_file) # Com configurações personalizadas syn_config = SynthesisConfig( volume=1.0, length_scale=1.2, # mais lento noise_scale=0.8, # menos variação normalize_audio=True ) with wave.open("saida_lenta.wav", "wb") as w: voice.synthesize_wav("Falando mais devagar...", w, syn_config=syn_config)
6️⃣ Aceleração com GPU (opcional)
Se tiver uma placa NVIDIA com CUDA:
pip install onnxruntime-gpuE no código Python:
voice = PiperVoice.load("voz.onnx", use_cuda=True)
Dicas Finais- Vozes completas em: huggingface.co/rhasspy/piper-voices
- Amostras de áudio: rhasspy.github.io/piper-samples
- Servidor Web:
python -m piper.http_server— para uso repetido sem recarregar o modelo - Código fonte: github.com/OHF-Voice/piper1-gpl
Dúvidas? Pergunte aqui mesmo na comunidade!

-
R Rodrigo Serpa moved this topic from Getting Started on
-
R Rodrigo Serpa moved this topic from Copy & Paste on
-
R Rodrigo Serpa moved this topic from Getting Started on
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login