[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7CTNJVT288VBX3XAAFXTC10":3,"skill-same:01M7CTNJVT288VBX3XAAFXTC10":98},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":28,"commitSha":29,"skillDirectory":30,"forksCount":14,"repositoryHtmlUrl":31,"repositoryHomepageUrl":6,"ownerHtmlUrl":32,"ownerBlogUrl":33,"ownerDescription":34,"updatedAt":35,"install":36,"resources":49},"01M7CTNJVT288VBX3XAAFXTC10","videodb",null,"See, Understand, Act on video and audio. See- ingest from local files, URLs, RTSP\u002Flive feeds, or live record desktop; return realtime context and playable stream links. Understand- extract frames, build visual\u002Fsemantic\u002Ftemporal indexes, and search moments with timestamps and auto-clips. Act- transcode and normalize (codec, fps, resolution, aspect ratio), perform timeline edits (subtitles, text\u002Fimage overlays, branding, audio overlays, dubbing, translation), generate media assets (image, audio, video), and create real time alerts for events from live streams or desktop capture.","Henrique1601\u002FSkiilsToIAs","Henrique1601","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F92006691?v=4","01M7CRXVT0GVXVK80JT1GR687S","Henrique Bezerra Dos Santos","01M7CRXVTN5Y8TMWJ1MDSKCQ1T",0,"MIT","https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fdesign\u002Fvideodb\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: videodb\ndescription: See, Understand, Act on video and audio. See- ingest from local files, URLs, RTSP\u002Flive feeds, or live record desktop; return realtime context and playable stream links. Understand- extract frames, build visual\u002Fsemantic\u002Ftemporal indexes, and search moments with timestamps and auto-clips. Act- transcode and normalize (codec, fps, resolution, aspect ratio), perform timeline edits (subtitles, text\u002Fimage overlays, branding, audio overlays, dubbing, translation), generate media assets (image, audio, video), and create real time alerts for events from live streams or desktop capture.\nmetadata:\n  origin: ECC\nallowed-tools: Read Grep Glob Bash(python:*)\nargument-hint: \"[task description]\"\n---\n\n# VideoDB Skill\n\n**Perception + memory + actions for video, live streams, and desktop sessions.**\n\n## When to use\n\n### Desktop Perception\n- Start\u002Fstop a **desktop session** capturing **screen, mic, and system audio**\n- Stream **live context** and store **episodic session memory**\n- Run **real-time alerts\u002Ftriggers** on what's spoken and what's happening on screen\n- Produce **session summaries**, a searchable timeline, and **playable evidence links**\n\n### Video ingest + stream\n- Ingest a **file or URL** and return a **playable web stream link**\n- Transcode\u002Fnormalize: **codec, bitrate, fps, resolution, aspect ratio**\n\n### Index + search (timestamps + evidence)\n- Build **visual**, **spoken**, and **keyword** indexes\n- Search and return exact moments with **timestamps** and **playable evidence**\n- Auto-create **clips** from search results\n\n### Timeline editing + generation\n- Subtitles: **generate**, **translate**, **burn-in**\n- Overlays: **text\u002Fimage\u002Fbranding**, motion captions\n- Audio: **background music**, **voiceover**, **dubbing**\n- Programmatic composition and exports via **timeline operations**\n\n### Live streams (RTSP) + monitoring\n- Connect **RTSP\u002Flive feeds**\n- Run **real-time visual and spoken understanding** and emit **events\u002Falerts** for monitoring workflows\n\n## How it works\n\n### Common inputs\n- Local **file path**, public **URL**, or **RTSP URL**\n- Desktop capture request: **start \u002F stop \u002F summarize session**\n- Desired operations: get context for understanding, transcode spec, index spec, search query, clip ranges, timeline edits, alert rules\n\n### Common outputs\n- **Stream URL**\n- Search results with **timestamps** and **evidence links**\n- Generated assets: subtitles, audio, images, clips\n- **Event\u002Falert payloads** for live streams\n- Desktop **session summaries** and memory entries\n\n### Running Python code\n\nBefore running any VideoDB code, change to the project directory and load environment variables:\n\n```python\nfrom dotenv import load_dotenv\nload_dotenv(\".env\")\n\nimport videodb\nconn = videodb.connect()\n```\n\nThis reads `VIDEO_DB_API_KEY` from:\n1. Environment (if already exported)\n2. Project's `.env` file in current directory\n\nIf the key is missing, `videodb.connect()` raises `AuthenticationError` automatically.\n\nDo NOT write a script file when a short inline command works.\n\nWhen writing inline Python (`python -c \"...\"`), always use properly formatted code — use semicolons to separate statements and keep it readable. For anything longer than ~3 statements, use a heredoc instead:\n\n```bash\npython \u003C\u003C 'EOF'\nfrom dotenv import load_dotenv\nload_dotenv(\".env\")\n\nimport videodb\nconn = videodb.connect()\ncoll = conn.get_collection()\nprint(f\"Videos: {len(coll.get_videos())}\")\nEOF\n```\n\n### Setup\n\nWhen the user asks to \"setup videodb\" or similar:\n\n### 1. Install SDK\n\n```bash\npip install \"videodb[capture]\" python-dotenv\n```\n\nIf `videodb[capture]` fails on Linux, install without the capture extra:\n\n```bash\npip install videodb python-dotenv\n```\n\n### 2. Configure API key\n\nThe user must set `VIDEO_DB_API_KEY` using **either** method:\n\n- **Export in terminal** (before starting Claude): `export VIDEO_DB_API_KEY=your-key`\n- **Project `.env` file**: Save `VIDEO_DB_API_KEY=your-key` in the project's `.env` file\n\nGet a free API key at [console.videodb.io](https:\u002F\u002Fconsole.videodb.io) (50 free uploads, no credit card).\n\n**Do NOT** read, write, or handle the API key yourself. Always let the user set it.\n\n### Quick Reference\n\n### Upload media\n\n```python\n# URL\nvideo = coll.upload(url=\"https:\u002F\u002Fexample.com\u002Fvideo.mp4\")\n\n# YouTube\nvideo = coll.upload(url=\"https:\u002F\u002Fwww.youtube.com\u002Fwatch?v=VIDEO_ID\")\n\n# Local file\nvideo = coll.upload(file_path=\"\u002Fpath\u002Fto\u002Fvideo.mp4\")\n```\n\n### Transcript + subtitle\n\n```python\n# force=True skips the error if the video is already indexed\nvideo.index_spoken_words(force=True)\ntext = video.get_transcript_text()\nstream_url = video.add_subtitle()\n```\n\n### Search inside videos\n\n```python\nfrom videodb.exceptions import InvalidRequestError\n\nvideo.index_spoken_words(force=True)\n\n# search() raises InvalidRequestError when no results are found.\n# Always wrap in try\u002Fexcept and treat \"No results found\" as empty.\ntry:\n    results = video.search(\"product demo\")\n    shots = results.get_shots()\n    stream_url = results.compile()\nexcept InvalidRequestError as e:\n    if \"No results found\" in str(e):\n        shots = []\n    else:\n        raise\n```\n\n### Scene search\n\n```python\nimport re\nfrom videodb import SearchType, IndexType, SceneExtractionType\nfrom videodb.exceptions import InvalidRequestError\n\n# index_scenes() has no force parameter — it raises an error if a scene\n# index already exists. Extract the existing index ID from the error.\ntry:\n    scene_index_id = video.index_scenes(\n        extraction_type=SceneExtractionType.shot_based,\n        prompt=\"Describe the visual content in this scene.\",\n    )\nexcept Exception as e:\n    match = re.search(r\"id\\s+([a-f0-9]+)\", str(e))\n    if match:\n        scene_index_id = match.group(1)\n    else:\n        raise\n\n# Use score_threshold to filter low-relevance noise (recommended: 0.3+)\ntry:\n    results = video.search(\n        query=\"person writing on a whiteboard\",\n        search_type=SearchType.semantic,\n        index_type=IndexType.scene,\n        scene_index_id=scene_index_id,\n        score_threshold=0.3,\n    )\n    shots = results.get_shots()\n    stream_url = results.compile()\nexcept InvalidRequestError as e:\n    if \"No results found\" in str(e):\n        shots = []\n    else:\n        raise\n```\n\n### Timeline editing\n\n**Important:** Always validate timestamps before building a timeline:\n- `start` must be >= 0 (negative values are silently accepted but produce broken output)\n- `start` must be \u003C `end`\n- `end` must be \u003C= `video.length`\n\n```python\nfrom videodb.timeline import Timeline\nfrom videodb.asset import VideoAsset, TextAsset, TextStyle\n\ntimeline = Timeline(conn)\ntimeline.add_inline(VideoAsset(asset_id=video.id, start=10, end=30))\ntimeline.add_overlay(0, TextAsset(text=\"The End\", duration=3, style=TextStyle(fontsize=36)))\nstream_url = timeline.generate_stream()\n```\n\n### Transcode video (resolution \u002F quality change)\n\n```python\nfrom videodb import TranscodeMode, VideoConfig, AudioConfig\n\n# Change resolution, quality, or aspect ratio server-side\njob_id = conn.transcode(\n    source=\"https:\u002F\u002Fexample.com\u002Fvideo.mp4\",\n    callback_url=\"https:\u002F\u002Fexample.com\u002Fwebhook\",\n    mode=TranscodeMode.economy,\n    video_config=VideoConfig(resolution=720, quality=23, aspect_ratio=\"16:9\"),\n    audio_config=AudioConfig(mute=False),\n)\n```\n\n### Reframe aspect ratio (for social platforms)\n\n**Warning:** `reframe()` is a slow server-side operation. For long videos it can take\nseveral minutes and may time out. Best practices:\n- Always limit to a short segment using `start`\u002F`end` when possible\n- For full-length videos, use `callback_url` for async processing\n- Trim the video on a `Timeline` first, then reframe the shorter result\n\n```python\nfrom videodb import ReframeMode\n\n# Always prefer reframing a short segment:\nreframed = video.reframe(start=0, end=60, target=\"vertical\", mode=ReframeMode.smart)\n\n# Async reframe for full-length videos (returns None, result via webhook):\nvideo.reframe(target=\"vertical\", callback_url=\"https:\u002F\u002Fexample.com\u002Fwebhook\")\n\n# Presets: \"vertical\" (9:16), \"square\" (1:1), \"landscape\" (16:9)\nreframed = video.reframe(start=0, end=60, target=\"square\")\n\n# Custom dimensions\nreframed = video.reframe(start=0, end=60, target={\"width\": 1280, \"height\": 720})\n```\n\n### Generative media\n\n```python\nimage = coll.generate_image(\n    prompt=\"a sunset over mountains\",\n    aspect_ratio=\"16:9\",\n)\n```\n\n## Error handling\n\n```python\nfrom videodb.exceptions import AuthenticationError, InvalidRequestError\n\ntry:\n    conn = videodb.connect()\nexcept AuthenticationError:\n    print(\"Check your VIDEO_DB_API_KEY\")\n\ntry:\n    video = coll.upload(url=\"https:\u002F\u002Fexample.com\u002Fvideo.mp4\")\nexcept InvalidRequestError as e:\n    print(f\"Upload failed: {e}\")\n```\n\n### Common pitfalls\n\n| Scenario | Error message | Solution |\n|----------|--------------|----------|\n| Indexing an already-indexed video | `Spoken word index for video already exists` | Use `video.index_spoken_words(force=True)` to skip if already indexed |\n| Scene index already exists | `Scene index with id XXXX already exists` | Extract the existing `scene_index_id` from the error with `re.search(r\"id\\s+([a-f0-9]+)\", str(e))` |\n| Search finds no matches | `InvalidRequestError: No results found` | Catch the exception and treat as empty results (`shots = []`) |\n| Reframe times out | Blocks indefinitely on long videos | Use `start`\u002F`end` to limit segment, or pass `callback_url` for async |\n| Negative timestamps on Timeline | Silently produces broken stream | Always validate `start >= 0` before creating `VideoAsset` |\n| `generate_video()` \u002F `create_collection()` fails | `Operation not allowed` or `maximum limit` | Plan-gated features — inform the user about plan limits |\n\n## Examples\n\n### Canonical prompts\n- \"Start desktop capture and alert when a password field appears.\"\n- \"Record my session and produce an actionable summary when it ends.\"\n- \"Ingest this file and return a playable stream link.\"\n- \"Index this folder and find every scene with people, return timestamps.\"\n- \"Generate subtitles, burn them in, and add light background music.\"\n- \"Connect this RTSP URL and alert when a person enters the zone.\"\n\n### Screen Recording (Desktop Capture)\n\nUse `ws_listener.py` to capture WebSocket events during recording sessions. Desktop capture supports **macOS** only.\n\n#### Quick Start\n\n1. **Choose state dir**: `STATE_DIR=\"${VIDEODB_EVENTS_DIR:-$HOME\u002F.local\u002Fstate\u002Fvideodb}\"`\n2. **Start listener**: `VIDEODB_EVENTS_DIR=\"$STATE_DIR\" python scripts\u002Fws_listener.py --clear \"$STATE_DIR\" &`\n3. **Get WebSocket ID**: `cat \"$STATE_DIR\u002Fvideodb_ws_id\"`\n4. **Run capture code** (see reference\u002Fcapture.md for the full workflow)\n5. **Events written to**: `$STATE_DIR\u002Fvideodb_events.jsonl`\n\nUse `--clear` whenever you start a fresh capture run so stale transcript and visual events do not leak into the new session.\n\n#### Query Events\n\n```python\nimport json\nimport os\nimport time\nfrom pathlib import Path\n\nevents_dir = Path(os.environ.get(\"VIDEODB_EVENTS_DIR\", Path.home() \u002F \".local\" \u002F \"state\" \u002F \"videodb\"))\nevents_file = events_dir \u002F \"videodb_events.jsonl\"\nevents = []\n\nif events_file.exists():\n    with events_file.open(encoding=\"utf-8\") as handle:\n        for line in handle:\n            try:\n                events.append(json.loads(line))\n            except json.JSONDecodeError:\n                continue\n\ntranscripts = [e[\"data\"][\"text\"] for e in events if e.get(\"channel\") == \"transcript\"]\ncutoff = time.time() - 300\nrecent_visual = [\n    e for e in events\n    if e.get(\"channel\") == \"visual_index\" and e[\"unix_ts\"] > cutoff\n]\n```\n\n## Additional docs\n\nReference documentation is in the `reference\u002F` directory adjacent to this SKILL.md file. Use the Glob tool to locate it if needed.\n\n- [reference\u002Fapi-reference.md](reference\u002Fapi-reference.md) - Complete VideoDB Python SDK API reference\n- [reference\u002Fsearch.md](reference\u002Fsearch.md) - In-depth guide to video search (spoken word and scene-based)\n- [reference\u002Feditor.md](reference\u002Feditor.md) - Timeline editing, assets, and composition\n- [reference\u002Fstreaming.md](reference\u002Fstreaming.md) - HLS streaming and instant playback\n- [reference\u002Fgenerative.md](reference\u002Fgenerative.md) - AI-powered media generation (images, video, audio)\n- [reference\u002Frtstream.md](reference\u002Frtstream.md) - Live stream ingestion workflow (RTSP\u002FRTMP)\n- [reference\u002Frtstream-reference.md](reference\u002Frtstream-reference.md) - RTStream SDK methods and AI pipelines\n- [reference\u002Fcapture.md](reference\u002Fcapture.md) - Desktop capture workflow\n- [reference\u002Fcapture-reference.md](reference\u002Fcapture-reference.md) - Capture SDK and WebSocket events\n- [reference\u002Fuse-cases.md](reference\u002Fuse-cases.md) - Common video processing patterns and examples\n\n**Do not use ffmpeg, moviepy, or local encoding tools** when VideoDB supports the operation. The following are all handled server-side by VideoDB — trimming, combining clips, overlaying audio or music, adding subtitles, text\u002Fimage overlays, transcoding, resolution changes, aspect-ratio conversion, resizing for platform requirements, transcription, and media generation. Only fall back to local tools for operations listed under Limitations in reference\u002Feditor.md (transitions, speed changes, crop\u002Fzoom, colour grading, volume mixing).\n\n### When to use what\n\n| Problem | VideoDB solution |\n|---------|-----------------|\n| Platform rejects video aspect ratio or resolution | `video.reframe()` or `conn.transcode()` with `VideoConfig` |\n| Need to resize video for Twitter\u002FInstagram\u002FTikTok | `video.reframe(target=\"vertical\")` or `target=\"square\"` |\n| Need to change resolution (e.g. 1080p → 720p) | `conn.transcode()` with `VideoConfig(resolution=720)` |\n| Need to overlay audio\u002Fmusic on video | `AudioAsset` on a `Timeline` |\n| Need to add subtitles | `video.add_subtitle()` or `CaptionAsset` |\n| Need to combine\u002Ftrim clips | `VideoAsset` on a `Timeline` |\n| Need to generate voiceover, music, or SFX | `coll.generate_voice()`, `generate_music()`, `generate_sound_effect()` |\n\n## Provenance\n\nReference material for this skill is vendored locally under `skills\u002Fvideodb\u002Freference\u002F`.\nUse the local copies above instead of following external repository links at runtime.\n","# VideoDB Skill\n\n**Perception + memory + actions for video, live streams, and desktop sessions.**\n\n## When to use\n\n### Desktop Perception\n- Start\u002Fstop a **desktop session** capturing **screen, mic, and system audio**\n- Stream **live context** and store **episodic session memory**\n- Run **real-time alerts\u002Ftriggers** on what's spoken and what's happening on screen\n- Produce **session summaries**, a searchable timeline, and **playable evidence links**\n\n### Video ingest + stream\n- Ingest a **file or URL** and return a **playable web stream link**\n- Transcode\u002Fnormalize: **codec, bitrate, fps, resolution, aspect ratio**\n\n### Index + search (timestamps + evidence)\n- Build **visual**, **spoken**, and **keyword** indexes\n- Search and return exact moments with **timestamps** and **playable evidence**\n- Auto-create **clips** from search results\n\n### Timeline editing + generation\n- Subtitles: **generate**, **translate**, **burn-in**\n- Overlays: **text\u002Fimage\u002Fbranding**, motion captions\n- Audio: **background music**, **voiceover**, **dubbing**\n- Programmatic composition and exports via **timeline operations**\n\n### Live streams (RTSP) + monitoring\n- Connect **RTSP\u002Flive feeds**\n- Run **real-time visual and spoken understanding** and emit **events\u002Falerts** for monitoring workflows\n\n## How it works\n\n### Common inputs\n- Local **file path**, public **URL**, or **RTSP URL**\n- Desktop capture request: **start \u002F stop \u002F summarize session**\n- Desired operations: get context for understanding, transcode spec, index spec, search query, clip ranges, timeline edits, alert rules\n\n### Common outputs\n- **Stream URL**\n- Search results with **timestamps** and **evidence links**\n- Generated assets: subtitles, audio, images, clips\n- **Event\u002Falert payloads** for live streams\n- Desktop **session summaries** and memory entries\n\n### Running Python code\n\nBefore running any VideoDB code, change to the project directory and load environment variables:\n\n```python\nfrom dotenv import load_dotenv\nload_dotenv(\".env\")\n\nimport videodb\nconn = videodb.connect()\n```\n\nThis reads `VIDEO_DB_API_KEY` from:\n1. Environment (if already exported)\n2. Project's `.env` file in current directory\n\nIf the key is missing, `videodb.connect()` raises `AuthenticationError` automatically.\n\nDo NOT write a script file when a short inline command works.\n\nWhen writing inline Python (`python -c \"...\"`), always use properly formatted code — use semicolons to separate statements and keep it readable. For anything longer than ~3 statements, use a heredoc instead:\n\n```bash\npython \u003C\u003C 'EOF'\nfrom dotenv import load_dotenv\nload_dotenv(\".env\")\n\nimport videodb\nconn = videodb.connect()\ncoll = conn.get_collection()\nprint(f\"Videos: {len(coll.get_videos())}\")\nEOF\n```\n\n### Setup\n\nWhen the user asks to \"setup videodb\" or similar:\n\n### 1. Install SDK\n\n```bash\npip install \"videodb[capture]\" python-dotenv\n```\n\nIf `videodb[capture]` fails on Linux, install without the capture extra:\n\n```bash\npip install videodb python-dotenv\n```\n\n### 2. Configure API key\n\nThe user must set `VIDEO_DB_API_KEY` using **either** method:\n\n- **Export in terminal** (before starting Claude): `export VIDEO_DB_API_KEY=your-key`\n- **Project `.env` file**: Save `VIDEO_DB_API_KEY=your-key` in the project's `.env` file\n\nGet a free API key at [console.videodb.io](https:\u002F\u002Fconsole.videodb.io) (50 free uploads, no credit card).\n\n**Do NOT** read, write, or handle the API key yourself. Always let the user set it.\n\n### Quick Reference\n\n### Upload media\n\n```python\n# URL\nvideo = coll.upload(url=\"https:\u002F\u002Fexample.com\u002Fvideo.mp4\")\n\n# YouTube\nvideo = coll.upload(url=\"https:\u002F\u002Fwww.youtube.com\u002Fwatch?v=VIDEO_ID\")\n\n# Local file\nvideo = coll.upload(file_path=\"\u002Fpath\u002Fto\u002Fvideo.mp4\")\n```\n\n### Transcript + subtitle\n\n```python\n# force=True skips the error if the video is already indexed\nvideo.index_spoken_words(force=True)\ntext = video.get_transcript_text()\nstream_url = video.add_subtitle()\n```\n\n### Search inside videos\n\n```python\nfrom videodb.exceptions import InvalidRequestError\n\nvideo.index_spoken_words(force=True)\n\n# search() raises InvalidRequestError when no results are found.\n# Always wrap in try\u002Fexcept and treat \"No results found\" as empty.\ntry:\n    results = video.search(\"product demo\")\n    shots = results.get_shots()\n    stream_url = results.compile()\nexcept InvalidRequestError as e:\n    if \"No results found\" in str(e):\n        shots = []\n    else:\n        raise\n```\n\n### Scene search\n\n```python\nimport re\nfrom videodb import SearchType, IndexType, SceneExtractionType\nfrom videodb.exceptions import InvalidRequestError\n\n# index_scenes() has no force parameter — it raises an error if a scene\n# index already exists. Extract the existing index ID from the error.\ntry:\n    scene_index_id = video.index_scenes(\n        extraction_type=SceneExtractionType.shot_based,\n        prompt=\"Describe the visual content in this scene.\",\n    )\nexcept Exception as e:\n    match = re.search(r\"id\\s+([a-f0-9]+)\", str(e))\n    if match:\n        scene_index_id = match.group(1)\n    else:\n        raise\n\n# Use score_threshold to filter low-relevance noise (recommended: 0.3+)\ntry:\n    results = video.search(\n        query=\"person writing on a whiteboard\",\n        search_type=SearchType.semantic,\n        index_type=IndexType.scene,\n        scene_index_id=scene_index_id,\n        score_threshold=0.3,\n    )\n    shots = results.get_shots()\n    stream_url = results.compile()\nexcept InvalidRequestError as e:\n    if \"No results found\" in str(e):\n        shots = []\n    else:\n        raise\n```\n\n### Timeline editing\n\n**Important:** Always validate timestamps before building a timeline:\n- `start` must be >= 0 (negative values are silently accepted but produce broken output)\n- `start` must be \u003C `end`\n- `end` must be \u003C= `video.length`\n\n```python\nfrom videodb.timeline import Timeline\nfrom videodb.asset import VideoAsset, TextAsset, TextStyle\n\ntimeline = Timeline(conn)\ntimeline.add_inline(VideoAsset(asset_id=video.id, start=10, end=30))\ntimeline.add_overlay(0, TextAsset(text=\"The End\", duration=3, style=TextStyle(fontsize=36)))\nstream_url = timeline.generate_stream()\n```\n\n### Transcode video (resolution \u002F quality change)\n\n```python\nfrom videodb import TranscodeMode, VideoConfig, AudioConfig\n\n# Change resolution, quality, or aspect ratio server-side\njob_id = conn.transcode(\n    source=\"https:\u002F\u002Fexample.com\u002Fvideo.mp4\",\n    callback_url=\"https:\u002F\u002Fexample.com\u002Fwebhook\",\n    mode=TranscodeMode.economy,\n    video_config=VideoConfig(resolution=720, quality=23, aspect_ratio=\"16:9\"),\n    audio_config=AudioConfig(mute=False),\n)\n```\n\n### Reframe aspect ratio (for social platforms)\n\n**Warning:** `reframe()` is a slow server-side operation. For long videos it can take\nseveral minutes and may time out. Best practices:\n- Always limit to a short segment using `start`\u002F`end` when possible\n- For full-length videos, use `callback_url` for async processing\n- Trim the video on a `Timeline` first, then reframe the shorter result\n\n```python\nfrom videodb import ReframeMode\n\n# Always prefer reframing a short segment:\nreframed = video.reframe(start=0, end=60, target=\"vertical\", mode=ReframeMode.smart)\n\n# Async reframe for full-length videos (returns None, result via webhook):\nvideo.reframe(target=\"vertical\", callback_url=\"https:\u002F\u002Fexample.com\u002Fwebhook\")\n\n# Presets: \"vertical\" (9:16), \"square\" (1:1), \"landscape\" (16:9)\nreframed = video.reframe(start=0, end=60, target=\"square\")\n\n# Custom dimensions\nreframed = video.reframe(start=0, end=60, target={\"width\": 1280, \"height\": 720})\n```\n\n### Generative media\n\n```python\nimage = coll.generate_image(\n    prompt=\"a sunset over mountains\",\n    aspect_ratio=\"16:9\",\n)\n```\n\n## Error handling\n\n```python\nfrom videodb.exceptions import AuthenticationError, InvalidRequestError\n\ntry:\n    conn = videodb.connect()\nexcept AuthenticationError:\n    print(\"Check your VIDEO_DB_API_KEY\")\n\ntry:\n    video = coll.upload(url=\"https:\u002F\u002Fexample.com\u002Fvideo.mp4\")\nexcept InvalidRequestError as e:\n    print(f\"Upload failed: {e}\")\n```\n\n### Common pitfalls\n\n| Scenario | Error message | Solution |\n|----------|--------------|----------|\n| Indexing an already-indexed video | `Spoken word index for video already exists` | Use `video.index_spoken_words(force=True)` to skip if already indexed |\n| Scene index already exists | `Scene index with id XXXX already exists` | Extract the existing `scene_index_id` from the error with `re.search(r\"id\\s+([a-f0-9]+)\", str(e))` |\n| Search finds no matches | `InvalidRequestError: No results found` | Catch the exception and treat as empty results (`shots = []`) |\n| Reframe times out | Blocks indefinitely on long videos | Use `start`\u002F`end` to limit segment, or pass `callback_url` for async |\n| Negative timestamps on Timeline | Silently produces broken stream | Always validate `start >= 0` before creating `VideoAsset` |\n| `generate_video()` \u002F `create_collection()` fails | `Operation not allowed` or `maximum limit` | Plan-gated features — inform the user about plan limits |\n\n## Examples\n\n### Canonical prompts\n- \"Start desktop capture and alert when a password field appears.\"\n- \"Record my session and produce an actionable summary when it ends.\"\n- \"Ingest this file and return a playable stream link.\"\n- \"Index this folder and find every scene with people, return timestamps.\"\n- \"Generate subtitles, burn them in, and add light background music.\"\n- \"Connect this RTSP URL and alert when a person enters the zone.\"\n\n### Screen Recording (Desktop Capture)\n\nUse `ws_listener.py` to capture WebSocket events during recording sessions. Desktop capture supports **macOS** only.\n\n#### Quick Start\n\n1. **Choose state dir**: `STATE_DIR=\"${VIDEODB_EVENTS_DIR:-$HOME\u002F.local\u002Fstate\u002Fvideodb}\"`\n2. **Start listener**: `VIDEODB_EVENTS_DIR=\"$STATE_DIR\" python scripts\u002Fws_listener.py --clear \"$STATE_DIR\" &`\n3. **Get WebSocket ID**: `cat \"$STATE_DIR\u002Fvideodb_ws_id\"`\n4. **Run capture code** (see reference\u002Fcapture.md for the full workflow)\n5. **Events written to**: `$STATE_DIR\u002Fvideodb_events.jsonl`\n\nUse `--clear` whenever you start a fresh capture run so stale transcript and visual events do not leak into the new session.\n\n#### Query Events\n\n```python\nimport json\nimport os\nimport time\nfrom pathlib import Path\n\nevents_dir = Path(os.environ.get(\"VIDEODB_EVENTS_DIR\", Path.home() \u002F \".local\" \u002F \"state\" \u002F \"videodb\"))\nevents_file = events_dir \u002F \"videodb_events.jsonl\"\nevents = []\n\nif events_file.exists():\n    with events_file.open(encoding=\"utf-8\") as handle:\n        for line in handle:\n            try:\n                events.append(json.loads(line))\n            except json.JSONDecodeError:\n                continue\n\ntranscripts = [e[\"data\"][\"text\"] for e in events if e.get(\"channel\") == \"transcript\"]\ncutoff = time.time() - 300\nrecent_visual = [\n    e for e in events\n    if e.get(\"channel\") == \"visual_index\" and e[\"unix_ts\"] > cutoff\n]\n```\n\n## Additional docs\n\nReference documentation is in the `reference\u002F` directory adjacent to this SKILL.md file. Use the Glob tool to locate it if needed.\n\n- [reference\u002Fapi-reference.md](reference\u002Fapi-reference.md) - Complete VideoDB Python SDK API reference\n- [reference\u002Fsearch.md](reference\u002Fsearch.md) - In-depth guide to video search (spoken word and scene-based)\n- [reference\u002Feditor.md](reference\u002Feditor.md) - Timeline editing, assets, and composition\n- [reference\u002Fstreaming.md](reference\u002Fstreaming.md) - HLS streaming and instant playback\n- [reference\u002Fgenerative.md](reference\u002Fgenerative.md) - AI-powered media generation (images, video, audio)\n- [reference\u002Frtstream.md](reference\u002Frtstream.md) - Live stream ingestion workflow (RTSP\u002FRTMP)\n- [reference\u002Frtstream-reference.md](reference\u002Frtstream-reference.md) - RTStream SDK methods and AI pipelines\n- [reference\u002Fcapture.md](reference\u002Fcapture.md) - Desktop capture workflow\n- [reference\u002Fcapture-reference.md](reference\u002Fcapture-reference.md) - Capture SDK and WebSocket events\n- [reference\u002Fuse-cases.md](reference\u002Fuse-cases.md) - Common video processing patterns and examples\n\n**Do not use ffmpeg, moviepy, or local encoding tools** when VideoDB supports the operation. The following are all handled server-side by VideoDB — trimming, combining clips, overlaying audio or music, adding subtitles, text\u002Fimage overlays, transcoding, resolution changes, aspect-ratio conversion, resizing for platform requirements, transcription, and media generation. Only fall back to local tools for operations listed under Limitations in reference\u002Feditor.md (transitions, speed changes, crop\u002Fzoom, colour grading, volume mixing).\n\n### When to use what\n\n| Problem | VideoDB solution |\n|---------|-----------------|\n| Platform rejects video aspect ratio or resolution | `video.reframe()` or `conn.transcode()` with `VideoConfig` |\n| Need to resize video for Twitter\u002FInstagram\u002FTikTok | `video.reframe(target=\"vertical\")` or `target=\"square\"` |\n| Need to change resolution (e.g. 1080p → 720p) | `conn.transcode()` with `VideoConfig(resolution=720)` |\n| Need to overlay audio\u002Fmusic on video | `AudioAsset` on a `Timeline` |\n| Need to add subtitles | `video.add_subtitle()` or `CaptionAsset` |\n| Need to combine\u002Ftrim clips | `VideoAsset` on a `Timeline` |\n| Need to generate voiceover, music, or SFX | `coll.generate_voice()`, `generate_music()`, `generate_sound_effect()` |\n\n## Provenance\n\nReference material for this skill is vendored locally under `skills\u002Fvideodb\u002Freference\u002F`.\nUse the local copies above instead of following external repository links at runtime.\n",{"name":5,"metadata":24,"description":7,"allowed-tools":26,"argument-hint":27},{"origin":25},"ECC","Read Grep Glob Bash(python:*)","[task description]","main","a73152352c0612252131e5cf84e91312a6cf17dc","design\u002Fvideodb","https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs","https:\u002F\u002Fgithub.com\u002FHenrique1601","https:\u002F\u002Fbezerraportifolio.netlify.app\u002F","Full Stack Developer | React, Next.js, TypeScript, Node.js & IA | Construindo produtos digitais e soluções SaaS","2026-11-15 02:56:04",{"source":8,"skillName":5,"commands":37,"prompt":47,"zipAvailable":48},[38,41,44],{"tool":39,"command":40},"npx","npx skills add Henrique1601\u002FSkiilsToIAs --skill videodb",{"tool":42,"command":43},"bunx","bunx skills add Henrique1601\u002FSkiilsToIAs --skill videodb",{"tool":45,"command":46},"pnpm","pnpm dlx skills add Henrique1601\u002FSkiilsToIAs --skill videodb","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fdesign\u002Fvideodb\u002FSKILL.md",true,[50,56,60,64,68,72,76,80,84,88,92],{"path":51,"resourceType":52,"resourceTypeDesc":53,"sizeBytes":54,"sourceHtmlUrl":55},"reference\u002Fapi-reference.md","REFERENCE","参考文档",20455,"https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fdesign\u002Fvideodb\u002Freference\u002Fapi-reference.md",{"path":57,"resourceType":52,"resourceTypeDesc":53,"sizeBytes":58,"sourceHtmlUrl":59},"reference\u002Fcapture-reference.md",12190,"https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fdesign\u002Fvideodb\u002Freference\u002Fcapture-reference.md",{"path":61,"resourceType":52,"resourceTypeDesc":53,"sizeBytes":62,"sourceHtmlUrl":63},"reference\u002Fcapture.md",4847,"https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fdesign\u002Fvideodb\u002Freference\u002Fcapture.md",{"path":65,"resourceType":52,"resourceTypeDesc":53,"sizeBytes":66,"sourceHtmlUrl":67},"reference\u002Feditor.md",16558,"https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fdesign\u002Fvideodb\u002Freference\u002Feditor.md",{"path":69,"resourceType":52,"resourceTypeDesc":53,"sizeBytes":70,"sourceHtmlUrl":71},"reference\u002Fgenerative.md",10263,"https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fdesign\u002Fvideodb\u002Freference\u002Fgenerative.md",{"path":73,"resourceType":52,"resourceTypeDesc":53,"sizeBytes":74,"sourceHtmlUrl":75},"reference\u002Frtstream-reference.md",15286,"https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fdesign\u002Fvideodb\u002Freference\u002Frtstream-reference.md",{"path":77,"resourceType":52,"resourceTypeDesc":53,"sizeBytes":78,"sourceHtmlUrl":79},"reference\u002Frtstream.md",1881,"https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fdesign\u002Fvideodb\u002Freference\u002Frtstream.md",{"path":81,"resourceType":52,"resourceTypeDesc":53,"sizeBytes":82,"sourceHtmlUrl":83},"reference\u002Fsearch.md",7928,"https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fdesign\u002Fvideodb\u002Freference\u002Fsearch.md",{"path":85,"resourceType":52,"resourceTypeDesc":53,"sizeBytes":86,"sourceHtmlUrl":87},"reference\u002Fstreaming.md",11867,"https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fdesign\u002Fvideodb\u002Freference\u002Fstreaming.md",{"path":89,"resourceType":52,"resourceTypeDesc":53,"sizeBytes":90,"sourceHtmlUrl":91},"reference\u002Fuse-cases.md",4451,"https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fdesign\u002Fvideodb\u002Freference\u002Fuse-cases.md",{"path":93,"resourceType":94,"resourceTypeDesc":95,"sizeBytes":96,"sourceHtmlUrl":97},"scripts\u002Fws_listener.py","SCRIPT","脚本",8422,"https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fdesign\u002Fvideodb\u002Fscripts\u002Fws_listener.py",[99,106,113,121,128,135],{"skillNo":100,"name":101,"nameZh":6,"description":102,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":103,"categories":104,"keywords":105,"publishedAt":19},"01M7E2ANBW9V6AVX5JXNCEAWF8","rag-architect-agent","Agente Arquiteto de RAG, Embeddings & Busca Vetorial. Especialista em design e implementação de pipelines de Retrieval-Augmented Generation de alta fidelidade: chunking semântico, modelagem pgvector no PostgreSQL (Neon\u002FSupabase), busca híbrida (cosseno + BM25), reranking, validação via TypeSafe AI e filosofia Ponytail (anti-overengineering).","https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fcustom-agents\u002Frag-architect-agent\u002FSKILL.md",[],[],{"skillNo":107,"name":108,"nameZh":6,"description":109,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":110,"categories":111,"keywords":112,"publishedAt":19},"01M7E29KKF8R02ZRGYE2MJM67G","rag-architecture-patterns","Padrões arquiteturais e implementação de pipelines RAG (Retrieval-Augmented Generation) de alta fidelidade para qualquer projeto ou sistema. Cobre chunking semântico, embeddings, busca híbrida (pgvector + BM25), reranking, validação via TypeSafe AI e filosofia Ponytail (anti-overengineering).","https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Fai-agents\u002Frag-architecture-patterns\u002FSKILL.md",[],[],{"skillNo":114,"name":115,"nameZh":6,"description":116,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":117,"licenseFileUrl":6,"sourceHtmlUrl":118,"categories":119,"keywords":120,"publishedAt":19},"01M7CWRA8E3BJ7CPY8N8EG28J1","skill-repair","Use this to fix and re-install agent skills that have failed installation.\nThis skill provides the necessary context and permissions to surgically update\nthe `manifest.json` after a fix has been applied.","Apache-2.0","https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Futilities\u002Fskill-repair\u002FSKILL.md",[],[],{"skillNo":122,"name":123,"nameZh":6,"description":124,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":125,"categories":126,"keywords":127,"publishedAt":19},"01M7CWR66FZP8FA47WVZ4Z2EXC","security-scan","Scan your Claude Code configuration (.claude\u002F directory) for security vulnerabilities, misconfigurations, and injection risks using AgentShield. Checks CLAUDE.md, settings.json, MCP servers, hooks, and agent definitions.","https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Futilities\u002Fsecurity-scan\u002FSKILL.md",[],[],{"skillNo":129,"name":130,"nameZh":6,"description":131,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":132,"categories":133,"keywords":134,"publishedAt":19},"01M7CWR0QPY58QPTR1P759TFNG","security-review","Use this skill when adding authentication, handling user input, working with secrets, creating API endpoints, or implementing payment\u002Fsensitive features. Provides comprehensive security checklist and patterns.","https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Futilities\u002Fsecurity-review\u002FSKILL.md",[],[],{"skillNo":136,"name":137,"nameZh":6,"description":138,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":139,"categories":140,"keywords":141,"publishedAt":19},"01M7CWQXCE40XWT4FZ3VWZFGDP","security-bounty-hunter","Hunt for exploitable, bounty-worthy security issues in repositories. Focuses on remotely reachable vulnerabilities that qualify for real reports instead of noisy local-only findings.","https:\u002F\u002Fgithub.com\u002FHenrique1601\u002FSkiilsToIAs\u002Fblob\u002Fmain\u002Futilities\u002Fsecurity-bounty-hunter\u002FSKILL.md",[],[]]