youtube-fetch

Solid

Fetches YouTube video metadata and transcripts using yt-dlp. Activate when the user shares a YouTube URL (youtube.com, youtu.be), asks to 'fetch this video', 'get the transcript', 'what does this video say', 'summarize this YouTube video', or references video content that needs to be retrieved. Also activate when processing multiple YouTube URLs in batch. Do NOT use for non-YouTube video platforms, local video files, or audio-only podcast URLs.

AI & Automation 89 stars 16 forks Updated today MIT

Install

View on GitHub

Quality Score: 85/100

Stars 20%
65
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

## Overview This skill retrieves YouTube video content (metadata and transcripts) using yt-dlp. WebFetch does not work reliably for YouTube (dynamic content, SSL issues). yt-dlp is the reliable alternative. **Prerequisite:** `yt-dlp` must be installed (`pip install yt-dlp`). ## Workflow 1. Ensure yt-dlp is available (install if needed): ``` which yt-dlp || pip install yt-dlp ``` 2. Fetch metadata for each video: ``` yt-dlp --skip-download --print '%(title)s|||%(uploader)s|||%(description)s' 'VIDEO_URL' ``` 3. Fetch the auto-generated transcript: ``` mkdir -p /tmp/yt-transcripts yt-dlp --write-auto-sub --skip-download --sub-lang en -o '/tmp/yt-transcripts/%(id)s' 'VIDEO_URL' ``` The transcript lands at `/tmp/yt-transcripts/VIDEO_ID.en.vtt`. 4. Clean the VTT file into plain text (strip timestamps and tags): ``` sed '/^WEBVTT/d;/^Kind:/d;/^Language:/d;/^[0-9][0-9]:[0-9][0-9]/d;/^$/d;s/<[^>]*>//g' /tmp/yt-transcripts/VIDEO_ID.en.vtt | awk '!seen[$0]++' ``` 5. If the transcript is too large to read at once, pipe through `head -N` / `tail -n +N` to read in chunks. 6. If no English auto-subs are available, try without `--sub-lang`: ``` yt-dlp --write-auto-sub --skip-download -o '/tmp/yt-transcripts/%(id)s' 'VIDEO_URL' ``` Then check `ls /tmp/yt-transcripts/VIDEO_ID.*.vtt` for available languages. 7. If SSL errors occur, add `--no-check-certificate`. ## Output Format Present results per video as: ``` ### Video: [Ti...

Details

Author
WingedGuardian
Repository
WingedGuardian/GENesis-AGI
Created
4 months ago
Last Updated
today
Language
Python
License
MIT

Similar Skills

Semantically similar based on skill content — not just same category