mcpField
R
ra-video-download

ra-video-download

github.com/pluviobyteCreative & media1.7k172 installsUpdated 5w ago
Repository

About ra-video-download

ra-video-download is a skill for acquiring source media in content-production workflows. It runs a bundled downloader, verifies that the resulting media is playable, and follows rules for storing source details and avoiding file overwrites.

Key features

  1. 01Downloads video or audio only
  2. 02Selects methods by supported site
  3. 03Checks playable streams and duration
  4. 04Stores source details and avoids overwrites

Use cases

  1. 01Acquire short videos as production references
  2. 02Download approved source media for a project
  3. 03Verify downloaded files and record media details

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/pluviobyte/rnskill --skill ra-video-download

After installing, type/ra-video-downloadin Claude Code to confirm it loaded.

Bundled filesagents/openai.yamlscripts/download_media.py

Details

From the project README

视频下载

Download source media only. Do not transcribe, rewrite, edit, or publish it.

Storage rules

  • Keep source URLs, source titles, source metadata, and downloaded reference media inside 01-内容生产/视频工作台/.internal/ by default.
  • Use 01-内容生产/视频工作台/制作中/<日期-主题>/原始素材/ only when the caller explicitly names a production project and the media is an approved production input.
  • Never place source information in a handoff, finished script, final archive, or public document.
  • Never overwrite an existing file. Let the downloader add a stable suffix or stop.

Workflow

  1. Confirm that the URL is source media and that downloading it is within the user's request.
  2. Run the bundled downloader. It uses this order:
    • Douyin: TikHub media URL, then yt-dlp with browser cookies, then plain yt-dlp.
    • Other supported sites: plain yt-dlp, optionally with browser cookies when required.
  3. Inspect the returned local path and media probe. A successful HTTP response alone is not delivery.
  4. Require a playable audio or video stream and a non-zero duration. Report the local path, duration, dimensions, and selected download method.
  5. If every route fails, preserve the concise failure log and state the missing prerequisite. Do not claim that the video was downloaded.

Command

Use the Python interpreter that can import tikhub for the best Douyin path. In this workspace, prefer /opt/homebrew/bin/python3 when available.

/opt/homebrew/bin/python3 scripts/download_media.py '<url>'

Useful options:

# Explicit production input directory
/opt/homebrew/bin/python3 scripts/download_media.py '<url>' --output-dir '01-内容生产/视频工作台/制作中/<日期-主题>/原始素材/<项目>'

# Extract audio only
/opt/homebrew/bin/python3 scripts/download_media.py '<url>' --audio-only

# Use an authenticated browser profile for a protected public page
/opt/homebrew/bin/python3 scripts/download_media.py '<url>' --cookies-from-browser chrome

Resolve scripts/download_media.py relative to this SKILL.md; do not assume the current directory is the skill directory.

Safety and failure handling

  • Use browser cookies only for the requested public media. Do not print, copy, or persist raw cookies.
  • Read TIKHUB_API_KEY from the environment or the workspace-root .env; never print it.
  • Do not bypass private-account access controls, paywalls, DRM, or deleted/private media.
  • Treat TikHub and browser cookies as acquisition fallbacks, not as proof that reuse rights exist.
  • Keep the original source file untouched after download.
  • If ffprobe fails, reject the file even if it has an .mp4 extension.

Handoff

Return a compact result containing:

  • local media path
  • source metadata path
  • method used (tikhub, yt-dlp-cookie, or yt-dlp)
  • duration, resolution, and codecs
  • any limitation such as watermark, missing audio, or authentication failure

Then route onward only when requested: ra-逐字稿提取skill for source speech extraction, video-use for editing, or ra-video-production-director for production.

Comments

Markdown supported