Skip to content

JimLiu/baoyu-skills / skills/baoyu-youtube-transcript

baoyu-youtube-transcript

Verified

Downloads YouTube video transcripts/subtitles and cover images by URL or video ID. Supports multiple languages, translation, chapters, and speaker identification. Caches raw data for fast re-formatting. Use when user asks to "get YouTube transcript", "download subtitles", "get captions", "YouTube字幕", "YouTube封面", "视频封面", "video thumbnail", "video cover image", or provides a YouTube URL and wants the transcript/subtitle text or cover image extracted.

FileKindSize
SKILL.mdskill md6.5 KB
prompts/speaker-transcript.mdmarkdown4.6 KB
scripts/main.test.tsscript8.5 KB
scripts/main.tsscript8.4 KB
scripts/shared.tsscript3.4 KB
scripts/storage.tsscript1.9 KB
scripts/transcript.tsscript13.5 KB
scripts/types.tsscript2.4 KB
scripts/youtube.tsscript22.4 KB

scripts/types.ts

View on GitHub
export type Format = "text" | "srt";

export interface Options {
  videoIds: string[];
  languages: string[];
  format: Format;
  translate: string;
  list: boolean;
  excludeGenerated: boolean;
  excludeManual: boolean;
  output: string;
  outputDir: string;
  timestamps: boolean;
  chapters: boolean;
  speakers: boolean;
  refresh: boolean;
}

export interface Snippet {
  text: string;
  start: number;
  duration: number;
}

export interface Sentence {
  text: string;
  start: string;
  end: string;
}

export interface TranscriptLanguage {
  language: string;
  languageCode: string;
}

export interface TranscriptInfo {
  language: string;
  languageCode: string;
  isGenerated: boolean;
  isTranslatable: boolean;
  baseUrl: string;
  translationLanguages: TranscriptLanguage[];
}

export interface Chapter {
  title: string;
  start: number;
  end: number;
}

export interface LanguageMeta {
  code: string;
  name: string;
  isGenerated: boolean;
}

export interface VideoMeta {
  videoId: string;
  title: string;
  channel: string;
  channelId: string;
  description: string;
  duration: number;
  publishDate: string;
  url: string;
  coverImage: string;
  thumbnailUrl: string;
  language: LanguageMeta;
  chapters: Chapter[];
}

export interface VideoResult {
  videoId: string;
  title?: string;
  filePath?: string;
  content?: string;
  error?: string;
}

export interface InnerTubeSession {
  apiKey: string;
  webClientVersion: string;
  visitorData: string;
}

export interface InnerTubeClient {
  id: string;
  clientName: string;
  clientVersion?: string;
  clientHeaderName?: string;
  userAgent: string;
  extraContext?: Record<string, any>;
}

export interface TranscriptError extends Error {
  code?: string;
}

export interface YtDlpTrack {
  ext?: string;
  url?: string;
  name?: string;
}

export interface YtDlpInfo {
  title?: string;
  channel?: string;
  channel_id?: string;
  uploader?: string;
  uploader_id?: string;
  description?: string;
  duration?: number;
  upload_date?: string;
  webpage_url?: string;
  thumbnail?: string;
  thumbnails?: { url?: string; width?: number; height?: number }[];
  subtitles?: Record<string, YtDlpTrack[]>;
  automatic_captions?: Record<string, YtDlpTrack[]>;
}

export type VideoSource =
  | { kind: "innertube"; data: any; transcripts: TranscriptInfo[] }
  | { kind: "yt-dlp"; info: YtDlpInfo; transcripts: TranscriptInfo[] };
slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack."Stars: 198kUpdated Claude CodeCodexVerifiedInstall
ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read.Stars: 194kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report.Stars: 194kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt.Stars: 194kUpdated Claude CodeCodexVerifiedInstall