JimLiu/baoyu-skills / skills/baoyu-youtube-transcript
baoyu-youtube-transcript
VerifiedDownloads 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.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 6.5 KB |
| prompts/speaker-transcript.md | markdown | 4.6 KB |
| scripts/main.test.ts | script | 8.5 KB |
| scripts/main.ts | script | 8.4 KB |
| scripts/shared.ts | script | 3.4 KB |
| scripts/storage.ts | script | 1.9 KB |
| scripts/transcript.ts | script | 13.5 KB |
| scripts/types.ts | script | 2.4 KB |
| scripts/youtube.ts | script | 22.4 KB |
scripts/types.ts
View on GitHubexport 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[] };
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| 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: 198k | Updated | Claude CodeCodex | Verified | Install |
| 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: 194k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report. | Stars: 194k | Updated | Claude CodeCodex | Verified | Install |
| 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: 194k | Updated | Claude CodeCodex | Verified | Install |