youtube-transcript
Skill1 starsChanged 3 months agoMITView on GitHub
Use when the user wants the text content of a YouTube video — the full transcript, timestamped segments, a search for a specific topic within the video, or a summary/quote — from a URL or bare video ID.
- Installs packages
59 other projects use a version of this.
Adopted by
Most recently taken up by
- arcadiumdata/skillstheir own version, first seen Nov 8, 2026
- yinbaozong/Video-Note-Forgetheir own version, first seen Nov 8, 2026
- tubeagentkit/youtube-transcript-skillstheir own version, first seen Nov 7, 2026
- ong6/skillstheir own version, first seen Nov 5, 2026
- tsukhani/jclawtheir own version, first seen Nov 5, 2026
- DanielLavrushin/tspu-docstheir own version, first seen Nov 1, 2026
Used with
Projects with it also use research-prompt, ship-learn-next and 9 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
matyasstochSkillresearch-prompt
Write a single-paragraph Deep Research prompt to hand to a human researcher (or a deep-research AI). Use when the user wants a research brief, a "deep research prompt", a one-paragraph task for a researcher, or asks "what should our researcher look for". Produces ONE tight paragraph with full context, numbered sub-questions, and per-finding output format.
Also in 3 projects that use this
michalparkolaSkillship-learn-next
Transform learning content (like YouTube transcripts, articles, tutorials) into actionable implementation plans using the Ship-Learn-Next framework. Use when user wants to turn advice, lessons, or educational content into concrete action steps, reps, or a learning quest.
Also in 4 projects that use this
huskerjeffSkillyoutube-search
Search YouTube and extract video metadata and captions using yt-dlp. Use when the user wants to search YouTube, find video transcripts, research topics via YouTube, or feed video content into other tools like NotebookLM.
Also in 4 projects that use this
michalparkolaSkillarticle-extractor
Extract clean article content from URLs (blog posts, articles, tutorials) and save as readable text. Use when user wants to download, extract, or save an article/blog post from a URL without ads, navigation, or clutter.
Also in 3 projects that use this
MicrosoftSkillweb-search
Also in 3 projects that use this
GoogleSkillteach
Teach the user a new skill or concept, within this workspace.
Also in 3 projects that use this
Other versions59 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 59
- badlogic/pi-skills★ 2.5ksame name
- amosblomqvist/pi-config★ 1.1ksame name
- DanielLavrushin/tspu-docs★ 660same name
- michalparkola/tapestry-skills-for-claude-code★ 557same name
- michalparkola/tapestry-skills★ 538same name
- glebis/claude-skills★ 410same name
- matyasstoch/david-skills★ 59same name
- tubeagentkit/youtube-transcript-skills★ 44same name
- tsukhani/jclaw★ 42same name
- qa-aman/claude-skills★ 24same name
49 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository58 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- api-test-suiteSkill
- ascii-artSkill
- caddy-reverse-proxySkill
- changelog-generatorSkill
- color-palette-generatorSkill
- cron-taskSkill
- csv-toolkitSkill
- discord-bot-buildSkill
- docker-umbrellaSkill
- dotfiles-manageSkill
- email-sendSkill
- env-config-managerSkill
- excalidraw-diagramSkill
- file-organizerSkill
- forgejo-self-hostSkill
- frontend-design-toolkitSkill
- generate-dockerfileSkill
- gif-searchSkill
- git-backupSkill
- github-actions-ciSkill
- hallmark-readmeSkill
- http-api-testerSkill
- invoice-generatorSkill
- json-formatterSkill
- log-analyzerSkill
- markdown-linterSkill
- markdown-to-pdfSkill
- markdown-to-slidesSkill
- mcp-server-buildSkill
- media-id-mappingSkill
- movie-catalogue-siteSkill
- movie-night-calendarSkill
- ntfy-notifierSkill
- ocr-documentsSkill
- ollama-localSkill
- openapi-generatorSkill
- password-generatorSkill
- pdf-extractSkill
- portfolio-upkeepSkill
- qr-code-generatorSkill
- regex-testerSkill
- resume-builderSkill
- rss-monitorSkill
- searxng-self-hostSkill
- skill-publishSkill
- skill-registry-catalogSkill
- skills-portfolio-scaffoldSkill
- snippet-managerSkill
- sqlite-dashboardSkill
- streaming-provider-embedsSkill
- tailscale-deploySkill
- telegram-bot-buildSkill
- tmdb-metadataSkill
- uptime-kuma-self-hostSkill
- watchlist-syncSkill
- webhook-receiverSkill
The file
We split this skill into the rules it gives an agent
2 rules. 0 are common, 0 are distinctive, and 2 are very specific to this project.
0
Common
Most of the 50 edited versions we read keep these.
0
Distinctive
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 128
Calling
get_transcriptwithout a fallback: Not all videos have captions — it raises NoTranscriptFound. - Very specific: line 138
Hardcoding
languages=["en"]for non-English content: If the requested language isn't present, get_transcript raises rather than falling …
“Common” is measured: kept by at least 6 in 10 of the 50 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
youtube-transcript
Overview
Fetch transcripts from YouTube videos. The agent retrieves the video's caption track, cleans the text, and returns it as plain text or structured segments with timestamps.
When to Use
- The user wants the text content of a YouTube video.
- The user wants to search for a specific topic within a video.
- The user wants to summarize or quote a video.
- The user says "get the transcript", "what does this video say", or "extract the captions".
Prerequisites
pip install youtube-transcript-apiBasic Transcript
from youtube_transcript_api import YouTubeTranscriptApi
def get_transcript(video_id: str, lang: str = "en") -> str:
"""Get the full transcript as plain text."""
transcript = YouTubeTranscriptApi.get_transcript(video_id, languages=[lang])
return " ".join([snippet["text"] for snippet in transcript])With Timestamps
def get_transcript_with_timestamps(video_id: str, lang: str = "en") -> list:
"""Get transcript as a list of {start, duration, text} dicts."""
transcript = YouTubeTranscriptApi.get_transcript(video_id, languages=[lang])
return [
{
"start": snippet["start"],
"end": snippet["start"] + snippet["duration"],
"text": snippet["text"]
}
for snippet in transcript
]Extract Video ID from URL
import re
def extract_video_id(url: str) -> str:
patterns = [
r"(?:youtube\.com/watch\?v=|youtu\.be/|youtube\.com/embed/)([a-zA-Z0-9_-]{11})",
r"youtube\.com/shorts/([a-zA-Z0-9_-]{11})",
]
for pattern in patterns:
match = re.search(pattern, url)
if match:
return match.group(1)
# Maybe it's already just the ID
if re.match(r"^[a-zA-Z0-9_-]{11}$", url):
return url
raise ValueError(f"Could not extract video ID from: {url}")Full Workflow
# 1. Get video ID from URL
video_id = extract_video_id("https://www.youtube.com/watch?v=dQw4w9WgXcQ")
# 2. Get transcript
transcript = get_transcript(video_id)
# 3. Optionally save to file
with open("transcript.txt", "w") as f:
f.write(transcript)Search Within Transcript
def search_transcript(video_id: str, query: str, lang: str = "en") -> list:
"""Find segments containing a query string."""
transcript = YouTubeTranscriptApi.get_transcript(video_id, languages=[lang])
query_lower = query.lower()
matches = []
for snippet in transcript:
if query_lower in snippet["text"].lower():
matches.append({
"timestamp": snippet["start"],
"text": snippet["text"]
})
return matchesTranslate Non-English Transcripts
from youtube_transcript_api import YouTubeTranscriptApi
def get_transcript_any_language(video_id: str) -> str:
"""Get transcript in any available language."""
transcript_list = YouTubeTranscriptApi.list_transcripts(video_id)
for transcript in transcript_list:
try:
return " ".join([s["text"] for s in transcript.fetch()])
except:
continue
raise ValueError("No transcript available in any language")Common Pitfalls
- Calling
get_transcriptwithout a fallback. Not all videos have captions — it raisesNoTranscriptFound. Calllist_transcriptsfirst to check what's actually available before assuming a fixedlang. - Treating auto-generated captions as manual-quality. YouTube auto-captions are usually available but less accurate (misheard words, no punctuation) — don't present them as a verbatim transcript without noting the source.
- Fetching many videos back-to-back with no delay. YouTube rate-limits frequent requests; space out multiple fetches or batch jobs will start failing partway through.
- Assuming
VideoUnavailablemeans a transient error. It means the video is private or deleted — retrying won't help; report it as unavailable to the user. - Hardcoding
languages=["en"]for non-English content. If the requested language isn't present,get_transcriptraises rather than falling back — uselist_transcriptsto discover available (including auto-translated) languages first. - Returning raw transcript text with HTML entities intact. Segments can contain
&,', etc. — runhtml.unescape()before presenting the text.
Verification Checklist
extract_video_idcorrectly parses the actual URL format given (watch, youtu.be, embed, or shorts) before fetching.list_transcriptswas checked when the firstget_transcriptcall fails, rather than immediately reporting failure to the user.- Returned text has no raw HTML entities (
&,') left unescaped. - Timestamped output (if requested) has
start/endvalues that increase monotonically and cover the video's actual duration.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

