dsh-drawai 0.4.2 → 0.4.4

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 (379) hide show
  1. package/README.md +7 -5
  2. package/lib/client.js +142 -16
  3. package/lib/index.js +7945 -7719
  4. package/lib/motion/asset-pack.js +394 -394
  5. package/lib/motion/assets.js +291 -291
  6. package/lib/motion/demo-assets-lock.js +10 -10
  7. package/lib/motion/mgstyles/briefs/23-ink-wash.md +147 -0
  8. package/lib/motion/mgstyles/catalog.d/23-ink-wash.json +28 -0
  9. package/lib/motion/mgstyles/catalog.json +127 -14
  10. package/lib/motion/mgstyles/upstream/demos/23-ink-wash/brush.js +149 -0
  11. package/lib/motion/mgstyles/upstream/demos/23-ink-wash/film.js +202 -0
  12. package/lib/motion/mgstyles/upstream/manifest.json +28 -3
  13. package/lib/motion/mgstyles/upstream/prompts/23-ink-wash.md +59 -0
  14. package/lib/motion/mgstyles/vendor/README.md +28 -28
  15. package/lib/motion/mgstyles/vendor/modules/d3/LICENSE +13 -13
  16. package/lib/motion/mgstyles/vendor/modules/d3/dist/d3.min.js +2 -2
  17. package/lib/motion/mgstyles/vendor/modules/opentype.js/LICENSE +20 -20
  18. package/lib/motion/mgstyles/vendor/modules/opentype.js/dist/opentype.mjs +14460 -14460
  19. package/lib/motion/mgstyles/vendor/modules/simplex-noise/LICENSE +21 -21
  20. package/lib/motion/mgstyles/vendor/modules/simplex-noise/dist/esm/simplex-noise.js +465 -465
  21. package/lib/motion/mgstyles/vendor/modules/topojson-client/LICENSE +13 -13
  22. package/lib/motion/mgstyles/vendor/modules/topojson-client/dist/topojson-client.min.js +2 -2
  23. package/lib/motion/project.js +5 -1
  24. package/lib/motion/qa.js +116 -6
  25. package/lib/motion/render.js +179 -179
  26. package/lib/motion/scene-kit.js +1 -1
  27. package/lib/motion/shotcraft/upstream/SKILL.md +286 -286
  28. package/lib/motion/shotcraft/upstream/assets/lib/Caption.tsx +54 -54
  29. package/lib/motion/shotcraft/upstream/assets/lib/ClipCard.tsx +200 -200
  30. package/lib/motion/shotcraft/upstream/assets/lib/DigitRoll.tsx +45 -45
  31. package/lib/motion/shotcraft/upstream/assets/lib/FlashCut.tsx +20 -20
  32. package/lib/motion/shotcraft/upstream/assets/lib/FlatPanel.tsx +65 -65
  33. package/lib/motion/shotcraft/upstream/assets/lib/PageCam.tsx +151 -151
  34. package/lib/motion/shotcraft/upstream/assets/lib/VerticalTicker.tsx +129 -129
  35. package/lib/motion/shotcraft/upstream/assets/lib/helpers/camera.tsx +75 -75
  36. package/lib/motion/shotcraft/upstream/assets/lib/helpers/motion.ts +40 -40
  37. package/lib/motion/shotcraft/upstream/assets/lib/helpers/rand.ts +11 -11
  38. package/lib/motion/shotcraft/upstream/assets/lib/helpers/shake.ts +10 -10
  39. package/lib/motion/shotcraft/upstream/assets/scripts/build-readme-cover.mjs +49 -49
  40. package/lib/motion/shotcraft/upstream/assets/scripts/capture-template.mjs +210 -210
  41. package/lib/motion/shotcraft/upstream/assets/scripts/sfx-source.py +423 -423
  42. package/lib/motion/shotcraft/upstream/assets/scripts/smoke-render-demos.py +170 -170
  43. package/lib/motion/shotcraft/upstream/assets/scripts/test_sfx_source.py +157 -157
  44. package/lib/motion/shotcraft/upstream/demos/README.md +120 -120
  45. package/lib/motion/shotcraft/upstream/demos/_fixtures/Brand.tsx +112 -112
  46. package/lib/motion/shotcraft/upstream/demos/_fixtures/Fixtures.tsx +647 -647
  47. package/lib/motion/shotcraft/upstream/demos/_fixtures/Look.tsx +316 -316
  48. package/lib/motion/shotcraft/upstream/demos/_fixtures/Motion.tsx +82 -82
  49. package/lib/motion/shotcraft/upstream/demos/_fixtures/PageCam2D.tsx +115 -115
  50. package/lib/motion/shotcraft/upstream/demos/_fixtures/Polish.tsx +243 -243
  51. package/lib/motion/shotcraft/upstream/demos/_textures/live-layout.json +388 -388
  52. package/lib/motion/shotcraft/upstream/demos/camera/basic-3d-scene/Basic3DScene.tsx +250 -250
  53. package/lib/motion/shotcraft/upstream/demos/camera/crash-zoom-punch/CrashImpactReal.tsx +305 -305
  54. package/lib/motion/shotcraft/upstream/demos/camera/crash-zoom-punch/CrashZoomReal.tsx +246 -246
  55. package/lib/motion/shotcraft/upstream/demos/camera/cursor-flyover/CursorFlyover.tsx +390 -390
  56. package/lib/motion/shotcraft/upstream/demos/camera/depth-layer-moves/MultiplaneReal.tsx +138 -138
  57. package/lib/motion/shotcraft/upstream/demos/camera/graze-face-tour/GrazeFaceTour.tsx +542 -542
  58. package/lib/motion/shotcraft/upstream/demos/camera/overhead-camera-moves/OverheadTabletopDrop.tsx +315 -315
  59. package/lib/motion/shotcraft/upstream/demos/camera/overhead-camera-moves/TiltReveal.tsx +299 -299
  60. package/lib/motion/shotcraft/upstream/demos/camera/space-camera-moves/DroneDiveLanding.tsx +173 -173
  61. package/lib/motion/shotcraft/upstream/demos/camera/space-camera-moves/ExplodedView.tsx +348 -348
  62. package/lib/motion/shotcraft/upstream/demos/camera/steep-tilt-glide/SteepTiltGlide.tsx +366 -366
  63. package/lib/motion/shotcraft/upstream/demos/camera/tension-camera-moves/BulletTimeFreezeOrbit.tsx +279 -279
  64. package/lib/motion/shotcraft/upstream/demos/camera/tension-camera-moves/PullBackIsolation.tsx +184 -184
  65. package/lib/motion/shotcraft/upstream/demos/camera/terminal-3d/Terminal3D.tsx +390 -390
  66. package/lib/motion/shotcraft/upstream/demos/data/before-after-slider-scrub/BeforeAfterSliderScrub.tsx +155 -155
  67. package/lib/motion/shotcraft/upstream/demos/data/chart-live-moves/AxisRescaleShockV2.tsx +303 -303
  68. package/lib/motion/shotcraft/upstream/demos/data/chart-live-moves/OscilloscopeStreamV2.tsx +290 -290
  69. package/lib/motion/shotcraft/upstream/demos/data/chart-live-moves/UnitDotSwarmRegroupV2.tsx +278 -278
  70. package/lib/motion/shotcraft/upstream/demos/data/gauge-readout-moves/NeedleSweepSelftest.tsx +307 -307
  71. package/lib/motion/shotcraft/upstream/demos/data/gauge-readout-moves/TapeScrollFixedPointer.tsx +215 -215
  72. package/lib/motion/shotcraft/upstream/demos/data/scroll-brake-moves/BrakeReticleLock.tsx +299 -299
  73. package/lib/motion/shotcraft/upstream/demos/data/scroll-brake-moves/ChangelogScrollBrake.tsx +232 -232
  74. package/lib/motion/shotcraft/upstream/demos/data/timeline-travel/TimelineTravel.tsx +290 -290
  75. package/lib/motion/shotcraft/upstream/demos/effects/assemble-then-type-flyin/AssembleThenTypeFlyin.tsx +273 -273
  76. package/lib/motion/shotcraft/upstream/demos/effects/aurora-bloom-bg-flip/AuroraBloomBgFlip.tsx +167 -167
  77. package/lib/motion/shotcraft/upstream/demos/effects/brand-frame-snap/BrandFrameSnap.tsx +536 -536
  78. package/lib/motion/shotcraft/upstream/demos/effects/fui-hud-moves/ReticleLockOn.tsx +164 -164
  79. package/lib/motion/shotcraft/upstream/demos/effects/glow-flyline-moves/FlylineArc.tsx +175 -175
  80. package/lib/motion/shotcraft/upstream/demos/effects/glow-flyline-moves/GlowOrbAmbient.tsx +197 -197
  81. package/lib/motion/shotcraft/upstream/demos/effects/glow-flyline-moves/OrbFlylineRelay.tsx +241 -241
  82. package/lib/motion/shotcraft/upstream/demos/effects/icon-performance-moves/AttentionBounce.tsx +279 -279
  83. package/lib/motion/shotcraft/upstream/demos/effects/impact-feedback/AnimeImpact.tsx +230 -230
  84. package/lib/motion/shotcraft/upstream/demos/effects/impact-feedback/HitCounter.tsx +345 -345
  85. package/lib/motion/shotcraft/upstream/demos/effects/light-play-moves/SheenSweepRetry.tsx +275 -275
  86. package/lib/motion/shotcraft/upstream/demos/effects/light-play-moves/SpotlightSweepReveal.tsx +229 -229
  87. package/lib/motion/shotcraft/upstream/demos/effects/radial-ripple-phone-chips/RadialRipplePhoneChips.tsx +312 -312
  88. package/lib/motion/shotcraft/upstream/demos/effects/riso-print-hits/RisoMisregistrationHit.tsx +222 -222
  89. package/lib/motion/shotcraft/upstream/demos/effects/scan-bracket-sweep/ScanBracketSweep.tsx +295 -295
  90. package/lib/motion/shotcraft/upstream/demos/effects/scanline-annotate-focus/ScanlineAnnotateFocus.tsx +329 -329
  91. package/lib/motion/shotcraft/upstream/demos/effects/scanline-assemble-flyin/ScanlineAssembleFlyin.tsx +315 -315
  92. package/lib/motion/shotcraft/upstream/demos/effects/slam-entrance-moves/ImpactBurstKit.tsx +264 -264
  93. package/lib/motion/shotcraft/upstream/demos/effects/slam-entrance-moves/KanadaPerspectiveSnap.tsx +260 -260
  94. package/lib/motion/shotcraft/upstream/demos/effects/slam-entrance-moves/ScoreSlam.tsx +263 -263
  95. package/lib/motion/shotcraft/upstream/demos/effects/spotlight-sweep-moves/CornerSpotlightReveal.tsx +123 -123
  96. package/lib/motion/shotcraft/upstream/demos/effects/spotlight-sweep-moves/GlowWakeSleepPanel.tsx +187 -187
  97. package/lib/motion/shotcraft/upstream/demos/effects/spotlight-sweep-moves/SlideSpotlightPan.tsx +175 -175
  98. package/lib/motion/shotcraft/upstream/demos/interaction/autolayout-gap-dial/AutolayoutGapDial.tsx +305 -305
  99. package/lib/motion/shotcraft/upstream/demos/interaction/canvas-materialize-moves/DiagramCascadeBuild.tsx +350 -350
  100. package/lib/motion/shotcraft/upstream/demos/interaction/canvas-materialize-moves/PanelToCanvasMaterialize.tsx +352 -352
  101. package/lib/motion/shotcraft/upstream/demos/interaction/chip-grid-single-select-blackout/ChipGridSingleSelectBlackout.tsx +218 -218
  102. package/lib/motion/shotcraft/upstream/demos/interaction/collab-cursor-moves/CursorCastEnsemble.tsx +297 -297
  103. package/lib/motion/shotcraft/upstream/demos/interaction/glass-pill-dictation-typing/GlassPillDictationTyping.tsx +157 -157
  104. package/lib/motion/shotcraft/upstream/demos/interaction/hashtag-to-pill-materialize/HashtagToPillMaterialize.tsx +218 -218
  105. package/lib/motion/shotcraft/upstream/demos/interaction/picker-carousel-feature-cycle/PickerCarouselFeatureCycle.tsx +202 -202
  106. package/lib/motion/shotcraft/upstream/demos/interaction/segmented-thumb-hero/SegmentedThumbHero.tsx +265 -265
  107. package/lib/motion/shotcraft/upstream/demos/interaction/theme-switch-moves/PaletteThemeRipple.tsx +457 -457
  108. package/lib/motion/shotcraft/upstream/demos/interaction/theme-switch-moves/ThemeSweepToggle.tsx +446 -446
  109. package/lib/motion/shotcraft/upstream/demos/interaction/type-and-filter/TypeAndFilter.tsx +249 -249
  110. package/lib/motion/shotcraft/upstream/demos/interaction/voice-waveform-live/VoiceWaveformLive.tsx +278 -278
  111. package/lib/motion/shotcraft/upstream/demos/opening/crane-rise-reveal/CraneRiseReveal.tsx +332 -332
  112. package/lib/motion/shotcraft/upstream/demos/opening/dataviz-landscape-open/DatavizLandscapeOpen.tsx +358 -358
  113. package/lib/motion/shotcraft/upstream/demos/opening/fracture/Fracture.tsx +201 -201
  114. package/lib/motion/shotcraft/upstream/demos/opening/icon-field-colorize/IconFieldColorize.tsx +200 -200
  115. package/lib/motion/shotcraft/upstream/demos/opening/letterspace-materialize/LetterspaceMaterialize.tsx +208 -208
  116. package/lib/motion/shotcraft/upstream/demos/opening/magician-card-flourish/MagicianCardFlourish.tsx +341 -341
  117. package/lib/motion/shotcraft/upstream/demos/opening/orbit-ring-title-open/OrbitRingTitleOpen.tsx +389 -389
  118. package/lib/motion/shotcraft/upstream/demos/opening/spotlight-hero-card/SpotlightHeroCard.tsx +293 -293
  119. package/lib/motion/shotcraft/upstream/demos/opening/stroke-segment-build/StrokeSegmentBuild.tsx +183 -183
  120. package/lib/motion/shotcraft/upstream/demos/opening/text-as-mask/TextAsMask.tsx +245 -245
  121. package/lib/motion/shotcraft/upstream/demos/outro/grain-dissolve/GrainDissolve.tsx +222 -222
  122. package/lib/motion/shotcraft/upstream/demos/outro/logo-shrink-wordmark-lockup/LogoShrinkWordmarkLockup.tsx +223 -223
  123. package/lib/motion/shotcraft/upstream/demos/outro/neon-triple-marquee/NeonTripleMarquee.tsx +217 -217
  124. package/lib/motion/shotcraft/upstream/demos/outro/outro-group-photo-launch/OutroGroupPhotoLaunch.tsx +343 -343
  125. package/lib/motion/shotcraft/upstream/demos/outro/ui-strip-away-outro/UiStripAwayOutro.tsx +357 -357
  126. package/lib/motion/shotcraft/upstream/demos/outro/ui-to-brand-morph/IconFlipBloomLogo.tsx +187 -187
  127. package/lib/motion/shotcraft/upstream/demos/outro/ui-to-brand-morph/InputMorphsIntoLogo.tsx +333 -333
  128. package/lib/motion/shotcraft/upstream/demos/rhythm/beat-cut-moves/PaparazziFlash.tsx +274 -274
  129. package/lib/motion/shotcraft/upstream/demos/rhythm/beat-step-list-theme-cycle/BeatStepListThemeCycle.tsx +270 -270
  130. package/lib/motion/shotcraft/upstream/demos/rhythm/panel-grid-moves/ComicPanelSplit.tsx +430 -430
  131. package/lib/motion/shotcraft/upstream/demos/rhythm/quad-split-parallel-scenes/QuadSplitParallelScenes.tsx +252 -252
  132. package/lib/motion/shotcraft/upstream/demos/rhythm/rhythm-interrupt-moves/JumpCutPunchIn.tsx +106 -106
  133. package/lib/motion/shotcraft/upstream/demos/rhythm/sakuga-timing-shift/SakugaTimingShift.tsx +288 -288
  134. package/lib/motion/shotcraft/upstream/demos/rhythm/speed-ramp-freeze/FreezeAnnotateReal.tsx +362 -362
  135. package/lib/motion/shotcraft/upstream/demos/rhythm/trailer-grammar-moves/TrailerBumper.tsx +168 -168
  136. package/lib/motion/shotcraft/upstream/demos/transition/bottom-push-stack-wipe/BottomPushStackWipe.tsx +310 -310
  137. package/lib/motion/shotcraft/upstream/demos/transition/card-flip-reveal/CardFlipReveal.tsx +261 -261
  138. package/lib/motion/shotcraft/upstream/demos/transition/card-flock-tumble/CardFlockTumble.tsx +459 -459
  139. package/lib/motion/shotcraft/upstream/demos/transition/circle-match-iris/CircleMatchIris.tsx +294 -294
  140. package/lib/motion/shotcraft/upstream/demos/transition/gradient-transition/GradientTransition.tsx +161 -161
  141. package/lib/motion/shotcraft/upstream/demos/transition/line-carry-transition/LineCarryTransition.tsx +248 -248
  142. package/lib/motion/shotcraft/upstream/demos/transition/mosaic-reframe/MosaicReframe.tsx +359 -359
  143. package/lib/motion/shotcraft/upstream/demos/transition/page-turn-transitions/BarnDoorSplit.tsx +227 -227
  144. package/lib/motion/shotcraft/upstream/demos/transition/print-texture-transitions/InkBleedReveal.tsx +162 -162
  145. package/lib/motion/shotcraft/upstream/demos/transition/shot-transitions/PortalWipeV2.tsx +248 -248
  146. package/lib/motion/shotcraft/upstream/demos/transition/shot-transitions/WhipBrakeReal.tsx +186 -186
  147. package/lib/motion/shotcraft/upstream/demos/transition/tear-streak-transitions/GlitchDisplace.tsx +355 -355
  148. package/lib/motion/shotcraft/upstream/demos/transition/transition-hidden-cut/InvisibleCut.tsx +272 -272
  149. package/lib/motion/shotcraft/upstream/demos/transition/transition-hidden-cut/LightLeakBurn.tsx +262 -262
  150. package/lib/motion/shotcraft/upstream/demos/transition/transition-hidden-cut/VersusSlam.tsx +217 -217
  151. package/lib/motion/shotcraft/upstream/demos/transition/transition-travel/LetterformZoom.tsx +285 -285
  152. package/lib/motion/shotcraft/upstream/demos/transition/white-flash-logo-simplify-cut/WhiteFlashLogoSimplifyCut.tsx +205 -205
  153. package/lib/motion/shotcraft/upstream/demos/transition/wipe-transitions/BlindsSlice.tsx +178 -178
  154. package/lib/motion/shotcraft/upstream/demos/typography/blur-slide/BlurSlide.tsx +147 -147
  155. package/lib/motion/shotcraft/upstream/demos/typography/brace-expand/BraceExpand.tsx +143 -143
  156. package/lib/motion/shotcraft/upstream/demos/typography/brand-ink-open/BrandInkOpen.tsx +134 -134
  157. package/lib/motion/shotcraft/upstream/demos/typography/countdown-arc-scatter/CountdownArcScatter.tsx +217 -217
  158. package/lib/motion/shotcraft/upstream/demos/typography/flying-words/FlyingWords.tsx +198 -198
  159. package/lib/motion/shotcraft/upstream/demos/typography/glitch-cycle/GlitchCycle.tsx +221 -221
  160. package/lib/motion/shotcraft/upstream/demos/typography/gradient-word-sweep/GradientWordSweep.tsx +312 -312
  161. package/lib/motion/shotcraft/upstream/demos/typography/lead-word-zoom-assemble/LeadWordZoomAssemble.tsx +261 -261
  162. package/lib/motion/shotcraft/upstream/demos/typography/marker-underline-title/MarkerUnderlineTitle.tsx +121 -121
  163. package/lib/motion/shotcraft/upstream/demos/typography/outline-word-fill/OutlineWordFill.tsx +153 -153
  164. package/lib/motion/shotcraft/upstream/demos/typography/paper-title-card/PaperTitleCard.tsx +179 -179
  165. package/lib/motion/shotcraft/upstream/demos/typography/pill-chip-slot-cycle-handled/PillChipSlotCycleHandled.tsx +140 -140
  166. package/lib/motion/shotcraft/upstream/demos/typography/pill-slot-cycle/PillSlotCycle.tsx +309 -309
  167. package/lib/motion/shotcraft/upstream/demos/typography/text-column-converge/TextColumnConverge.tsx +191 -191
  168. package/lib/motion/shotcraft/upstream/demos/typography/title-demote-to-label/TitleDemoteToLabel.tsx +292 -292
  169. package/lib/motion/shotcraft/upstream/demos/typography/type-assembly-moves/LetterformDriftAssembly.tsx +135 -135
  170. package/lib/motion/shotcraft/upstream/demos/typography/type-assembly-moves/SplitTextStagger.tsx +124 -124
  171. package/lib/motion/shotcraft/upstream/demos/typography/type-assembly-moves/TextOnPath.tsx +255 -255
  172. package/lib/motion/shotcraft/upstream/demos/typography/type-entrance-moves/LetterDropPhysics.tsx +173 -173
  173. package/lib/motion/shotcraft/upstream/demos/typography/type-rhythm-sync/FontWeightPump.tsx +225 -225
  174. package/lib/motion/shotcraft/upstream/demos/typography/type-rhythm-sync/KaraokeFillSync.tsx +141 -141
  175. package/lib/motion/shotcraft/upstream/demos/typography/typewriter-moves/TypewriterErrorRetype.tsx +137 -137
  176. package/lib/motion/shotcraft/upstream/demos/typography/vertical-word-roll-blur-cycle/VerticalWordRollBlurCycle.tsx +147 -147
  177. package/lib/motion/shotcraft/upstream/demos/typography/word-relay-filmstrip/WordRelayFilmstrip.tsx +409 -409
  178. package/lib/motion/shotcraft/upstream/demos/typography/word-relay-geometry/WordRelayGeometry.tsx +280 -280
  179. package/lib/motion/shotcraft/upstream/demos/ui-entrance/avatar-bracket-carousel/AvatarBracketCarousel.tsx +271 -271
  180. package/lib/motion/shotcraft/upstream/demos/ui-entrance/bezier-source-converge-merge/BezierSourceConvergeMerge.tsx +385 -385
  181. package/lib/motion/shotcraft/upstream/demos/ui-entrance/card-stack/CardStack.tsx +312 -312
  182. package/lib/motion/shotcraft/upstream/demos/ui-entrance/carousel-3d/Carousel3D.tsx +303 -303
  183. package/lib/motion/shotcraft/upstream/demos/ui-entrance/clipcard-looping/ClipCardLooping.tsx +77 -77
  184. package/lib/motion/shotcraft/upstream/demos/ui-entrance/cloner-depth-echo/ClonerDepthEcho.tsx +311 -311
  185. package/lib/motion/shotcraft/upstream/demos/ui-entrance/deck-deal-flyin/DeckDealFlyin.tsx +307 -307
  186. package/lib/motion/shotcraft/upstream/demos/ui-entrance/doc-park-left-pill-deal/DocParkLeftPillDeal.tsx +349 -349
  187. package/lib/motion/shotcraft/upstream/demos/ui-entrance/document-typewriter-reveal/DocumentTypewriterReveal.tsx +255 -255
  188. package/lib/motion/shotcraft/upstream/demos/ui-entrance/draw-svg-trace/DrawSvgTrace.tsx +244 -244
  189. package/lib/motion/shotcraft/upstream/demos/ui-entrance/element-body-moves/ContactShadowLift.tsx +217 -217
  190. package/lib/motion/shotcraft/upstream/demos/ui-entrance/integration-hub-map/IntegrationHubMap.tsx +652 -652
  191. package/lib/motion/shotcraft/upstream/demos/ui-entrance/list-reveal/ListReveal.tsx +153 -153
  192. package/lib/motion/shotcraft/upstream/demos/ui-entrance/list-stack-press/ListStackPress.tsx +238 -238
  193. package/lib/motion/shotcraft/upstream/demos/ui-entrance/neon-frame-forerun/NeonFrameForerun.tsx +324 -324
  194. package/lib/motion/shotcraft/upstream/demos/ui-entrance/neon-frame-orbit-drop/NeonFrameForerunOrbit.tsx +354 -354
  195. package/lib/motion/shotcraft/upstream/demos/ui-entrance/page-waterfall-wall/PageWaterfallWall.tsx +101 -101
  196. package/lib/motion/shotcraft/upstream/demos/ui-entrance/page-waterfall-wall/VerticalTicker.tsx +129 -129
  197. package/lib/motion/shotcraft/upstream/demos/ui-entrance/product-card-progressive-assemble/ProductCardProgressiveAssemble.tsx +297 -297
  198. package/lib/motion/shotcraft/upstream/demos/ui-entrance/radial-wave/RadialWave.tsx +57 -57
  199. package/lib/motion/shotcraft/upstream/demos/ui-entrance/research-card-stack-scroll/ResearchCardStackScroll.tsx +155 -155
  200. package/lib/motion/shotcraft/upstream/demos/ui-entrance/row-embed/RowEmbed.tsx +175 -175
  201. package/lib/motion/shotcraft/upstream/demos/ui-entrance/value-stagger-gradient/ValueStaggerGradient.tsx +153 -153
  202. package/lib/motion/shotcraft/upstream/demos/ui-entrance/wall-reveal-moves/BentoLightUp.tsx +146 -146
  203. package/lib/motion/shotcraft/upstream/demos/ui-entrance/wall-reveal-moves/WireframeDrawOn.tsx +226 -226
  204. package/lib/motion/shotcraft/upstream/gallery/api/library.json +1 -1
  205. package/lib/motion/shotcraft/upstream/references/aesthetic-rules.md +193 -193
  206. package/lib/motion/shotcraft/upstream/references/final-review.md +121 -121
  207. package/lib/motion/shotcraft/upstream/references/guided-free-creation.md +199 -199
  208. package/lib/motion/shotcraft/upstream/references/jianying-export.md +183 -183
  209. package/lib/motion/shotcraft/upstream/references/music-beat-sync.md +257 -257
  210. package/lib/motion/shotcraft/upstream/references/pipeline.md +382 -382
  211. package/lib/motion/shotcraft/upstream/references/publish-upload-post.md +111 -111
  212. package/lib/motion/shotcraft/upstream/references/sequences/promo-energy-arc.md +50 -50
  213. package/lib/motion/shotcraft/upstream/references/sfx-sourcing.md +95 -95
  214. package/lib/motion/shotcraft/upstream/references/shots/camera/basic-3d-scene.md +41 -41
  215. package/lib/motion/shotcraft/upstream/references/shots/camera/crash-zoom-punch.md +52 -52
  216. package/lib/motion/shotcraft/upstream/references/shots/camera/cursor-flyover.md +39 -39
  217. package/lib/motion/shotcraft/upstream/references/shots/camera/depth-layer-moves.md +39 -39
  218. package/lib/motion/shotcraft/upstream/references/shots/camera/graze-face-tour.md +57 -57
  219. package/lib/motion/shotcraft/upstream/references/shots/camera/overhead-camera-moves.md +51 -51
  220. package/lib/motion/shotcraft/upstream/references/shots/camera/space-camera-moves.md +46 -46
  221. package/lib/motion/shotcraft/upstream/references/shots/camera/steep-tilt-glide.md +52 -52
  222. package/lib/motion/shotcraft/upstream/references/shots/camera/tension-camera-moves.md +43 -43
  223. package/lib/motion/shotcraft/upstream/references/shots/camera/terminal-3d.md +42 -42
  224. package/lib/motion/shotcraft/upstream/references/shots/data/before-after-slider-scrub.md +48 -48
  225. package/lib/motion/shotcraft/upstream/references/shots/data/chart-live-moves.md +52 -52
  226. package/lib/motion/shotcraft/upstream/references/shots/data/gauge-readout-moves.md +45 -45
  227. package/lib/motion/shotcraft/upstream/references/shots/data/scroll-brake-moves.md +46 -46
  228. package/lib/motion/shotcraft/upstream/references/shots/data/timeline-travel.md +44 -44
  229. package/lib/motion/shotcraft/upstream/references/shots/effects/assemble-then-type-flyin.md +63 -63
  230. package/lib/motion/shotcraft/upstream/references/shots/effects/aurora-bloom-bg-flip.md +54 -54
  231. package/lib/motion/shotcraft/upstream/references/shots/effects/brand-frame-snap.md +58 -58
  232. package/lib/motion/shotcraft/upstream/references/shots/effects/fui-hud-moves.md +35 -35
  233. package/lib/motion/shotcraft/upstream/references/shots/effects/glow-flyline-moves.md +53 -53
  234. package/lib/motion/shotcraft/upstream/references/shots/effects/icon-performance-moves.md +42 -42
  235. package/lib/motion/shotcraft/upstream/references/shots/effects/impact-feedback.md +50 -50
  236. package/lib/motion/shotcraft/upstream/references/shots/effects/light-play-moves.md +46 -46
  237. package/lib/motion/shotcraft/upstream/references/shots/effects/radial-ripple-phone-chips.md +56 -56
  238. package/lib/motion/shotcraft/upstream/references/shots/effects/riso-print-hits.md +49 -49
  239. package/lib/motion/shotcraft/upstream/references/shots/effects/scan-bracket-sweep.md +50 -50
  240. package/lib/motion/shotcraft/upstream/references/shots/effects/scanline-annotate-focus.md +53 -53
  241. package/lib/motion/shotcraft/upstream/references/shots/effects/scanline-assemble-flyin.md +53 -53
  242. package/lib/motion/shotcraft/upstream/references/shots/effects/slam-entrance-moves.md +55 -55
  243. package/lib/motion/shotcraft/upstream/references/shots/effects/spotlight-sweep-moves.md +52 -52
  244. package/lib/motion/shotcraft/upstream/references/shots/interaction/autolayout-gap-dial.md +60 -60
  245. package/lib/motion/shotcraft/upstream/references/shots/interaction/canvas-materialize-moves.md +57 -57
  246. package/lib/motion/shotcraft/upstream/references/shots/interaction/chip-grid-single-select-blackout.md +51 -51
  247. package/lib/motion/shotcraft/upstream/references/shots/interaction/collab-cursor-moves.md +41 -41
  248. package/lib/motion/shotcraft/upstream/references/shots/interaction/glass-pill-dictation-typing.md +53 -53
  249. package/lib/motion/shotcraft/upstream/references/shots/interaction/hashtag-to-pill-materialize.md +60 -60
  250. package/lib/motion/shotcraft/upstream/references/shots/interaction/picker-carousel-feature-cycle.md +55 -55
  251. package/lib/motion/shotcraft/upstream/references/shots/interaction/segmented-thumb-hero.md +57 -57
  252. package/lib/motion/shotcraft/upstream/references/shots/interaction/theme-switch-moves.md +47 -47
  253. package/lib/motion/shotcraft/upstream/references/shots/interaction/type-and-filter.md +37 -37
  254. package/lib/motion/shotcraft/upstream/references/shots/interaction/voice-waveform-live.md +54 -54
  255. package/lib/motion/shotcraft/upstream/references/shots/opening/brand-ink-open.md +36 -36
  256. package/lib/motion/shotcraft/upstream/references/shots/opening/crane-rise-reveal.md +56 -56
  257. package/lib/motion/shotcraft/upstream/references/shots/opening/dataviz-landscape-open.md +56 -56
  258. package/lib/motion/shotcraft/upstream/references/shots/opening/fracture.md +40 -40
  259. package/lib/motion/shotcraft/upstream/references/shots/opening/icon-field-colorize.md +60 -60
  260. package/lib/motion/shotcraft/upstream/references/shots/opening/letterspace-materialize.md +57 -57
  261. package/lib/motion/shotcraft/upstream/references/shots/opening/magician-card-flourish.md +73 -73
  262. package/lib/motion/shotcraft/upstream/references/shots/opening/orbit-ring-title-open.md +87 -87
  263. package/lib/motion/shotcraft/upstream/references/shots/opening/spotlight-hero-card.md +55 -55
  264. package/lib/motion/shotcraft/upstream/references/shots/opening/stroke-segment-build.md +50 -50
  265. package/lib/motion/shotcraft/upstream/references/shots/opening/text-as-mask.md +59 -59
  266. package/lib/motion/shotcraft/upstream/references/shots/outro/grain-dissolve.md +38 -38
  267. package/lib/motion/shotcraft/upstream/references/shots/outro/logo-shrink-wordmark-lockup.md +38 -38
  268. package/lib/motion/shotcraft/upstream/references/shots/outro/neon-triple-marquee.md +59 -59
  269. package/lib/motion/shotcraft/upstream/references/shots/outro/outro-group-photo-launch.md +39 -39
  270. package/lib/motion/shotcraft/upstream/references/shots/outro/ui-strip-away-outro.md +61 -61
  271. package/lib/motion/shotcraft/upstream/references/shots/outro/ui-to-brand-morph.md +52 -52
  272. package/lib/motion/shotcraft/upstream/references/shots/rhythm/beat-cut-moves.md +50 -50
  273. package/lib/motion/shotcraft/upstream/references/shots/rhythm/beat-step-list-theme-cycle.md +66 -66
  274. package/lib/motion/shotcraft/upstream/references/shots/rhythm/panel-grid-moves.md +43 -43
  275. package/lib/motion/shotcraft/upstream/references/shots/rhythm/quad-split-parallel-scenes.md +38 -38
  276. package/lib/motion/shotcraft/upstream/references/shots/rhythm/rhythm-interrupt-moves.md +38 -38
  277. package/lib/motion/shotcraft/upstream/references/shots/rhythm/sakuga-timing-shift.md +56 -56
  278. package/lib/motion/shotcraft/upstream/references/shots/rhythm/speed-ramp-freeze.md +44 -44
  279. package/lib/motion/shotcraft/upstream/references/shots/rhythm/trailer-grammar-moves.md +38 -38
  280. package/lib/motion/shotcraft/upstream/references/shots/transition/bottom-push-stack-wipe.md +63 -63
  281. package/lib/motion/shotcraft/upstream/references/shots/transition/card-flip-reveal.md +57 -57
  282. package/lib/motion/shotcraft/upstream/references/shots/transition/card-flock-tumble.md +63 -63
  283. package/lib/motion/shotcraft/upstream/references/shots/transition/circle-match-iris.md +58 -58
  284. package/lib/motion/shotcraft/upstream/references/shots/transition/gradient-transition.md +45 -45
  285. package/lib/motion/shotcraft/upstream/references/shots/transition/line-carry-transition.md +55 -55
  286. package/lib/motion/shotcraft/upstream/references/shots/transition/mosaic-reframe.md +49 -49
  287. package/lib/motion/shotcraft/upstream/references/shots/transition/page-turn-transitions.md +42 -42
  288. package/lib/motion/shotcraft/upstream/references/shots/transition/print-texture-transitions.md +42 -42
  289. package/lib/motion/shotcraft/upstream/references/shots/transition/shot-transitions.md +45 -45
  290. package/lib/motion/shotcraft/upstream/references/shots/transition/tear-streak-transitions.md +48 -48
  291. package/lib/motion/shotcraft/upstream/references/shots/transition/transition-hidden-cut.md +55 -55
  292. package/lib/motion/shotcraft/upstream/references/shots/transition/transition-travel.md +43 -43
  293. package/lib/motion/shotcraft/upstream/references/shots/transition/white-flash-logo-simplify-cut.md +41 -41
  294. package/lib/motion/shotcraft/upstream/references/shots/transition/wipe-transitions.md +42 -42
  295. package/lib/motion/shotcraft/upstream/references/shots/typography/blur-slide.md +59 -59
  296. package/lib/motion/shotcraft/upstream/references/shots/typography/brace-expand.md +55 -55
  297. package/lib/motion/shotcraft/upstream/references/shots/typography/countdown-arc-scatter.md +65 -65
  298. package/lib/motion/shotcraft/upstream/references/shots/typography/document-typewriter-reveal.md +42 -42
  299. package/lib/motion/shotcraft/upstream/references/shots/typography/flying-words.md +64 -64
  300. package/lib/motion/shotcraft/upstream/references/shots/typography/glitch-cycle.md +64 -64
  301. package/lib/motion/shotcraft/upstream/references/shots/typography/gradient-word-sweep.md +54 -54
  302. package/lib/motion/shotcraft/upstream/references/shots/typography/lead-word-zoom-assemble.md +91 -91
  303. package/lib/motion/shotcraft/upstream/references/shots/typography/marker-underline-title.md +51 -51
  304. package/lib/motion/shotcraft/upstream/references/shots/typography/outline-word-fill.md +66 -66
  305. package/lib/motion/shotcraft/upstream/references/shots/typography/paper-title-card.md +38 -38
  306. package/lib/motion/shotcraft/upstream/references/shots/typography/pill-chip-slot-cycle-handled.md +66 -66
  307. package/lib/motion/shotcraft/upstream/references/shots/typography/pill-slot-cycle.md +58 -58
  308. package/lib/motion/shotcraft/upstream/references/shots/typography/text-column-converge.md +61 -61
  309. package/lib/motion/shotcraft/upstream/references/shots/typography/title-demote-to-label.md +64 -64
  310. package/lib/motion/shotcraft/upstream/references/shots/typography/type-assembly-moves.md +45 -45
  311. package/lib/motion/shotcraft/upstream/references/shots/typography/type-entrance-moves.md +41 -41
  312. package/lib/motion/shotcraft/upstream/references/shots/typography/type-rhythm-sync.md +51 -51
  313. package/lib/motion/shotcraft/upstream/references/shots/typography/typewriter-moves.md +42 -42
  314. package/lib/motion/shotcraft/upstream/references/shots/typography/vertical-word-roll-blur-cycle.md +63 -63
  315. package/lib/motion/shotcraft/upstream/references/shots/typography/word-relay-filmstrip.md +57 -57
  316. package/lib/motion/shotcraft/upstream/references/shots/typography/word-relay-geometry.md +75 -75
  317. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/avatar-bracket-carousel.md +59 -59
  318. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/bezier-source-converge-merge.md +67 -67
  319. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/card-stack.md +60 -60
  320. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/carousel-3d.md +66 -66
  321. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/cloner-depth-echo.md +40 -40
  322. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/deck-deal-flyin.md +45 -45
  323. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/doc-park-left-pill-deal.md +62 -62
  324. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/draw-svg-trace.md +55 -55
  325. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/element-body-moves.md +37 -37
  326. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/integration-hub-map.md +55 -55
  327. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/list-reveal.md +50 -50
  328. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/list-stack-press.md +43 -43
  329. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/neon-frame-forerun.md +55 -55
  330. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/neon-frame-orbit-drop.md +51 -51
  331. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/page-waterfall-wall.md +51 -51
  332. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/product-card-progressive-assemble.md +56 -56
  333. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/radial-wave.md +49 -49
  334. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/research-card-stack-scroll.md +57 -57
  335. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/row-embed.md +36 -36
  336. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/value-stagger-gradient.md +64 -64
  337. package/lib/motion/shotcraft/upstream/references/shots/ui-entrance/wall-reveal-moves.md +47 -47
  338. package/lib/motion/shotcraft/upstream/references/sound-design.md +170 -170
  339. package/lib/motion/shotcraft/upstream/references/workbench.md +157 -157
  340. package/lib/motion/shotcraft/upstream/template/TEMPLATE.md +103 -103
  341. package/lib/motion/shotcraft/upstream/template/THEMES.md +44 -44
  342. package/lib/motion/shotcraft/upstream/template/package.json +20 -20
  343. package/lib/motion/shotcraft/upstream/template/remotion.config.ts +6 -6
  344. package/lib/motion/shotcraft/upstream/template/src/Root.tsx +17 -17
  345. package/lib/motion/shotcraft/upstream/template/src/aifl/Caption.tsx +65 -65
  346. package/lib/motion/shotcraft/upstream/template/src/aifl/DigitRoll.tsx +48 -48
  347. package/lib/motion/shotcraft/upstream/template/src/aifl/FlashCut.tsx +24 -24
  348. package/lib/motion/shotcraft/upstream/template/src/aifl/Main.tsx +192 -192
  349. package/lib/motion/shotcraft/upstream/template/src/aifl/PaperTitleCard.tsx +111 -111
  350. package/lib/motion/shotcraft/upstream/template/src/aifl/live/PageCam.tsx +150 -150
  351. package/lib/motion/shotcraft/upstream/template/src/aifl/live/SceneDetail.tsx +158 -158
  352. package/lib/motion/shotcraft/upstream/template/src/aifl/live/SceneFlyIn.tsx +468 -468
  353. package/lib/motion/shotcraft/upstream/template/src/aifl/live/SceneOpen.tsx +552 -552
  354. package/lib/motion/shotcraft/upstream/template/src/aifl/live/SceneOutroLive.tsx +411 -411
  355. package/lib/motion/shotcraft/upstream/template/src/aifl/live/ScenePapers.tsx +200 -200
  356. package/lib/motion/shotcraft/upstream/template/src/aifl/live/SceneWbr.tsx +324 -324
  357. package/lib/motion/shotcraft/upstream/template/src/aifl/live-layout.json +388 -388
  358. package/lib/motion/shotcraft/upstream/template/src/index.ts +4 -4
  359. package/lib/motion/shotcraft/upstream/template/src/themes/ThemedFilm.tsx +7 -7
  360. package/lib/motion/shotcraft/upstream/template/src/themes/manifest.tsx +68 -68
  361. package/lib/motion/shotcraft/upstream/template/src/themes/palette-assets.json +1 -1
  362. package/lib/motion/shotcraft/upstream/template/src/themes/palette-assets.ts +24 -24
  363. package/lib/motion/shotcraft/upstream/template/src/themes/palettes.json +74 -74
  364. package/lib/motion/shotcraft/upstream/template/src/themes/visual-theme.tsx +91 -91
  365. package/lib/motion/shotcraft/upstream/template/src/workbench.ts +213 -213
  366. package/lib/motion/shotcraft/upstream/template/tsconfig.json +15 -15
  367. package/lib/motion/style-frames.js +306 -306
  368. package/lib/motion/sync.js +214 -214
  369. package/lib/motion-library.js +1 -1
  370. package/lib/motion-project.js +105 -105
  371. package/lib/motion-render-worker.js +174 -174
  372. package/lib/routing/router.js +222 -222
  373. package/lib/routing/vendor/README.md +96 -96
  374. package/lib/routing/vendor/libavoid-routing.js +753 -753
  375. package/lib/routing/vendor/libavoid.min.js +59 -59
  376. package/lib/svg-export.js +1344 -0
  377. package/lib/video-trace-pool.js +128 -128
  378. package/package.json +3 -2
  379. package/LICENSE +0 -4175
