Logo Youtube Podcast Ingestion

Youtube Podcast Ingestion

Cộng đồng
uzairansaruzi
youtube-podcast-ingestion

Đưa podcast trên YouTube vào cơ sở tri thức — lấy bản chép lời, tách theo người nói/chương, tạo bản tóm tắt và lưu vào bất kỳ kho markdown nào (chẳng hạn Obsidian). Dùng khi người dùng chia sẻ URL podcast, muốn đưa một cuộc phỏng vấn/tập phát sóng trên YouTube vào cơ sở tri thức hoặc muốn lưu trữ nội dung nói dài để tham khảo sau này.

Add to TypingMind

Tổng quan

Nhà phát hànhuzairansaruzi
Kho mãyoutube-ingest
Tên kỹ năngyoutube-podcast-ingestion
Sao
29
Bản fork
4
Tệp đi kèm
2
Giấy phépMIT
Liên kết
  • Hướng dẫn bằng Markdown

    Tệp SKILL.md được mô hình tải khi cần, nên chỉ tốn token khi có yêu cầu thực sự phù hợp.

  • Dùng được với mọi LLM

    Kỹ năng AI dùng hướng dẫn viết bằng Markdown thay vì mã dành riêng cho một nhà cung cấp, nên dùng được với GPT, Claude, Gemini, Grok hoặc mô hình cục bộ.

  • 2 tệp đi kèm

    Các tập lệnh, mẫu và tài liệu tham khảo mà mô hình có thể đọc khi làm việc. Các tệp chỉ cho phép đọc và không bao giờ được thực thi.

  • Mã nguồn mở

    Được uzairansaruzi công bố trên GitHub. Hãy đọc các tệp nguồn trước khi cài đặt.

Cài đặt

Cài đặt kỹ năng AI Youtube Podcast Ingestion trong TypingMind để dùng với bất kỳ LLM nào, hoặc thêm vào một tác nhân AI khác có thể đọc SKILL.md.

1

Cài đặt trong TypingMind

TypingMind cài đặt kỹ năng trực tiếp từ thư mục GitHub — đọc SKILL.md, đóng gói các tệp tài nguyên và lưu kết quả trên máy.

  1. Mở ứng dụng và vào Plugin → Kỹ năng.
  2. Chọn "Cài đặt từ GitHub".
  3. Dán URL của thư mục kỹ năng được hiển thị bên dưới rồi xác nhận.
    https://github.com/uzairansaruzi/youtube-ingest/tree/main
  4. Bật kỹ năng trong từng cuộc trò chuyện mà bạn muốn sử dụng kỹ năng đó.
Plugin → Kỹ năng → Thêm kỹ năng → Từ URL GitHub, sau đó dán URL thư mục và nhấn Tiếp tục.
2

Cài đặt trong tác nhân AI khác

Bất kỳ tác nhân AI nào đọc được định dạng Agent Skills đều có thể dùng kỹ năng này — hãy sao chép thư mục vào thư mục kỹ năng của tác nhân AI đó.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/uzairansaruzi/youtube-ingest.git \
  .claude/skills/youtube-podcast-ingestion
Khởi động lại Claude Code sau khi sao chép để ứng dụng nhận kỹ năng mới.

Sử dụng trong TypingMind

Bật Youtube Podcast Ingestion trong bất kỳ cuộc trò chuyện nào trên TypingMind, mô hình sẽ tự xử lý phần còn lại. Tên và mô tả của kỹ năng nằm trong prompt hệ thống. Ngay khi có yêu cầu phù hợp, mô hình tự tải toàn bộ hướng dẫn — bạn không cần gọi thủ công và kỹ năng không tốn token cho đến khi thực sự được dùng.

Mô hình tự nạp Youtube Podcast Ingestion ngay khi có yêu cầu phù hợp.

Dùng được với mọi mô hình AI

Kỹ năng AI là các hướng dẫn Markdown thuần túy, không phải mã dành riêng cho một nhà cung cấp, nên bạn có thể dùng Youtube Podcast Ingestion với cả những mô hình khác ngoài mô hình ban đầu. Chỉ cần cài đặt một lần trong TypingMind rồi dùng với GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama hoặc mô hình cục bộ do bạn tự chạy — tất cả đều dùng khóa API của riêng bạn.

  • Chỉ tải khi cần

    Prompt hệ thống chỉ chứa tên và mô tả. Hướng dẫn được tải khi có yêu cầu phù hợp đầu tiên, nên khi kỹ năng chưa được dùng, bạn không tốn token cho phần hướng dẫn.

  • Đổi mô hình ngay trong cuộc trò chuyện

    Vì kỹ năng là hướng dẫn chứ không phải mã, việc đổi mô hình không làm kỹ năng ngừng hoạt động — mô hình tiếp theo vẫn đọc cùng tệp SKILL.md.

