Agent Skills › sdyckjq-lab/llm-wiki-skill › youtube-transcript

youtube-transcript

GitHub

从YouTube视频提取字幕或转录文本。支持指定URL、视频ID及时间戳格式,自动处理段落整理与文件保存,适用于需要获取视频文字内容的场景。

deps/youtube-transcript/SKILL.md sdyckjq-lab/llm-wiki-skill

Trigger Scenarios

用户请求YouTube视频的转录本、字幕或 captions 用户提供 YouTube URL 并要求提取内容

Install

npx skills add sdyckjq-lab/llm-wiki-skill --skill youtube-transcript -g -y
More Options

Non-standard path

npx skills add https://github.com/sdyckjq-lab/llm-wiki-skill/tree/main/deps/youtube-transcript -g -y

Use without installing

npx skills use sdyckjq-lab/llm-wiki-skill@youtube-transcript

指定 Agent (Claude Code)

npx skills add sdyckjq-lab/llm-wiki-skill --skill youtube-transcript -a claude-code -g -y

安装 repo 全部 skill

npx skills add sdyckjq-lab/llm-wiki-skill --all -g -y

预览 repo 内 skill

npx skills add sdyckjq-lab/llm-wiki-skill --list

SKILL.md

Frontmatter
{
    "name": "youtube-transcript",
    "description": "Extract transcripts from YouTube videos. Use when the user asks for a transcript, subtitles, or captions of a YouTube video and provides a YouTube URL (youtube.com\/watch?v=, youtu.be\/, or similar). Supports output with or without timestamps."
}

YouTube Transcript

Extract transcripts from YouTube videos using the youtube-transcript-api.

Usage

Run the script with a YouTube URL or video ID:

uv run scripts/get_transcript.py "VIDEO_URL_OR_ID"

With timestamps:

uv run scripts/get_transcript.py "VIDEO_URL_OR_ID" --timestamps

Defaults

  • Without timestamps (default): Plain text, one line per caption segment
  • With timestamps: [MM:SS] text format (or [HH:MM:SS] for longer videos)

Supported URL Formats

  • https://www.youtube.com/watch?v=VIDEO_ID
  • https://youtu.be/VIDEO_ID
  • https://youtube.com/embed/VIDEO_ID
  • Raw video ID (11 characters)

Output

  • CRITICAL: YOU MUST NEVER MODIFY THE RETURNED TRANSCRIPT
  • If the transcript is without timestamps, you SHOULD clean it up so that it is arranged by complete paragraphs and the lines don't cut in the middle of sentences.
  • If you were asked to save the transcript to a specific file, save it to the requested file.
  • If no output file was specified, use the YouTube video ID with a -transcript.txt suffix.

Notes

  • Fetches auto-generated or manually added captions (whichever is available)
  • Requires the video to have captions enabled
  • Falls back to auto-generated captions if manual ones aren't available

Version History

  • 2ef2c36 Current 2026-07-25 05:28

Same Skill Collection

platforms/claude/companions/llm-wiki-upgrade/SKILL.md
SKILL.md
workbench/.claude/skills/pdf/SKILL.md
deps/baoyu-url-to-markdown/SKILL.md
workbench/.claude/skills/docx/SKILL.md
workbench/.claude/skills/pptx/SKILL.md
workbench/.claude/skills/xlsx/SKILL.md

Metadata

Files
0
Version
efa2294
Hash
4d4a96b1
Indexed
2026-07-25 05:28

ホーム - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-10-01 18:42
浙ICP备14020137号-1