Communitygithub.com

AlemTuzlak/skills

当用户希望将视频或音频文件转录为带有词级时间戳的文本时使用——自动启动一个捆绑在本技能中的本地 Whisper (whisper.cpp) Docker 服务,并生成 transcript.txt、transcript.srt 和词级 transcript.words.json 文件。也作为 /produce-video 的构建模块。触发词包括“转录这个视频”、“获取转录文本”、“transcribe-video”。

skills 是什么?

该技能通过本地捆绑的 whisper.cpp 服务,将视频或音频文件转录为文本,并生成词级时间戳。它完全在本地运行,不依赖任何外部项目或云 API,特别适合需要精确时间同步的字幕叠加或视频制作。技能包含一个自动化的 Docker 运行器,负责构建镜像、启动容器、检查健康状态,并通过 ffmpeg 将输入音频转换为 16kHz 单声道 WAV 格式后再提交给 Whisper 服务。输出包括纯文本 transcript.txt、SRT 字幕文件以及 JSON 格式的词级时间戳数组(包含每个词的开始和结束时间)。该技能在 Claude Code、Cursor 等 AI 代理平台上运行,要求本地安装 Docker 和 ffmpeg,并至少使用 Node.js 22。首次构建镜像较慢(需编译 whisper.cpp 并下载模型),但后续调用会复用容器以实现快速响应。它也可作为更复杂工作流(如 /produce-video)的底层转录模块使用。

兼容平台~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/AlemTuzlak/skills/tree/HEAD/skills/transcribe-video

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

转录视频

使用捆绑的 whisper.cpp 服务在本地转录任何视频/音频文件。无需外部项目或云 API。返回词级时间戳(用于同步叠加/字幕)。

使用时机

  • “转录这个剪辑/视频/音频”、“给我带时间戳的转录文本”。
  • 作为 /produce-video 的子步骤。

运行方式

一切由捆绑的运行器驱动——切勿要求用户管理 Docker:

node scripts/transcribe.mjs <视频或音频路径> [--out <目录>] [--port 9111] [--language en] [--no-word-ts] [--task transcribe|translate]
node scripts/transcribe.mjs --stop      # 停止热容器

运行器:

  1. 检查 Docker 守护进程是否可达(如果不可达,则失败并给出指导)。
  2. 如果 transcribe-video-whisper 镜像缺失,则从 assets/whisper-service/ 构建(首次构建较慢:编译 whisper.cpp 并烘焙 ggml-base.en.bin 模型)。
  3. 启动 transcribe-video-whisper 容器(主机端口 9111 → 容器 9001);如果已运行则复用,如果停止则 docker start。
  4. 等待 GET /healthz 报告正常。
  5. 使用本地 ffmpeg 从输入中提取 16 kHz 单声道 WAV(whisper.cpp 仅解码 WAV),然后将其 POST 到 /transcribe,带上 word_ts=true。
  6. 将 transcript.txt、transcript.srt、transcript.words.json 写入 --out(默认:输入文件目录),并在标准输出打印一行 JSON 结果。

输出

  • transcript.txt — 纯文本。
  • transcript.srt — 字幕文本。
  • transcript.words.json — [{ "word", "start", "end" }],以秒为单位,按时间排序。这是叠加/字幕的同步源。

标准输出结果行(供 /produce-video 等编程调用者使用):

{ "ok": true, "outDir": "...", "wordCount": 38, "segmentCount": 2, "files": { "txt": "transcript.txt", "srt": "transcript.srt", "words": "transcript.words.json" } }

要求

  • 必须安装 Docker — Whisper 服务在容器中运行,因此必须安装并运行 Docker Desktop。运行器首先检查此项,如果 Docker 缺失或守护进程关闭,则失败并给出安装/启动指导;没有非 Docker 的回退方案。
  • 必须安装 ffmpeg(用于为 Whisper 提取 16 kHz 单声道 WAV)—— 运行器会提前检查,如果未在 PATH 中,则失败并报错。
  • Node ≥ 22。

备注

  • 容器保持运行(--restart unless-stopped)以支持热复用;使用 --stop 停止。
  • 如果请求词级时间戳但未返回任何结果,运行器会失败报错(叠加同步依赖于此)。
  • 参见 references/ 了解 Docker 生命周期、API 形态以及供应商来源信息。

