Przejdź do treści
Biblioteka skilli
Marketing i treści · Przegląd i audyt

mp4-preflight

/mp4-preflight

Sprawdza gotowy plik wideo przed wysłaniem, mierząc kontener, strumienie, głośność i błyski, i wydaje werdykt.

Repozytorium
mp4-preflight ↗
Licencja
MIT
Ostatnia zmiana repozytorium
08.11.2026

Ocena i bezpieczeństwo

100/ 100Klasa: dobry
Format25 / 25
Frontmatter z nazwą i opisem, poprawna nazwa, opis do 1024 znaków, nazwa zgodna z folderem.
Odkrywalność25 / 25
Opis mówi, kiedy użyć skilla, ma sensowną długość i jest w 3. osobie.
Treść35 / 35
Co najmniej 150 słów i do 500 linii, nagłówki, listy kroków, przykłady albo kod.
Higiena15 / 15
Bez zaślepek typu TODO, bez ścieżek Windows, z licencją.
Ryzykobrak sygnałów w skanie
Pliki w paczce
6
Skrypty
0
Komentarze HTML
0
Adresy URL w SKILL.md
0
Przestarzałość

Brak sygnałów. Repozytorium zmienione 08.11.2026, bez odwołań do wycofanych modeli i API.

Licencja

MIT, otwarta: można używać i zmieniać, z zachowaniem informacji o autorze.

Co robi i kiedy

Sprawdza gotowy plik wideo przed wysłaniem, mierząc kontener, strumienie, głośność i błyski, i wydaje werdykt.

Oryginalny opis (EN)

Final technical gate for a finished video file before it is uploaded or handed over. Use when an agent (or a person) has rendered an MP4/MOV, especially one built in code with Remotion, HyperFrames, three.js, Motion Canvas or ffmpeg, and needs to prove it will arrive intact. Freezes a delivery card, measures the real file with ffprobe/ffmpeg (container, streams, loudness, true peak, black, freeze, silence, flashing, captions), and returns CLEARED, REVIEW or RETURN with timestamps to look at.

Jak działa

  1. What this is
  2. When to use it
  3. The verdicts
  4. Step by step
  5. What gets measured
  6. Examples
  7. Tips
  8. Files
Sekcje z nagłówków SKILL.md, w oryginale · 74 linii, 1 235 słów
Podgląd SKILL.md
---
name: mp4-preflight
description: Final technical gate for a finished video file before it is uploaded or handed over. Use when an agent (or a person) has rendered an MP4/MOV, especially one built in code with Remotion, HyperFrames, three.js, Motion Canvas or ffmpeg, and needs to prove it will arrive intact. Freezes a delivery card, measures the real file with ffprobe/ffmpeg (container, streams, loudness, true peak, black, freeze, silence, flashing, captions), and returns CLEARED, REVIEW or RETURN with timestamps to look at.
---

# mp4-preflight

[中文版](SKILL.zh-CN.md)

## What this is

Agents are now good at making videos: they write the script, build every frame in code, lay in sound and hand back an MP4. They are much worse at noticing that the file they hand back is broken in ways nobody asked about. A render can open on a second of black, end on a frozen frame, carry a sound that stops half a second before the picture, be four decibels too loud for the platform, refuse to start streaming until it has fully downloaded, or strobe fast enough to be a photosensitivity risk. None of these show up in a nice still, and an agent cannot hear the mix.

mp4-preflight is the step between "render finished" and "send it". It works like an aircraft preflight: a card written before the check, a fixed list of measurements on the real file, and a clear go or no-go. It never judges whether the film is good. It only proves the file is what the card says it should be.

## When to use it

- A code-built video (short film, ad, explainer, music video, product loop) has just been rendered and is about to be delivered.
- Someone hands you an MP4 and asks "is this ready to upload?"
- A platform rejected or quietly turned down an upload and you need to know why.
- You change the encode settings, the sound mix or the edit and want to confirm nothing else moved.

Do not use it to review story, taste or pacing, and do not treat its flash check as a medical or legal clearance.

## The verdicts

Each check returns PASS, WARN, FAIL, WAIVED (a measured event that the card declared on purpose, with a reason) or SKIP (could not be measured). The file gets one overall verdict:

- **CLEARED**: nothing failed or warned. Deliver it.
- **REVIEW**: only warnings. Look at the listed moments and either fix them or declare them intentional on the card with a reason.
- **RETURN**: at least one failure. Fix and re-render before anyone sees it.

## Step by step

1. **Freeze the delivery card before you look at results.** Run `python3 scripts/mp4preflight.py init --profile youtube > delivery.json` (profiles: `youtube`, `social`, `ebu-r128`, `atsc-a85`, `none`) and fill in what the destination demands: exact duration and tolerance, width, height, frame rate, whether audio is required, and the caption file if there is one. Writing it first stops you from bending the targets to match whatever came out.
2. **Declare the deliberate moments.** A fade to black at an act break, a held end card, a beat of silence: list each in `intentional` with `kind` (`black`, `freeze`, `silence`, `tail` or `flash`), `start`, `end` and a `why`. An entry without a reason is rejected. Anything that is not declared is treated as a mistake.
3. **Run the check on the exact file you will send.** `python3 scripts/mp4preflight.py check final.mp4 --card delivery.json --md preflight.md --json preflight.json`. Do not check an intermediate render and then send a re-encode.
4. **Read the table top down.** Failures come first. Each row names the moment (`at`) and what to change.
5. **Use your eyes on the flagged moments.** Run `python3 scripts/mp4preflight.py sheet final.mp4 --out sheet.png` for a timestamped contact sheet, or pull single frames at the listed times with `ffmpeg -ss <t> -i final.mp4 -frames:v 1 frame.png`. Look at them before deciding a WARN is fine.
6. **Fix at the source, not with a patch.** Loudness off by a few LU: change the master gain and re-measure; only reach for a limiter when peaks are the problem. Moov after mdat: remux with `-movflags +faststart` (no re-encode). Odd width: resize to an even number. Black open: start the timeline on the first real frame.
7. **Re-run until CLEARED, or until every remaining WARN has a written reason on the card.** Keep the final `preflight.md` next to the delivered file.
8. **Ask a human to listen.** The tool measures sound; it does not hear it. When you deliver, name the two or three seconds that matter most for the listener to check.

