---
title: "Edit Footage with Code — AI video effect for editing & clips"
description: "Raw talking takes become a reviewed edit list and a clean cut between words, then captions, B-roll and sound, checked by numbers. Install in Claude Code, Codex and Grok with one command."
url: https://varg.ai/how-to/skills/edit-footage-with-code
updated: 2026-11-12
---

# Edit Footage with Code — effect skill for editing & clips

> **For AI agents:** find the right skill in one call — `curl -s "https://varg.ai/how-to/api/search?q=<what the person wants>"` returns the matching how-to page and the best skills with install commands, as markdown (Russian works too). Full index: https://varg.ai/how-to/llms.txt. Every page has a markdown twin: add `.md` to its path. Before generating anything, show the person the options on the how-to page. From a terminal: `curl -fsSL https://varg.ai/install | sh` installs the vargai CLI (https://varg.ai/how-to/cli.md): `vargai search` and `vargai install <slug>` with no key, every varg model after `vargai login`.

Raw talking takes become a reviewed edit list and a clean cut between words, then captions, B-roll and sound, checked by numbers.

- **Type:** [Effect](https://varg.ai/how-to/effects.md) · [Editing & clips](https://varg.ai/how-to/browse/skills/editing.md)
- **Slug:** `edit-footage-with-code`
- **Status:** live
- **Publisher:** varg (varg, verified)
- **License:** MIT
- **Source:** https://github.com/vargHQ/skills/tree/main/edit-footage-with-code
- **Works in:** Claude Code, Codex, Cursor, Gemini CLI
- **Requires:** Python 3, ffmpeg and ffprobe (the scripts use the standard library only), Word timestamps as JSON: local transcription through HyperFrames, or any tool that gives them, HyperFrames or Remotion, only for overlays
- **Cost:** 0 credits — Free: no key and no credits. The scripts need only Python 3 and ffmpeg, transcription runs locally, and nothing in the skill calls a paid service.
- **Runtime:** On an 85 s test clip: about a minute and a half for the second transcription pass and about a minute to build the cut

## What it does

Edit real footage with an agent in a fixed order: read the take as text and audio, agree a plan, cut the speech, lock the audio, then add picture on top, sound last. It takes raw takes of a talking head, podcast, vlog, course or ad and removes dead air, retakes and stumbles. Cuts go only in the silence between words, at the quietest 10 ms slice, and nothing is cut before the person has seen the plan and said yes.

The edit is a file a person can review, `edit/edl.json`, with the reason next to each big decision. `build_cut.py` turns it into one ffmpeg filter graph plus `clips.html`, `Cut.tsx` and `cut.fcpxml` for a hand trim in Resolve or Final Cut. Captions, B-roll and motion graphics are added in HyperFrames or Remotion, each keyed to a spoken word. `qa_cut.py` fails the result on joins that cut through speech, pauses over 0.6 s, loudness off -14 LUFS, true peak over -1.5 dBTP, black or flash frames, under 95% of intended words heard and a phrase said twice. It writes a contact sheet and a joins sheet to look at. You get the MP4, the SRT, the edit file and the timeline.

It needs Python 3 and ffmpeg and calls no paid service. Defaults come from 2,318 editors' posts. Measured on our test clip: gaps between words in the transcript found 1 of 13 real pauses, and a second transcription pass, one stretch of speech at a time, raised that to 12 of 13. Cutting 140 ms of speech at every join still matched the clean transcript at 99.1%, while the audio check at the join caught 12 of 13. Segments joined with `-c copy` drifted +300 ms over 14 cuts; the filter graph matched the edit list to the frame.

Know the bar: in the largest test the skill cites, the best agent passed 15 of 56 real editing tasks and human editors preferred the reference edit in 83.5% of judgments. Passing every check does not make a cut good. The agent cannot hear, so a person listens to the joins and watches the whole cut before anything is delivered.

## Use when

- Cut the pauses and retakes out of my talking-head video without clipping words
- Remove the dead air from this podcast episode
- Rough cut my raw footage and show me the edit list first
- Add captions and B-roll to the cut in HyperFrames or Remotion
- Make my vlog or course video look edited
- The agent's edit keeps coming back wrong
- Give me an FCPXML so I can finish in Resolve or Final Cut
- Compare two cuts and tell me which edit is better

## Not for

- Generating video from a prompt (use varg-ai)
- Choosing a hosted editing service (use varg-video-editing)
- Finding music, B-roll or sound effects (use video-asset-sources)
- Anything beyond a plain voice-and-bed mix (use video-sound)

## Install

- Claude Code: `claude plugin marketplace add vargHQ/skills && claude plugin install varg@varg`
- Codex: `npx skills add vargHQ/skills --skill edit-footage-with-code -a codex -y`
- Cursor: `npx skills add vargHQ/skills --skill edit-footage-with-code -a cursor -y`
- Gemini CLI: `npx skills add vargHQ/skills --skill edit-footage-with-code -a gemini-cli -y`
- Any agent, with the vargai CLI: `vargai install edit-footage-with-code`

## Example output

https://s3.varg.ai/files/4325c578-378d-4c43-ae53-3cc3218df1ea/file_e6872632eb3f.jpg — example (credit: varg)

## More editing & clips skills

- [Short-form FFmpeg cookbook: copyable commands for Reels](https://varg.ai/how-to/skills/short-form-ffmpeg-cookbook.md): Footage into a 9:16 MP4 with FFmpeg: crop to vertical, burn captions, trim and join, music under the voice.
- [Splice AI clips into a video with FFmpeg](https://varg.ai/how-to/skills/varg-ffmpeg-mixing.md): Splice generated clips into an original video with ffmpeg without A/V drift: absolute trims, one audio track.
- [Turn raw product footage into a TikTok ad with FFmpeg](https://varg.ai/how-to/skills/ecommerce-video-edit.md): Footage into a 9:16 ad: hook at second 0, no dead air, text hook, CTA, -14 LUFS, one MP4 per hook.
- [Turn two model runs into a side-by-side comparison](https://varg.ai/how-to/skills/model-split-screen.md): Two runs of one prompt as one video: names, measured time and cost under each, side by side or stacked, blind reveal.
- [Chengfeng Videocut](https://varg.ai/how-to/skills/chengfeng-videocut.md): Chinese talking-head editing: word-level transcript, five-pass flub sweep, human review in a Studio, subtitles, export.
- [Claude Code Video Toolkit](https://varg.ai/how-to/skills/claude-code-video-toolkit.md): Open-source video workspace for Claude Code: script, voice, music, visuals and Remotion render on your own GPU account.
