@bigcookie/mcp-audio-to-text
v1.3.0
Published
MCP Server for audio/video to text transcription using Google Gemini
Maintainers
Readme
MCP Audio to Text
一個用於語音轉文字的 MCP Server,使用 Google Gemini 進行轉錄。
功能特色
- 支援多種音頻/影片格式:
.mp3,.m4a,.wav,.mp4,.webm,.ogg,.flac等 - 自動處理大檔案分割(超過 20MB 或 3 分鐘)
- 中文自動轉為繁體中文
- 可選擇模型:
flash(較快)或pro(較準確)
系統需求
- Node.js 18+
- ffmpeg(系統層級安裝)
- Google API Key
安裝 ffmpeg
# Ubuntu/Debian
sudo apt install ffmpeg
# macOS
brew install ffmpeg
# Windows
# 下載 https://ffmpeg.org/download.html 並加到 PATH使用方式
Claude Desktop 設定
編輯設定檔:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"audio-to-text": {
"command": "npx",
"args": ["-y", "@bigcookie/mcp-audio-to-text"],
"env": {
"GOOGLE_API_KEY": "your-google-api-key"
}
}
}
}Claude CLI 設定
claude mcp add audio-to-text -e GOOGLE_API_KEY=your-api-key -- npx -y @bigcookie/mcp-audio-to-textMCP Tool
transcribe_audio
將音頻或影片檔案轉換為文字。
參數:
| 參數 | 類型 | 必填 | 說明 |
|------|------|------|------|
| file_path | string | 是 | 音頻或影片檔案的絕對路徑 |
| output_dir | string | 否 | 輸出目錄路徑(預設為檔案同目錄下的 {檔名}_transcription) |
| model | string | 否 | 使用的模型:flash(較快,預設)或 pro(較準確) |
環境變數
| 變數 | 說明 |
|------|------|
| GOOGLE_API_KEY | Google AI API Key(必要) |
License
MIT
