agentleFS
binay-pybinay-py/claude-skills/skills/event-recap-video/SKILL.md

event-recap-video

Skill1 starsChanged 6 days agoMITView on GitHub

Turn a pile of phone photos/videos from an event (conference, trip, retreat, wedding) into a hooky recap video with ffmpeg — a 16:9 main cut, a 9:16 version, and a ~45 s beat-synced reel. Use when the user wants a recap/highlight/montage video from their own footage.

  • Installs packages

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

3 rules. About 0 are common, 1 is distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Put each export/zip in its own folder under raw/.

    line 20
  2. Distinctive:

    If a render is killed, delete clip files that fail ffprobe before re-running (the cache would reuse them).

    line 55
  3. Very specific:

    When someone approves the 16:9 edit and asks for 9:16, give them the SAME edit vertical (python build.py vertical-full).

    line 58

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Event recap video

Tested end to end on a 780-item event library. Requires ffmpeg/ffprobe on PATH and Python 3.10+ with pip install pillow pillow-heif numpy.

Scripts live next to this file. Copy into the project:

  • scripts/analyze.py, build.py, reel.py, motion.py, fonts.py → project root
  • scripts/work/*.py → <project>/work/
  • examples/*.json → project root, then edit them

Project layout: raw/ (untouched originals), music/, work/ (cache), output/, edit.json (the whole edit). Fonts are found automatically on Windows/macOS/Linux; override with FONT_SERIF, FONT_SERIF_BOLD, FONT_SANS_BOLD, FONT_BLACK, FONT_EMOJI, FONT_DEVANAGARI. Nepali/Hindi titles, labels and reel text switch to a Devanagari font automatically and ffmpeg shapes them correctly, but it shapes a whole line in the script of its first letter: start a mixed line with the Nepali word ("दिन १ · Jun 12", not "Jun 12 · दिन १"). Emoji only work in motion.py stickers; build.py and reel.py drop them because ffmpeg draws them as boxes. motion.py stickers and the shortlist are drawn with Pillow; their Devanagari is shaped by ffmpeg word by word when Pillow has no raqm.

1. Get media

  • Put each export/zip in its own folder under raw/. Never modify originals.
  • Google Photos has no API for an existing library: drive the user's own logged-in browser over CDP (see the brave-cdp skill in this repo). Grid items are a[href*="/photo/"]; day headers are [role=checkbox][aria-label^="Select all photos from"].
  • Select day headers with REAL mouse events (Input.dispatchMouseEvent), verify the "N selected" text, press Shift+D. The tab must be in front (Page.bringToFront) or the grid stays grey.
  • Google clears the selection after a download and header aria-checked can go stale; reload before reselecting.
  • Browser.setDownloadBehavior with allowAndName saves the zip under its GUID with no extension; watch Browser.downloadProgress for completed.

2. Analyze and pick

  • python analyze.py → work/media.json (capture time from EXIF / video creation_time in local tz, blur, brightness, duplicates, loudness) + per-day contact sheets in work/sheets/.
  • python work/vsheets.py → 3-frame strips per video. LOOK at every sheet. Skip clips that rotate mid-recording, pocket shots and dark night clips.
  • python work/loudest.py ID:seconds ... finds the loudest window (singing, speech, cheering). Verify with a 1 fps frame strip before trimming.
  • Shared/forwarded files have no capture date (falls back to file mtime) — place them by eye.

3. Edit (what audiences liked)

  • Lead with VIDEO (~90% clips); photos only for strong group shots. Photo-heavy cuts feel slow.
  • Cold open hook: 8–10 clips of 1.2–1.8 s, hook_xf 0.1 near-hard cuts, then the title card. Then days in order with a small "label": "Day N · date" on each day's first clip, 3–4 s cuts, and a few 9–12 s moments flagged "speech": true (music ducks under them).
  • Music makes or breaks the hook. Chain 2 tracks of similar tempo ("music": [a, b], 3 s crossfade) instead of looping one. python work/bpm.py file.mp3 estimates tempo.
  • edit.json keys: title, subtitle, closing, closing_sub, title_bg / closing_bg (+ _bg_at for video ids), music / vertical_music, music_volume, duck_volume, ambient_volume, photo_seconds, hook_xf, closing_seconds, horizontal_hook, horizontal, vertical_hook, vertical. Segment: {"id", "at" (0–1 centre) | "start", "dur", "speech", "label", "xf"}.
  • python work/shortlist.py → output/shortlist.jpg (a frame at every cut). Show it to the user before rendering.

4. Render and QC

  • python build.py [horizontal|vertical|vertical-full] — per-segment cache in work/seg, xfade chain, loudnorm −14 LUFS, x264.
  • EDIT=other.json OUT_SUFFIX=-v2 python build.py renders an alternative edit without touching the main one.
  • QC every render: nb_frames == duration*30 (xfade chains can drop frames), blackdetect count 0, ebur128 ≈ −14 LUFS, and a tile sheet of frames (fps=1/5,tile=8x6) to eyeball rotation and cut-off titles.
  • ffmpeg 7+ prefers -/filter_complex file over the deprecated -filter_complex_script.

5. Beat-synced reel (IG / TikTok / FB) — reel.py + reel.json

  • python reel.py → output/reel.mp4 (~45 s), built on build.py's segment renderer.
  • Cuts land exactly on the beat grid (bpm hint, auto phase, frame-rounded cut times). Double-check tempo: naive estimators often return half/double (85 vs 154).
  • First second = the most surprising moment, with a "POV: …" line. 4-beat cuts, 6–8 beats on hero moments, slow push-in on every clip, white flash on section starts.
  • Text: heavy sans, white with thick black outline, ~24% from the top (clear of TikTok/IG buttons), slide-up fade. 5–7 short lines total; the last one is the event name.

6. Meme / motion cut — motion.py + motion.json (only when the user asks for memes/stickers)

  • Many people find this style too much for a heartfelt event. Default to sections 3–5.
  • One long, steady track (~3 min) instead of chaining; beat grid via comb-filter search.
  • Per clip: beats, speed (0.5 slow-mo / 2 fast-forward), freeze (beats; tape-stop + silence + desaturate), cap sticker (rounded box, tilt, elastic pop, colour emoji), day slam titles + whoosh, title, verse, shake, punch, flash, zoom.
  • If a render is killed, delete clip files that fail ffprobe before re-running (the cache would reuse them).

7. Vertical and social delivery

  • When someone approves the 16:9 edit and asks for 9:16, give them the SAME edit vertical (python build.py vertical-full). Don't restyle an approved edit; "make it more attractive" means polish only.
  • Platforms (especially Facebook) mute posts with unlicensed music. Offer an original-sound version (an edit with "music": null) and/or a silent copy (ffmpeg -i in.mp4 -an -c copy out.mp4) so music can be added from the platform's licensed library.
  • Final polish: eq=contrast=1.07:saturation=1.2:gamma=0.97,colorbalance=rm=0.03:bm=-0.03:rh=0.02:bh=-0.02,unsharp=5:5:0.45,vignette=angle=PI/5.5 + audio highpass=80,dynaudnorm,acompressor,loudnorm=I=-14.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.