mirror of
https://github.com/hypit-ai/hypit.git
synced 2026-11-06 18:57:21 +00:00
920fa76cb7
Every file here is re-encoded, never re-exported: nothing was re-rendered from
a source project, so no frame, sample or pixel is chosen differently than it
was before. The saving is entirely encoder settings that were wrong for the
material.
docs/quickstart/videos (8 files, 90.1 MiB -> 18.7 MiB). These are screen
recordings that were exported at live-action bitrates -- 3.9 to 7.4 Mbps for
flat UI with long static stretches, which is what a camera needs and a screen
capture never does. Re-encoded with
-c:v libx264 -crf 23 -preset slow -pix_fmt yuv420p -c:a copy \
-movflags +faststart
The audio is copied, not re-encoded, and that half is worth stating because the
first attempt of this change got it wrong: it carried -an and dropped the audio
track outright, on the untested assumption that screen recordings have none.
Five of the eight are digital silence (-91 dB) but three carry real audio,
peaking to 0.0 dB. Verified per file against the previous revision: video frame
count, audio frame count, width, height and duration all match exactly (e.g.
request_natural_language_changes 1046 video / 1502 audio frames,
review_the_paid_result 604 / 869), and the decoded PCM of every audio track
hashes identically to the original.
examples/ranking-football/*/reused/{messi,ronaldo}.mp4 (6 files, 42.7 MiB ->
17.0 MiB). Same video settings, -c:a copy. 241 frames unchanged, SSIM 0.9837 /
PSNR 41.9 dB, decoded audio PCM hash identical to the original.
38 PNGs across examples/ and packages/*/preview (89.4 MiB -> 57.3 MiB), losslessly
recompressed with -strip -define png:compression-level=9. Extensions and format
unchanged; the decoded RGBA pixel hash matches the original for 38 of 38, so
this is metadata and deflate settings only.
No file grew. Every mp4 keeps moov ahead of mdat, so they still start playing
before they finish downloading.
This does not shrink .git -- the ~725 MiB of history still holds every previous
blob, and only a rewrite would change that. What gets cheaper is everything that
touches a single revision: shallow clones, a working tree, CI checkouts, and
downstream hypihub, which embeds these assets into its binary.