🎁 Get the FREE AI Skills Starter Guide β€” Subscribe β†’
BytesAgainBytesAgain
πŸ¦€ ClawHub

tube-summary

by @dillera

Search YouTube videos on any topic, extract English subtitles, and generate detailed summaries with key topics, quotes, and timestamps.

Versionv1.0.0
Downloads3,090
Stars⭐ 2
Comments1
TERMINAL
clawhub install tube-summary

πŸ“– About This Skill


name: tube-summary description: Search YouTube for videos on any topic and get intelligent summaries from video subtitles. Use when you need to: (1) Find and preview YouTube videos on a subject, (2) Get a detailed description of what a video covers based on its actual content, (3) Quickly understand video topics without watching. Workflow: search YouTube β†’ pick a video β†’ extract and summarize subtitles.

tube-summary

Search YouTube for videos on any topic, then extract and summarize their content using subtitles.

Quick Start

Step 1: Search for Videos

When asked about a topic, search YouTube and list the top 10 results:

python3 scripts/youtube-search.py "your search query"

This returns a numbered list of videos with titles, channels, and view counts.

Step 2: User Picks a Video

The user selects one video by number (e.g., "3" for the third video).

Step 3: Download Subtitles

Extract English subtitles from the selected video using yt-dlp:

yt-dlp --write-subs --sub-langs en --skip-download "VIDEO_URL"

This creates a .en.vtt subtitle file without downloading the video.

Step 4: Process & Summarize

Use the subtitle processor to analyze and summarize:

python3 scripts/process-subtitles.py "path/to/subtitle-file.vtt"

This generates:

  • Key Topics: Main subjects covered in the video
  • Summary: Concise 2-3 paragraph description of content
  • Timestamps: Notable moments with context
  • Key Quotes: Important statements from speakers
  • Workflow

    1. Search β†’ youtube-search.py "" β†’ Display top 10 videos 2. User selects β†’ e.g., "Video 5" 3. Extract URL β†’ From the search results 4. Download subs β†’ yt-dlp --write-subs --sub-langs en --skip-download "URL" 5. Process β†’ process-subtitles.py "subtitle.vtt" 6. Present β†’ Formatted summary with key points

    Prerequisites

  • yt-dlp (install: pip install yt-dlp)
  • requests (for YouTube search fallback)
  • Python 3.7+
  • Notes

  • If YouTube search API is unavailable, the fallback uses web scraping via requests
  • Subtitles may be auto-generated if not manually authored
  • Some videos may not have English subtitles available
  • The subtitle file is created in the same directory as yt-dlp is run
  • Example Usage

    User: "Tell me about Rust programming language"

    β†’ Search returns 10 videos about Rust

    User: "Summarize video 3"

    β†’ Downloads subtitles from video 3 β†’ Processes and returns detailed summary

    πŸ’‘ Examples

    Step 1: Search for Videos

    When asked about a topic, search YouTube and list the top 10 results:

    python3 scripts/youtube-search.py "your search query"
    

    This returns a numbered list of videos with titles, channels, and view counts.

    Step 2: User Picks a Video

    The user selects one video by number (e.g., "3" for the third video).

    Step 3: Download Subtitles

    Extract English subtitles from the selected video using yt-dlp:

    yt-dlp --write-subs --sub-langs en --skip-download "VIDEO_URL"
    

    This creates a .en.vtt subtitle file without downloading the video.

    Step 4: Process & Summarize

    Use the subtitle processor to analyze and summarize:

    python3 scripts/process-subtitles.py "path/to/subtitle-file.vtt"
    

    This generates:

  • Key Topics: Main subjects covered in the video
  • Summary: Concise 2-3 paragraph description of content
  • Timestamps: Notable moments with context
  • Key Quotes: Important statements from speakers
  • βš™οΈ Configuration

  • yt-dlp (install: pip install yt-dlp)
  • requests (for YouTube search fallback)
  • Python 3.7+
  • πŸ“‹ Tips & Best Practices

  • If YouTube search API is unavailable, the fallback uses web scraping via requests
  • Subtitles may be auto-generated if not manually authored
  • Some videos may not have English subtitles available
  • The subtitle file is created in the same directory as yt-dlp is run