Communitygithub.com

Desesbraker/agentes-vip

從 YouTube 影片中擷取逐字稿,並使用智慧分析框架生成詳盡的摘要。

agentes-vip 是什麼?

這個名為「youtube-summarizer」的技能,其主要功能是從 YouTube 影片中提取逐字稿(transcript),並運用進階的 STAR + R-I-S-E 分析框架,自動生成結構化且詳盡的摘要。對於需要深入分析教學影片、講座、課程或資訊性內容的使用者來說,這項技能非常實用。它會先驗證影片網址的有效性,並檢查影片是否能提供逐字稿。支援的語言如 Python,依賴於 `youtube-transcript-api` 函式庫來執行擷取工作。處理流程分為五個步驟:驗證網址、檢查影片可用性、提取逐字稿、應用框架生成摘要,以及格式化輸出為 Markdown 文件。最終輸出會包含影片標題、頻道、連結等後設資料,以及按主題分類的詳細分析、關鍵概念和結論。此技能設計上優先考慮分析的完整性與詳細程度,而非簡潔性,因此非常適合用來建立影片內容的參考文檔,無需重看影片即可掌握精髓。它主要應用於 Claude Code 等 AI 代理平台。

相容平台✓Claude Code~Codex CLI~Cursor
npx skills add https://github.com/Desesbraker/agentes-vip/tree/HEAD/full%20skill/plugins/antigravity-awesome-skills-claude/skills/youtube-summarizer

在你喜歡的 AI 中提問

開啟一個已預先載入此 Agent Skill 的新對話。

說明文件

youtube-summarizer

目的

此技能從 YouTube 影片中提取逐字稿,並使用 STAR + R-I-S-E 框架生成詳盡且完整的摘要。它會驗證影片的可用性,使用 youtube-transcript-api Python 函式庫提取逐字稿,並產生捕捉所有見解、論點和關鍵點的詳細文件。

此技能專為需要從教育影片、講座、教學課程或資訊性內容中進行全面內容分析與建立參考文檔的使用者而設計。

使用時機

遇到以下情況時應使用此技能:

  • 使用者提供 YouTube 影片網址,並希望獲得詳細摘要
  • 使用者需要記錄影片內容以供參考,無需重新觀看
  • 使用者希望從教育內容中提取見解、關鍵點和論點
  • 使用者需要從 YouTube 影片中取得逐字稿以進行分析
  • 使用者要求「總結」、「摘要」或「提取內容」來自 YouTube 影片
  • 使用者希望獲得優先考慮完整性的詳盡文檔

步驟 0:發現與設定

在處理影片前,請先驗證環境與依賴項:

# 檢查是否已安裝 youtube-transcript-api
python3 -c "import youtube_transcript_api" 2>/dev/null
if [ $? -ne 0 ]; then
    echo "⚠️  youtube-transcript-api not found"
    # 提供安裝選項
fi

# 檢查 Python 是否可用
if ! command -v python3 &>/dev/null; then
    echo "❌ Python 3 is required but not installed"
    exit 1
fi

如果缺少依賴項,請詢問使用者:

youtube-transcript-api 是必需的,但尚未安裝。

您要現在安裝嗎?
- [ ] 是 - 使用 pip 安裝 (pip install youtube-transcript-api)
- [ ] 否 - 我會手動安裝

如果使用者選擇「是」:

pip install youtube-transcript-api

驗證安裝:

python3 -c "import youtube_transcript_api; print('✅ youtube-transcript-api installed successfully')"

主要工作流程

進度追蹤指南

在整個工作流程中,請在每個步驟前顯示視覺進度條,讓使用者了解進度。進度條格式如下:

echo "[████░░░░░░░░░░░░░░░░] 20% - Step 1/5: Validating URL"

格式規範:

  • 寬度 20 個字元(使用 █ 表示已完成,░ 表示未完成)
  • 百分比增量:步驟 1=20%,步驟 2=40%,步驟 3=60%,步驟 4=80%,步驟 5=100%
  • 顯示當前/總步驟數(例如 "Step 3/5")
  • 當前階段的簡短描述