Hướng dẫn của kỹ năng

Đây là nội dung SKILL.md mà mô hình tải. Hãy đọc trước khi cài đặt — kỹ năng là những hướng dẫn mà mô hình của bạn sẽ làm theo.

YouTube Podcast Ingestion

Ingest YouTube podcasts, interviews, and long-form spoken content into a structured markdown knowledge base. Extracts transcripts, identifies speakers and chapters, generates summaries, and saves everything as linked markdown files.

Prerequisites

bash
pip install youtube-transcript-api

Optional but recommended:

bash
pip install openai  # for AI-powered speaker identification & chaptering

Overview

This skill handles the full pipeline for podcast ingestion:

  1. Fetch — extract transcript from any YouTube URL (standard, shorts, live, embed, youtu.be)
  2. Chunk — split long transcripts into manageable segments by time or topic
  3. Structure — identify speakers, chapters, and key segments
  4. Summarize — generate per-chapter and full-episode summaries
  5. Save — write structured markdown to your vault with frontmatter, tags, and backlinks

When to Use

  • User shares a podcast, interview, or long-form YouTube URL
  • User says "ingest this podcast" or "save this episode"
  • User wants to build a personal knowledge base from spoken content
  • User references a podcast episode and wants it searchable in Obsidian

Don't use for: Short clips under 5 minutes (use youtube-content instead), music videos, or videos without spoken dialogue.

Quick Start

bash
# Ingest a podcast episode
python3 scripts/ingest.py "https://youtube.com/watch?v=VIDEO_ID" --vault ~/obsidian-vault/Podcasts

# With speaker identification (requires OpenAI API key)
python3 scripts/ingest.py "URL" --vault ~/obsidian-vault/Podcasts --identify-speakers --api-key $OPENAI_API_KEY

# Just fetch and preview, don't save
python3 scripts/ingest.py "URL" --dry-run

Set Your Vault Path

The --vault flag points to any directory you choose. Examples:

bash
# Obsidian vault (iCloud or local)
python3 scripts/ingest.py "URL" --vault ~/Library/Mobile\ Documents/iCloud~md~obsidian/Documents/MyVault/Podcasts

# Any local folder
python3 scripts/ingest.py "URL" --vault ~/Documents/podcast-notes

# Current directory
python3 scripts/ingest.py "URL" --vault .

You can also set a default in ~/.config/youtube-podcast-ingestion/config.yaml:

yaml
vault_path: ~/obsidian-vault/Podcasts

The Ingestion Pipeline

1. Fetch Transcript

Uses youtube-transcript-api to extract the full transcript. Handles:

  • Auto-generated and manual captions
  • Language fallback (e.g., --language en,tr)
  • Any YouTube URL format
bash
python3 scripts/fetch_transcript.py "URL" --timestamps

2. Detect Chapters

YouTube chapters (if present) are extracted from the video description. If no chapters exist, the script can optionally generate them via AI or use fixed time windows.

From description (free):

bash
python3 scripts/ingest.py "URL" --vault ~/vault --chapters-from-description

AI-generated (requires API key):

bash
python3 scripts/ingest.py "URL" --vault ~/vault --generate-chapters --api-key $OPENAI_API_KEY

Fixed windows (free, deterministic):

bash
python3 scripts/ingest.py "URL" --vault ~/vault --chunk-minutes 10

3. Identify Speakers

For multi-speaker podcasts, speaker labels can be inferred from:

  • AI diarization (best quality, requires API key)
  • Pattern heuristics (free, catches "Host:" and "Guest:" patterns in transcript)
  • Manual override via --speakers "Host Name,Guest Name"
bash
python3 scripts/ingest.py "URL" --vault ~/vault --speakers "Lex Fridman,Elon Musk"

4. Generate Summaries

Summaries are generated at three levels:

  • Episode summary — 3-5 sentence overview
  • Chapter summaries — one paragraph per chapter
  • Key quotes — notable statements with timestamps

AI-powered (default if --api-key provided):

bash
python3 scripts/ingest.py "URL" --vault ~/vault --api-key $OPENAI_API_KEY

Template-based (free, no API key):

  • Uses simple extractive summarization: first/last sentences of each chapter + longest sentence as key quote

5. Save to Vault

Output is a markdown file with YAML frontmatter:

markdown
---
title: "Podcast Title"
channel: "Channel Name"
date: "2026-05-01"
duration: "2:34:56"
url: "https://youtube.com/watch?v=..."
tags: [podcast, ai, interview]
speakers: ["Lex Fridman", "Elon Musk"]
chapters:
  - title: "Introduction"
    start: "0:00"
    end: "5:30"
    summary: "Host introduces the guest and topics."
---

# Podcast Title

## Episode Summary

[AI or template-generated summary]

