Find the frame rate and size of a clip
1:00CC-BY-SA-4.0 · Taco fleur
Proof frames
Tool calls
probe_video
Arguments
{
"source": "$CLIP"
}
Result
{
"ok": true,
"data": {
"source_path": "~/work/cards/probe-sports/clip.mp4",
"duration_sec": 60,
"width": 320,
"height": 240,
"fps": 24,
"format_name": "mov,mp4,m4a,3gp,3g2,mj2",
"size_bytes": 2595310,
"has_audio": true,
"audio_codec": "aac",
"video_codec": "h264",
"fingerprint": "894110967c448bf9048f",
"has_video": true
}
}
contact_sheet
Arguments
{
"source": "$CLIP",
"samples": 4
}
Result
{
"ok": true,
"data": {
"file_path": "<cache>/894110967c448bf9048f/contact_sheets/sheet_4samples_4cols_e05b35.jpg",
"sample_count": 4,
"rows": 1,
"cols": 4,
"start_sec": 7.5,
"end_sec": 52.5,
"timestamps": [
7.5,
22.5,
37.5,
52.5
],
"frame_width": 768,
"frame_height": 576,
"tool_file": {
"_tag": "ToolFile",
"name": "sheet_4samples_4cols_e05b35.jpg",
"mimeType": "image/jpeg",
"encoding": "base64",
"data": "<241180 base64 chars dropped>",
"byteLength": 180885
}
}
}
Question and answer
- Question
- What is the frame rate of this video, and how big is it?
- Answer
- The file plays at 24 frames per second.
Check passedanswer 24.0, expected 24.0 ±0.05
How it was checked
- Truth from
- constructed
- Fixed at
Planted by this recipe: ffmpeg re-encoded the source at 24 frames per second and 320 px wide (the choice is seeded from the card id). The truth is that setting; the tolerance 0.05 allows for rounding in the probe.
The source was re-encoded by a script at 24 frames per second and 320 px wide, so the answer is the setting the script chose, not a real-world camera fact.
Try it yourself
Use agentic-video to probe my video. Tell me its frame rate, width and height, then make a contact sheet of it. Use my own file.
- 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
- Taco fleur
- Source
- commons.wikimedia.org
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.