Borrowing it
Nothing to install: this file belongs to fengredrum/asr-mcp. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/fengredrum/asr-mcp/main/CLAUDE.mdgit clone --depth 1 https://github.com/fengredrum/asr-mcpWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/instructions/fengredrum/asr-mcp/claude-md)<a href="https://agentmods.dev/instructions/fengredrum/asr-mcp/claude-md"><img src="https://agentmods.dev/badge/instructions/fengredrum/asr-mcp/claude-md.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00936 | $0.00936 |
| Opus 5 | $0.00468 | $0.00468 |
| Sonnet 5 | $0.00187 | $0.00187 |
| Haiku 4.5 | $0.00094 | $0.00094 |
Grade A, and why
asr-mcp CLAUDE.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 7d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
What it actually says
CLAUDE.md
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
项目简介
ASR MCP 服务(asr-mcp):基于本地 Whisper Large V3 MLX 模型的语音转文本 MCP server(stdio 传输),对外暴露两个工具:transcribe_audio(转写)与 correct_transcription(LLM 纠错)。
常用命令
包管理使用 uv(默认索引为阿里云镜像,见 pyproject.toml),虚拟环境 .venv(Python 3.12)。
- 安装依赖:
uv sync - 运行 MCP server:
uv run server.py - 直接运行转写 worker(绕过 MCP 调试转写链路):
.venv/bin/python worker.py <音频路径> <text|timestamps|srt> <输出文件> [语言] - 无自动化测试框架:用
test_samples/做端到端验证——Docker_Sandboxes_Claude_Code.m4a是测试音频,同名.md是参考文稿(可用于 reference 模式纠错的对照文本)。
架构
四个文件构成一条流水线,核心设计是把「MCP 工具调用」与「重转写任务」解耦到不同进程:
server.py:MCP server 本体。transcribe_audio用asyncio.create_subprocess_exec把转写交给worker.py子进程,再以asyncio.wait_for(proc.wait(), HEARTBEAT_SECONDS)做事件驱动等待(不轮询进程状态),期间经ctx.report_progress心跳上报进度。默认超时 600 秒;超时后不杀子进程——worker 继续在后台跑完并自行落盘,工具如实返回「未完成」而非「出错」,提示调用方稍后检查输出文件。worker.py:一次性工作进程。转写、写文件完成后,向 stdout 打印一行 JSON 作为状态协议:成功{"status": "ok", "output", "chars", "preview"};失败{"status": "error", "error"}且退出码 1。server.py 只解析 stdout 的最后一行——改动此协议时两端必须同步。transcriber.py:mlx_whisper.transcribe的薄封装。模型路径取环境变量ASR_MCP_MODEL_PATH,未设置时回退到DEFAULT_MODEL_PATH(作者本地路径,仅为兼容旧用法)。关键 workaround:该模型转写中文时默认不输出任何标点,必须按语言注入initial_prompt引导加标点(zh / other 各一条,见_INITIAL_PROMPTS)。formatter.py:三种输出格式(text / timestamps / srt)。_normalize_punct只在标点紧邻 CJK 字符时把半角转全角,避免影响纯英文内容——修改标点逻辑时保留这个约束。
输出文件命名约定:{音频名}.txt、{音频名}_timestamps.txt、{音频名}.srt;纠错结果约定保存为 {音频名}_corrected.txt。
correct_transcription 的 Sampling 回退
纠错优先走 MCP Sampling——仅当客户端 capabilities 声明了 sampling 时才调用 ctx.session.create_message;多数客户端不支持,此时工具返回一份现成的纠错提示词(semantic / reference 两种模式各一套),由当前会话的 LLM 自己按提示词完成纠错。修改该工具时两条路径都要兼顾。
开发要求(来自 开发需求.md)
- 转写必须后台运行、完成后自动上报,不得轮询进度;默认超时 10 分钟,超时后需区分「未完成」与「转写出错」两种结论。
- 所有 Python 包用 uv 管理、在
.venv中运行、走阿里云镜像源。
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 7d ago First seen · 37 lines · 936 tokens per session scan A 1c1146051df3
asr-mcp CLAUDE.md is an instructions file published in the GitHub repository fengredrum/asr-mcp (0 stars, last pushed 1mo ago), licensed MIT. It adds 936 tokens to every session, about $0.0047 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other instructions, from other repositories
codex AGENTS.md
AGENTS.md instructions for openai/codex, covering rust/codex-rs, the codex-core crate, code review rules, crate api surface and model visible context.
vscode buildNext.instructions.md
Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).
next.js AGENTS.md
AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.
langchain AGENTS.md
AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, applying the notice (cutover) and fallback chain (never fail the build).
spec-kit AGENTS.md
AGENTS.md instructions for github/spec-kit, covering agents.md, about spec kit and specify, quickstart — add a new integration in 5 steps, integration architecture and integrationmanifest — file tracking.