## Chapters

### Introduction (0:00 - 5:30)

**Summary:** Host introduces the guest and topics.

**Key Quotes:**
- "..." — Speaker Name (0:45)

**Transcript:**
> [Timestamped transcript excerpt]

---

### [Next Chapter] ...

## Full Transcript

<details>
<summary>Click to expand full transcript</summary>

[Complete transcript with timestamps]

</details>

Configuration

Create a config file at ~/.config/youtube-podcast-ingestion/config.yaml:

yaml
vault_path: ~/obsidian-vault/Podcasts
api_key: ${OPENAI_API_KEY}  # env var substitution
model: gpt-4o-mini
default_tags: [podcast, ingested]
chunk_minutes: 15
speaker_detection: heuristic  # heuristic | ai | none
chapter_source: description   # description | ai | fixed

Or pass all options as CLI flags — the script never requires a config file.

CLI Reference

usage: ingest.py [-h] [--vault VAULT] [--config CONFIG] [--dry-run]
                 [--tags TAGS] [--api-key API_KEY] [--model MODEL]
                 [--speakers SPEAKERS] [--identify-speakers]
                 [--chapters-from-description] [--generate-chapters]
                 [--chunk-minutes CHUNK_MINUTES] [--language LANGUAGE]
                 url

positional arguments:
  url                   YouTube URL or video ID

options:
  -h, --help            show this help message and exit
  --vault VAULT         Output directory for markdown file (default: current dir)
  --config CONFIG       Path to config YAML
  --dry-run             Print output without saving
  --tags TAGS           Comma-separated tags (default: podcast)
  --api-key API_KEY     OpenAI API key for AI features
  --model MODEL         OpenAI model (default: gpt-4o-mini)
  --speakers SPEAKERS   Comma-separated speaker names
  --identify-speakers   Auto-detect speakers (requires --api-key)
  --chapters-from-description
                        Extract chapters from video description
  --generate-chapters   AI-generate chapters (requires --api-key)
  --chunk-minutes CHUNK_MINUTES
                        Fixed chunk size in minutes (default: 15)
  --language LANGUAGE   Comma-separated language codes (default: en)

Workflows

Ingest to Obsidian

bash
python3 scripts/ingest.py "https://youtube.com/watch?v=..." \
  --vault ~/obsidian-vault/Podcasts \
  --tags podcast,ai,interview \
  --chapters-from-description

File is saved as ~/obsidian-vault/Podcasts/YYYY-MM-DD-podcast-title.md with full frontmatter.

Ingest with AI Summaries

bash
export OPENAI_API_KEY="***"
python3 scripts/ingest.py "URL" \
  --vault ~/obsidian-vault/Podcasts \
  --generate-chapters \
  --identify-speakers \
  --tags podcast,ai

Batch Ingest a Playlist

bash
for url in $(cat podcast_urls.txt); do
  python3 scripts/ingest.py "$url" --vault ~/obsidian-vault/Podcasts --chapters-from-description
done

Preview Before Saving

bash
python3 scripts/ingest.py "URL" --dry-run | head -100

Output Structure

~/obsidian-vault/
└── Podcasts/
    ├── 2026-05-01-lex-fridman-elon-musk.md
    ├── 2026-04-28-huberman-sleep.md
    └── .index/
        └── podcast-index.md   # auto-generated backlinks index

The optional .index/podcast-index.md is updated on each ingestion and links all episodes by tag, channel, and speaker for graph navigation in Obsidian.

Pitfalls

  1. Transcript disabled: Some podcasts disable auto-captions. The script exits with a clear error — check if the video has manual subtitles available.

  2. AI costs add up: For 3-hour podcasts, AI chaptering + speaker ID + summarization can use 50K tokens. Use --model gpt-4o-mini (default) to keep costs low ($0.03/episode).

  3. YouTube chapters are user-defined: Not all podcasts have chapters. The --chapters-from-description flag falls back to --chunk-minutes if no chapters are found.

  4. Speaker identification is heuristic by default: Without --api-key, speakers are guessed from transcript patterns (e.g., "Host:" prefixes). This is often wrong for unstructured conversations. Use --speakers for manual override or --identify-speakers with an API key.

  5. Large transcripts: Episodes over 4 hours can produce markdown files >1MB. Obsidian handles them fine, but mobile sync may lag. Use --chunk-minutes to split into multiple files if needed.

  6. ASR hallucinations: Auto-generated transcripts mishear tech names. Common issues documented in youtube-content skill apply — "xAI" becomes "SpaceX", product names get mangled. Always spot-check key quotes before citing.

  7. Rate limits: youtube-transcript-api has no explicit rate limit, but bulk ingestion (>50 videos/hour) can trigger IP throttling. Add sleep 5 between requests in batch scripts.