在步驟 1 之前顯示初始狀態框:

╔══════════════════════════════════════════════════════════════╗
║     📹  YOUTUBE SUMMARIZER - Processing Video                ║
╠══════════════════════════════════════════════════════════════╣
║ → Step 1: Validating URL                 [IN PROGRESS]       ║
║ ○ Step 2: Checking Availability                              ║
║ ○ Step 3: Extracting Transcript                              ║
║ ○ Step 4: Generating Summary                                 ║
║ ○ Step 5: Formatting Output                                  ║
╠══════════════════════════════════════════════════════════════╣
║ Progress: ██████░░░░░░░░░░░░░░░░░░░░░░░░  20%               ║
╚══════════════════════════════════════════════════════════════╝

步驟 1:驗證 YouTube 網址

目標: 提取影片 ID 並驗證網址格式。

支援的網址格式:

  • https://www.youtube.com/watch?v=VIDEO_ID
  • https://youtube.com/watch?v=VIDEO_ID
  • https://youtu.be/VIDEO_ID
  • https://m.youtube.com/watch?v=VIDEO_ID

操作:

# 使用正規表達式或 URL 解析來提取影片 ID
URL="$USER_PROVIDED_URL"

# 格式 1: youtube.com/watch?v=VIDEO_ID
if echo "$URL" | grep -qE 'youtube\.com/watch\?v='; then
    VIDEO_ID=$(echo "$URL" | sed -E 's/.*[?&]v=([^&]+).*/\1/')
# 格式 2: youtu.be/VIDEO_ID  
elif echo "$URL" | grep -qE 'youtu\.be/'; then
    VIDEO_ID=$(echo "$URL" | sed -E 's/.*youtu\.be\/([^?]+).*/\1/')
else
    echo "❌ Invalid YouTube URL format"
    exit 1
fi

echo "📹 Video ID extracted: $VIDEO_ID"

如果網址無效:

❌ Invalid YouTube URL

請提供一個有效的 YouTube 網址,格式如下:
- https://www.youtube.com/watch?v=VIDEO_ID
- https://youtu.be/VIDEO_ID

範例:https://www.youtube.com/watch?v=dQw4w9WgXcQ

步驟 2:檢查影片與逐字稿可用性

進度:

echo "[████████░░░░░░░░░░░░] 40% - Step 2/5: Checking Availability"

目標: 驗證影片是否存在且逐字稿可存取。

操作:

from youtube_transcript_api import YouTubeTranscriptApi, TranscriptsDisabled, NoTranscriptFound
import sys

video_id = sys.argv[1]

try:
    # 取得可用的逐字稿列表
    transcript_list = YouTubeTranscriptApi.list_transcripts(video_id)
    
    print(f"✅ Video accessible: {video_id}")
    print("📝 Available transcripts:")
    
    for transcript in transcript_list:
        print(f"  - {transcript.language} ({transcript.language_code})")
        if transcript.is_generated:
            print("    [Auto-generated]")
    
except TranscriptsDisabled:
    print(f"❌ Transcripts are disabled for video {video_id}")
    sys.exit(1)
    
except NoTranscriptFound:
    print(f"❌ No transcript found for video {video_id}")
    sys.exit(1)
    
except Exception as e:
    print(f"❌ Error accessing video: {e}")
    sys.exit(1)

錯誤處理:

錯誤訊息行動
找不到影片"❌ Video does not exist or is private"要求使用者確認網址
逐字稿已停用"❌ Transcripts are disabled for this video"無法繼續
無可用逐字稿"❌ No transcript found (not auto-generated or manually added)"無法繼續
私人/受限制的影片"❌ Video is private or restricted"要求提供公開影片

步驟 3:提取逐字稿

進度:

echo "[████████████░░░░░░░░] 60% - Step 3/5: Extracting Transcript"

目標: 以偏好的語言檢索逐字稿。

