<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[🐧 Installing Piper TTS on Linux — Step-by-Step Guide]]></title><description><![CDATA[<h2><img src="https://community.tacflow.ai/assets/plugins/nodebb-plugin-emoji/emoji/android/1f5e3.png?v=22224b5b6ea" class="not-responsive emoji emoji-android emoji--speaking_head_in_silhouette" style="height:23px;width:auto;vertical-align:middle" title="🗣" alt="🗣" />️ What is Piper TTS?</h2>
<p dir="auto"><strong>Piper</strong> is a fast, neural text-to-speech engine that runs <strong>100% offline</strong> and locally. It uses <a href="https://github.com/espeak-ng/espeak-ng" rel="nofollow ugc">espeak-ng</a> for phonemization and works on any Linux distribution.</p>
<p dir="auto">It supports <strong>40+ languages</strong>, including <strong>Brazilian Portuguese (pt_BR)</strong>, with high-quality voices.</p>
<hr />
<h2><img src="https://community.tacflow.ai/assets/plugins/nodebb-plugin-emoji/emoji/android/1f4e5.png?v=22224b5b6ea" class="not-responsive emoji emoji-android emoji--inbox_tray" style="height:23px;width:auto;vertical-align:middle" title="📥" alt="📥" /> Installing on Linux</h2>
<h3>1️⃣ Install Python 3.9+ and pip</h3>
<p dir="auto"><strong>Debian / Ubuntu / Linux Mint:</strong></p>
<pre><code class="language-bash">sudo apt update
sudo apt install python3 python3-pip python3-venv -y
</code></pre>
<p dir="auto"><strong>Fedora / RHEL / CentOS:</strong></p>
<pre><code class="language-bash">sudo dnf install python3 python3-pip
</code></pre>
<p dir="auto"><strong>Arch Linux / Manjaro:</strong></p>
<pre><code class="language-bash">sudo pacman -S python python-pip
</code></pre>
<p dir="auto"><strong>openSUSE:</strong></p>
<pre><code class="language-bash">sudo zypper install python3 python3-pip
</code></pre>
<hr />
<h3>2️⃣ Install Piper</h3>
<pre><code class="language-bash">pip install piper-tts
</code></pre>
<blockquote>
<p dir="auto"><img src="https://community.tacflow.ai/assets/plugins/nodebb-plugin-emoji/emoji/android/1f4a1.png?v=22224b5b6ea" class="not-responsive emoji emoji-android emoji--bulb" style="height:23px;width:auto;vertical-align:middle" title="💡" alt="💡" /> <strong>Recommendation:</strong> Use a virtual environment to avoid conflicts:</p>
<pre><code class="language-bash">python3 -m venv piper-env
source piper-env/bin/activate
pip install piper-tts
</code></pre>
</blockquote>
<hr />
<h3>3️⃣ Download a Voice</h3>
<pre><code class="language-bash">python3 -m piper.download_voices
</code></pre>
<p dir="auto">To download a specific voice:</p>
<pre><code class="language-bash"># Brazilian Portuguese
python3 -m piper.download_voices pt_BR-edresson-medium

# American English
python3 -m piper.download_voices en_US-lessac-medium
</code></pre>
<p dir="auto">Voices are available at <a href="https://huggingface.co/rhasspy/piper-voices" rel="nofollow ugc">huggingface.co/rhasspy/piper-voices</a>.</p>
<hr />
<h3>4️⃣ Test the Voice</h3>
<pre><code class="language-bash">python3 -m piper -m pt_BR-edresson-medium -f test.wav -- "Hello! This is a test message from Piper TTS on Linux."
</code></pre>
<p dir="auto">To hear it directly (requires ffplay):</p>
<pre><code class="language-bash"># Install ffplay
sudo apt install ffmpeg   # Debian/Ubuntu
sudo dnf install ffmpeg   # Fedora

# Test
python3 -m piper -m pt_BR-edresson-medium -- "Hello, world!"
</code></pre>
<hr />
<h3>5️⃣ Using the Python API</h3>
<pre><code class="language-python">import wave
from piper import PiperVoice, SynthesisConfig

voice = PiperVoice.load("pt_BR-edresson-medium.onnx")

with wave.open("output.wav", "wb") as wav_file:
    voice.synthesize_wav("Welcome to Piper TTS on Linux!", wav_file)

syn_config = SynthesisConfig(
    volume=1.0,
    length_scale=1.1,
    noise_scale=0.9,
    normalize_audio=True
)
with wave.open("adjusted.wav", "wb") as w:
    voice.synthesize_wav("Custom phrase...", w, syn_config=syn_config)
</code></pre>
<hr />
<h3>6️⃣ HTTP Server (for continuous use)</h3>
<p dir="auto">To avoid reloading the model for each phrase, start the server:</p>
<pre><code class="language-bash">python3 -m piper.http_server
</code></pre>
<p dir="auto">Access at: <a href="http://localhost:5000" rel="nofollow ugc">http://localhost:5000</a></p>
<p dir="auto">Example with curl:</p>
<pre><code class="language-bash">curl -X POST http://localhost:5000/synthesize \
  -H "Content-Type: application/json" \
  -d '{"text": "Hello Piper server!", "voice": "pt_BR-edresson-medium"}' \
  --output audio.wav
</code></pre>
<hr />
<h3>7️⃣ GPU Acceleration (optional)</h3>
<p dir="auto">With an NVIDIA GPU:</p>
<pre><code class="language-bash">pip install onnxruntime-gpu

# In code
voice = PiperVoice.load("voice.onnx", use_cuda=True)
</code></pre>
<hr />
<h2><img src="https://community.tacflow.ai/assets/plugins/nodebb-plugin-emoji/emoji/android/1f3af.png?v=22224b5b6ea" class="not-responsive emoji emoji-android emoji--dart" style="height:23px;width:auto;vertical-align:middle" title="🎯" alt="🎯" /> Linux Tips</h2>
<ul>
<li><strong>Home Assistant Integration:</strong> Piper is the default TTS engine in Home Assistant OS</li>
<li><strong>Automation:</strong> Use piper in shell scripts for voice notifications</li>
<li><strong>Batch processing:</strong> <code>cat phrases.txt | python3 -m piper -m voice -f output.wav</code></li>
<li><strong>Native binaries</strong> (without Python): Download from <a href="https://github.com/rhasspy/piper/releases/tag/v1.2.0" rel="nofollow ugc">github.com/rhasspy/piper/releases</a> for amd64/arm64/armv7</li>
</ul>
<hr />
<p dir="auto"><strong>Useful links:</strong></p>
<ul>
<li><a href="https://rhasspy.github.io/piper-samples" rel="nofollow ugc">Voice samples</a></li>
<li><a href="https://github.com/OHF-Voice/piper1-gpl" rel="nofollow ugc">Source code</a></li>
<li><a href="https://github.com/OHF-Voice/piper1-gpl/blob/main/docs/API_PYTHON.md" rel="nofollow ugc">Python API docs</a></li>
</ul>
<p dir="auto">Questions? Ask here! <img src="https://community.tacflow.ai/assets/plugins/nodebb-plugin-emoji/emoji/android/1f680.png?v=22224b5b6ea" class="not-responsive emoji emoji-android emoji--rocket" style="height:23px;width:auto;vertical-align:middle" title="🚀" alt="🚀" /></p>
]]></description><link>https://community.tacflow.ai/topic/37/installing-piper-tts-on-linux-step-by-step-guide</link><generator>RSS for Node</generator><lastBuildDate>Sun, 26 Jul 2026 11:30:26 GMT</lastBuildDate><atom:link href="https://community.tacflow.ai/topic/37.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 24 Jun 2026 21:45:35 GMT</pubDate><ttl>60</ttl></channel></rss>