ffmpeg-video-editing

ffmpeg-video-editing is a skill for Claude Code, Codex from benchflow-ai/skillsbench. It costs 59 tokens per session (1,039 once invoked), scanned A, original, Apache-2.0.

Instructions for editing video files with FFmpeg, a command-line video-processing program. They cover keeping, removing, joining, and re-encoding sections of common video formats.

In plain words
What is it for?
Use it to trim clips, remove sections from the middle, join compatible segments, process several cuts, or re-encode for frame-accurate editing.
Why use it?
It provides repeatable commands for precise video changes without needing a graphical editing application.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to trim clips, remove sections from the middle, join compatible segments, process several cuts, or re-encode for frame-accurate editing.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/benchflow-ai/skillsbench/ffmpeg-video-editing
About the project

SkillsBench is a benchmark for measuring how effectively AI agents use modular skills—folders containing instructions, scripts, and resources—to complete specialized tasks. It helps researchers and developers evaluate both skill quality and agent behavior, including tasks that require combining multiple skills. The catalogue’s skills and instructions are evaluated as part of this workflow.

benchflow-ai/skillsbench · 1,754 stars · on GitHub · skillsbench.ai

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add benchflow-ai/skillsbench --skill ffmpeg-video-editing
Clone the repo
git clone --depth 1 https://github.com/benchflow-ai/skillsbench

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for ffmpeg-video-editing

README.md
[![agentmods](https://agentmods.dev/badge/skills/benchflow-ai/skillsbench/ffmpeg-video-editing/github.svg)](https://agentmods.dev/skills/benchflow-ai/skillsbench/ffmpeg-video-editing)
Your own site
<a href="https://agentmods.dev/skills/benchflow-ai/skillsbench/ffmpeg-video-editing"><img src="https://agentmods.dev/badge/skills/benchflow-ai/skillsbench/ffmpeg-video-editing/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for ffmpeg-video-editing

Your own site · 80×15
<a href="https://agentmods.dev/skills/benchflow-ai/skillsbench/ffmpeg-video-editing"><img src="https://agentmods.dev/badge/skills/benchflow-ai/skillsbench/ffmpeg-video-editing.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 59 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,039 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00059 $0.01039
Opus 5 $0.00030 $0.00519
Sonnet 5 $0.00012 $0.00208
Haiku 4.5 $0.00006 $0.00104

Measured 9d ago against content hash 4e33abec2186, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

ffmpeg-video-editing scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Runs shell commandslowCapability

Expected in a hook, worth knowing in a rule or an instructions file.

result = subprocess.run([
tasks-extra/video-filler-word-remover/environment/skills/ffmpeg-video-editing/SKILL.md · 141 lines

How it starts

The opening of the file, as written. The whole thing — 141 lines — stays where its author put it; the contents beside it link to each section on GitHub.

FFmpeg Video Editing

Cutting Video Segments

Extract a portion (keep segment)

# Extract from start_time to end_time
ffmpeg -i input.mp4 -ss START -to END -c copy output.mp4

# With re-encoding for frame-accurate cuts
ffmpeg -i input.mp4 -ss START -to END -c:v libx264 -c:a aac output.mp4

Remove a segment (cut out middle)

To remove a segment, split into parts and concatenate:

# 1. Extract before the cut
ffmpeg -i input.mp4 -to CUT_START -c copy part1.mp4

# 2. Extract after the cut  
ffmpeg -i input.mp4 -ss CUT_END -c copy part2.mp4

# 3. Concatenate
ffmpeg -f concat -safe 0 -i filelist.txt -c copy output.mp4

Concatenating Multiple Segments

Using concat demuxer (recommended for same-codec files)

Create a file list (segments.txt):

file 'segment1.mp4'
file 'segment2.mp4'
file 'segment3.mp4'

Then concatenate:

ffmpeg -f concat -safe 0 -i segments.txt -c copy output.mp4

Using filter_complex (for re-encoding)

ffmpeg -i seg1.mp4 -i seg2.mp4 -i seg3.mp4 \
  -filter_complex "[0:v][0:a][1:v][1:a][2:v][2:a]concat=n=3:v=1:a=1[v][a]" \
  -map "[v]" -map "[a]" output.mp4

Removing Multiple Segments (Batch)

For removing many short segments (like filler words), the efficient approach:

  1. Calculate the "keep" segments (inverse of remove segments)
  2. Extract each keep segment
  3. Concatenate all keep segments
import subprocess
import os

def remove_segments(input_file, segments_to_remove, output_file):
    """
    segments_to_remove: list of (start, end) tuples in seconds
    """
    # Get video duration
    result = subprocess.run([
        'ffprobe', '-v', 'error', '-show_entries', 'format=duration',
        '-of', 'default=noprint_wrappers=1:nokey=1', input_file
    ], capture_output=True, text=True)
    duration = float(result.stdout.strip())

    # Sort segments and merge overlapping
    segments = sorted(segments_to_remove)

    # Calculate keep segments (gaps between remove segments)
    keep_segments = []
    current_pos = 0.0

    for start, end in segments:
        if start > current_pos:
            keep_segments.append((current_pos, start))
        current_pos = max(current_pos, end)

    if current_pos < duration:
        keep_segments.append((current_pos, duration))

    # Extract each keep segment
    temp_files = []
    for i, (start, end) in enumerate(keep_segments):
        temp_file = f'/tmp/seg_{i:04d}.mp4'
        subprocess.run([
            'ffmpeg', '-y', '-i', input_file,
            '-ss', str(start), '-to', str(end),
            '-c', 'copy', temp_file
        ], check=True)
        temp_files.append(temp_file)

    # Create concat list
    list_file = '/tmp/concat_list.txt'
    with open(list_file, 'w') as f:
        for temp_file in temp_files:
            f.write(f"file '{temp_file}'\n")

    # Concatenate
    subprocess.run([
        'ffmpeg', '-y', '-f', 'concat', '-safe', '0',
        '-i', list_file, '-c', 'copy', output_file
    ], check=True)

    # Cleanup
    for f in temp_files:
        os.remove(f)
    os.remove(list_file)

Read the full file on GitHub · 141 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 141 lines · 59 tokens per session scan A 4e33abec2186

Subscribe to this mod's changes

ffmpeg-video-editing is a skill published in the GitHub repository benchflow-ai/skillsbench (1,754 stars, last pushed 1mo ago), licensed Apache-2.0. It adds 59 tokens to every session and 1,039 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.