操作:

from youtube_transcript_api import YouTubeTranscriptApi

video_id = "VIDEO_ID"

try:
    # 首先嘗試以使用者偏好的語言取得逐字稿
    # 如果不可用,則回退到英文
    transcript = YouTubeTranscriptApi.get_transcript(
        video_id, 
        languages=['pt', 'en']  # 首選葡萄牙語,回退到英文
    )
    
    # 將逐字稿片段合併為完整文字
    full_text = " ".join([entry['text'] for entry in transcript])
    
    # 取得影片後設資料
    from youtube_transcript_api import YouTubeTranscriptApi
    transcript_list = YouTubeTranscriptApi.list_transcripts(video_id)
    
    print("✅ Transcript extracted successfully")
    print(f"📊 Transcript length: {len(full_text)} characters")
    
    # 儲存到臨時檔案以供處理
    with open(f"/tmp/transcript_{video_id}.txt", "w") as f:
        f.write(full_text)
    
except Exception as e:
    print(f"❌ Error extracting transcript: {e}")
    exit(1)

逐字稿處理:

  • 將所有逐字稿片段合併為連貫的文字
  • 盡可能保留標點符號和格式
  • 移除重複或重疊的片段(如果是自動生成的產物)
  • 儲存到臨時檔案以供分析

步驟 4:生成綜合摘要

進度:

echo "[████████████████░░░░] 80% - Step 4/5: Generating Summary"

目標: 應用增強的 STAR + R-I-S-E 提示來建立詳細摘要。

應用的提示:

使用第二階段(STAR + R-I-S-E 框架)的增強提示,並將提取的逐字稿作為輸入。

操作:

  1. 載入完整的逐字稿文字
  2. 應用全面的摘要提示
  3. 使用 AI 模型(Claude/GPT)生成結構化摘要
  4. 確保輸出遵循定義的結構:
    • 包含影片後設資料的標題
    • 執行摘要
    • 詳細的逐段分析
    • 關鍵見解與結論
    • 概念與術語
    • 資源與參考資料

實作:

# 使用逐字稿檔案作為 AI 提示的輸入
TRANSCRIPT_FILE="/tmp/transcript_${VIDEO_ID}.txt"

# AI 代理將:
# 1. 讀取逐字稿
# 2. 應用 STAR + R-I-S-E 摘要框架
# 3. 生成全面的 Markdown 輸出
# 4. 使用標題、列表和高亮進行結構化

Read "$TRANSCRIPT_FILE"  # 將逐字稿讀入上下文

然後應用完整的摘要提示(來自第二階段的增強版本)。

步驟 5:格式化並呈現輸出

進度:

echo "[████████████████████] 100% - Step 5/5: Formatting Output"

目標: 以乾淨、結構良好的 Markdown 格式提供摘要。

輸出結構:

# [影片標題]

