跳到主要内容
知仓学习社ZHICANG

video-transcript

Extract video transcripts: yt-dlp subtitles to clean paragraphs.

不碰外部(只输出文字)无严重或高危命中notque/vexjoy-agent

它会碰到什么

扫了多少2 个文本文件,6 KB
它会碰到什么不碰外部(只输出文字)
命中总数0 处
命中统计严重 0 · 高 0 · 中 0 · 低 0

这一栏是扫描器报的事实,不是结论。命中多不等于有毒(安全工具、规则库、示例脚本本来就会包含危险写法),命中少也不等于干净。它和你手上的凭据、文件、网络有什么关系,需要你自己看。

技能内容

Video Transcript

Pull a video's transcript as readable paragraphs. Two paths, in order:

Path 1 — uploader subtitles (accurate, prefer when present):

yt-dlp --skip-download --write-subs --sub-langs en --sub-format vtt \
  -o '<work-dir>/%(id)s' '<URL>'

Path 2 — auto-generated captions (fallback when path 1 writes no file):

yt-dlp --skip-download --write-auto-subs --sub-langs en --sub-format vtt \
  -o '<work-dir>/%(id)s' '<URL>'

Then clean the VTT into paragraphs:

python3 skills/research/video-transcript/scripts/vtt_to_paragraph.py <work-dir>/<id>.en.vtt

Default output is plain paragraph text with [Music]-style cues stripped and the rolling duplicates of auto-captions deduplicated. Use --timestamps for [mm:ss] markers, --keep-brackets to keep cue tags, -o FILE to write to a file.

For other languages, change --sub-langs (e.g. de, en.*). List what a video offers with yt-dlp --list-subs '<URL>'.

Error handling

Both paths write no .vtt file

Cause: video has no subtitles or captions in the requested language.

Solution: run yt-dlp --list-subs '<URL>' and pick an available language; if none exist, report that and offer audio transcription via the markdown-converter skill on a downloaded audio file.

HTTP 429 / "Sign in to confirm"

Cause: platform rate-limiting the host.

Solution: wait and retry with --sleep-requests 2; keep request volume low.

Cleaner output repeats lines

Cause: VTT came from a third path (e.g. translated captions) with cue formats the dedupe misses.

Solution: rerun the cleaner; if repeats remain, file the sample VTT alongside a fix to vtt_to_paragraph.py.

想直接用这个技能?

本站把开放许可(MIT / Apache 等)的技能按仓库打包整理到网盘,点一下转存到你自己的网盘,不用一个个从 GitHub 拉。许可未声明的技能只给原始仓库链接,不打包。

它属于哪个仓库

星标★ 419
本站分层T2
该仓技能数122
原文件路径skills/research/video-transcript/SKILL.md

同一个仓库里的其他技能

看这个仓库的全部 122 个技能