Video Subtitles 标志

Video Subtitles

组织
video-db
video-subtitles

Subtitles, captions and transcripts for a video or audio file. Use when the user wants a transcript (plain or timestamped) of a video, podcast or call recording, static subtitles burned in with a chosen font, colour and position, a transcript or subtitles translated into another language, or dubbing. Animated or karaoke captions belong to video-edit. Works on YouTube links, public video URLs, audio files and media already in the user's VideoDB account.

Add to TypingMind

概览

发布者video-db
代码仓库skills
技能名称video-subtitles
星标数
139
复刻数
10
附带文件
仅含指令
许可协议MIT
链接
  • Markdown 格式的指令

    模型按需加载 SKILL.md 文件,因此只有在请求确实与该技能匹配时才会消耗 Token。

  • 兼容任何大语言模型

    AI 技能采用纯 Markdown,而非特定提供商的代码,因此可搭配 GPT、Claude、Gemini、Grok 或本地模型使用。

  • 指令自成一体

    模型所需的一切都包含在指令中,无需同步额外文件。

  • 开源

    由 video-db 发布于 GitHub。请在安装前查看技能的源文件。

安装

在 TypingMind 中安装 Video Subtitles AI 技能,即可搭配任意大语言模型使用;也可以将其放入其他支持读取 SKILL.md 的智能体中。

1

安装到 TypingMind

TypingMind 可直接从 GitHub 文件夹安装技能:读取 SKILL.md,打包资源文件,并将结果保存在本地。

  1. 打开应用,前往“插件 → 技能”。
  2. 选择“从 GitHub 安装”。
  3. 粘贴下方的技能文件夹 URL 并确认。
    https://github.com/video-db/skills/tree/main/skills/video-subtitles
  4. 请在每个需要使用该技能的聊天中启用它。
依次选择“插件 → 技能 → 添加技能 → 从 GitHub URL 导入”,然后粘贴文件夹 URL 并点击“继续”。
2

安装到其他智能体

任何支持 Agent Skills 格式的智能体都可以使用此技能,只需将文件夹复制到该智能体的技能目录中。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/video-db/skills.git /tmp/skills
mkdir -p .claude/skills
cp -r /tmp/skills/skills/video-subtitles .claude/skills/video-subtitles
复制后,请重启 Claude Code,以加载新技能。

在 TypingMind 中使用此技能

在任意 TypingMind 聊天中启用 Video Subtitles,后续即可交由模型处理。技能的名称和描述会放在系统提示词中,一旦请求匹配,模型就会自动加载完整指令,无需您手动调用,且在实际使用前不会消耗 Token。

一旦请求与技能匹配,模型就会自动加载 Video Subtitles。

兼容任何 AI 模型

AI 技能是纯 Markdown 指令,而非特定提供商的代码,因此 Video Subtitles 不局限于最初适配的模型。只需在 TypingMind 中安装一次,即可搭配 GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama 或您自行运行的本地模型使用,全程使用您自己的 API 密钥。

  • 仅在需要时加载

    系统提示词中仅包含技能名称和描述。首次遇到匹配的请求时才会加载完整指令,因此技能未使用时,这些指令不会消耗 Token。

  • 在聊天中切换模型

    技能是指令而非代码,因此切换模型不会导致技能失效,新模型会读取同一个 SKILL.md。

技能指令

这是模型会加载的 SKILL.md 内容。请在安装前阅读,因为技能就是模型将遵循的指令。

Subtitles and transcripts