Verification Checklist

  • pip install youtube-transcript-api installed
  • Target --vault directory exists and is writable
  • Episode markdown file created with correct frontmatter
  • Chapters align with actual content (spot-check 2-3 chapters)
  • Key quotes are correctly attributed and timestamped
  • Obsidian graph shows the new node and backlinks
  • .index/podcast-index.md updated (if using --update-index)

Tệp đi kèm

Khi kỹ năng đã được tải, mô hình có thể đọc các tệp này nếu cần. Các tệp này chỉ dùng để đọc và không bao giờ được thực thi.

Câu hỏi thường gặp

Kỹ năng AI Youtube Podcast Ingestion làm được gì?

Đưa podcast trên YouTube vào cơ sở tri thức — lấy bản chép lời, tách theo người nói/chương, tạo bản tóm tắt và lưu vào bất kỳ kho markdown nào (chẳng hạn Obsidian). Dùng khi người dùng chia sẻ URL podcast, muốn đưa một cuộc phỏng vấn/tập phát sóng trên YouTube vào cơ sở tri thức hoặc muốn lưu trữ nội dung nói dài để tham khảo sau này.

Vì sao nên dùng Youtube Podcast Ingestion trên TypingMind?

Vì bạn chỉ cần cài một lần rồi dùng với bất kỳ mô hình nào. Youtube Podcast Ingestion là nội dung Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên cùng một kỹ năng có thể chạy trên GPT-5, Claude, Gemini, Grok hoặc mô hình trên thiết bị — và bạn có thể đổi mô hình ngay trong cuộc trò chuyện mà kỹ năng vẫn hoạt động. TypingMind dùng khóa API riêng của bạn, nên bạn thanh toán trực tiếp cho nhà cung cấp thay vì trả phí thuê bao theo suất người dùng, đồng thời kỹ năng và các cuộc trò chuyện vẫn nằm trong bộ lưu trữ của bạn.

Làm thế nào để cài Youtube Podcast Ingestion trong TypingMind?

Mở Plugin → Kỹ năng → Cài đặt từ GitHub trong TypingMind rồi dán https://github.com/uzairansaruzi/youtube-ingest/tree/main. TypingMind đọc tệp SKILL.md, đóng gói các tệp đi kèm rồi cài đặt cả gói dưới dạng một kỹ năng mà bạn có thể bật cho từng cuộc trò chuyện.

Những mô hình AI nào có thể dùng Youtube Podcast Ingestion?

Bất kỳ mô hình nào bạn kết nối trong TypingMind. Kỹ năng AI là các hướng dẫn bằng Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên GPT, Claude, Gemini, Grok và các mô hình chạy trên thiết bị đều có thể tải kỹ năng này khi có yêu cầu phù hợp.

Có thể dùng Youtube Podcast Ingestion với bao nhiêu mô hình AI?

Bao nhiêu cũng được. Miễn là mô hình hỗ trợ kỹ năng, bạn có thể dùng Youtube Podcast Ingestion với mô hình đó — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama và nhiều mô hình khác — tất cả đều trên TypingMind với khóa API riêng của bạn.

Kỹ năng AI Youtube Podcast Ingestion có miễn phí không?

Có. Kỹ năng này được uzairansaruzi phát hành trên GitHub theo giấy phép MIT. Bạn chỉ trả tiền cho nhà cung cấp AI của mình theo số token đã dùng.

Kỹ năng AI là gì?

Kỹ năng AI là một gói hướng dẫn có thể tái sử dụng, chỉ cho mô hình AI cách thực hiện một tác vụ cụ thể. Kỹ năng tuân theo định dạng mở Agent Skills: một tệp SKILL.md chứa tên và mô tả, cùng các tập lệnh, mẫu hoặc tệp tham khảo mà mô hình có thể cần. Mô hình chỉ đọc hướng dẫn khi yêu cầu của bạn phù hợp với kỹ năng, nên kỹ năng đã cài đặt không phát sinh chi phí cho đến khi được sử dụng.

Kỹ năng AI khác gì với plugin hoặc máy chủ MCP?

Plugin hoặc máy chủ MCP cung cấp các công cụ mới mà mô hình có thể gọi. Khi mô hình gọi một công cụ, mã của công cụ đó chạy ở đâu đó và trả về kết quả. Còn kỹ năng AI cung cấp kiến thức và quy trình: cách tiếp cận tác vụ, các bước cần thực hiện và những tiêu chí mà kết quả cần đáp ứng. Kỹ năng chỉ là nội dung Markdown, nên không cần máy chủ, khóa API hay môi trường thực thi và hoạt động với mọi mô hình.

Xem tất cả

Tạo ngay không gian làm việc AI riêng

Đăng ký bản tin của chúng tôi để nhận thông báo về tính năng mới và các đợt tặng quà sắp tới 👇