Skip to main content
Glama

Piper TTS MCP Server

🎤 Piper TTS MCP Server

A Model Context Protocol (MCP) server that integrates Piper TTS for high-quality text-to-speech functionality. This server provides a speak tool that converts text to speech and plays it directly through your speakers with customizable volume control.

✨ Features

  • 🔊 High-quality text-to-speech using Piper TTS
  • 🎚️ Volume control (0.01 to 1.00)
  • Memory-based audio playback (no temporary files)
  • 🔧 Customizable voice parameters (speaker, speed, voice variation)
  • 🚀 Fast and lightweight MCP integration
  • 🔇 Silent operation (no console output)

📋 Requirements

⚠️ Important Prerequisites:

  • Python 3.12+ installed on your system
  • Piper TTS service running on localhost:5000

You can set this up using the included Docker configuration or by running Piper TTS separately.

🚀 Quick Start

1. 🐳 Start Piper TTS Service

Clone this repo and start the TTS service:

git clone https://github.com/CryptoDappDev/piper-tts-mcp.git cd piper-tts-mcp

Option A: Using Docker Compose (Recommended)

docker compose up -d

Option B: Using Docker Build

docker build -t piper-tts-mcp . docker run -p 5000:5000 piper-tts-mcp

2. 🔧 Configure MCP Client

Add the server to your MCP configuration (e.g., .mcp.json for Claude Desktop):

{ "mcpServers": { "speak": { "command": "uv", "args": [ "--directory", "/path/to/your/piper-tts-mcp", "run", "server.py" ] } } }

3. 🎉 Enjoy!

The speak tool is now available in your MCP client!

🛠️ Usage

The MCP server provides a speak tool with the following parameters:

ParameterTypeDefaultDescription
textstringrequiredText to convert to speech
speaker_idint0Voice speaker ID
length_scalefloat1.1Speech speed (lower = faster)
noise_scalefloat0.667Voice variation control
noise_w_scalefloat0.333Pronunciation variation
volumefloat0.15Volume level (0.01 to 1.00)

Example Usage

# Basic usage speak("Hello, world!") # With custom volume speak("This is louder!", volume=0.5) # With custom voice settings speak("Fast and varied speech", length_scale=0.8, volume=0.3, noise_scale=0.8)

🔧 Development

Dependencies

  • Python 3.12+
  • mcp[cli] - MCP framework
  • requests - HTTP client for TTS API
  • pygame - Audio playback

Local Development

# Install dependencies uv sync # Run the server uv run server.py

📦 Docker Configuration

The included Docker setup provides:

  • Piper TTS service on port 5000
  • Pre-configured voice models
  • Automatic startup

🎙️ Voice Models

The default voice model used in this repository is en_GB-cori-high (British English, female voice).

🔍 Exploring Voice Options

🛠️ Changing Voice Models

To use a different voice model:

  1. Choose a voice from the voice samples page
  2. Update the Dockerfile - Replace en_GB-cori-high with your chosen voice model:
    # Download your preferred voice model RUN python3 -m piper.download_voices your-chosen-voice-model # Update the server command CMD ["sh", "-c", "python3 -m piper.http_server -m your-chosen-voice-model"]
  3. Rebuild the Docker image:
    docker build -t piper-tts-mcp . docker compose up -d

🎨 Creating Custom Voices

Creating your own custom voice requires additional effort and research. Please refer to the Piper documentation for guidance on voice training and customization.

🤝 Contributing

Contributions are welcome! Please feel free to submit issues and pull requests.

📄 License

This project is open source and available under the MIT License.

🙏 Acknowledgments


Made with ❤️ for the MCP community

Install Server
A
security – no known vulnerabilities
F
license - not found
A
quality - confirmed to work

Tools

Integrates Piper TTS into the Model Context Protocol, allowing AI assistants to convert text to speech and play it through speakers with customizable voice settings and volume control.

  1. ✨ Features
    1. 📋 Requirements
      1. 🚀 Quick Start
        1. 1. 🐳 Start Piper TTS Service
        2. 2. 🔧 Configure MCP Client
        3. 3. 🎉 Enjoy!
      2. 🛠️ Usage
        1. Example Usage
      3. 🔧 Development
        1. Dependencies
        2. Local Development
      4. 📦 Docker Configuration
        1. 🎙️ Voice Models
          1. 🔍 Exploring Voice Options
          2. 🛠️ Changing Voice Models
          3. 🎨 Creating Custom Voices
        2. 🤝 Contributing
          1. 📄 License
            1. 🙏 Acknowledgments

              Related MCP Servers

              • -
                security
                F
                license
                -
                quality
                Provides text-to-speech capabilities through the Model Context Protocol, allowing applications to easily integrate speech synthesis with customizable voices, adjustable speech speed, and cross-platform audio playback support.
                Last updated -
                7
                Python
              • A
                security
                A
                license
                A
                quality
                Provides an interface between AI assistants and Tripo AI via Model Context Protocol, enabling generation of 3D assets from natural language and importing them to Blender.
                Last updated -
                16
                171
                Python
                MIT License
                • Linux
                • Apple
              • A
                security
                F
                license
                A
                quality
                A Model Context Protocol server that enables AI assistants to utilize AivisSpeech Engine's high-quality voice synthesis capabilities through a standardized API interface.
                Last updated -
                1
                TypeScript
              • -
                security
                F
                license
                -
                quality
                Enables seamless integration with Typecast API through the Model Context Protocol, allowing clients to manage voices, convert text to speech, and play audio in a standardized way.
                Last updated -
                2
                Python

              View all related MCP servers

              MCP directory API

              We provide all the information about MCP servers via our MCP API.

              curl -X GET 'https://glama.ai/api/mcp/v1/servers/CryptoDappDev/piper-tts-mcp'

              If you have feedback or need assistance with the MCP directory API, please join our Discord server