skills/youtube-transcript/SKILL.md
Tải transcript/caption YouTube bằng yt-dlp. Trigger: YouTube URL, subtitles, captions, video text.
npx skillsauth add hoangvantuan/claude-plugin youtube-transcriptInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Download transcript from YouTube video, convert to clean plain text.
Follow this exact order. Stop and inform the user if any step fails.
command -v yt-dlp
If not found, install:
brew install yt-dlpsudo apt install -y yt-dlppip3 install yt-dlpIf installation fails, tell the user to install manually.
VIDEO_URL="THE_URL"
yt-dlp --print "%(title)s" "$VIDEO_URL"
yt-dlp --list-subs "$VIDEO_URL"
Note what's available: manual subtitles (higher quality) vs auto-generated.
Try in order until one succeeds:
Manual subtitles (best quality):
yt-dlp --write-sub --skip-download --output "transcript_temp" "$VIDEO_URL"
Auto-generated subtitles (fallback):
yt-dlp --write-auto-sub --skip-download --output "transcript_temp" "$VIDEO_URL"
Both produce a .vtt file.
If neither works, inform the user that video này không có phụ đề.
Use the bundled conversion script to deduplicate and clean the VTT output:
VIDEO_TITLE=$(yt-dlp --print "%(title)s" "$VIDEO_URL" | tr '/' '_' | tr ':' '-' | tr '?' '' | tr '"' '')
VTT_FILE=$(ls transcript_temp*.vtt 2>/dev/null | head -n 1)
python3 skills/youtube-transcript/scripts/vtt-to-txt.py "$VTT_FILE" "${VIDEO_TITLE}.txt"
Then clean up the temporary VTT file:
rm "$VTT_FILE"
Tell the user the file name and location. Offer to read/display the content if they want to review it.
YouTube auto-generated VTT files show captions progressively with overlapping timestamps, producing many duplicate lines. The conversion script uses a seen-set to preserve speaking order while removing duplicates.
By default yt-dlp downloads all available subtitle languages. To target a specific language:
yt-dlp --write-auto-sub --sub-langs vi --skip-download --output "transcript_temp" "$VIDEO_URL"
Common codes: en (English), vi (Vietnamese), ja (Japanese), ko (Korean).
Read references/error-handling.md for solutions to common issues (private videos, geo-blocking, SSL errors, missing subtitles).
tools
Bộ nhớ tri thức cấp dự án tự cải tiến: capture bài học, consolidate đúc kết, recall tra cứu + thực thi. Dữ liệu ghi vào memory/ ở gốc repo.
development
Phán quyết go/no-go + ưu tiên cho một hạng mục kỹ thuật, xác minh bằng chứng read-only trước khi kết luận.
tools
Viết/rà soát/tách user story, acceptance criteria, INVEST, epic, backlog từ requirement/PRD/bug/feature.
tools
Phân tích quyết định/vấn đề bằng Thu Giang Nguyễn Duy Cần: Thuật Tư Tưởng, Dịch Lý, Lão Trang, quân bình.