SkillsGrove
SkillsGrove/Kurzvideo & Creator/tsukhani/jclaw/youtube-transcript

youtube-transcript

Installation

$npx skills add https://github.com/tsukhani/jclaw --skill youtube-transcript
$git clone --depth 1 https://github.com/tsukhani/jclaw.git /tmp/jclaw && mkdir -p ~/.claude/skills && cp -r /tmp/jclaw/skills/youtube-transcript ~/.claude/skills/youtube-transcript
Bitte installiere diesen Agent Skill für mich: https://github.com/tsukhani/jclaw/tree/e6d2b5ef0f1a0a0f3b1e60097ef0a1ee0ffddcc5/skills/youtube-transcript – lies zuerst seine SKILL.md und seine Skripte und installiere ihn erst dann in meinen Skills-Ordner, wenn du bestätigt hast, dass er sicher ist.

Zusammenfassung

Originalbeschreibung · MITRetrieve the transcript text from a YouTube video given a URL or video ID.
Die folgende SKILL.md ist aus tsukhani/jclaw (Commit e6d2b5e) unter der Lizenz MIT wiedergegeben. Der Text ist unverändert; lediglich die Metadaten im Dateikopf sind weggelassen, Bilder werden als Links angezeigt und sehr lange Dateien werden gekürzt. Copyright 2026 Abundent Sdn Bhd. Lizenz: LICENSE. Es wird nur die Anleitungsdatei angezeigt; etwaige Skripte finden Sie im Original-Repository.

YouTube Transcript

When asked to retrieve a transcript from a YouTube video:

  1. Extract the video ID

    • If the user provides a full URL (e.g. https://www.youtube.com/watch?v=VIDEO_ID or https://youtu.be/VIDEO_ID), parse out the 11-character video ID.
    • If the user provides just the raw video ID, use it directly.
  2. Fetch the transcript

    • Use the exec tool to run a one-liner Python script that calls the youtube_transcript_api library: python3 -c "from youtube_transcript_api import YouTubeTranscriptApi; api=YouTubeTranscriptApi(); t=api.fetch('VIDEO_ID'); print('TOTAL:{}'.format(len(t))); [print('{:06.2f}|{}'.format(s.start, s.text)) for s in t]"
      • The output is a series of lines: TOTAL:508 followed by entries like 72.50|Hello world
    • If it fails with ModuleNotFoundError, the library is missing: run python3 -m pip install "youtube-transcript-api==1.2.4" --quiet once with exec, then run the fetch again. Install only then, and only this version, which is the one the skill is tested with.
    • If the library raises any other error (e.g. TranscriptsDisabled, NoTranscriptFound, or connectivity issues), report the error text concisely and stop.
  3. Parse the response

    • Split the output by lines.
    • Skip the TOTAL: line (used only for verification).
    • For each remaining line: split on the first | — the left side is the timestamp in seconds (float), the right side is the caption text. Decode HTML entities on the caption text (e.g. &amp; → &, &quot; → ", &#39; → ', &lt; → <, &gt; → >).
    • Format each timestamp as [MM:SS] from the float seconds (e.g. 72.50 → [01:12]).
    • Combine each caption into a single line: [MM:SS] {decoded_text}.
    • Join all lines with a newline into the final transcript string.
  4. Deliver the result

    • If the combined transcript exceeds 4000 characters, save it to a file:
      • Create the directory youtube-transcript/ at the root of the workspace if it doesn't exist.
      • Write the content to youtube-transcript/{VIDEO_ID}-transcript.txt using the filesystem tool.
      • Report back with a markdown file link: [{VIDEO_ID}-transcript.txt](<youtube-transcript/{VIDEO_ID}-transcript.txt>)
    • If the transcript is short, return it directly in chat wrapped in a markdown code block for readability.
  5. Error handling

    • If the library or transcript fetch fails, report the error text concisely.
    • If the video has no captions/transcript available, report this plainly to the user.
    • Be concise and factual when reporting errors.

Output Location: If this skill generates files, they are written to youtube-transcript/ at the root of the agent's workspace (e.g., youtube-transcript/abc123-transcript.txt).

Vollständigen Lizenztext ansehen (MIT)
MIT License

Copyright (c) 2026 Abundent Sdn Bhd

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.