TikTok analyzer
Claude cannot watch video or open TikTok links, but it can read images and text. This skill converts the video into both: a timestamped transcript, evenly spaced frames, and the post metadata. Then you read them and answer.
Steps
- Run the extractor (works for a URL or a local video path).
<skill-dir>is the folder that holds this SKILL.md, wherever the skill is installed:
If the script fails on a missing package, install the dependencies once withpython "<skill-dir>/scripts/extract.py" "<url-or-file>" "<out_dir>"python -m pip install -r "<skill-dir>/requirements.txt". Use the scratchpad or a temp dir for<out_dir>, not the user's project. Optional args: max frames (default 24), Whisper model (defaultbase; usesmallif the speech is noisy, accented or non-English). First run downloads the Whisper model, so allow a few minutes. - Read
metadata.json(caption, author, date, hashtags, counts, sound), thentranscript.txt. - Read the frames in
frames/with the Read tool, in order. File names carry the timestamp (t0012.3s.jpg), so you can line each frame up with the transcript. Frames matter because much of TikTok's information is burned-in text, product shots, charts and demos that are never spoken. - Answer the user's actual question. For fact extraction, separate what was said (transcript), shown (frames, including on-screen text), and claimed in the caption. Cite timestamps so the user can check the source.
Rules for honest analysis
- Frames are samples, about one per 2 seconds. Do not claim something was absent from the video, only that it did not appear in the sampled frames or transcript. For a specific moment, re-run with a higher max frames count.
- Whisper makes mistakes on names, brands, numbers and slang. Flag any fact that hinges on one transcribed word or number, and cross-check it against on-screen text.
- A creator saying something is not evidence it is true. When the user wants fact-checking, list the claims, mark which are verifiable, and verify with a web search rather than repeating the claim as fact.
- Whisper often mishears product names (it heard "Claude" as "cloud" every time in testing). Use context and the on-screen text to correct these, and say you did.
- Engagement counts and captions are context, not verdicts.
When it fails
- Photo carousels / slideshows: yt-dlp may not download them. Ask the user to screen-record or save the video, then pass the file path.
- Login-walled, private, region-blocked or deleted videos: the download errors out. Ask for a saved file instead.
- "Unexpected response from webpage request": TikTok's bot check needs browser impersonation. Run
python -m pip install -U "yt-dlp[curl-cffi]"and retry. This was needed on the first real test. - HTTP 403 or other extractor errors: TikTok changes often. Run
python -m pip install -U yt-dlpand retry once. - No speech: the transcript is empty, lean on frames and caption, and say so.
- Missing packages:
python -m pip install -r "<skill-dir>/requirements.txt"(ffmpeg is bundled through imageio-ffmpeg, no system install needed).