@@ -1,111 +1,111 @@
1
- # 发布到社交平台:成片 → TikTok / Instagram / YouTube / LinkedIn / X …
2
-
3
- 把交付的 MP4 一次发到 TikTok、Instagram(Reels 或 Stories)、YouTube(含 Shorts)、
4
- LinkedIn、Facebook、X、Threads、Pinterest、Bluesky,可立即发布或定时发布。
5
- 脚本 `publish/upload_post.py`,通过 [Upload-Post](https://upload-post.com) API 完成,
6
- 只用 Python 标准库(无需 venv / pip)。
7
-
8
- **触发时机**:只在用户**主动要求**把成片发到社交平台时执行(例如"帮我发到
9
- TikTok 和 YouTube")。它不是交付收尾 1-2-3 之外的第 4 条推荐,不要主动推销。
10
- 发布是公开且难以撤回的操作,**必须先让用户确认文案和平台清单**,再真正发布。
11
-
12
- > **说明**:Upload-Post 是第三方托管服务。免费版每月 10 次上传,覆盖上面除
13
- > TikTok 以外的全部平台(TikTok 需付费版)。只有用户配置了自己的 API key 时
14
- > 本流程才会联网。
15
-
16
- ## 1. 一次性准备(用户操作)
17
-
18
- 1. 在 https://upload-post.com 注册,创建一个 profile,把要发的社交账号连到这个 profile。
19
- 2. 在后台创建 API key。
20
- 3. 设置环境变量(或写进用户自己的 shell 配置):
21
-
22
- ```bash
23
- export UPLOAD_POST_API_KEY=...
24
- export UPLOAD_POST_USER=<profile 名>
25
- ```
26
-
27
- 缺这两个变量时,告诉用户以上三步,停下等待,不要尝试发布。
28
-
29
- ## 2. 选文件与准备文案
30
-
31
- - **文件**:用交付的成片。配了 BGM 的片子有两版(带 BGM / 无 BGM),默认发
32
- **带 BGM 版**;用户另有要求按用户的来。
33
- - **画幅**:TikTok、Reels、Shorts 要竖屏 9:16。成片是横屏 16:9 时如实告诉用户
34
- (这些平台会加黑边或裁切),建议改发 YouTube / LinkedIn / X / Facebook,或另渲
35
- 一版竖屏。
36
- - **文案 `--title`**:在 TikTok / Instagram / X / Threads 上就是正文,按社交文案写
37
- (钩子一句 + 2–4 个话题标签),不要写成 YouTube 标题。含 YouTube 时 ≤100 字符。
38
- 交付收尾第 1 条里用户若同意 @ 作者,把那句放进文案。
39
- - **长描述 `--description`**:YouTube / LinkedIn / Facebook / Pinterest 用。
40
- - **AI 声明 `--ai-generated`**:询问用户是否标注 AI 生成内容。成片由 Agent 以代码
41
- 渲染,一般不属于"逼真的合成影像",默认不标;用了 AI 生成画面或 AI 配音时建议标。
42
-
43
- 把「文案 + 描述 + 平台清单 + 定时(如有)+ 各平台隐私设置」整理给用户,
44
- **得到明确确认后**再进入下一步。
45
-
46
- ## 3. 先 dry-run(不发布)
47
-
48
- ```bash
49
- python3 publish/upload_post.py --video out/promo.mp4 --title "<文案>" \
50
- --description "<长描述>" --platforms tiktok,instagram,youtube --dry-run --json-out
51
- ```
52
-
53
- 检查输出:`authOk` 为 `true`;`missingPlatforms` 非空说明这些平台没连到 profile,
54
- 会被跳过,告诉用户去后台连接,或从清单里去掉。
55
-
56
- ## 4. 发布
57
-
58
- 去掉 `--dry-run` 重跑。脚本等待各平台结果(默认最多 10 分钟),逐平台输出链接或错误。
59
-
60
- - **每条发布命令只跑一次。** 无论超时、断网、报错还是 `status: "unknown"`,都**不要
61
- 重跑发布命令**,重跑会生成新的 request_id,同一视频会被发两次。只能查询:
62
- `python3 publish/upload_post.py --status <requestId> --json-out`
63
- - 脚本如何区分:只有 **400 / 401 / 403 / 422**(服务端受理前明确拒绝)才判失败,此时
64
- 没有任何东西被发出去,修正参数后可以再发。5xx、网关错误、超时、断网、2xx 却无有效
65
- JSON 都属于"不确定",视频可能已被受理。脚本会自动用同一个 request_id 查询:查到就
66
- 照常继续;仍无法确认则输出 `status: "unknown"`(退出码 2)、`requestId` 和
67
- `statusCommand`,并带 `doNotRerun: true`。
68
- - 脚本在**发送之前**就把 `request_id` 和对应的 `--status` 命令打到 stderr。进程中途
69
- 被中断时,用这条命令查询,不要重跑发布。
70
- - 定时发布(`--schedule 2026-10-01T09:00:00 --timezone Asia/Shanghai`)立即返回
71
- `jobId` + `requestId` 和 `statusCommand`。定时任务按 **`jobId`** 查询:
72
- `python3 publish/upload_post.py --status <jobId> --json-out`(输出里的 `statusCommand`
73
- 就是这条命令)。
74
-
75
- ## 5. 向用户汇报
76
-
77
- 每个平台一行:链接、或原因。
78
-
79
- | 平台结果 | 含义 |
80
- |---|---|
81
- | `completed` + `url` | 已发布。私密发布没有公开链接:YouTube 仍给出本人可看的链接,其他平台给 `postId` + `note` |
82
- | `skipped` | profile 没连这个平台,没有发 |
83
- | `failed` / `retryable` | `error` 是平台给的原因(如账号授权过期,去后台重新连接);`retryable` 会由服务端自动重试 |
84
- | TikTok `inbox: true` | TikTok 把视频放进了草稿箱,需要用户在 TikTok App 里点发布 |
85
- | 整体 `status: "unknown"` | 无法确认是否已受理。原样告诉用户 `requestId`,稍后用 `statusCommand` 查询;**不要重跑发布命令** |
86
-
87
- ## 6. 参数速查
88
-
89
- | 参数 | 说明 |
90
- |---|---|
91
- | `--video` / `--title` | 成片路径 / 各平台共用文案 |
92
- | `--description` / `--description-file` | 长描述 |
93
- | `--platforms` | `tiktok,instagram,youtube,linkedin,facebook,x,threads,pinterest,bluesky`(别名 `twitter` `reels` `shorts`) |
94
- | `--user` | profile 名,默认 `$UPLOAD_POST_USER` |
95
- | `--schedule` + `--timezone` | 定时发布(≤365 天),IANA 时区,默认 UTC |
96
- | `--first-comment` | 发布后自动发第一条评论 |
97
- | `--ai-generated` | AI 生成内容声明(TikTok / Instagram / YouTube / X) |
98
- | `--thumbnail` | 自定义封面(YouTube、LinkedIn) |
99
- | `--youtube-privacy` | `private`(默认)/ `unlisted` / `public` |
100
- | `--tags` | YouTube 标签,逗号分隔 |
101
- | `--tiktok-privacy` / `--tiktok-draft` | TikTok 隐私(默认沿用账号设置)/ 只存草稿 |
102
- | `--instagram-story` | 发 Stories 而非 Reels |
103
- | `--facebook-page-id` / `--linkedin-page-id` | 指定 Facebook 主页 / 以 LinkedIn 公司页发布 |
104
- | `--pinterest-board` | Pinterest 必填 |
105
- | `--status ID` | 查询之前的发布:即时发布用 request_id,定时发布用 job_id |
106
- | `--dry-run` / `--json-out` | 只校验不发布 / 输出一行 JSON |
107
-
108
- 错误类型(`errorType`):`auth`(key 缺失或错误)、`validation`(参数错误,或所选平台都没连接)、
109
- `forbidden`(套餐不支持,如免费版发 TikTok)、`quota`(频率或套餐上限)、`http`(网络 / 服务端)。
110
-
111
- 离线单测:`python3 -m unittest publish/test_upload_post.py -v`
1
+ # 发布到社交平台:成片 → TikTok / Instagram / YouTube / LinkedIn / X …
2
+
3
+ 把交付的 MP4 一次发到 TikTok、Instagram(Reels 或 Stories)、YouTube(含 Shorts)、
4
+ LinkedIn、Facebook、X、Threads、Pinterest、Bluesky,可立即发布或定时发布。
5
+ 脚本 `publish/upload_post.py`,通过 [Upload-Post](https://upload-post.com) API 完成,
6
+ 只用 Python 标准库(无需 venv / pip)。
7
+
8
+ **触发时机**:只在用户**主动要求**把成片发到社交平台时执行(例如"帮我发到
9
+ TikTok 和 YouTube")。它不是交付收尾 1-2-3 之外的第 4 条推荐,不要主动推销。
10
+ 发布是公开且难以撤回的操作,**必须先让用户确认文案和平台清单**,再真正发布。
11
+
12
+ > **说明**:Upload-Post 是第三方托管服务。免费版每月 10 次上传,覆盖上面除
13
+ > TikTok 以外的全部平台(TikTok 需付费版)。只有用户配置了自己的 API key 时
14
+ > 本流程才会联网。
15
+
16
+ ## 1. 一次性准备(用户操作)
17
+
18
+ 1. 在 https://upload-post.com 注册,创建一个 profile,把要发的社交账号连到这个 profile。
19
+ 2. 在后台创建 API key。
20
+ 3. 设置环境变量(或写进用户自己的 shell 配置):
21
+
22
+ ```bash
23
+ export UPLOAD_POST_API_KEY=...
24
+ export UPLOAD_POST_USER=<profile 名>
25
+ ```
26
+
27
+ 缺这两个变量时,告诉用户以上三步,停下等待,不要尝试发布。
28
+
29
+ ## 2. 选文件与准备文案
30
+
31
+ - **文件**:用交付的成片。配了 BGM 的片子有两版(带 BGM / 无 BGM),默认发
32
+ **带 BGM 版**;用户另有要求按用户的来。
33
+ - **画幅**:TikTok、Reels、Shorts 要竖屏 9:16。成片是横屏 16:9 时如实告诉用户
34
+ (这些平台会加黑边或裁切),建议改发 YouTube / LinkedIn / X / Facebook,或另渲
35
+ 一版竖屏。
36
+ - **文案 `--title`**:在 TikTok / Instagram / X / Threads 上就是正文,按社交文案写
37
+ (钩子一句 + 2–4 个话题标签),不要写成 YouTube 标题。含 YouTube 时 ≤100 字符。
38
+ 交付收尾第 1 条里用户若同意 @ 作者,把那句放进文案。
39
+ - **长描述 `--description`**:YouTube / LinkedIn / Facebook / Pinterest 用。
40
+ - **AI 声明 `--ai-generated`**:询问用户是否标注 AI 生成内容。成片由 Agent 以代码
41
+ 渲染,一般不属于"逼真的合成影像",默认不标;用了 AI 生成画面或 AI 配音时建议标。
42
+
43
+ 把「文案 + 描述 + 平台清单 + 定时(如有)+ 各平台隐私设置」整理给用户,
44
+ **得到明确确认后**再进入下一步。
45
+
46
+ ## 3. 先 dry-run(不发布)
47
+
48
+ ```bash
49
+ python3 publish/upload_post.py --video out/promo.mp4 --title "<文案>" \
50
+ --description "<长描述>" --platforms tiktok,instagram,youtube --dry-run --json-out
51
+ ```
52
+
53
+ 检查输出:`authOk` 为 `true`;`missingPlatforms` 非空说明这些平台没连到 profile,
54
+ 会被跳过,告诉用户去后台连接,或从清单里去掉。
55
+
56
+ ## 4. 发布
57
+
58
+ 去掉 `--dry-run` 重跑。脚本等待各平台结果(默认最多 10 分钟),逐平台输出链接或错误。
59
+
60
+ - **每条发布命令只跑一次。** 无论超时、断网、报错还是 `status: "unknown"`,都**不要
61
+ 重跑发布命令**,重跑会生成新的 request_id,同一视频会被发两次。只能查询:
62
+ `python3 publish/upload_post.py --status <requestId> --json-out`
63
+ - 脚本如何区分:只有 **400 / 401 / 403 / 422**(服务端受理前明确拒绝)才判失败,此时
64
+ 没有任何东西被发出去,修正参数后可以再发。5xx、网关错误、超时、断网、2xx 却无有效
65
+ JSON 都属于"不确定",视频可能已被受理。脚本会自动用同一个 request_id 查询:查到就
66
+ 照常继续;仍无法确认则输出 `status: "unknown"`(退出码 2)、`requestId` 和
67
+ `statusCommand`,并带 `doNotRerun: true`。
68
+ - 脚本在**发送之前**就把 `request_id` 和对应的 `--status` 命令打到 stderr。进程中途
69
+ 被中断时,用这条命令查询,不要重跑发布。
70
+ - 定时发布(`--schedule 2026-10-01T09:00:00 --timezone Asia/Shanghai`)立即返回
71
+ `jobId` + `requestId` 和 `statusCommand`。定时任务按 **`jobId`** 查询:
72
+ `python3 publish/upload_post.py --status <jobId> --json-out`(输出里的 `statusCommand`
73
+ 就是这条命令)。
74
+
75
+ ## 5. 向用户汇报
76
+
77
+ 每个平台一行:链接、或原因。
78
+
79
+ | 平台结果 | 含义 |
80
+ |---|---|
81
+ | `completed` + `url` | 已发布。私密发布没有公开链接:YouTube 仍给出本人可看的链接,其他平台给 `postId` + `note` |
82
+ | `skipped` | profile 没连这个平台,没有发 |
83
+ | `failed` / `retryable` | `error` 是平台给的原因(如账号授权过期,去后台重新连接);`retryable` 会由服务端自动重试 |
84
+ | TikTok `inbox: true` | TikTok 把视频放进了草稿箱,需要用户在 TikTok App 里点发布 |
85
+ | 整体 `status: "unknown"` | 无法确认是否已受理。原样告诉用户 `requestId`,稍后用 `statusCommand` 查询;**不要重跑发布命令** |
86
+
87
+ ## 6. 参数速查
88
+
89
+ | 参数 | 说明 |
90
+ |---|---|
91
+ | `--video` / `--title` | 成片路径 / 各平台共用文案 |
92
+ | `--description` / `--description-file` | 长描述 |
93
+ | `--platforms` | `tiktok,instagram,youtube,linkedin,facebook,x,threads,pinterest,bluesky`(别名 `twitter` `reels` `shorts`) |
94
+ | `--user` | profile 名,默认 `$UPLOAD_POST_USER` |
95
+ | `--schedule` + `--timezone` | 定时发布(≤365 天),IANA 时区,默认 UTC |
96
+ | `--first-comment` | 发布后自动发第一条评论 |
97
+ | `--ai-generated` | AI 生成内容声明(TikTok / Instagram / YouTube / X) |
98
+ | `--thumbnail` | 自定义封面(YouTube、LinkedIn) |
99
+ | `--youtube-privacy` | `private`(默认)/ `unlisted` / `public` |
100
+ | `--tags` | YouTube 标签,逗号分隔 |
101
+ | `--tiktok-privacy` / `--tiktok-draft` | TikTok 隐私(默认沿用账号设置)/ 只存草稿 |
102
+ | `--instagram-story` | 发 Stories 而非 Reels |
103
+ | `--facebook-page-id` / `--linkedin-page-id` | 指定 Facebook 主页 / 以 LinkedIn 公司页发布 |
104
+ | `--pinterest-board` | Pinterest 必填 |
105
+ | `--status ID` | 查询之前的发布:即时发布用 request_id,定时发布用 job_id |
106
+ | `--dry-run` / `--json-out` | 只校验不发布 / 输出一行 JSON |
107
+
108
+ 错误类型(`errorType`):`auth`(key 缺失或错误)、`validation`(参数错误,或所选平台都没连接)、
109
+ `forbidden`(套餐不支持,如免费版发 TikTok)、`quota`(频率或套餐上限)、`http`(网络 / 服务端)。
110
+
111
+ 离线单测:`python3 -m unittest publish/test_upload_post.py -v`
@@ -1,50 +1,50 @@
1
- ---
2
- name: promo-energy-arc
3
- 一句话: 全片能量骨架——低开品牌 → 单主角立传 → 字卡呼吸间隔的功能爬升段 → 发布会峰值收场
4
- 适用: 30–60s 多功能 web 产品宣传片的默认全片结构(分镜阶段先填骨架再挑卡)
5
- 段数: 4 段位 + 2–4 张呼吸字卡
6
- ---
7
-
8
- ## 意图
9
-
10
- 把散落在 R1–R3/Q5/Q8/P4 的节奏规则合成一条可直接填空的全片曲线。
11
- 模板片成片(1085f)与两次独立复现(各 900f)三次成表均收敛到同一
12
- 骨架——它是默认项,不是令:逐项目可有意识偏离,偏离写进项目 spec。
13
-
14
- ## 段位表
15
-
16
- | 段位 | 时长占比 | 能量 | 职责 | 候选配方卡 |
17
- |------|----------|------|------|------------|
18
- | ① 品牌开场 | 8–12%(30s 片);开场+立传合计可达 20%(模板片) | 低 | 字标压印 + hold ≥1s(R1),交棒产品页面 | brand-ink-open |
19
- | ② 单主角立传 | 12–15% | 中(质感最高、节奏最慢) | 一个主角、一条完整动作弧 ≥3s(Q5/R3),立出产品原子单位 | spotlight-hero-card(+aesthetic-rules.md Q2 高清 rasterize 技法) |
20
- | ③ 功能爬升段 | 55–65% | 中高⇄低交替 | 每镜绑一个独特功能、一种手法只当一次主角(P4);镜与镜之间按需插呼吸字卡 | deck-deal-flyin / type-and-filter / list-stack-press / row-embed / document-typewriter-reveal |
21
- | ④ 发布会收场 | 13–16% | 峰值(全片最高) | 已展示功能各出代表元素合影围住字标(Q8),sign-off hold ≥1s(R1) | outro-group-photo-launch |
22
-
23
- 呼吸字卡(paper-title-card)规则:每 1–2 个功能镜头后插一张,单张
24
- 50–55f(≈1.8s),全片 2–4 张;重要功能出场前用作引导字卡(C2)。
25
- 模板片 10 镜里字卡占 4 席,两次复现各 2 席——密度按功能镜头数取。
26
-
27
- ## 填空流程(替代 ad-hoc 推导)
28
-
29
- 1. 列产品功能清单(P4),数出功能镜头数 N。
30
- 2. 按段位表分配总帧数:先扣 ①②④ 与字卡的预算,剩余给 ③ 均分。
31
- 每镜预算内**先划走 hold/rest 帧**(R1 落定 ≥30f、批量收尾 15f,R3)
32
- 再排动效——不是排完动效再找空隙。
33
- 3. ③ 段能量交替:高能量镜(发牌/堆叠)与稳节奏镜(交互/读字段)
34
- 间隔排列,信息密度最高的镜头(文档/报告类)放在峰值收场之前——
35
- 模板片与两次复现均把文档/报告类镜头排在倒数第 2–3 位。
36
- 4. 逐槽位扫 shots/ frontmatter 挑卡,选中的卡读全文。
37
- 5. 镜头排定后逐接缝选转场式(shot-transitions 技法卡三式选型),
38
- 写进分镜表"关键动效"列——转场帧从相邻镜头预算划走。
39
-
40
- ## 已知坑
41
-
42
- - 骨架当风格令全局硬套:段位占比是模板片单例实证(标注:单例判例),
43
- 15s 短片或单功能产品应大胆合并段位,但 ①hold/④峰值两端不可省。
44
- - ③ 段只堆高能量镜:连续高能量读作嘈杂,交替与字卡就是节奏本身。
45
- - 呼吸字卡写成第二遍 tagline:字卡与 outro 文案重复即删(P4 判例:
46
- outro tagline 去重)。
47
-
48
- ## 参考实现
49
-
50
- template/src/aifl/Main.tsx AIFL_SHOTS 段位表(sum=1085f)。
1
+ ---
2
+ name: promo-energy-arc
3
+ 一句话: 全片能量骨架——低开品牌 → 单主角立传 → 字卡呼吸间隔的功能爬升段 → 发布会峰值收场
4
+ 适用: 30–60s 多功能 web 产品宣传片的默认全片结构(分镜阶段先填骨架再挑卡)
5
+ 段数: 4 段位 + 2–4 张呼吸字卡
6
+ ---
7
+
8
+ ## 意图
9
+
10
+ 把散落在 R1–R3/Q5/Q8/P4 的节奏规则合成一条可直接填空的全片曲线。
11
+ 模板片成片(1085f)与两次独立复现(各 900f)三次成表均收敛到同一
12
+ 骨架——它是默认项,不是令:逐项目可有意识偏离,偏离写进项目 spec。
13
+
14
+ ## 段位表
15
+
16
+ | 段位 | 时长占比 | 能量 | 职责 | 候选配方卡 |
17
+ |------|----------|------|------|------------|
18
+ | ① 品牌开场 | 8–12%(30s 片);开场+立传合计可达 20%(模板片) | 低 | 字标压印 + hold ≥1s(R1),交棒产品页面 | brand-ink-open |
19
+ | ② 单主角立传 | 12–15% | 中(质感最高、节奏最慢) | 一个主角、一条完整动作弧 ≥3s(Q5/R3),立出产品原子单位 | spotlight-hero-card(+aesthetic-rules.md Q2 高清 rasterize 技法) |
20
+ | ③ 功能爬升段 | 55–65% | 中高⇄低交替 | 每镜绑一个独特功能、一种手法只当一次主角(P4);镜与镜之间按需插呼吸字卡 | deck-deal-flyin / type-and-filter / list-stack-press / row-embed / document-typewriter-reveal |
21
+ | ④ 发布会收场 | 13–16% | 峰值(全片最高) | 已展示功能各出代表元素合影围住字标(Q8),sign-off hold ≥1s(R1) | outro-group-photo-launch |
22
+
23
+ 呼吸字卡(paper-title-card)规则:每 1–2 个功能镜头后插一张,单张
24
+ 50–55f(≈1.8s),全片 2–4 张;重要功能出场前用作引导字卡(C2)。
25
+ 模板片 10 镜里字卡占 4 席,两次复现各 2 席——密度按功能镜头数取。
26
+
27
+ ## 填空流程(替代 ad-hoc 推导)
28
+
29
+ 1. 列产品功能清单(P4),数出功能镜头数 N。
30
+ 2. 按段位表分配总帧数:先扣 ①②④ 与字卡的预算,剩余给 ③ 均分。
31
+ 每镜预算内**先划走 hold/rest 帧**(R1 落定 ≥30f、批量收尾 15f,R3)
32
+ 再排动效——不是排完动效再找空隙。
33
+ 3. ③ 段能量交替:高能量镜(发牌/堆叠)与稳节奏镜(交互/读字段)
34
+ 间隔排列,信息密度最高的镜头(文档/报告类)放在峰值收场之前——
35
+ 模板片与两次复现均把文档/报告类镜头排在倒数第 2–3 位。
36
+ 4. 逐槽位扫 shots/ frontmatter 挑卡,选中的卡读全文。
37
+ 5. 镜头排定后逐接缝选转场式(shot-transitions 技法卡三式选型),
38
+ 写进分镜表"关键动效"列——转场帧从相邻镜头预算划走。
39
+
40
+ ## 已知坑
41
+
42
+ - 骨架当风格令全局硬套:段位占比是模板片单例实证(标注:单例判例),
43
+ 15s 短片或单功能产品应大胆合并段位,但 ①hold/④峰值两端不可省。
44
+ - ③ 段只堆高能量镜:连续高能量读作嘈杂,交替与字卡就是节奏本身。
45
+ - 呼吸字卡写成第二遍 tagline:字卡与 outro 文案重复即删(P4 判例:
46
+ outro tagline 去重)。
47
+
48
+ ## 参考实现
49
+
50
+ template/src/aifl/Main.tsx AIFL_SHOTS 段位表(sum=1085f)。
@@ -1,95 +1,95 @@
1
- # Freesound 音效选材
2
-
3
- 新制作与换音直接从 [Freesound](https://freesound.org) 获取 SFX,不再使用共享本地音效库。
4
- 用户指定的音源仍优先。BGM 沿用独立选曲流程,见 [sound-design.md](sound-design.md) §2。
5
- 本模块负责选材、下载与来源记录;钉帧、混音、输出偏移补偿继续按 sound-design 执行。
6
-
7
- ## 1. 把画面写成声音需求
8
-
9
- 每个 cue 记录:对应镜头/动作、声源或材质、目标时长、攻击/尾音、音色和许可要求。
10
- 例如纸卡滑入:`paper slide`,0.2–0.8s,干燥、单次、无长尾、CC0。
11
- 以声源匹配为先,再比较时长、录音描述与热度;不要只搜索抽象情绪或宽泛的 `click`。
12
-
13
- - 单击/滑动不要选混有多个动作的长段录音,除非能明确裁出所需动作。
14
- - 下载量与评分人数用于辅助排序,不能替代匹配度;大量评分的 4.4 分通常比 6 人评出的
15
- 4.9 分更有参考性。推荐时引用实际数据,缺失值保留未知,不能编造。
16
- - 上传者描述提供声源、设备、处理方式线索;优先清晰且匹配的实际声源。
17
- 名牌设备不保证质量,口技或内置麦克风也不自动意味着不可用,按项目质感判断。
18
- - UI 动作的拟音与合成提示音分开判断,遵守 aesthetic-rules S1/S4。
19
-
20
- ## 2. 搜索
21
-
22
- 脚本独立实现,Python 3.9+ 标准库,无需 Freesound API key;下载/分析需 ffmpeg、ffprobe。
23
- 从 skill 根目录执行;路径含空格时加引号。安装在其他位置时用脚本绝对路径。
24
-
25
- ```bash
26
- python3 assets/scripts/sfx-source.py search "paper slide" --max-duration 1 --limit 5 --output /path/to/video/audio-search.json
27
- python3 assets/scripts/sfx-source.py search "short cinematic impact" --license by --max-duration 3 --pages 2
28
- ```
29
-
30
- 输出 JSON 含 ID、标题、作者、素材页、预览地址、描述、时长、下载量、评分和人数。
31
- 保留搜索相关性顺序,并在本地再次过滤许可与时长。`--pages` 最多 3 页,先缩窄关键词,
32
- 不以抓取更多页面代替选材。搜索输出只用于比较,不作为下载时的许可凭据。
33
-
34
- 许可默认 `cc0`;`by` 允许 CC0 和 CC BY。商用产品片不接受 BY-NC、Sampling+ 或未知许可。
35
- 用户愿意接受署名时可用 `--license by`,无需对每条声音重复询问。
36
-
37
- ## 3. 下载到当前视频工程
38
-
39
- 把 ID 换成本次搜索返回的候选;`get` 也支持已知 ID,不依赖全局缓存。
40
-
41
- ```bash
42
- python3 assets/scripts/sfx-source.py get fs:12345 fs:67890 --out-dir /path/to/video/public/audio/sfx
43
- ```
44
-
45
- 需要 CC BY 时在 `get` 上同样传 `--license by`。下载前重新读取各素材的详情页、
46
- 核对实际许可 URL 与版本,再有界并发下载。不会修改网络代理,也不会自动切换其他音源。
47
-
48
- 产物:
49
-
50
- - `fs-<id>.mp3`:Freesound 的高质量 **有损 MP3 预览**,不是上传者的原始 WAV。
51
- - `audio-manifest.json`:来源、作者、素材页、许可 URL/版本、预览标记、下载时间、
52
- SHA-256、修改记录与实际音频分析。
53
- - `FREESOUND-CREDITS.md`:可随工程交付的来源与署名清单;CC BY 条目需进入发布页说明
54
- 或成片署名,不能仅留在工程文件中。剪辑、变速、归一化等改动需补写 `changes`。
55
-
56
- 重复下载会核对文件哈希,不覆盖自行修改或来源不明的同名文件。每个输出目录同一时间
57
- 只运行一个 `get`。部分下载失败时成功项仍保留清单,命令退出非零;根据逐条结果只重试失败 ID。
58
- 无匹配候选时调整查询;网站超时/限流/页面结构变化时停止该来源的自动调用,说明具体问题。
59
- 可给出素材页供人工下载,再按同样字段记录来源;不能用 HTML 错误页冒充音频。
60
-
61
- 原音质或无损处理有明确要求时,从素材页走 Freesound 支持的登录/下载流程取得原文件;
62
- 不能把预览转 WAV 后标成“原始无损素材”。记录真实文件种类、地址、哈希并重新分析。
63
-
64
- ## 4. 分析、试听与接入
65
-
66
- `get` 自动用 ffprobe 与 ffmpeg 解码验收,记录实际格式/采样率/声道、时长、sample peak、
67
- 整体 RMS、10ms RMS 能量峰和相对峰值 -40dB 的活动区间。这些不是 LUFS、true peak 或精确动作起点。
68
- 多个动作的录音需要选择正确的峰值,不能直接将全文件最大峰用于所有 cue。
69
-
70
- 单独分析处理后的文件:
71
-
72
- ```bash
73
- python3 assets/scripts/sfx-source.py analyze /path/to/video/public/audio/sfx/fs-12345.mp3 --output /path/to/video/audio-analysis.json
74
- ```
75
-
76
- 处理后更新 manifest 的文件名、SHA-256、`analysis` 和 `changes`;原文件与处理后文件的
77
- 峰值时间分开记录。浏览器试听或把候选垫入片段检查音色、底噪、尾音与音乐的关系。
78
- 工具只有元数据/测量能力时,明确写“未试听”,不要将下载数、波形或 ffmpeg 分析描述成听感。
79
- 自主创作可基于证据选定并继续;用户要求听候选时给素材页或支持的本地音频预览。
80
-
81
- 随后将固定文件接入中央 SFX 表,`from` 从 `SHOTS`/`beatF` 派生,并根据
82
- sound-design §4.6 补偿音源峰值与输出偏移。下载文件必须随工程保存,不能只引用远程 URL。
83
- 工作台显示工程音频;新增下载后重新运行 `node workbench/scripts/open.mjs <工程目录>` 更新索引。
84
-
85
- ## 5. 模板与交付
86
-
87
- `template/public/audio/` 的历史文件保留供原样运行与验证,不作为新项目的选材池。
88
- 用模板为新产品制作时,沿用 SFX 的动作语义和钉帧结构,从 Freesound 选音后重新测量、对齐;
89
- 用户明确要求复现原声音时保留该要求,并按模板授权记录核实音源。
90
- 共享 SFX 目录移除前的完整记录可从 Git 历史查询,BGM 授权仍在 `assets/audio/ATTRIBUTION.md`。
91
-
92
- 交付音频文件、manifest、署名清单和 SFX 时间表。终检见 [final-review.md](final-review.md) A10。
93
-
94
- 选材方法参考 [vibe-motion/sound](https://github.com/vibe-motion/sound)(查阅版本 `01f81d6`);
95
- 本仓库的 CLI 为独立实现,未引入其脚本或个人 Clash 配置。
1
+ # Freesound 音效选材
2
+
3
+ 新制作与换音直接从 [Freesound](https://freesound.org) 获取 SFX,不再使用共享本地音效库。
4
+ 用户指定的音源仍优先。BGM 沿用独立选曲流程,见 [sound-design.md](sound-design.md) §2。
5
+ 本模块负责选材、下载与来源记录;钉帧、混音、输出偏移补偿继续按 sound-design 执行。
6
+
7
+ ## 1. 把画面写成声音需求
8
+
9
+ 每个 cue 记录:对应镜头/动作、声源或材质、目标时长、攻击/尾音、音色和许可要求。
10
+ 例如纸卡滑入:`paper slide`,0.2–0.8s,干燥、单次、无长尾、CC0。
11
+ 以声源匹配为先,再比较时长、录音描述与热度;不要只搜索抽象情绪或宽泛的 `click`。
12
+
13
+ - 单击/滑动不要选混有多个动作的长段录音,除非能明确裁出所需动作。
14
+ - 下载量与评分人数用于辅助排序,不能替代匹配度;大量评分的 4.4 分通常比 6 人评出的
15
+ 4.9 分更有参考性。推荐时引用实际数据,缺失值保留未知,不能编造。
16
+ - 上传者描述提供声源、设备、处理方式线索;优先清晰且匹配的实际声源。
17
+ 名牌设备不保证质量,口技或内置麦克风也不自动意味着不可用,按项目质感判断。
18
+ - UI 动作的拟音与合成提示音分开判断,遵守 aesthetic-rules S1/S4。
19
+
20
+ ## 2. 搜索
21
+
22
+ 脚本独立实现,Python 3.9+ 标准库,无需 Freesound API key;下载/分析需 ffmpeg、ffprobe。
23
+ 从 skill 根目录执行;路径含空格时加引号。安装在其他位置时用脚本绝对路径。
24
+
25
+ ```bash
26
+ python3 assets/scripts/sfx-source.py search "paper slide" --max-duration 1 --limit 5 --output /path/to/video/audio-search.json
27
+ python3 assets/scripts/sfx-source.py search "short cinematic impact" --license by --max-duration 3 --pages 2
28
+ ```
29
+
30
+ 输出 JSON 含 ID、标题、作者、素材页、预览地址、描述、时长、下载量、评分和人数。
31
+ 保留搜索相关性顺序,并在本地再次过滤许可与时长。`--pages` 最多 3 页,先缩窄关键词,
32
+ 不以抓取更多页面代替选材。搜索输出只用于比较,不作为下载时的许可凭据。
33
+
34
+ 许可默认 `cc0`;`by` 允许 CC0 和 CC BY。商用产品片不接受 BY-NC、Sampling+ 或未知许可。
35
+ 用户愿意接受署名时可用 `--license by`,无需对每条声音重复询问。
36
+
37
+ ## 3. 下载到当前视频工程
38
+
39
+ 把 ID 换成本次搜索返回的候选;`get` 也支持已知 ID,不依赖全局缓存。
40
+
41
+ ```bash
42
+ python3 assets/scripts/sfx-source.py get fs:12345 fs:67890 --out-dir /path/to/video/public/audio/sfx
43
+ ```
44
+
45
+ 需要 CC BY 时在 `get` 上同样传 `--license by`。下载前重新读取各素材的详情页、
46
+ 核对实际许可 URL 与版本,再有界并发下载。不会修改网络代理,也不会自动切换其他音源。
47
+
48
+ 产物:
49
+
50
+ - `fs-<id>.mp3`:Freesound 的高质量 **有损 MP3 预览**,不是上传者的原始 WAV。
51
+ - `audio-manifest.json`:来源、作者、素材页、许可 URL/版本、预览标记、下载时间、
52
+ SHA-256、修改记录与实际音频分析。
53
+ - `FREESOUND-CREDITS.md`:可随工程交付的来源与署名清单;CC BY 条目需进入发布页说明
54
+ 或成片署名,不能仅留在工程文件中。剪辑、变速、归一化等改动需补写 `changes`。
55
+
56
+ 重复下载会核对文件哈希,不覆盖自行修改或来源不明的同名文件。每个输出目录同一时间
57
+ 只运行一个 `get`。部分下载失败时成功项仍保留清单,命令退出非零;根据逐条结果只重试失败 ID。
58
+ 无匹配候选时调整查询;网站超时/限流/页面结构变化时停止该来源的自动调用,说明具体问题。
59
+ 可给出素材页供人工下载,再按同样字段记录来源;不能用 HTML 错误页冒充音频。
60
+
61
+ 原音质或无损处理有明确要求时,从素材页走 Freesound 支持的登录/下载流程取得原文件;
62
+ 不能把预览转 WAV 后标成“原始无损素材”。记录真实文件种类、地址、哈希并重新分析。
63
+
64
+ ## 4. 分析、试听与接入
65
+
66
+ `get` 自动用 ffprobe 与 ffmpeg 解码验收,记录实际格式/采样率/声道、时长、sample peak、
67
+ 整体 RMS、10ms RMS 能量峰和相对峰值 -40dB 的活动区间。这些不是 LUFS、true peak 或精确动作起点。
68
+ 多个动作的录音需要选择正确的峰值,不能直接将全文件最大峰用于所有 cue。
69
+
70
+ 单独分析处理后的文件:
71
+
72
+ ```bash
73
+ python3 assets/scripts/sfx-source.py analyze /path/to/video/public/audio/sfx/fs-12345.mp3 --output /path/to/video/audio-analysis.json
74
+ ```
75
+
76
+ 处理后更新 manifest 的文件名、SHA-256、`analysis` 和 `changes`;原文件与处理后文件的
77
+ 峰值时间分开记录。浏览器试听或把候选垫入片段检查音色、底噪、尾音与音乐的关系。
78
+ 工具只有元数据/测量能力时,明确写“未试听”,不要将下载数、波形或 ffmpeg 分析描述成听感。
79
+ 自主创作可基于证据选定并继续;用户要求听候选时给素材页或支持的本地音频预览。
80
+
81
+ 随后将固定文件接入中央 SFX 表,`from` 从 `SHOTS`/`beatF` 派生,并根据
82
+ sound-design §4.6 补偿音源峰值与输出偏移。下载文件必须随工程保存,不能只引用远程 URL。
83
+ 工作台显示工程音频;新增下载后重新运行 `node workbench/scripts/open.mjs <工程目录>` 更新索引。
84
+
85
+ ## 5. 模板与交付
86
+
87
+ `template/public/audio/` 的历史文件保留供原样运行与验证,不作为新项目的选材池。
88
+ 用模板为新产品制作时,沿用 SFX 的动作语义和钉帧结构,从 Freesound 选音后重新测量、对齐;
89
+ 用户明确要求复现原声音时保留该要求,并按模板授权记录核实音源。
90
+ 共享 SFX 目录移除前的完整记录可从 Git 历史查询,BGM 授权仍在 `assets/audio/ATTRIBUTION.md`。
91
+
92
+ 交付音频文件、manifest、署名清单和 SFX 时间表。终检见 [final-review.md](final-review.md) A10。
93
+
94
+ 选材方法参考 [vibe-motion/sound](https://github.com/vibe-motion/sound)(查阅版本 `01f81d6`);
95
+ 本仓库的 CLI 为独立实现,未引入其脚本或个人 Clash 配置。
@@ -1,41 +1,41 @@
1
- ---
2
- name: basic-3d-scene
3
- 一句话: impress.js 式空间演示:卡片以不同位置/旋转/缩放散布 3D 空间,相机取各步姿态之逆依次飞行对齐,末步拉到 OVERVIEW 总览
4
- 适用: 概念/路线图/三步法的空间化讲述;替代平面 slides 的"每一步都换个空间视角"
5
- 时长: 约 7.5s(225f@30fps;四站,三段飞行 28/32/32f,每站停留 ≥30f)
6
- 能量: 中(每次转场有空间惊喜,停留段安静读卡)
7
- ---
8
-
9
- ## 意图
10
- 把"翻页"变成"在想法的空间里旅行":每张卡不仅有位置还有姿态(第二站世界左转 38°、第三站整个画框侧躺 90°),相机对齐它时观众的世界也跟着转——空间变化本身成为"进入新章节"的仪式感。
11
-
12
- ## 动效核心
13
- - 核心配方一行:**camera = stepTransform.inverse()**。每站只写卡片自己的 pose(x/y/z/rx/ry/rz/s),相机变换按 `scale(1/s) rotateZ(-rz) rotateY(-ry) rotateX(-rx) translate3d(-x,-y,-z)` 取逆,顺序严格相反
14
- - demo 用 graphite 暗场(近单色 + 香槟金点缀),video-shotcraft 的三章节卡 Frame / Craft / Ship(品牌短句拆成三章,卡头右侧挂标志 + 字标):卡片 1240×700 **原生 1:1 排版**(对位时就是屏幕像素,不经设计坐标放大,字不糊),156px 标题 + 44px 说明 + 被卡边裁切的 560px 细体章节数字
15
- - 四站姿态各有戏剧点:STEP01 原点正视 → STEP02 (1690,−260,−650) + ry−38° → STEP03 (2590,830,−850) + rz90°(画框侧躺,相机跟着转正它)→ OVERVIEW s=2.7(相机 1/2.7 拉远),总览站位置按"三卡落在右上、左下留给落版"反解
16
- - 飞行链式插值:三段飞行 36–64 / 96–128 / 158–190(帧),不对称 in-out bezier(0.62,0,0.16,1);站间飞行途中相机额外拉远 30%(hop,sin 包络)让观众看见空间里的其他卡;飞行段做时间采样运动模糊(快门 0.5f,子帧 1–8 按相机位移自适应)
17
- - 停留段不死:落位后相机极缓推近 1.5%(下一段起飞时同曲线还原),卡底金色进度线走满当前段;标题在落位前 8f 逐字从线下升起,每张卡只揭示一次
18
- - 空间参照:70 颗真 3D 浮尘挂在世界坐标里(各有 z),视差全部来自相机;enter/exit 聚焦按"站距"`d = |af − i|` 给 `opacity 0.22–1 + blur 0–7px`,总览段全员回到 0.85
19
- - OVERVIEW 落版挂在总览站姿态上(放大 2.7 倍排版,相机 1/2.7 看回来 = 屏幕 1:1):眉题是 video-shotcraft 标志 + 字标,"Craft the shot." 150px 衬线逐词升起,尾段 hold 推近 1.5%
20
-
21
- ## 参数表
22
- | 参数 | 典型值 | 调节手感 |
23
- |------|--------|----------|
24
- | 站点姿态 | 每站至少一个新变换维度 | 只挪 x/y 是平移幻灯片;rz 站(画框旋转)是记忆点,一支片用一次 |
25
- | 飞行时长 | 28–32f | 有旋转的段别短于 28f,观众需要时间理解"世界在转" |
26
- | 停留时长 | ≥30f | 读卡位;卡内文字多时优先加停留而不是减飞行 |
27
- | hop 拉远 | 30% | 0 = 贴着卡面平移,看不到空间;>50% 每段都像总览 |
28
- | OVERVIEW 缩放 | s=2.7 | 值越大总览越"高空";先定总览海报构图,再反解各站世界坐标 |
29
- | 聚焦衰减 | opacity 0.22 底 + blur 7px 峰 | 底值别低于 0.2——离焦卡要"在场",纯黑会丢空间感 |
30
- | perspective | 2600px | 与最大 |z|(850)比值约 3:1;更深的 z 需同步加大 persp 防畸变 |
31
-
32
- ## 已知坑
33
- - 逆变换的旋转顺序(Z→Y→X 反着正变换的 X→Y→Z)不能乱——乱序在单轴旋转时看不出来,多轴复合站会歪
34
- - 卡片 pose 写在卡自身 transform 和相机公式两处消费,加站只改 POSES 表,两处 transform 字符串别动
35
- - rz90° 站的卡内文字会跟着躺倒,相机转正后才可读——这是设计(转正瞬间"啊看懂了"),但该站文案要短
36
- - 落版挂在世界里时,最后一段飞行中它是斜的:显影要晚(飞行过半再淡入),逐字揭示等落位前 6f 再开始
37
- - OVERVIEW 后无返程,作段落收尾用;要循环回 STEP01 就在末尾加一段 fly back(cam 再 lerp 回 POSES[0])
38
-
39
- ## 参考实现
40
- demos/camera/basic-3d-scene/
41
- (Basic3DScene.tsx)
1
+ ---
2
+ name: basic-3d-scene
3
+ 一句话: impress.js 式空间演示:卡片以不同位置/旋转/缩放散布 3D 空间,相机取各步姿态之逆依次飞行对齐,末步拉到 OVERVIEW 总览
4
+ 适用: 概念/路线图/三步法的空间化讲述;替代平面 slides 的"每一步都换个空间视角"
5
+ 时长: 约 7.5s(225f@30fps;四站,三段飞行 28/32/32f,每站停留 ≥30f)
6
+ 能量: 中(每次转场有空间惊喜,停留段安静读卡)
7
+ ---
8
+
9
+ ## 意图
10
+ 把"翻页"变成"在想法的空间里旅行":每张卡不仅有位置还有姿态(第二站世界左转 38°、第三站整个画框侧躺 90°),相机对齐它时观众的世界也跟着转——空间变化本身成为"进入新章节"的仪式感。
11
+
12
+ ## 动效核心
13
+ - 核心配方一行:**camera = stepTransform.inverse()**。每站只写卡片自己的 pose(x/y/z/rx/ry/rz/s),相机变换按 `scale(1/s) rotateZ(-rz) rotateY(-ry) rotateX(-rx) translate3d(-x,-y,-z)` 取逆,顺序严格相反
14
+ - demo 用 graphite 暗场(近单色 + 香槟金点缀),video-shotcraft 的三章节卡 Frame / Craft / Ship(品牌短句拆成三章,卡头右侧挂标志 + 字标):卡片 1240×700 **原生 1:1 排版**(对位时就是屏幕像素,不经设计坐标放大,字不糊),156px 标题 + 44px 说明 + 被卡边裁切的 560px 细体章节数字
15
+ - 四站姿态各有戏剧点:STEP01 原点正视 → STEP02 (1690,−260,−650) + ry−38° → STEP03 (2590,830,−850) + rz90°(画框侧躺,相机跟着转正它)→ OVERVIEW s=2.7(相机 1/2.7 拉远),总览站位置按"三卡落在右上、左下留给落版"反解
16
+ - 飞行链式插值:三段飞行 36–64 / 96–128 / 158–190(帧),不对称 in-out bezier(0.62,0,0.16,1);站间飞行途中相机额外拉远 30%(hop,sin 包络)让观众看见空间里的其他卡;飞行段做时间采样运动模糊(快门 0.5f,子帧 1–8 按相机位移自适应)
17
+ - 停留段不死:落位后相机极缓推近 1.5%(下一段起飞时同曲线还原),卡底金色进度线走满当前段;标题在落位前 8f 逐字从线下升起,每张卡只揭示一次
18
+ - 空间参照:70 颗真 3D 浮尘挂在世界坐标里(各有 z),视差全部来自相机;enter/exit 聚焦按"站距"`d = |af − i|` 给 `opacity 0.22–1 + blur 0–7px`,总览段全员回到 0.85
19
+ - OVERVIEW 落版挂在总览站姿态上(放大 2.7 倍排版,相机 1/2.7 看回来 = 屏幕 1:1):眉题是 video-shotcraft 标志 + 字标,"Craft the shot." 150px 衬线逐词升起,尾段 hold 推近 1.5%
20
+
21
+ ## 参数表
22
+ | 参数 | 典型值 | 调节手感 |
23
+ |------|--------|----------|
24
+ | 站点姿态 | 每站至少一个新变换维度 | 只挪 x/y 是平移幻灯片;rz 站(画框旋转)是记忆点,一支片用一次 |
25
+ | 飞行时长 | 28–32f | 有旋转的段别短于 28f,观众需要时间理解"世界在转" |
26
+ | 停留时长 | ≥30f | 读卡位;卡内文字多时优先加停留而不是减飞行 |
27
+ | hop 拉远 | 30% | 0 = 贴着卡面平移,看不到空间;>50% 每段都像总览 |
28
+ | OVERVIEW 缩放 | s=2.7 | 值越大总览越"高空";先定总览海报构图,再反解各站世界坐标 |
29
+ | 聚焦衰减 | opacity 0.22 底 + blur 7px 峰 | 底值别低于 0.2——离焦卡要"在场",纯黑会丢空间感 |
30
+ | perspective | 2600px | 与最大 |z|(850)比值约 3:1;更深的 z 需同步加大 persp 防畸变 |
31
+
32
+ ## 已知坑
33
+ - 逆变换的旋转顺序(Z→Y→X 反着正变换的 X→Y→Z)不能乱——乱序在单轴旋转时看不出来,多轴复合站会歪
34
+ - 卡片 pose 写在卡自身 transform 和相机公式两处消费,加站只改 POSES 表,两处 transform 字符串别动
35
+ - rz90° 站的卡内文字会跟着躺倒,相机转正后才可读——这是设计(转正瞬间"啊看懂了"),但该站文案要短
36
+ - 落版挂在世界里时,最后一段飞行中它是斜的:显影要晚(飞行过半再淡入),逐字揭示等落位前 6f 再开始
37
+ - OVERVIEW 后无返程,作段落收尾用;要循环回 STEP01 就在末尾加一段 fly back(cam 再 lerp 回 POSES[0])
38
+
39
+ ## 参考实现
40
+ demos/camera/basic-3d-scene/
41
+ (Basic3DScene.tsx)