mcp-tts-server

by kaichen

1 stars
308 downloads
Not rated
GitHub

Description

# mcp-tts-server This project provides a Text-to-Speech (TTS) server based on the Model Context Protocol (MCP), utilizing the Groq API for speech generation. ## Features - Implements an MCP server for TTS functionality. - Connects to the Groq API…

About

# mcp-tts-server This project provides a Text-to-Speech (TTS) server based on the Model Context Protocol (MCP), utilizing the Groq API for speech generation. ## Features - Implements an MCP server for TTS functionality. - Connects to the Groq API (`https://api.groq.com/openai/v1/audio/speech`) for generating lifelike…

Details

Author
kaichen
GitHub stars
1
Downloads
308
Categories
Other

- Implements an MCP server for TTS functionality.
- Connects to the Groq API for speech generation.
- Provides a generate_speech tool via MCP.
- Supports multiple audio formats: wav, mp3, aac, opus, flac.
- Optional local playback using @tropicbliss/symphonia.
- Requires a Groq API key set as GROQ_API_KEY.

Install dependencies with bun install, then add the server to your MCP client configuration as a stdio transport. Provide your Groq API key via the GROQ_API_KEY environment variable. The server exposes a generate_speech tool that can be invoked through the MCP protocol.

mcp-tts-server

This project provides a Text-to-Speech (TTS) server based on the Model Context Protocol (MCP), utilizing the Groq API for speech generation.

Features

- Implements an MCP server for TTS functionality.
- Connects to the Groq API (https://api.groq.com/openai/v1/audio/speech) for generating lifelike audio from text.
- Provides a generate_speech tool accessible via the MCP protocol.
- Supports multiple audio output formats (wav, mp3, aac, opus, flac).
- Uses @tropicbliss/symphonia to play the generated audio directly on the server machine (optional).
- Requires a Groq API key set as an environment variable (GROQ_API_KEY).

Installation

To install dependencies:

bun install

Running the Server on MCP Client

To run the server using the stdio transport:

{
  "mcpServers": {
    "mcp-tts-server": {
      "command": "bunx",
      "args": [
        "--bun",
        "mcp-tts-server",
      ],
      "env": {
        "GROQ_API_KEY": "gsk_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
      }
    }
  }
}

Project Structure

- src/server.ts: Defines the core MCP server logic, including the generate_speech tool and interaction with the Groq API.
- src/cli.ts: Provides a command-line interface to run the MCP server over stdio.

This project was created using bun init in bun v1.2.7. Bun is a fast all-in-one JavaScript runtime.

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.