mcp-audio-server

mcp-audio-server

0

MCP Audio Server is designed to process audio files, offering features such as tempo detection, key detection, and chord analysis. It provides a RESTful API for easy integration and supports structured logging and metrics for observability.

MCP Audio Server

A Model Context Protocol (MCP) server for audio processing and chord analysis.

Features

  • Audio file decoding and normalization with FFmpeg
  • Music analysis capabilities:
    • Tempo detection (BPM)
    • Key detection
    • Chord analysis and tracking
  • RESTful API with structured responses
  • JSON schema validation for inputs and outputs
  • Robust error handling with descriptive messages
  • Resource management with concurrency controls
  • Caching for performance optimization
  • Observability with structured logging and metrics
  • Comprehensive test suite
  • Containerized deployment with Docker

Installation

Docker (Recommended)

Use Docker Compose for the quickest setup:

Manual Installation

  1. Prerequisites:

    • Python 3.10 or higher
    • FFmpeg
    • Poetry
  2. Install dependencies:

  3. Run the server:

API Documentation

The full OpenAPI specification is available at /docs when the server is running:

Endpoints

  • POST /analyze_chords: Analyze audio for chords, key, and tempo
  • GET /health: Health check endpoint
  • GET /ready: Readiness check for load balancers
  • GET /metrics: Prometheus metrics (redirects to metrics server)

License and Compliance

This project is licensed under the MIT License.