**頻道:** [頻道名稱]  
**長度:** [持續時間]  
**網址:** [https://youtube.com/watch?v=VIDEO_ID]  
**發布日期:** [如果有的話]


## 📝 詳細摘要

### [主題 1]

[包含範例、資料、引用的詳細說明...]

#### [子主題 1.1]

[詳細分析...]

### [主題 2]

[繼續詳細分析...]


## 📚 概念與術語

- **[術語 1]:** [定義與上下文]
- **[術語 2]:** [定義與上下文]


## 📌 結論

[最終綜合與重點摘要]

範例 2:缺少依賴項

使用者輸入:

claude> summarize this youtube video https://youtu.be/abc123

技能回應:

⚠️  youtube-transcript-api not installed

此技能需要 Python 函式庫 'youtube-transcript-api'。

您要現在安裝嗎?
- [ ] 是 - 使用 pip 安裝
- [ ] 否 - 我會手動安裝

使用者選擇「是」:

$ pip install youtube-transcript-api
Successfully installed youtube-transcript-api-0.6.1

✅ Installation complete! Proceeding with video summary...

範例 4:無效的網址

使用者輸入:

claude> summarize youtube video www.youtube.com/some-video

技能回應:

❌ Invalid YouTube URL format

預期的格式範例:
- https://www.youtube.com/watch?v=VIDEO_ID
- https://youtu.be/VIDEO_ID

請提供有效的 YouTube 影片網址。

📊 執行摘要

本影片提供了人工智慧(AI)基本概念的全面介紹,專為想要了解現代 AI 技術基礎與實際應用的初學者和專業人士設計。講師涵蓋了從基本定義到機器學習演算法的所有內容,並使用實際範例和視覺化來促進理解。

[... 繼續詳細摘要 ...]

儲存選項:

您想儲存什麼?
→ 摘要 + 原始逐字稿

✅ 檔案已儲存:resumo-exemplo123-2026-02-01.md (包含原始逐字稿)
[████████████████████] 100% - ✓ Processing complete!

歡迎來到這個關於機器學習基礎的全面教學。在今天的影片中,我們將探討驅動現代 AI 系統的核心概念...


版本: 1.2.0 最後更新: 2026-02-02 維護者: Eric Andrade

Individual skills in this repo

This repo contains 16 individual skills — each has its own dedicated page.

Desesbraker/agentes-vip

Skill for discovering and researching autonomous AI agents, tools, and ecosystems using the AgentFolio directory.

Desesbraker/agentes-vip

Advanced JavaScript animation library skill for creating complex, high-performance web animations.

Desesbraker/agentes-vip

Audit and fix animation performance issues including layout thrashing, compositor properties, scroll-linked motion, and blur effects. Use when animations stutter, transitions jank, or reviewing CSS/JS animation performance.

Desesbraker/agentes-vip

Internationalization and localization patterns. Detecting hardcoded strings, managing translations, locale files, RTL support.

Desesbraker/agentes-vip

AI-powered animation tool for creating motion in logos, UI, icons, and social media assets.

Desesbraker/agentes-vip

CRITICAL: Use for Makepad animation system. Triggers on: makepad animation, makepad animator, makepad hover, makepad state, makepad transition, "from: { all: Forward", makepad pressed, makepad 动画, makepad 状态, makepad 过渡, makepad 悬停效果

Desesbraker/agentes-vip

Best practices for Remotion - Video creation in React

Desesbraker/agentes-vip

Generate walkthrough videos from Stitch projects using Remotion with smooth transitions, zooming, and text overlays

Desesbraker/agentes-vip

Seek and analyze video content using Memories.ai Large Visual Memory Model for persistent video intelligence

Desesbraker/agentes-vip

Three.js animation - keyframe animation, skeletal animation, morph targets, animation mixing. Use when animating objects, playing GLTF animations, creating procedural motion, or blending animations.

Desesbraker/agentes-vip

Automate TikTok tasks via Rube MCP (Composio): upload/publish videos, post photos, manage content, and view user profiles/stats. Always search tools first for current schemas.

Desesbraker/agentes-vip

Video and audio perception, indexing, and editing. Ingest files/URLs/live streams, build visual/spoken indexes, search with timestamps, edit timelines, add overlays/subtitles, generate media, and create real-time alerts.

Desesbraker/agentes-vip

Upload, stream, search, edit, transcribe, and generate AI video and audio using the VideoDB SDK.

Desesbraker/agentes-vip

Automate YouTube tasks via Rube MCP (Composio): upload videos, manage playlists, search content, get analytics, and handle comments. Always search tools first for current schemas.

Desesbraker/agentes-vip

Generates high-converting Next.js/React landing pages with Tailwind CSS. Uses PAS, AIDA, and BAB frameworks for optimized copy/components (Heroes, Features, Pricing). Focuses on Core Web Vitals/SEO.

Desesbraker/agentes-vip

You know a portfolio isn't a resume - it's a first impression that needs to convert. You balance creativity with usability. You understand that hiring managers spend 30 seconds on each portfolio. You make those 30 seconds count. You help people stand out without being gimmicky.

相關技能