agentcut 0.2.26 → 0.2.27

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (94) hide show
  1. package/README.md +177 -177
  2. package/dist/studio/agents/claude.js +3 -2
  3. package/dist/studio/agents/claude.js.map +1 -1
  4. package/dist/studio/chat.js +1 -1
  5. package/dist/studio/chat.js.map +1 -1
  6. package/dist/studio/cli.js +24 -24
  7. package/dist/studio/download.d.ts +24 -0
  8. package/dist/studio/download.js +234 -0
  9. package/dist/studio/download.js.map +1 -0
  10. package/dist/studio/host.js +8 -0
  11. package/dist/studio/host.js.map +1 -1
  12. package/dist/studio/housekeeping.d.ts +2 -2
  13. package/dist/studio/housekeeping.js +18 -17
  14. package/dist/studio/housekeeping.js.map +1 -1
  15. package/dist/studio/release-cursor.js +21 -21
  16. package/dist/studio/release-video.js +10 -10
  17. package/dist/studio/tools.js +7 -0
  18. package/dist/studio/tools.js.map +1 -1
  19. package/package.json +56 -56
  20. package/template/AGENTS.md +14 -14
  21. package/template/components/README.md +70 -70
  22. package/template/components/before-after/BeforeAfter.tsx +89 -89
  23. package/template/components/catalog.ts +107 -107
  24. package/template/components/cinematic/Device3D.tsx +324 -324
  25. package/template/components/cinematic/devices3d/display-model.ts +184 -184
  26. package/template/components/cinematic/devices3d/iphone-model.ts +643 -643
  27. package/template/components/cinematic/devices3d/macbook-model.ts +608 -608
  28. package/template/components/cinematic/devices3d/models.ts +657 -657
  29. package/template/components/cinematic/devices3d/runtime.ts +267 -267
  30. package/template/components/cinematic/math.ts +100 -100
  31. package/template/components/color/grade-effect.ts +650 -650
  32. package/template/components/color/grade.ts +512 -512
  33. package/template/components/color/looks.ts +154 -154
  34. package/template/components/countdown/Countdown.tsx +166 -166
  35. package/template/components/dot-trace-title/DotTraceTitle.tsx +181 -181
  36. package/template/components/dot-trace-title/meta.json +51 -51
  37. package/template/components/generate/GenerateReveal.tsx +381 -381
  38. package/template/components/hook-card/HookCard.tsx +554 -554
  39. package/template/components/index.ts +199 -199
  40. package/template/components/lib.ts +191 -191
  41. package/template/components/line-diagram/LineDiagram.tsx +205 -205
  42. package/template/components/line-diagram/meta.json +215 -215
  43. package/template/components/list-card/ListCard.tsx +104 -104
  44. package/template/components/live-clip.ts +75 -75
  45. package/template/components/looks.tsx +1447 -1447
  46. package/template/components/loops/LoopCanvas.tsx +132 -132
  47. package/template/components/loops/engine.ts +184 -184
  48. package/template/components/loops/library.ts +667 -667
  49. package/template/components/loops/library2.ts +777 -777
  50. package/template/components/motion-loop/MotionLoop.tsx +37 -37
  51. package/template/components/motion-loop/meta.json +311 -311
  52. package/template/components/props.ts +73 -73
  53. package/template/components/quote-card/QuoteCard.tsx +71 -71
  54. package/template/components/style-layer.tsx +233 -233
  55. package/template/components/styles.ts +113 -113
  56. package/template/components/types.ts +66 -66
  57. package/template/components/word-pop/WordPop.tsx +59 -59
  58. package/template/components/word-stack/WordStack.tsx +122 -122
  59. package/template/presets/charcoal-sketch/PROMPT.md +48 -48
  60. package/template/presets/charcoal-sketch/scripts/duck_music.py +34 -34
  61. package/template/presets/punk-cut-paper/scenes/Motif.tsx +376 -376
  62. package/template/presets/punk-cut-paper/scenes/Photo.tsx +73 -73
  63. package/template/presets/punk-cut-paper/scenes/Ransom.tsx +119 -119
  64. package/template/runtime/composition.tsx +1189 -1189
  65. package/template/runtime/helpers.tsx +230 -230
  66. package/template/runtime/index.tsx +22 -22
  67. package/template/runtime/types.ts +315 -315
  68. package/template/skill/SKILL.md +186 -187
  69. package/template/skill/references/broll.md +44 -44
  70. package/template/skill/references/browser-export.md +61 -61
  71. package/template/skill/references/cinematic.md +206 -206
  72. package/template/skill/references/color.md +79 -79
  73. package/template/skill/references/craft.md +97 -97
  74. package/template/skill/references/editing-styles.md +57 -57
  75. package/template/skill/references/feature-launch.md +34 -34
  76. package/template/skill/references/footage.md +72 -72
  77. package/template/skill/references/format.md +142 -142
  78. package/template/skill/references/how-to.md +146 -146
  79. package/template/skill/references/launch-direction.md +89 -89
  80. package/template/skill/references/loops.md +151 -151
  81. package/template/skill/references/mcp-external.md +19 -19
  82. package/template/skill/references/performance.md +93 -93
  83. package/template/skill/references/person-cutout.md +19 -19
  84. package/template/skill/references/presets.md +60 -60
  85. package/template/skill/references/product-launch.md +134 -134
  86. package/template/skill/references/release-capture.md +53 -53
  87. package/template/skill/references/sound.md +167 -166
  88. package/template/skill/references/style-spy.md +160 -160
  89. package/template/skill/references/website-howto.md +45 -45
  90. package/template/starter/.studio/chat.json +1 -1
  91. package/template/starter/layers.json +46 -46
  92. package/template/starter/notes.md +4 -4
  93. package/template/starter/project.json +13 -13
  94. package/template/starter/scenes/Title.tsx +38 -38