Individual skills in this repo

This repo contains 14 individual skills — each has its own dedicated page.

AlemTuzlak/skills

Use when the user wants to write a blog post about a feature, product change, PR, git diff, or any technical topic - accepts marketing briefs, PRs, git refs, codebase paths, or freeform descriptions as input

AlemTuzlak/skills

Use when the user wants to generate a changelog, release notes, or document what changed between versions, tags, or PRs

AlemTuzlak/skills

Use when writing, editing, or organizing documentation, when planning what docs a feature needs, and whenever planning or implementing a new feature or change in a repo (docs ship with the code). Also use when tempted to write docs without showing the discovered readers to the user, without asking for tone, or without loading simple-english and i-have-adhd. Triggers on "write docs for X", "document this feature", "add a guide", "update the docs", "reorganize the docs", "plan feature X", "implement X", or /docs.

AlemTuzlak/skills

Use when a bug is in play: a test fails, CI is red, an API returns the wrong result, a stack trace appears, or the user says it is broken or fix this. Don't use for a new feature with no failure, for types-only work, or for docs.

AlemTuzlak/skills

Use when the user invokes /i-have-adhd, says they have ADHD, or asks for ADHD-friendly output. Also used as a required writing filter by the docs skill. Don't use for marketing copy or after the user says "stop adhd mode" or "normal mode".

AlemTuzlak/skills

Use when a settled change must be turned into an ordered stack of small blocks before anyone implements. Don't use for unsettled intent, typos, comments, formatting, docs-only work, or writing the implementation itself.

AlemTuzlak/skills

Use when the user wants to write a product update email, feature announcement newsletter, or digest email for users or subscribers

AlemTuzlak/skills

Use when the user wants to turn a raw talking-head / screen-share recording into a finished, edited, annotated video plus a full content package. Removes silences, flags mistakes for the user to cut, transcribes, adds transcript-synced overlays (code, on-screen code highlights, word highlights, lists, comparisons, diagrams, section labels, punch-in zooms), renders with original audio, then generates blog/socials/YouTube content. Triggers on "produce a video", "edit my video", "annotate my recording", "/produce-video".

AlemTuzlak/skills

Use when the user runs /prove-it or says prove it, prove the changes, show me in the browser, or asks to prove a UI or API change. Don't use only because the agent is about to say done, for types-only work, or for docs with no behavior to prove.

AlemTuzlak/skills

Use when the user wants to write, draft, or author an RFC (Request for Comments) / technical design doc for a feature, change, or architectural decision. Interactively interviews the user, grounds the proposal in the actual codebase, presents 2-3 concrete API/code-snippet approaches to choose from, then writes a review-ready RFC. Triggers on "write an RFC", "draft an RFC", "RFC for X", "design doc for X", or /rfc.

AlemTuzlak/skills

Use when the user wants to deeply learn a new topic from scratch. Runs a pre-interview (current knowledge, end-goal proficiency, depth, practice load, background, scope), researches online (articles, niche-influencer blogs, canonical docs, subtopic landscape), then produces a structured markdown course with mandatory visual diagrams, evidence-based learning-science features (retrieval practice, spaced callbacks, worked-example fading, concept ledger, jargon gate, analogy hygiene), and a self-contained interactive HTML mini-course. Triggers on /teach-me, "teach me about X", "I want to learn X", "deep dive on X", "create a course on X", "study X with me".

AlemTuzlak/skills

Use when the change intent is already settled and the agent must map what a behavior change touches before an implementation plan or any code. Use for new features, bug fixes, and refactors that move a boundary. Don't use for typos, comments, formatting, lockfile-only diffs, docs with no code, or while the user is still deciding what they want.

AlemTuzlak/skills

Use when the user wants to write a video script for a product demo, feature walkthrough, launch video, or social media video about a feature or product change

AlemTuzlak/skills

Use when the user wants YouTube metadata for a video — a click-worthy title, an SEO/above-the-fold description, tags, and timestamped chapters. Accepts a transcript (ideally timestamped SRT), a topic, a PR, or a freeform description. Used standalone and by /produce-video. Triggers on "youtube title", "youtube description", "youtube chapters", "youtube tags", "youtube metadata", "youtube-copy".

相关技能