| name | watch-cli-video-agent |
| description | Download and analyze social videos using frames + transcript for AI agent understanding at 50× lower cost than multimodal APIs |
| triggers | ["analyze this video for me","watch this YouTube video","get frames and transcript from video","download and extract video content","transcribe this social media video","help me understand what's in this video","extract architecture from this tutorial video","clone the UI from this demo video"] |
watch-cli Video Agent Skill
Skill by ara.so — Devtools Skills collection.
What It Does
watch-cli gives AI agents the ability to "watch" social videos by decomposing them into frames (JPGs) + audio transcript, avoiding expensive multimodal video APIs. Works with YouTube, X/Twitter, LinkedIn, TikTok, Reddit, Vimeo, and Facebook. ~50× cheaper and ~5× faster than calling a multimodal LLM on full video.
The insight: Videos are just frames + audio. Extract both, read them separately with vision + text LLMs, and you have full video understanding without burning a video model on every frame.
Installation
curl -fsSL https://raw.githubusercontent.com/sonpiaz/watch-cli/main/install.sh | bash
Dependencies (installer checks, but install manually if needed):
yt-dlp — video downloader
ffmpeg — frame/audio extraction
jq, curl, python3 — utilities
macOS:
brew install yt-dlp ffmpeg jq
Debian/Ubuntu:
sudo apt install yt-dlp ffmpeg jq python3 curl
Configuration
Set your Kyma API key (or bring-your-own Groq/Google keys):
export KYMA_API_KEY=kyma-xxxxxxxx
Get a free key at https://kymaapi.com (includes ~1 hour of free transcription credit).
Alternative: For bring-your-own-keys, create .env:
GROQ_API_KEY=gsk_...
GOOGLE_AI_KEY=AIza...
Core Commands
watch — Full video analysis (orchestrator)
watch <url> [frame-count] [--cookies <file>]
Downloads video, extracts frames, transcribes audio — returns everything in one structured block.
Example:
watch https://www.youtube.com/watch?v=dQw4w9WgXcQ
Output structure:
VIDEO: /tmp/dl-video/abc123.mp4
DURATION: 218
FRAMES:
/tmp/frames_abc123/frame_01.jpg
/tmp/frames_abc123/frame_02.jpg
/tmp/frames_abc123/frame_03.jpg
...
TRANSCRIPT:
Today I want to talk about how decomposition unlocks 10× cost reduction...
With custom frame count (default is 8):
watch https://twitter.com/user/status/12345 16
For login-walled content (LinkedIn, private X, Facebook):
watch https://www.linkedin.com/posts/someone_activity-12345 --cookies ~/cookies.txt
(Auto-detects browser cookies if signed in; see troubleshooting for manual export)
dl-video — Download only
dl-video <url> [out-dir] [--cookies <file>]
Just downloads the video, returns the local mp4 path.
VIDEO_PATH=$(dl-video https://www.youtube.com/watch?v=dQw4w9WgXcQ /tmp/videos)
echo "Downloaded to: $VIDEO_PATH"
extract-frames — Frame extraction
extract-frames <video> [count] [out-dir]
Extracts N evenly-spaced JPG frames from a video.
extract-frames video.mp4 12 /tmp/my-frames
transcribe — Speech-to-text
transcribe <audio-or-video> [language]
Auto-extracts audio from video if needed, then transcribes using Whisper Large v3 Turbo via Kyma.
transcribe video.mp4
transcribe audio.mp3 en
Output: Plain text transcript.
audio-q — Audio scene Q&A
audio-q <audio-or-video> "<question>"
Beyond transcription: asks about tone, music, sound effects, language, emotion using a multimodal audio model (Gemini 3 Flash audio).
audio-q video.mp4 "What is the speaker's emotional tone? Is there background music?"
models — List available models
models
models --all
Shows live model list from Kyma API — transcribe and audio-understand aliases auto-update when Kyma swaps underlying models.
Frame Count Guidance
| Video Type | Recommended Frames |
|---|
| Short tweet/clip (<2 min) | 4–8 (default) |
| Tutorial/talk (5–20 min) | 8–16 |
| Lecture (20–60 min) | 16–24 |
| Conference talk (>1 hr) | 24–32 |
| Fast-cut UI demo | Double the recommendation |
Patterns for AI Agents
Pattern 1: Full video understanding
OUTPUT=$(watch https://www.youtube.com/watch?v=VIDEO_ID)
Pattern 2: Code tutorial → working implementation
watch https://www.youtube.com/watch?v=CODING_TUTORIAL 16
Pattern 3: Architecture extraction
watch https://www.youtube.com/watch?v=SYSTEM_DESIGN_TALK 24
Pattern 4: UI/UX cloning
watch https://twitter.com/designer/status/12345 12
Pattern 5: Audio-only analysis
TRANSCRIPT=$(transcribe podcast.mp3)
SCENE=$(audio-q podcast.mp3 "Describe the audio scene: tone, music, number of speakers, emotion")
Prompt Templates (Copy-Paste for Agents)
Located in prompts/ directory, paste above watch output:
implement-from-video.md — Coding walkthrough → working project
extract-architecture.md — System talk → architecture diagram
clone-ux.md — UI demo → React component
paper-to-code.md — Research talk → runnable notebook
tutorial-walkthrough.md — Long tutorial → cheat sheet
Usage:
watch https://www.youtube.com/watch?v=VIDEO_ID > output.txt
cat prompts/implement-from-video.md output.txt > full-context.txt
Cost Estimates
| Video Length | Transcribe Cost |
|---|
| 5 minutes | ~$0.003 |
| 1 hour | ~$0.04 |
| 2 hours | ~$0.08 |
Frame extraction is local (ffmpeg), free. Free Kyma credit covers ~25 hours of audio.
Comparison: Multimodal video API on 1-hour video ≈ $5. watch-cli ≈ $0.10. (~50× cheaper)
Troubleshooting
Login-walled videos (LinkedIn, private X, Facebook)
Auto-detection (usually works):
- Sign into the platform in your browser (Chrome, Firefox, Safari, Edge, Brave)
- Run
watch <url> — it auto-finds cookies
Manual cookie export (for servers/CI):
- Install browser extension: "Get cookies.txt LOCALLY" (Chrome/Firefox)
- Visit the platform while signed in
- Click extension → Export cookies.txt
- Save to
~/cookies.txt
- Run:
watch <url> --cookies ~/cookies.txt
Full guide: docs/cookies.md in the repo.
"Region-locked video" error
yt-dlp can't download region-restricted content. Workarounds:
- Use VPN to target region
- Pass
--cookies from browser with VPN active
"Audio file too large" error
Transcribe provider has 25MB audio limit. For 2+ hour videos:
ffmpeg -i long-video.mp4 -ss 00:00:00 -to 01:00:00 -c copy part1.mp4
ffmpeg -i long-video.mp4 -ss 01:00:00 -c copy part2.mp4
transcribe part1.mp4 > transcript1.txt
transcribe part2.mp4 > transcript2.txt
cat transcript1.txt transcript2.txt > full-transcript.txt
Empty transcript (silent video)
For screencasts with no speech:
- Increase frame count:
watch <url> 24
- Use
audio-q to describe any sound design: audio-q video.mp4 "Are there any UI sounds, clicks, or ambient audio?"
Fast-cut content missing key moments
Default 8 frames won't catch rapid edits. Solution:
watch <url> 32
Models not updating
transcribe and audio-q use Kyma aliases that auto-update. To see current models:
models
If you want to pin a specific model version, edit the script and replace the alias with a model ID from models --all.
Advanced: Using as Claude Code Skill
Copy the pre-built skill into Claude's skill directory:
mkdir -p ~/.claude/skills
cp -r skills/watch-cli ~/.claude/skills/
Now /watch <url> becomes a first-class command in Claude Code, with prompt library auto-attached.
Environment Variables Reference
export KYMA_API_KEY=kyma-xxxxxxxx
export GROQ_API_KEY=gsk_...
export GOOGLE_AI_KEY=AIza...
Real Agent Usage Example
$ watch https://www.youtube.com/watch?v=TUTORIAL_VIDEO 16
VIDEO: /tmp/dl-video/abc123.mp4
DURATION: 1847
FRAMES:
/tmp/frames_abc123/frame_01.jpg
/tmp/frames_abc123/frame_02.jpg
/tmp/frames_abc123/frame_03.jpg
/tmp/frames_abc123/frame_04.jpg
...
TRANSCRIPT:
Okay so first we're going to set up a new React project. Create a folder
called my-app, then run npm init. Now let's install these dependencies...
Key Takeaways for Agents
- Always use
watch for the full pipeline (unless you only need one piece)
- Read frames as images — they contain visual info the transcript can't capture
- Read transcript as text — it contains verbal explanations the frames don't show
- Combine both — frames + transcript = full video understanding
- Adjust frame count based on video type (fast-cut → more frames)
- For login-walled content — it auto-detects browser cookies, but fall back to
--cookies if needed
- Cost is negligible — transcription is ~$0.04/hour, don't hesitate to watch multiple videos
- Use prompt templates in
prompts/ for specific output types (architecture, code, UI, etc.)
License: MIT
Homepage: https://kymaapi.com
GitHub: https://github.com/sonpiaz/watch-cli