@@ -1,93 +1,93 @@
1
- # Preview performance
2
-
3
- The user watches the live preview, which draws every scene in their browser at playback speed. A scene
4
- that takes too long per frame makes the preview skip frames (choppy) and can freeze the tab while you
5
- capture frames. The export doesn't skip: it renders every frame at full quality. So:
6
-
7
- **Never lower what the render shows to make the preview smoother.** No lower resolution, fewer
8
- elements on screen, skipped frames, softer images or simpler motion. Every change below must render
9
- the same frames as before (check with captures); when one can't, keep the look and tell the user that
10
- part previews choppy but exports perfectly.
11
-
12
- ## Measure
13
-
14
- For website how-to videos, use the stall recovery in `website-howto.md`. Keep all required
15
- format, visual, playback and audio checks. Run page-heavy tools in sequence. A timed-out request
16
- can continue in the page; inspect `page.activeWork` before retrying. A small recovery probe does
17
- not replace the full review or reduce final render quality.
18
-
19
- - `agentcut_preview_check` (from/to in frames) plays a range muted in the user's preview and returns
20
- per visual clip: frames played and dropped, loading stalls, the longest freeze, the most DOM elements
21
- the clip drew, and a verdict: `smooth`, `choppy` from 20 % dropped, `heavy` from 40 % (and at least 6
22
- dropped frames); a freeze over a second or more than 0.5 s of stalls also counts as slow. It takes as
23
- long as the range plays: check the clip you changed, not the whole video every time. One check at a
24
- time; it stops if the user pauses or seeks.
25
- - `slowClips` lists the likeliest cause first. `sharesDropsOnly` marks a clip (often text or captions)
26
- that only sits on top of a slower one: fix the other one. `slowToMount` means the clip drops frames in
27
- the second before it starts, while it mounts early: its setup work is heavy (see rule 4), even when it
28
- plays fine afterwards.
29
- - `agentcut_status` → `page.previewPerformance` has the latest check (`lastCheck`), the user's own
30
- playback (`playback`) and seek timings (`scrub`). `current: false` means it was measured on an older build.
31
- - A check also returns `scrub`: how long a seek takes to reach the screen (`medianMs`, `p95Ms`, `slowClips`),
32
- jumping forward and back through the range. A scene can play well and still lag on a drag, because every
33
- seek draws it from nothing. Above 120 ms a drag visibly lags: the same fixes below apply, and work a scene
34
- repeats on every frame (not just at mount) is the usual cause.
35
- - Footage needs nothing from you: the helper makes fast-seeking copies for the preview by itself, and
36
- captures and exports always read the original. Only `src` on a video clip gets one, so use a video clip
37
- rather than a video inside a scene when footage is slow to scrub.
38
- - Run a check after building or changing a heavy scene (walls and grids, hundreds of elements, image
39
- sequences, big blurs, generated images) and before you say you're done. A first run includes loading
40
- (stalls); run it again to see steady playback. A machine's own jitter varies between runs: act on a
41
- `choppy` only when a second run agrees.
42
-
43
- ## Make it lighter (same pixels)
44
-
45
- 1. **Image sequences that stall.** Swapping a different picture every few frames makes the browser fetch
46
- and decode a full image each time. When a check shows stalls or drops on one, encode it into one video,
47
- but only if it keeps the same picture and timing:
48
- - Keep the images when the frames have transparency (H.264 has none, they'd render on black), or
49
- small text and hard-edged colored UI (4:2:0 color softens it).
50
- - The video must show each image on exactly the frames it shows now. Images held the same number of
51
- frames each: `-framerate <fps / frames per image>`. Any other timing (eased, held, reversed): write
52
- the images out in display order, one file per project frame, and encode at the project fps.
53
- - Encode at the frames' own size (never smaller than they ever appear), visually lossless, BT.709:
54
- ```
55
- ffmpeg -framerate <rate> -start_number <first> -i f%03d.png \
56
- -vf "pad=ceil(iw/2)*2:ceil(ih/2)*2,scale=out_color_matrix=bt709:out_range=tv,format=yuv420p" \
57
- -c:v libx264 -crf 12 -preset slow -colorspace bt709 -color_primaries bt709 -color_trc bt709 \
58
- -color_range tv -movflags +faststart out.mp4
59
- ```
60
- `pad` adds one pixel on the right or bottom when a side is odd (H.264 4:2:0 needs even sizes):
61
- draw the video at its padded size inside a box of the frames' size with `overflow: hidden`.
62
- - ffmpeg is on PATH or in `~/.agentcut/tools/ffmpeg/`; if there's none, ask the user.
63
- - Play it with `<Video>` from `@remotion/media` (`trimBefore` in frames to start inside it). Many tiles
64
- of the same footage: one video per distinct clip.
65
- - Capture frames across the sequence before and after and compare; if colors or edges differ,
66
- keep the images.
67
- 2. **Repeated complex elements that never change** (a wall of the same static card): draw the piece
68
- once to an image and show the copies as `<Img>`. Make it with `agentcut_capture_frames` at `scale: 2`
69
- with `region` set to the piece's box in composition pixels, on a frame where it's fully drawn and
70
- unobstructed; save it in `assets/` and show it at its 1x size. Keep the live version for every copy
71
- that animates or changes, and for anything the camera zooms past 2x, so its text stays sharp (House
72
- style).
73
- 3. **Draw only what's visible.** An absolutely positioned element that is fully outside the frame or at
74
- opacity 0 can `return null`. Not when it sits in a flex or grid layout (opacity 0 still takes its
75
- space, so its siblings would move), not when it holds `<Audio>`/`<Video>` (the sound would stop), and
76
- "outside" means after the camera's transforms and including its shadow and blur.
77
- 4. **Compute once.** Canvases, data URLs, noise and layout math that don't depend on the frame go in
78
- `useMemo` (or module scope), never in every render; nothing heavy in a component that mounts per tile.
79
- Anything random must stay deterministic: `random("seed")` from `remotion`, never `Math.random()`,
80
- which differs on every load and between the export's render tabs (it would flicker).
81
- 5. **One filter on a wrapper** instead of the same `filter`/`blur` on dozens of children, only when the
82
- children don't overlap or touch (a blur or drop-shadow of the group differs where they meet), then
83
- compare captures. Big animated blurs are the most expensive thing to draw: keep their area as small as
84
- the look allows.
85
- 6. **Fewer DOM nodes for the same look.** A stack of plain divs for a skeleton UI can often be one
86
- element with a `linear-gradient` background or an inline SVG that draws the same lines (check
87
- `browser-export.md` for what the export draws). Never remove anything that shows.
88
- 7. **WebGL and canvas scenes**: `usePreviewQuality()` lowers resolution and redraw rate in the preview
89
- only (`browser-export.md`); captures and the export keep full quality.
90
-
91
- After a change, capture the same frames as before (`agentcut_capture_frames`, the export's own
92
- renderer) and compare: the frames must look the same. Then run `agentcut_preview_check` again and report
93
- the before/after drop rates.
1
+ # Preview performance
2
+
3
+ The user watches the live preview, which draws every scene in their browser at playback speed. A scene
4
+ that takes too long per frame makes the preview skip frames (choppy) and can freeze the tab while you
5
+ capture frames. The export doesn't skip: it renders every frame at full quality. So:
6
+
7
+ **Never lower what the render shows to make the preview smoother.** No lower resolution, fewer
8
+ elements on screen, skipped frames, softer images or simpler motion. Every change below must render
9
+ the same frames as before (check with captures); when one can't, keep the look and tell the user that
10
+ part previews choppy but exports perfectly.
11
+
12
+ ## Measure
13
+
14
+ For website how-to videos, use the stall recovery in `website-howto.md`. Keep all required
15
+ format, visual, playback and audio checks. Run page-heavy tools in sequence. A timed-out request
16
+ can continue in the page; inspect `page.activeWork` before retrying. A small recovery probe does
17
+ not replace the full review or reduce final render quality.
18
+
19
+ - `agentcut_preview_check` (from/to in frames) plays a range muted in the user's preview and returns
20
+ per visual clip: frames played and dropped, loading stalls, the longest freeze, the most DOM elements
21
+ the clip drew, and a verdict: `smooth`, `choppy` from 20 % dropped, `heavy` from 40 % (and at least 6
22
+ dropped frames); a freeze over a second or more than 0.5 s of stalls also counts as slow. It takes as
23
+ long as the range plays: check the clip you changed, not the whole video every time. One check at a
24
+ time; it stops if the user pauses or seeks.
25
+ - `slowClips` lists the likeliest cause first. `sharesDropsOnly` marks a clip (often text or captions)
26
+ that only sits on top of a slower one: fix the other one. `slowToMount` means the clip drops frames in
27
+ the second before it starts, while it mounts early: its setup work is heavy (see rule 4), even when it
28
+ plays fine afterwards.
29
+ - `agentcut_status` → `page.previewPerformance` has the latest check (`lastCheck`), the user's own
30
+ playback (`playback`) and seek timings (`scrub`). `current: false` means it was measured on an older build.
31
+ - A check also returns `scrub`: how long a seek takes to reach the screen (`medianMs`, `p95Ms`, `slowClips`),
32
+ jumping forward and back through the range. A scene can play well and still lag on a drag, because every
33
+ seek draws it from nothing. Above 120 ms a drag visibly lags: the same fixes below apply, and work a scene
34
+ repeats on every frame (not just at mount) is the usual cause.
35
+ - Footage needs nothing from you: the helper makes fast-seeking copies for the preview by itself, and
36
+ captures and exports always read the original. Only `src` on a video clip gets one, so use a video clip
37
+ rather than a video inside a scene when footage is slow to scrub.
38
+ - Run a check after building or changing a heavy scene (walls and grids, hundreds of elements, image
39
+ sequences, big blurs, generated images) and before you say you're done. A first run includes loading
40
+ (stalls); run it again to see steady playback. A machine's own jitter varies between runs: act on a
41
+ `choppy` only when a second run agrees.
42
+
43
+ ## Make it lighter (same pixels)
44
+
45
+ 1. **Image sequences that stall.** Swapping a different picture every few frames makes the browser fetch
46
+ and decode a full image each time. When a check shows stalls or drops on one, encode it into one video,
47
+ but only if it keeps the same picture and timing:
48
+ - Keep the images when the frames have transparency (H.264 has none, they'd render on black), or
49
+ small text and hard-edged colored UI (4:2:0 color softens it).
50
+ - The video must show each image on exactly the frames it shows now. Images held the same number of
51
+ frames each: `-framerate <fps / frames per image>`. Any other timing (eased, held, reversed): write
52
+ the images out in display order, one file per project frame, and encode at the project fps.
53
+ - Encode at the frames' own size (never smaller than they ever appear), visually lossless, BT.709:
54
+ ```
55
+ ffmpeg -framerate <rate> -start_number <first> -i f%03d.png \
56
+ -vf "pad=ceil(iw/2)*2:ceil(ih/2)*2,scale=out_color_matrix=bt709:out_range=tv,format=yuv420p" \
57
+ -c:v libx264 -crf 12 -preset slow -colorspace bt709 -color_primaries bt709 -color_trc bt709 \
58
+ -color_range tv -movflags +faststart out.mp4
59
+ ```
60
+ `pad` adds one pixel on the right or bottom when a side is odd (H.264 4:2:0 needs even sizes):
61
+ draw the video at its padded size inside a box of the frames' size with `overflow: hidden`.
62
+ - ffmpeg is on PATH or in `~/.agentcut/tools/ffmpeg/`; if there's none, ask the user.
63
+ - Play it with `<Video>` from `@remotion/media` (`trimBefore` in frames to start inside it). Many tiles
64
+ of the same footage: one video per distinct clip.
65
+ - Capture frames across the sequence before and after and compare; if colors or edges differ,
66
+ keep the images.
67
+ 2. **Repeated complex elements that never change** (a wall of the same static card): draw the piece
68
+ once to an image and show the copies as `<Img>`. Make it with `agentcut_capture_frames` at `scale: 2`
69
+ with `region` set to the piece's box in composition pixels, on a frame where it's fully drawn and
70
+ unobstructed; save it in `assets/` and show it at its 1x size. Keep the live version for every copy
71
+ that animates or changes, and for anything the camera zooms past 2x, so its text stays sharp (House
72
+ style).
73
+ 3. **Draw only what's visible.** An absolutely positioned element that is fully outside the frame or at
74
+ opacity 0 can `return null`. Not when it sits in a flex or grid layout (opacity 0 still takes its
75
+ space, so its siblings would move), not when it holds `<Audio>`/`<Video>` (the sound would stop), and
76
+ "outside" means after the camera's transforms and including its shadow and blur.
77
+ 4. **Compute once.** Canvases, data URLs, noise and layout math that don't depend on the frame go in
78
+ `useMemo` (or module scope), never in every render; nothing heavy in a component that mounts per tile.
79
+ Anything random must stay deterministic: `random("seed")` from `remotion`, never `Math.random()`,
80
+ which differs on every load and between the export's render tabs (it would flicker).
81
+ 5. **One filter on a wrapper** instead of the same `filter`/`blur` on dozens of children, only when the
82
+ children don't overlap or touch (a blur or drop-shadow of the group differs where they meet), then
83
+ compare captures. Big animated blurs are the most expensive thing to draw: keep their area as small as
84
+ the look allows.
85
+ 6. **Fewer DOM nodes for the same look.** A stack of plain divs for a skeleton UI can often be one
86
+ element with a `linear-gradient` background or an inline SVG that draws the same lines (check
87
+ `browser-export.md` for what the export draws). Never remove anything that shows.
88
+ 7. **WebGL and canvas scenes**: `usePreviewQuality()` lowers resolution and redraw rate in the preview
89
+ only (`browser-export.md`); captures and the export keep full quality.
90
+
91
+ After a change, capture the same frames as before (`agentcut_capture_frames`, the export's own
92
+ renderer) and compare: the frames must look the same. Then run `agentcut_preview_check` again and report
93
+ the before/after drop rates.
@@ -1,19 +1,19 @@
1
- # Graphics behind a person
2
-
3
- Use agentcut_cutout_person when the user wants text or a graphic behind someone, or the person in front of something. Do not install segmentation packages, write background-removal scripts, export frames or use image APIs.
4
-
5
- The stack, top to bottom: the person cutout, the graphic, the original footage. The footage stays in place, so a slightly loose edge only shows where the graphic touches the person.
6
-
7
- 1. Add the graphic on a track above the footage first, and note its clip ID and frames.
8
- 2. Call agentcut_cutout_person with the footage clipId, fromFrame and durationInFrames covering only the frames where the graphic is on screen, and behind with the graphic's clip ID. Cutting out only those frames is much faster than the whole clip. The first run also downloads a model of about 26 MB.
9
- 3. Check captures at the start, middle and end of the range, and where the graphic overlaps the person. Look at hair, hands and fast movement.
10
-
11
- The tool adds a muted video clip to a track named Person cutout. Keep captions on a track above the cutout so the person doesn't cover them.
12
-
13
- - To grade a person apart from their background, use `agentcut_grade_subject` instead (see `references/color.md`).
14
- - It copies the footage clip's trim, speed, box, crop, fit and grade once. After changing those, or moving the footage, run the tool again with the same range; it replaces the earlier cutout on that range.
15
- - A range can't start or end inside an enter or exit animation of the footage, and a project style camera needs the whole clip: the tool returns needs_full_clip, so omit the range.
16
- - Works on the person in front; it can't choose between people, and it doesn't handle objects. Fast movement can leave soft or smeared edges. no_person means most of the range has nobody clearly visible.
17
- - Without WebGPU the tool is several times slower and accepts up to 1,800 frames at a time; with WebGPU, 5,400.
18
- - Frames stay on this computer. Scene-embedded video and remote URLs aren't supported.
19
- - Files go to assets/cutouts/. Use Undo, or delete the clip, to remove a cutout.
1
+ # Graphics behind a person
2
+
3
+ Use agentcut_cutout_person when the user wants text or a graphic behind someone, or the person in front of something. Do not install segmentation packages, write background-removal scripts, export frames or use image APIs.
4
+
5
+ The stack, top to bottom: the person cutout, the graphic, the original footage. The footage stays in place, so a slightly loose edge only shows where the graphic touches the person.
6
+
7
+ 1. Add the graphic on a track above the footage first, and note its clip ID and frames.
8
+ 2. Call agentcut_cutout_person with the footage clipId, fromFrame and durationInFrames covering only the frames where the graphic is on screen, and behind with the graphic's clip ID. Cutting out only those frames is much faster than the whole clip. The first run also downloads a model of about 26 MB.
9
+ 3. Check captures at the start, middle and end of the range, and where the graphic overlaps the person. Look at hair, hands and fast movement.
10
+
11
+ The tool adds a muted video clip to a track named Person cutout. Keep captions on a track above the cutout so the person doesn't cover them.
12
+
13
+ - To grade a person apart from their background, use `agentcut_grade_subject` instead (see `references/color.md`).
14
+ - It copies the footage clip's trim, speed, box, crop, fit and grade once. After changing those, or moving the footage, run the tool again with the same range; it replaces the earlier cutout on that range.
15
+ - A range can't start or end inside an enter or exit animation of the footage, and a project style camera needs the whole clip: the tool returns needs_full_clip, so omit the range.
16
+ - Works on the person in front; it can't choose between people, and it doesn't handle objects. Fast movement can leave soft or smeared edges. no_person means most of the range has nobody clearly visible.
17
+ - Without WebGPU the tool is several times slower and accepts up to 1,800 frames at a time; with WebGPU, 5,400.
18
+ - Frames stay on this computer. Scene-embedded video and remote URLs aren't supported.
19
+ - Files go to assets/cutouts/. Use Undo, or delete the clip, to remove a cutout.
@@ -1,60 +1,60 @@
1
- # Video style presets
2
-
3
- These are scene/asset kits. For Save current style, saved editing rules, or applying an editing style to different
4
- footage, read `references/editing-styles.md` instead. Existing kits stay in `library/presets/`.
5
-
6
- A video style is a recipe for a whole video that isn't a talking head: a music or lyric video, an explainer, a
7
- promo look. It lives in the workspace library, one folder per preset:
8
-
9
- ```
10
- library/presets/<id>/
11
- PROMPT.md the recipe: what to copy, the look, the workflow. Blanks in [brackets].
12
- preset.json name, description, kind, preview/poster file names, and the blanks as form fields
13
- preview.mp4 ~10 s of a video made with it (16:9, 960×540, no audio needed)
14
- poster.jpg one strong frame from it
15
- scenes/ the scene files the recipe copies into a project
16
- assets/ textures, fonts and other files the scenes need
17
- *.example.* optional: a script or layers.json that seeds the first timeline
18
- ```
19
-
20
- The style gallery (Styles tab → Video styles) lists every folder with a PROMPT.md, plays its preview, and shows a
21
- form built from `preset.json` fields. When the user fills it in, you get a message like:
22
-
23
- > Make a video with the "Punk Cut-Paper" video style: read library/presets/punk-cut-paper/PROMPT.md and follow it,
24
- > with these values for its blanks: - Song: assets/song.mp3 - Photos: … - Lyrics: transcribe them. Make it as a new
25
- > project.
26
-
27
- ## Using a preset
28
-
29
- 1. Read the preset's PROMPT.md and fill its blanks with the values given (ask only for what's missing and needed).
30
- 2. "As a new project": create it with `agentcut_create_project`, then copy the preset's `scenes/` and
31
- `assets/` into it (and any song/photos the user picked from another project or the library). "In this project":
32
- copy them into the open project and replace its timeline.
33
- 3. Follow the recipe's look and workflow exactly; it was written from a finished video, so don't improvise a new look.
34
-
35
- ## Saving a video style
36
-
37
- Use this workflow only when the user explicitly asks to save a scene/asset kit. The gallery's Save current style
38
- action saves editing instructions instead; follow `references/editing-styles.md` for it.
39
-
40
- 1. Copy the project's scene files and the assets the look needs (textures, fonts, overlays: not the user's song or
41
- personal photos) into `library/presets/<id>/`. Make the scenes generic: no names, personal facts or lyrics baked in
42
- (put example content in an `*.example.*` file).
43
- 2. Write PROMPT.md: what to copy, fonts for project.json, every rule of the look (layout, motion, timing to beats or
44
- words, colors, overlays), and the workflow. Put what changes per video in [brackets] (song, photos, title, about,
45
- lyrics, …).
46
- 3. Write preset.json:
47
- ```json
48
- { "name": "Punk Cut-Paper", "description": "One sentence on the look.", "kind": "Music video",
49
- "preview": "preview.mp4", "poster": "poster.jpg",
50
- "fields": [
51
- { "id": "song", "label": "Song", "type": "audio", "required": true },
52
- { "id": "photos", "label": "Photos", "type": "images" },
53
- { "id": "title", "label": "Title", "type": "text", "placeholder": "HAPPY BIRTHDAY SAM" },
54
- { "id": "lyrics", "label": "Lyrics", "type": "longtext", "placeholder": "Paste the lyrics, or leave empty" }
55
- ] }
56
- ```
57
- Field types: `text`, `longtext`, `audio` (the user picks an audio file), `images` (the user picks photos).
58
- 4. preview.mp4 and poster.jpg: cut ~10 s from the latest render in `renders/` (960×540, H.264, no audio) and grab one
59
- frame, choosing a stretch without personal photos when you can. With no render yet, export one first or ask.
60
- 5. Tell the user it's in the Styles tab under Video styles.
1
+ # Video style presets
2
+
3
+ These are scene/asset kits. For Save current style, saved editing rules, or applying an editing style to different
4
+ footage, read `references/editing-styles.md` instead. Existing kits stay in `library/presets/`.
5
+
6
+ A video style is a recipe for a whole video that isn't a talking head: a music or lyric video, an explainer, a
7
+ promo look. It lives in the workspace library, one folder per preset:
8
+
9
+ ```
10
+ library/presets/<id>/
11
+ PROMPT.md the recipe: what to copy, the look, the workflow. Blanks in [brackets].
12
+ preset.json name, description, kind, preview/poster file names, and the blanks as form fields
13
+ preview.mp4 ~10 s of a video made with it (16:9, 960×540, no audio needed)
14
+ poster.jpg one strong frame from it
15
+ scenes/ the scene files the recipe copies into a project
16
+ assets/ textures, fonts and other files the scenes need
17
+ *.example.* optional: a script or layers.json that seeds the first timeline
18
+ ```
19
+
20
+ The style gallery (Styles tab → Video styles) lists every folder with a PROMPT.md, plays its preview, and shows a
21
+ form built from `preset.json` fields. When the user fills it in, you get a message like:
22
+
23
+ > Make a video with the "Punk Cut-Paper" video style: read library/presets/punk-cut-paper/PROMPT.md and follow it,
24
+ > with these values for its blanks: - Song: assets/song.mp3 - Photos: … - Lyrics: transcribe them. Make it as a new
25
+ > project.
26
+
27
+ ## Using a preset
28
+
29
+ 1. Read the preset's PROMPT.md and fill its blanks with the values given (ask only for what's missing and needed).
30
+ 2. "As a new project": create it with `agentcut_create_project`, then copy the preset's `scenes/` and
31
+ `assets/` into it (and any song/photos the user picked from another project or the library). "In this project":
32
+ copy them into the open project and replace its timeline.
33
+ 3. Follow the recipe's look and workflow exactly; it was written from a finished video, so don't improvise a new look.
34
+
35
+ ## Saving a video style
36
+
37
+ Use this workflow only when the user explicitly asks to save a scene/asset kit. The gallery's Save current style
38
+ action saves editing instructions instead; follow `references/editing-styles.md` for it.
39
+
40
+ 1. Copy the project's scene files and the assets the look needs (textures, fonts, overlays: not the user's song or
41
+ personal photos) into `library/presets/<id>/`. Make the scenes generic: no names, personal facts or lyrics baked in
42
+ (put example content in an `*.example.*` file).
43
+ 2. Write PROMPT.md: what to copy, fonts for project.json, every rule of the look (layout, motion, timing to beats or
44
+ words, colors, overlays), and the workflow. Put what changes per video in [brackets] (song, photos, title, about,
45
+ lyrics, …).
46
+ 3. Write preset.json:
47
+ ```json
48
+ { "name": "Punk Cut-Paper", "description": "One sentence on the look.", "kind": "Music video",
49
+ "preview": "preview.mp4", "poster": "poster.jpg",
50
+ "fields": [
51
+ { "id": "song", "label": "Song", "type": "audio", "required": true },
52
+ { "id": "photos", "label": "Photos", "type": "images" },
53
+ { "id": "title", "label": "Title", "type": "text", "placeholder": "HAPPY BIRTHDAY SAM" },
54
+ { "id": "lyrics", "label": "Lyrics", "type": "longtext", "placeholder": "Paste the lyrics, or leave empty" }
55
+ ] }
56
+ ```
57
+ Field types: `text`, `longtext`, `audio` (the user picks an audio file), `images` (the user picks photos).
58
+ 4. preview.mp4 and poster.jpg: cut ~10 s from the latest render in `renders/` (960×540, H.264, no audio) and grab one
59
+ frame, choosing a stretch without personal photos when you can. With no render yet, export one first or ask.
60
+ 5. Tell the user it's in the Styles tab under Video styles.