home / skills / steipete / agent-scripts / video-transcript-downloader
This skill downloads videos, audio, subtitles, and clean transcripts from YouTube and other supported sites for easy saving and reading.
npx playbooks add skill steipete/agent-scripts --skill video-transcript-downloaderReview the files below or copy the command above to add this skill to your agents.
---
name: video-transcript-downloader
description: Download videos, audio, subtitles, and clean paragraph-style transcripts from YouTube and any other yt-dlp supported site. Use when asked to “download this video”, “save this clip”, “rip audio”, “get subtitles”, “get transcript”, or to troubleshoot yt-dlp/ffmpeg and formats/playlists.
---
# Video Transcript Downloader
`./scripts/vtd.js` can:
- Print a transcript as a clean paragraph (timestamps optional).
- Download video/audio/subtitles.
Transcript behavior:
- YouTube: fetch via `youtube-transcript-plus` when possible.
- Otherwise: pull subtitles via `yt-dlp`, then clean into a paragraph.
## Setup
```bash
cd ~/Projects/agent-scripts/skills/video-transcript-downloader && npm ci
```
## Transcript (default: clean paragraph)
```bash
./scripts/vtd.js transcript --url 'https://…'
./scripts/vtd.js transcript --url 'https://…' --lang en
./scripts/vtd.js transcript --url 'https://…' --timestamps
./scripts/vtd.js transcript --url 'https://…' --keep-brackets
```
## Download video / audio / subtitles
```bash
./scripts/vtd.js download --url 'https://…' --output-dir ~/Downloads
./scripts/vtd.js audio --url 'https://…' --output-dir ~/Downloads
./scripts/vtd.js subs --url 'https://…' --output-dir ~/Downloads --lang en
```
## Formats (list + choose)
List available formats (format ids, resolution, container, audio-only, etc):
```bash
./scripts/vtd.js formats --url 'https://…'
```
Download a specific format id (example):
```bash
./scripts/vtd.js download --url 'https://…' --output-dir ~/Downloads -- --format 137+140
```
Prefer MP4 container without re-encoding (remux when possible):
```bash
./scripts/vtd.js download --url 'https://…' --output-dir ~/Downloads -- --remux-video mp4
```
## Notes
- Default transcript output is a single paragraph. Use `--timestamps` only when asked.
- Bracketed cues like `[Music]` are stripped by default; keep them via `--keep-brackets`.
- Pass extra `yt-dlp` args after `--` for `transcript` fallback, `download`, `audio`, `subs`, `formats`.
```bash
./scripts/vtd.js formats --url 'https://…' -- -v
```
## Troubleshooting (only when needed)
- Missing `yt-dlp` / `ffmpeg`:
```bash
brew install yt-dlp ffmpeg
```
- Verify:
```bash
yt-dlp --version
ffmpeg -version | head -n 1
```
This skill downloads videos, audio, subtitles, and produces cleaned paragraph-style transcripts from YouTube and any site supported by yt-dlp. It prioritizes direct transcript APIs for YouTube and falls back to yt-dlp subtitle extraction with cleanup. Use it to fetch media, inspect available formats, or generate readable transcripts for research or archiving.
The tool queries YouTube transcript services when available to produce a single clean paragraph (timestamps optional). If that fails it uses yt-dlp to extract subtitles, then normalizes and strips bracketed cues by default. It also exposes commands to list formats, download chosen format ids, remux containers when possible, and extract audio or specific subtitle languages.
What if yt-dlp or ffmpeg is missing?
Install them (for example via brew install yt-dlp ffmpeg) and verify with yt-dlp --version and ffmpeg -version.
How do I keep timestamps in transcripts?
Use the --timestamps flag when running the transcript command to include timestamps.
Can I pass custom yt-dlp options?
Yes. Add extra yt-dlp arguments after --; they apply to transcript fallback, download, audio, subs, and formats commands.