PluginBench
Skill
Fail
Audit score 45

youtube-transcript

intellectronica/agent-skills

Extract transcripts from YouTube videos with optional timestamps.

What is youtube-transcript?

Fetches transcripts or captions from YouTube videos using the youtube-transcript-api. Use when a user provides a YouTube URL and asks for the transcript, subtitles, or captions. Supports both plain text and timestamped output formats.

  • Extract transcripts from YouTube videos by URL or video ID
  • Output transcripts with or without timestamps in [MM:SS] or [HH:MM:SS] format
  • Automatically use manually added captions, falling back to auto-generated ones
  • Support multiple YouTube URL formats (youtube.com/watch?v=, youtu.be/, embed URLs, or raw video IDs)
  • Save transcripts to a specified file or auto-generate filename with video ID

How to install youtube-transcript

npx skills add https://github.com/intellectronica/agent-skills --skill youtube-transcript
Prerequisites
  • youtube-transcript-api library (installed as part of skill)
  • uv package manager for running Python scripts
  • YouTube video must have captions enabled (auto-generated or manual)
Claude Code
Cursor
Windsurf
Cline

How to use youtube-transcript

  1. 1.Run the script with a YouTube URL or video ID: `uv run scripts/get_transcript.py "VIDEO_URL_OR_ID"`
  2. 2.Add the `--timestamps` flag if you need timestamps: `uv run scripts/get_transcript.py "VIDEO_URL_OR_ID" --timestamps`
  3. 3.If no output file is specified, the transcript saves automatically as `VIDEO_ID-transcript.txt`
  4. 4.For timestamped output without timestamps, clean up the transcript by arranging it into complete paragraphs and avoiding mid-sentence line breaks
  5. 5.If the user requested a specific output file, save the transcript to that file instead of the default

Use cases

Good for
  • Retrieve a transcript when a user shares a YouTube video link and asks for the text version
  • Extract timestamped captions for video editing or reference purposes
  • Get transcripts from educational or instructional videos for documentation
  • Save video captions to a file for accessibility or archival
  • Process transcripts by cleaning up sentence breaks and organizing into paragraphs
Who it's for
  • Content creators and video editors
  • Researchers and students needing video content in text form
  • Accessibility specialists preparing captions for distribution
  • Anyone needing to reference or search video content as text

youtube-transcript FAQ

What URL formats does this skill support?

It supports youtube.com/watch?v=VIDEO_ID, youtu.be/VIDEO_ID, youtube.com/embed/VIDEO_ID, and raw 11-character video IDs.

What happens if a video doesn't have manual captions?

The skill automatically falls back to auto-generated captions if manual ones aren't available.

Can I get timestamps in the transcript?

Yes, use the `--timestamps` flag to output captions in [MM:SS] format (or [HH:MM:SS] for longer videos).

Where does the transcript get saved?

By default, it saves to a file named VIDEO_ID-transcript.txt. You can specify a custom output file if needed.

Can I modify the returned transcript?

No, you must never modify the returned transcript. You may only clean up formatting (arrange into paragraphs, fix sentence breaks) if timestamps are not included.

Full instructions (SKILL.md)

Source of truth, from intellectronica/agent-skills.


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

Related skills

More from intellectronica/agent-skills and the wider catalog.