Which path

  1. VideoDB connector tools present (names such as generate_transcript, add_subtitles, translate_transcript, upload_media): use them. This is the path in Claude chat on web, desktop and mobile, and in Cowork. Do not install anything and do not ask for an API key.
  2. No VideoDB tools, but you have a shell (Claude Code, Cowork, any agent that can run Python): ask for the VideoDB API key in one friendly line (free at https://console.videodb.io, $20 of credits, no card). When the user gives it, in chat or any other way, save it yourself to the project's .env as VIDEO_DB_API_KEY, never print it, and continue with the Python SDK path at the end of this file. In Claude Code, /mcp then authorizing videodb also works.
  3. No VideoDB tools and no shell: you are in Claude chat. Reply with only this, adapted to the request: "VideoDB isn't connected yet. Open Settings → Connectors, find VideoDB, click Connect and log in (free, no card). Then send this request again and I'll take it from there." Do not mention API keys, .env, shells, Claude Code or /mcp here; none of them apply in chat, and a key pasted into chat cannot be used because nothing runs code there.

Talking to the user: never write "index", "indexed" or "indexing" in a reply. Say "searchable" ("it is now searchable by what was said and what is shown"), and "transcribe" rather than naming a job. One line of status at a time, then the result.

Long jobs return status: processing. The reply carries an output_url and names the tool to poll (poll_with, or retry_with on older servers). Call that tool with the output_url until it is done; several processing replies in a row are normal (a 10-minute YouTube upload takes about five), and a done reply with an empty result means poll once more. Never re-run the write; that starts a second job.

With the connector tools

Get the video. First search_videos_by_title(query); reuse the m- id if the video is already in the account. Otherwise, for a YouTube link or public URL, upload_media(url) and poll until done; note the m- id. Local files cannot come through the connector; the user uploads at https://console.videodb.io and shares the m- id.

Transcript. generate_transcript(media_id) (add language_code if the speech is not English), poll until done, then get_transcript(media_id, timestamped=true, segmenter="sentence") for sentence timestamps, or timestamped=false for plain text. The default segmenter is one segment per word and timestamped output is capped at 2000 segments, so pass segmenter="sentence" or start and end for long media. The transcript job result also carries text and a word list, but the list is truncated; read the transcript with get_transcript.

Subtitles burned into the video.

  1. generate_transcript(media_id) and poll until done (instant if the video already has a transcript). add_subtitles reads the video's transcript; a spoken_words analyzer run from understand_video counts too. index_spoken_words is the legacy v1 call and is not needed.
  2. add_subtitles(video_id, ...). Returns a stream_url and a player_url at once; it is not a job.
  3. An MP4 file: download_stream(stream_url, name="..."), poll, then share the download link.

Style options on add_subtitles: font_name, font_size (8 to 72, default 18), bold, italic, alignment (bottom_center default, top_center, middle_center, ...), border_style (outline, opaque_box or no_border), outline, outline_colour, shadow, margin_l, margin_r, margin_v. Colours use the ASS format &HAABBGGRR: opaque white &H00FFFFFF, black &H00000000, yellow &H0000FFFF. "White text on a black box" is primary_colour="&H00FFFFFF", back_colour="&H00000000", border_style="opaque_box".

Animated or karaoke captions, or captions on a composed video. Use the video-edit skill's render_timeline with a caption asset (src: "auto", animation: "karaoke"). The video must already be transcribed (generate_transcript, or a spoken_words analyzer run), or the render comes back with no captions and no error.

Translate. translate_transcript(video_id, language="Spanish") returns the translated, timestamped segments. Give them to the user as text or as an SRT-style list.

Dubbing and translated voiceover. Not available through the connector. In Claude Code, the SDK does it (${CLAUDE_PLUGIN_ROOT}/python/reference/editor.md, dubbing section). In chat, offer the translated transcript and say that dubbing needs the SDK.

With the Python SDK (Claude Code)

Set up first with /videodb:setup if import videodb fails. Full reference: ${CLAUDE_PLUGIN_ROOT}/python/SKILL.md.

python
from dotenv import load_dotenv; load_dotenv(".env")
import videodb
from videodb import SubtitleStyle, SubtitleAlignment, SubtitleBorderStyle
conn = videodb.connect(); coll = conn.get_collection()
video = coll.upload(url="https://www.youtube.com/watch?v=VIDEO_ID")
video.generate_transcript()
print(video.get_transcript_text())
stream_url = video.add_subtitle(SubtitleStyle(font_size=20, primary_colour="&H00FFFFFF",
                                              back_colour="&H00000000", border_style=SubtitleBorderStyle.opaque_box,
                                              alignment=SubtitleAlignment.bottom_center))
print(f"https://console.videodb.io/player?url={stream_url}")

常见问题

Video Subtitles AI 技能有什么作用?

Subtitles, captions and transcripts for a video or audio file. Use when the user wants a transcript (plain or timestamped) of a video, podcast or call recording, static subtitles burned in with a chosen font, colour and position, a transcript or subtitles translated into another language, or dubbing. Animated or karaoke captions belong to video-edit. Works on YouTube links, public video URLs, audio files and media already in the user's VideoDB account.

为什么在 TypingMind 中使用 Video Subtitles?

因为您只需安装一次,就能搭配任何模型使用。Video Subtitles 采用纯 Markdown 格式,而非特定提供商专用的代码,因此同一技能可用于 GPT-5、Claude、Gemini、Grok 或本地模型。您甚至可以在聊天中途切换模型,而不会影响技能的正常使用。TypingMind 使用您自己的 API 密钥,因此您直接向提供商付费,而不是按席位订阅;您的技能和聊天记录也都保留在您自己的存储空间中。

如何在 TypingMind 中安装 Video Subtitles?

在 TypingMind 中打开“插件 → 技能 → 从 GitHub 安装”,然后粘贴 https://github.com/video-db/skills/tree/main/skills/video-subtitles。TypingMind 会读取其中的 SKILL.md,并将其安装为技能,供您在各个聊天中按需启用。

哪些 AI 模型可以使用 Video Subtitles?

您在 TypingMind 中连接的任何模型都可以。AI 技能采用纯 Markdown 指令,而非特定提供商专用的代码,因此 GPT、Claude、Gemini、Grok 和本地模型都能在请求匹配时加载此技能。

Video Subtitles 可以搭配多少个 AI 模型使用?

数量不限。只要模型支持技能,您就可以将它与 Video Subtitles 搭配使用。GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llama 等模型都可以通过您自己的 API 密钥接入 TypingMind。

Video Subtitles AI 技能免费吗?

是的。video-db 已在 GitHub 上根据 MIT 许可证发布了该技能。您只需向自己的 AI 提供商支付所用 Token 的费用。

什么是 AI 技能?

AI 技能是一组可复用的指令,用于教会 AI 模型完成某项特定任务。它遵循开放的 Agent Skills 格式:包含名称和描述的 SKILL.md 文件,以及模型可能需要的脚本、模板或参考文件。模型仅在您的请求与技能匹配时才会读取这些指令,因此已安装的技能在使用前不会产生任何费用。

AI 技能与插件或 MCP 服务器有何不同?

插件或 MCP 服务器为模型提供可调用的新工具,也就是在某处运行并返回结果的代码。AI 技能则为模型提供知识和流程:如何处理任务、遵循哪些步骤,以及怎样的输出才算优质。技能采用纯 Markdown 格式,因此不需要服务器、API 密钥或运行时环境,并且适用于任何模型。

查看全部

立即创建您自己的 AI 工作区

订阅我们的电子简报,获取新功能和后续赠奖活动的通知 👇