SuperAPI AI Directory

youtube-podcast-extraction

Writing & research

View repository

Updated 10-16 01:34

About this skill

Workflow (Optimized SOP v2.0)

This Skill uses a four-stage SOP process to ensure automated delivery from raw video to advanced visualization results.

📍 Stage 1: Data Prep

  1. Use yt-dlp to get the video title and create the task directory.
  2. Download English VTT subtitles, call clean_subs.py to perform word-window sliding deduplication, and generate transcript_en.txt and timestamp_map.json. 3. Download the video file and save it as video.mp4。
    • Reliability Tip: Prefer using -f 18 or -f "best[height<=720][ext=mp4]" to ensure extremely fast downloads and no merging process.

📍 Stage 2: Deep Analysis

  1. Multi-level Processing Strategy: Automatically adjust extraction density based on video length:
    • Short videos (<10min): Perform structured translation of the original text and retain the complete logical skeleton.
    • Medium-length videos (10-30min): Perform approximately 60% high-fidelity core extraction, balancing detail and efficiency.
    • Ultra-long podcasts (>30min): Perform approximately 40% chapter-based deep extraction, focusing on strategic-level insights.
  2. Generate the core extraction document transcript_zh.md。
    • Quote Standards: The key quote section must retain the original bilingual Chinese and English text.
  3. Execute Pyramid Principle analysis and generate pyramid_analysis_zh.md。
  4. Key Task: Extract 5-7 core quotes from the analysis, ensure the English part matches the original subtitle text verbatim, and save them to quotes_list.json。

📍 Stage 3: Asset Generation

  1. Call generate_quotes_pro.js for rendering.
  2. Automation Logic: FFmpeg extracts the original frame based on the precise timestamp -> Playwright loads the cinematic HTML template -> Base64 embeds the background image -> Explicitly wait for image loading to complete (Wait for Load) -> Render and save as quotes/quote_n.jpg。
    • Technical Details: When extracting with FFmpeg, add a +0.5s offset to avoid potential transition black screens, and ensure the screenshot is highly synchronized with the subtitle content.

📍 Stage 4: Final Delivery

  1. Backfill the generated quote card references into pyramid_analysis_zh.md and transcript_zh.md。
  2. Generate multi-platform publishing copy publish_content.md(including adapted versions for Zhihu, Xiaohongshu, and Twitter).
  3. Clean up intermediate temporary files such as VTT.
Visual Standards (Cinema Style)
  • Design Specifications: Strictly follow the visual guidelines defined by visual_standard.md .
  • Typography Requirements: Left-aligned layout, English (38px Italic) on top, Chinese (28px Regular) below, with a 5px red decorative bar on the left.
  • Overlay Design: A dark gradient overlay on the bottom 1/3, with the footer containing a red pill label + video title.
Technical Specifications
  • Deduplication Logic: The word-window overlap algorithm must be used; simple line deduplication is strictly prohibited.
  • Rendering Engine: It is strictly prohibited to use ImageMagick to process text; rendering must go through the Playwright workflow to ensure font quality.
  • Positioning accuracy: Use a dedicated timestamp lookup script to precisely locate the position of key quotes.
  • Output constraints: All output files (.md, .html, .txt) are strictly prohibited from using Emoji to ensure professionalism.
Deliverables list
  • transcript_en.txt / timestamp_map.json (cleaned text and mapping)
  • transcript_zh.md (in-depth Chinese-English bilingual translation)
  • pyramid_analysis_zh.md (in-depth analysis with key quote cards embedded)
  • quotes/ (including final beautified images and index.md)
  • publish_content.md (multi-platform distribution copy)
Reference materials