MCP Audio Transcriber

MIT License
  • Linux

Integrations

  • Enables containerized deployment of the transcription service, making it portable and providing a consistent runtime environment.

  • Provides audio file processing capabilities, allowing the transcription service to handle various audio formats like .wav, .mp3, .ogg, and .m4a.

  • Integrates with OpenAI's Whisper models to provide high-quality, multi-language audio transcription with options for different model sizes.

MCP 音频转录器

这是一种可移植的 Dockerized Python 工具,它使用 OpenAI 的 Whisper 模型实现了用于音频转录的模型上下文协议 (MCP) ,甚至附带由 Streamlit 支持的 Web UI,以便您可以上传音频文件并以 JSON 格式下载转录。

🚀 功能

  • 模块化 MCP 接口mcp.py )定义了标准的ModelContextProtocol
  • 基于 Whisper 的实现WhisperMCP )可实现高质量、多语言的转录。
  • 用于批量或临时转录的命令行界面app.py ):
    python app.py <input_audio> <output_json> [--model MODEL_NAME]
  • Docker 支持一致的运行时:
    docker build -t mcp-transcriber . docker run --rm \ -v /full/path/to/data:/data \ mcp-transcriber:latest \ /data/input.wav /data/output.json
  • Streamlit 网络应用程序streamlit_app.py )允许最终用户:
    • 上传任何常见的音频文件(.wav、.mp3、.ogg、.m4a)
    • 选择 Whisper 型号尺寸
    • 现场预览转录
    • 一键下载 JSON 结果

📦先决条件

  • Python 3.10+
  • ffmpeg 已安装并位于您的 PATH 上
  • (可选)Docker Engine / Docker Desktop
  • (可选)Streamlit

🔧 安装

  1. 克隆 repo
    git clone https://github.com/ShreyasTembhare/MCP---Audio-Transcriber.git cd MCP---Audio-Transcriber
  2. Python 依赖项和 FFmpeg
    pip install --upgrade pip pip install -r requirements.txt # On Ubuntu/Debian: sudo apt update && sudo apt install ffmpeg # On Windows: # Download a static build from https://ffmpeg.org and add its bin/ to your PATH
  3. (可选)Docker
    • 安装 Docker Desktop
    • 如果使用 WSL2,请启用 WSL 集成。
  4. (可选)Streamlit
    pip install streamlit

🎯 使用方法

1. CLI 转录

python app.py <input_audio> <output_json> [--model tiny|base|small|medium|large]
  • <input_audio> :音频文件的路径
  • <output_json> :JSON 结果的保存路径
  • --model :选择 Whisper 模型大小(默认值:base)

例子:

python app.py data/input.ogg data/output.json --model tiny cat data/output.json

2. Docker

构建图像:

docker build -t mcp-transcriber .

运行它(挂载你的数据/文件夹):

docker run --rm \ -v "/full/path/to/your/project/data:/data" \ mcp-transcriber:latest \ /data/input.wav /data/output.json

然后检查:

ls data/output.json cat data/output.json

3. Streamlit Web UI

启动应用程序:

streamlit run streamlit_app.py
  • 在浏览器中打开http://localhost:8501
  • 上传音频文件
  • 选择 Whisper 模型尺寸
  • 点击转录
  • 预览并下载生成的 JSON

📁 项目结构

MCP-Audio-Transcriber/ ├── app.py # CLI entrypoint ├── mcp.py # Model Context Protocol + WhisperMCP ├── requirements.txt # Python dependencies ├── streamlit_app.py # Streamlit interface ├── Dockerfile # Container definition ├── .gitignore # ignore **pycache**, venvs, etc. ├── LICENSE # MIT license └── data/ # sample input and output ├── input.ogg └── output.json
-
security - not tested
A
license - permissive license
-
quality - not tested

一种可移植的 Dockerized Python 工具,使用 Whisper 模型实现用于音频转录的模型上下文协议,具有 CLI 和 Web UI 界面,用于将音频文件转换为 JSON 转录。

  1. 🚀 功能
    1. 📦先决条件
      1. 🔧 安装
        1. 🎯 使用方法
          1. CLI 转录
          2. Docker
          3. Streamlit Web UI
        2. 📁 项目结构

          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 -
            2
            Python
          • -
            security
            A
            license
            -
            quality
            A Model Context Protocol server that allows AI assistants like Claude and Cursor to create music and control Sonic Pi programmatically through OSC messages.
            Last updated -
            JavaScript
            MIT License
          • A
            security
            A
            license
            A
            quality
            A MCP server that enables transcription of audio files using OpenAI's Speech-to-Text API, with support for multiple languages and file saving options.
            Last updated -
            1
            2
            JavaScript
            MIT License
            • Linux
            • Apple
          • A
            security
            A
            license
            A
            quality
            A Model Context Protocol server that enables AI models to generate and play high-quality text-to-speech audio through your device's native audio system using Rime's voice synthesis API.
            Last updated -
            1
            176
            4
            JavaScript
            The Unlicense
            • Apple
            • Linux

          View all related MCP servers

          ID: kts1za3i9v