funasr-zh-tw-mcp
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@funasr-zh-tw-mcptranscribe the audio file /home/user/recordings/lecture.m4a"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
funasr-zh-tw-mcp
把阿里巴巴開源的 FunASR 中文語音辨識包成 MCP server、HTTP API 與 命令列工具,輸出**繁體中文(台灣用詞)**逐字稿。
全程在自己的電腦上運算,音檔不會上傳到任何雲端服務 —— 適合處理課堂錄音、會議記錄、訪談等不方便外傳的內容。
這個工具解決什麼問題
FunASR 的中文辨識品質很好,但預設輸出是簡體中文,而且只能寫 Python 腳本呼叫。這個專案做三件事:
自動轉繁體 —— 使用 OpenCC
s2twp設定,連台灣慣用詞一起轉(軟件→軟體、網絡→網路、信息→資訊)包成 MCP server —— 讓 Claude、Gemini CLI、Cursor 等 AI 助理可以直接呼叫
包成 HTTP API —— 讓自己的網頁工具或 ChatGPT 自訂 GPT 可以串接
Related MCP server: io.github.chicogong/ffvoice
支援哪些 AI 助理
平台 | 支援 | 說明 |
Claude Code | ✅ |
|
Claude Desktop | ✅ | 編輯設定檔即可 |
Gemini CLI | ✅ | 支援 MCP,設定方式類似 |
Cursor / Windsurf / Zed | ✅ | 都支援 MCP |
ChatGPT 桌面版 | ⚠️ | 開發者模式可掛 MCP,功能仍在演進中 |
ChatGPT 網頁版(自訂 GPT) | ⚠️ | 需先用 ngrok / cloudflared 把 HTTP API 公開到網際網路,ChatGPT 的伺服器連不到你的 localhost |
Gemini 網頁版 / Claude.ai 網頁版 | ❌ | 網頁版無法呼叫你本機的程式,這是瀏覽器沙箱的限制,不是設定問題 |
關於 Artifacts:Claude 的 Artifacts 有嚴格的 CSP 限制,禁止所有對外網路請求(包含 localhost),因此無法用 Artifact 呼叫本機的辨識服務。這是平台的安全設計,沒有繞過的方法。
安裝
1. 先裝 PyTorch
FunASR 需要 PyTorch,但它不會自動幫你裝(因為要看你有沒有顯卡)。
只用 CPU(大部分人):
pip install torch torchaudio --index-url https://download.pytorch.org/whl/cpu有 NVIDIA 顯卡(速度快很多):
pip install torch torchaudio --index-url https://download.pytorch.org/whl/cu1212. 裝本專案
pip install git+https://github.com/draiagent/funasr-zh-tw-mcp.git要用 HTTP API 的話,加裝 api 選配依賴:
pip install "funasr-zh-tw-mcp[api] @ git+https://github.com/draiagent/funasr-zh-tw-mcp.git"套件名稱是
funasr-zh-tw-mcp,但程式裡的模組名稱是funasr_mcp(比較短好打), 所以指令會寫成python -m funasr_mcp.mcp_server。
3. 首次執行會下載模型
第一次辨識時會自動從 ModelScope 下載約 1.5GB 的模型權重(辨識模型 + 語音端點偵測 + 標點還原),存在 ~/.cache/modelscope。之後就不會再下載。
依網速不同可能需要 10–30 分鐘,請耐心等候。
用法一:命令列
funasr-transcribe 課堂錄音.m4a輸出到檔案:
funasr-transcribe 課堂錄音.m4a -o 逐字稿.txt其他選項:
參數 | 說明 |
| 輸出檔路徑 |
| 不轉繁體,輸出模型原始簡體結果 |
| 附上每個字的時間戳(毫秒) |
支援格式:wav mp3 m4a flac ogg opus aac wma mp4 mov webm
用法二:MCP server(給 AI 助理呼叫)
Claude Code
claude mcp add funasr -- python -m funasr_mcp.mcp_serverClaude Desktop
編輯設定檔:
Windows:
%APPDATA%\Claude\claude_desktop_config.jsonmacOS:
~/Library/Application Support/Claude/claude_desktop_config.json
{
"mcpServers": {
"funasr": {
"command": "python",
"args": ["-m", "funasr_mcp.mcp_server"]
}
}
}如果你把套件裝在虛擬環境裡,command 要指向該環境的 python,例如
C:\\path\\to\\.venv\\Scripts\\python.exe。
設定完重開 Claude Desktop,就可以直接說:
幫我把 D:\錄音\第三堂課.m4a 轉成逐字稿
提供的工具
工具 | 功能 |
| 把音檔轉成繁體中文逐字稿。可選擇是否附時間戳。 |
| 預先載入模型,讓下一次辨識可以立刻開始(首次載入約 40 秒)。 |
用法三:HTTP API
funasr-api預設監聽 http://127.0.0.1:8000。
端點 | 方法 | 說明 |
| GET | 服務狀態、模型是否已載入 |
| POST | 上傳音檔(multipart),回傳逐字稿 |
| GET | 互動式 API 文件 |
| GET | OpenAPI schema(ChatGPT Actions 需要) |
範例:
curl -X POST http://127.0.0.1:8000/transcribe \
-F "file=@課堂錄音.m4a" \
-F "traditional=true"從自己的網頁工具呼叫:
const form = new FormData();
form.append('file', audioFile);
const res = await fetch('http://127.0.0.1:8000/transcribe', {
method: 'POST',
body: form,
});
const { text } = await res.json();環境變數
變數 | 預設 | 說明 |
|
| 監聽位址 |
|
| 監聽埠號 |
| 無 | 設定後啟用 Bearer token 驗證 |
| 僅 localhost | 允許的跨來源網址,逗號分隔 |
接到 ChatGPT 自訂 GPT
ChatGPT 的伺服器在雲端,連不到你家的 localhost,所以要先開一條通道:
cloudflared tunnel --url http://127.0.0.1:8000會拿到一個 https://xxx.trycloudflare.com 網址,把 /openapi.json 貼進自訂 GPT 的 Actions 設定即可。
⚠️ 公開服務前務必設定
FUNASR_API_TOKEN,否則任何人只要知道網址就能使用你的電腦做運算。
隱私
辨識完全在本機執行,音檔不會傳送到雲端
模型權重從 ModelScope 下載一次後存在本機
HTTP API 預設只綁定
127.0.0.1,不會對外開放只有在你自己主動開通道(ngrok / cloudflared)時才會對外,此時請務必設 token
已知限制
主要針對中文,其他語言請換用 FunASR 的其他模型
首次載入模型約需 40 秒;長時間不用可以先呼叫
preload_model暖機CPU 辨識速度約為即時的 1 倍(1 分鐘音檔約需 1 分鐘),有 GPU 會快很多
標點斷句偶爾會切錯位置,長篇逐字稿建議人工校對
繁體轉換的取捨:預設的
s2twp會一併轉換兩岸用詞,好處是「軟件→軟體、網絡→網路、 信息→資訊」都正確,但也可能過度轉換 —— 例如你說的「這份文件」會被轉成「這份檔案」 (因為文件在中國指的是 file)。若你的內容常出現這類詞,可改用純字形轉換: 在程式中呼叫core.transcribe(..., opencc_config="s2t"),或用 CLI 的--simplified取得原始輸出後自行處理。
授權
本專案採用 MIT License。
底層的 FunASR 由阿里巴巴達摩院開發,其程式碼與模型權重各有授權條款,商業使用前請自行確認。
Available Tools
2 toolspreload_model預先載入模型A
預先把 FunASR 模型載入記憶體,讓之後的 transcribe_audio 呼叫可以立即開始辨識。首次執行會下載約 1.5GB 的模型權重。模型已載入時呼叫不會有任何副作用。
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
Output Schema
| Name | Required | Description |
|---|---|---|
| loaded | Yes | 模型是否已就緒 |
| message | Yes | 人類可讀的狀態說明 |
| already_loaded | Yes | 呼叫前模型是否就已經載入 |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It discloses that the tool loads a model into memory, that the first execution downloads ~1.5GB of weights, and that calling it when already loaded has no side effects. This meaningfully informs the agent about cost, statefulness, and safety.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three short sentences with no filler. The primary purpose is front-loaded, followed by the most important behavioral caveats (download size and idempotence). Every sentence contributes useful information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a zero-parameter tool with an output schema and a single sibling, the description covers what the tool does, why it should be used, the main cost, and its side-effect behavior. Nothing essential is missing for an agent to decide when to invoke it.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool has zero parameters, so the baseline is 4. The description adds no parameter-level detail, but none is needed; the empty input schema and the description are fully consistent and sufficient.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a specific action ('預先把 FunASR 模型載入記憶體') with a clear purpose ('讓之後的 transcribe_audio 呼叫可以立即開始辨識'). It clearly distinguishes itself from the sibling transcribe_audio by describing a preloading step rather than the recognition step itself.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description clearly implies when to use the tool: before transcribe_audio calls to make them start immediately. It also provides relevant usage context about the first-run download and the idempotent nature when the model is already loaded, though it does not explicitly list exclusion cases or alternatives.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
transcribe_audio音檔轉繁體逐字稿A
將本機音檔轉成繁體中文逐字稿,支援 wav/mp3/m4a/flac/ogg/mp4 等格式。全程在本機運算,音檔不會上傳到任何雲端服務。注意:模型第一次載入約需 40 秒,若使用者在意等待時間可先呼叫 preload_model。
| Name | Required | Description | Default |
|---|---|---|---|
| file_path | Yes | ||
| traditional | No | ||
| with_timestamps | No |
Output Schema
| Name | Required | Description |
|---|---|---|
| text | Yes | 逐字稿(預設為繁體中文、台灣用詞) |
| raw_text | Yes | 模型原始輸出,未經繁體轉換的簡體中文 |
| audio_path | Yes | 辨識的音檔路徑 |
| timestamps | No | 每個字的 [起始毫秒, 結束毫秒],僅在 with_timestamps=true 時回傳 |
| duration_seconds | No | 音檔長度(秒) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full behavioral disclosure burden. It does well by revealing that processing is fully local, audio is not uploaded to any cloud service, and the first model load takes about 40 seconds with a mitigation path. It does not describe output details, but an output schema exists to cover that.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three short sentences with no filler: core purpose, privacy behavior, and latency mitigation are each given exactly one sentence. It is front-loaded and easy to scan.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a relatively simple tool with one required parameter and an output schema, the description covers purpose, supported formats, local processing, privacy, and the relevant sibling relationship. The main gap is parameter-level guidance for with_timestamps, but the boolean name and schema default provide enough signal for correct invocation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description needed to compensate for parameters like file_path, traditional, and with_timestamps. It only implicitly hints at traditional via 繁體中文 and at file_path via 本機音檔, while with_timestamps is never explained. An agent would have to rely on parameter names and defaults alone.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a clear verb and resource: converting local audio files into Traditional Chinese transcripts. It also lists supported formats and implicitly differentiates itself from the sibling preload_model by describing the actual transcription task.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
It clearly establishes when to use the tool: whenever a local audio file needs a Traditional Chinese transcript. It also gives an explicit conditional alternative: call preload_model first if the user cares about the ~40s model loading delay. No when-not-to-use scenario is stated, but there are no competing transcription siblings.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
TDQS
transcribe_audio performs the core transcription while preload_model handles model initialization; their purposes are completely distinct and cannot be confused. The descriptions clearly separate the main task from an optional optimization step.
Both tools follow the same verb_noun pattern: transcribe_audio and preload_model. The verb clearly indicates the action, and the noun indicates the target, making the naming predictable and consistent.
Two tools is appropriate for a narrow-purpose server: one primary transcription tool plus an optional model preloading optimization. Each tool earns its place without redundancy, and adding more tools would likely be unnecessary for this focused scope.
The server's domain is local audio transcription, and the tool set covers the full workflow: optional model preloading followed by transcription. There are no obvious gaps for the stated purpose, and the preload_model tool explicitly handles the cold-start concern.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
MCP server for Speech-to-Text
Free OpenAI-compatible inference with signed provenance receipts and 3 focused MCP tools.
MCP server for Text-to-Speech
An MCP server that gives any LLM or agent clean YouTube transcripts on demand: a single video, a whole channel, or a playlist, plus AI cleanup of auto-generated captions. API-key auth, credit-based, same backend as the public v1 API. Get a free API key with 25 free credits at youtubetranscriptdownload.com/account.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceA powerful speech-to-text MCP server that supports multiple audio formats and recognition engines including remote APIs (Bailian, OpenAI Whisper, iFLYTEK), Google Speech Recognition, and CMU Sphinx.1
- AlicenseNot gradedqualityCmaintenanceMCP server for offline speech-to-text and speaker diarization, enabling AI agents to transcribe audio locally without cloud APIs.3MIT
- FlicenseNot gradedqualityDmaintenanceA high-performance speech recognition MCP server based on Faster Whisper, providing efficient audio transcription capabilities with support for multiple model sizes, batch processing, and various output formats.17
- AlicenseNot gradedqualityBmaintenanceLocal-only transcription server for MCP agents, powered by CrispASR. Transcribes audio/video files without cloud uploads, supporting English and Chinese.1MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/draiagent/funasr-zh-tw-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server