docs: captioned demo media + soundtrack + README gif - #58
Merged
Conversation
Adds tests for apply_caption() (bottom-band caption bar overlay), font-fallback when no TrueType font is available, and audio-mux behavior (--music on/off) via ffmpeg stream probing. These import apply_caption from build_demo_media and synth_music from the not-yet- created scripts/_demo_audio.py, so this commit fails collection until the next commit adds the implementation (verified: ImportError). Assisted-by: Claude Code (sonnet subagent) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- apply_caption() draws a semi-transparent bottom caption bar (12% of frame height) with centered, auto-shrinking text; tries Segoe UI / Arial TrueType fonts and falls back to PIL's default bitmap font. Applied consistently to both mp4 and gif frames after canvas normalization. scripts/demo_captions.json supplies the 6 frame -> caption mappings; --captions overrides the sidecar path. - scripts/_demo_audio.py synthesizes a calm arpeggiated background track (C-G-Am-F progression, sine waves with click-free attack/decay envelopes, low amplitude, overall fade-in/out) with stdlib wave + math + array only (no numpy). mux_audio() muxes it into the mp4 via the bundled ffmpeg binary (video copy, aac audio); build_demo_media falls back to the silent mp4 with a warning if muxing fails. Gated behind --music (gif stays silent either way). Assisted-by: Claude Code (sonnet subagent) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Regenerated demo.mp4/demo.gif from the 6 existing demo frames with --seconds-per-frame 3 --gif-width 900 --music. Committed the captioned demo.gif (6 frames, ~382KB) to docs/assets/ and embedded it near the top of README.md, just under the badges. Assisted-by: Claude Code (sonnet subagent) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Enhances the demo-media pipeline and publishes the result:
apply_caption()overlays a caption bar explaining each screen (sign in → dashboard → AI Q&A math → practice → goals → progress). Captions inscripts/demo_captions.json.scripts/_demo_audio.pysynthesizes a gentle C–G–Am–F arpeggio (pure stdlibwave+math, no numpy) muxed into the mp4 via the bundled ffmpeg (--music). GIF stays silent.docs/assets/demo.gif(382KB) committed and embedded under the badges.Verification
demo.mp4(602KB, video + AAC audio confirmed via ffmpeg probe) + captioneddemo.gif. Captions viewed — legible; math frame showcases KaTeX.🤖 Generated with Claude Code
https://claude.ai/code/session_016v4C1daTwNakL6QDbmy3MJ