Find the edits in a 4-shot screen recording clip
Proof frames
Tool calls
detect_cuts
Arguments
{
"source": "$CLIP"
}
Result
{
"ok": true,
"data": {
"cuts": [
{
"timestamp_sec": 5.85,
"score": 0.809778,
"kind": "transition"
},
{
"timestamp_sec": 9.04,
"score": 0.189173,
"kind": "cut"
}
],
"total": 2
}
}
frame_at
Arguments
{
"source": "$CLIP",
"time_sec": 3.65
}
Result
{
"ok": true,
"data": {
"frame_time_sec": 3.64,
"width": 640,
"height": 360,
"source_width": 640,
"source_height": 360,
"crop": null,
"scale": 1,
"file_path": "<cache>/cf56f5311d412dfc3928/frame_at/frame_at_dc30b88b22dbe3e7.png",
"tool_file": {
"_tag": "ToolFile",
"name": "frame_at_dc30b88b22dbe3e7.png",
"mimeType": "image/png",
"encoding": "base64",
"data": "<13544 base64 chars dropped>",
"byteLength": 10158
}
}
}
Question and answer
- Question
- Where are the edits in this video? Which are hard cuts and which are fades?
- Answer
- detect_cuts lists 2 edits: 5.85 s is a fade, 9.04 s is a hard cut.
- Tool returned
- [5.85,9.04]
- Truth
- [3.64,5.9,9]
How it was checked
- Truth from
- constructed
- Fixed at
Planted by this recipe before any tool ran: ffmpeg cut 4 single-shot pieces from the source (no shot change by ffmpeg scene score above 0.2 within 0.5 s of a piece's edges; piece starts in the source 4.48, 14.44, 55.4, 46.88 s, piece lengths 3.64, 2.76, 3.6, 3.8 s, starts at least 8 s apart) and joined them in order with hard cuts and one 1 s cross-fade (xfade) after piece 2. The truth is the planted edit times 3.64 s (hard cut), 5.9 s (fade), 9 s (hard cut): each hard cut at its join, and the fade's middle. The calls are detect_cuts with its default threshold, then frame_at a quarter frame after the first planted edit (a fixed rule).
A script joined 4 pieces of one public screen recording clip with hard cuts and one 1 s fade, so this tests detection on a known constructed edit, not on a professionally cut film, and the audio was removed.
Try it yourself
Using agentic-video, find the edits in my video (the file I attach or name). Use detect_cuts to list every cut time, then check the first edit with frame_at. Tell me which edits are hard cuts and which are fades, with the times.
- Get the .mcpb file and open it in Claude Desktop.
- Or:
pip install agentic-video
Clip and licence
- Licence
- CC-BY-SA-4.0
- Author
- NairobiPapel
- Source
- commons.wikimedia.org
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.