## What gets measured

| area | checks |
|---|---|
| container | faststart (moov before mdat), duration against the card |
| picture stream | codec, width and height, even dimensions, rotation flag, declared vs average frame rate (variable-frame-rate warning), pixel format |
| sound stream | present when required, codec, sample rate, audio length vs picture length |
| loudness | integrated loudness against the profile target (warn inside two tolerances, fail beyond), true peak against the ceiling |
| events | black runs, frozen picture, silence, a black cold open, a held or black tail |
| flashing | a whole-frame brightness proxy: pairs of opposing swings of at least 10% of full scale, counted per one-second window; more than three is a failure |
| captions | the file exists and its last cue does not run past the end of the video |

## Examples

**A 90-second short for YouTube.** The card asks for 1920x1080 at 30 fps, 90 s ±0.5, and declares one act-break black (44.0 to 45.2 s) and a held end card. The first run returns RETURN: -9.8 LUFS (too loud by 4 LU), true peak -0.2 dBTP, and five full-frame flashes in the second starting at 1:03.3 from a lightning effect. The act-break black shows as WAIVED. The fix: drop the master by 4.5 dB, slow the lightning to two flashes a second and lower its contrast, remux with faststart. The second run is CLEARED.

**A 15-second vertical product loop.** The `social` card allows no black at the head and a tail hold of at most half a second, because the loop restarts. The check warns that the last 1.4 s is a frozen frame. Trimming it makes the loop seamless and the verdict CLEARED.

**"The platform says my upload is quiet."** No card for duration or size, just `--profile youtube`. The report shows -21.8 LUFS: the file is not broken, it is simply 8 LU under the target, so the platform plays it quietly next to everything else.

## Tips

- Measure the file, never the project. A re-encode can change frame rate, pixel format and loudness.
- Integrated loudness depends on the whole programme. Changing one loud scene moves the number, so re-check after every mix change.
- A single cut from dark to bright is not a flash; the proxy only counts there-and-back pairs. A strobe inside a small part of the frame, or a saturated red flash, can be risky without moving the average, so the proxy can miss it. For anything public with strobing, use a dedicated photosensitive-epilepsy analyser as well.
- A flash waiver never gives a clean pass. It downgrades the result to WARN so a person signs off on it.
- Profiles hold common working targets, not promises. Platforms change their rules, so confirm the current numbers for the destination and put them on the card.
- If the tool says SKIP, find out why. A skipped loudness check on a file with sound usually means the audio stream cannot be decoded.

## Files

- `scripts/mp4preflight.py`: the checker (`init`, `check`, `sheet`). Python 3 standard library plus ffmpeg and ffprobe.
- `examples/`: two delivery cards and a sample report.
- `tests/`: unit tests plus two end-to-end tests that render tiny clips with ffmpeg.
Pliki w paczce (6)
  • .gitignore 1 KB
  • LICENSE 1 KB
  • README.md 5 KB
  • README.zh-CN.md 5 KB
  • SKILL.md 7 KB
  • SKILL.zh-CN.md 7 KB

Wersje

W bazie nie ma innych skilli o nazwie mp4-preflight.

Migawka bazy z 13.11.2026 · wersja paczki a594ebe2da9e (skrót SHA-256 całej paczki)

Pobrania w ostatnich 30 dniach: 0 · ranking

Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.

Podobne skille

  • 100film-preflight
    Sprawdza gotowy film jednym przebiegiem ffmpeg przed publikacją: początek, czarne klatki, zamrożenia, cięcia i głośność.
  • 100ffmpeg-skill
    Edytuje wideo i audio lokalnym FFmpeg: cięcie, łączenie, kadrowanie, napisy, usuwanie ciszy i eksport na platformy.
  • 100ffmpeg
    Przetwarza, sprawdza i naprawia pliki audio i wideo w FFmpeg: kompresja, przycinanie, napisy, głośność i strumienie.
  • 95ffmpeg-skill
    Edytuje wideo i audio lokalnym FFmpeg: cięcie, łączenie, napisy, wycinanie ciszy, normalizację głośności i eksport pod platformy.
  • 100video-composition
    Składa, miksuje i waliduje gotowe wideo z FFmpeg i FFprobe: łączenie, nakładki, napisy, głośność, przejścia i eksport.
  • 100ffmpeg-media-workflow
    Planuje i wykonuje lokalne przekształcenia wideo i audio, takie jak napisy, głośność, synchronizacja i eksport.

Uwagi i zgłoszenia

Wiadomość trafi do Bartosza Sokolińskiego. Adres e-mail jest potrzebny tylko do odpowiedzi. Szczegóły w polityce prywatności.