Code To Video Previz 标志

Code To Video Previz

组织
vargHQ
code-to-video-previz

与智能体一起用代码制作视频原型。判断镜头是否需要 3D 原型,并选择合适的工具(Three.js、Blender、手机实拍演示、分镜、Remotion、Cinema 4D、Unreal);以真实米制单位布置几何体、人物、摄像机和灯光;逐镜头复刻参考视频,并求解 3D 摄像机参数;根据绘画或静帧布置镜头;没有参考时则创作新镜头;用数字和画面检查结果;并编写交接给 Seedance 或其他视频模型的说明。同一场景文件可在 Three.js 和无头 Blender 中渲染。适用于“预演”“粗略布局”“3D 动态分镜”“three.js 还是 blender”“为这个视频制作原型”“复刻这个镜头”“用 3D 重现这个视频”“布置这幅画”“用 Claude 或 Codex 设计镜头调度”“代码转视频”“为不同版本排序”“LLM 评审”等需求,或生成的镜头总是偏离预期时。不适用于带有审核 UI 的完整多镜头 three.js 电影(threejs-animatic、varg-previz)、不做原型而直接为镜头编写提示词(varg-video-prompting)或完整动画制作流程(video-animate)。

概览

发布者vargHQ
代码仓库skills
技能名称code-to-video-previz
星标数
30
复刻数
4
附带文件
25
许可协议MIT
链接
  • Markdown 格式的指令

    模型按需加载 SKILL.md 文件,因此只有在请求确实与该技能匹配时才会消耗 Token。

  • 兼容任何大语言模型

    AI 技能采用纯 Markdown,而非特定提供商的代码,因此可搭配 GPT、Claude、Gemini、Grok 或本地模型使用。

  • 25 个附带文件

    模型执行任务时可读取的脚本、模板和参考资料。这些文件为只读文件,绝不会被执行。

  • 开源

    由 vargHQ 发布于 GitHub。请在安装前查看技能的源文件。

安装

在 TypingMind 中安装 Code To Video Previz AI 技能,即可搭配任意大语言模型使用;也可以将其放入其他支持读取 SKILL.md 的智能体中。

1

安装到 TypingMind

TypingMind 可直接从 GitHub 文件夹安装技能:读取 SKILL.md,打包资源文件,并将结果保存在本地。

  1. 打开应用,前往“插件 → 技能”。
  2. 选择“从 GitHub 安装”。
  3. 粘贴下方的技能文件夹 URL 并确认。
    https://github.com/vargHQ/skills/tree/main/code-to-video-previz
  4. 请在每个需要使用该技能的聊天中启用它。
依次选择“插件 → 技能 → 添加技能 → 从 GitHub URL 导入”,然后粘贴文件夹 URL 并点击“继续”。
2

安装到其他智能体

任何支持 Agent Skills 格式的智能体都可以使用此技能,只需将文件夹复制到该智能体的技能目录中。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/vargHQ/skills.git /tmp/skills
mkdir -p .claude/skills
cp -r /tmp/skills/code-to-video-previz .claude/skills/code-to-video-previz
复制后,请重启 Claude Code,以加载新技能。

在 TypingMind 中使用此技能

在任意 TypingMind 聊天中启用 Code To Video Previz,后续即可交由模型处理。技能的名称和描述会放在系统提示词中,一旦请求匹配,模型就会自动加载完整指令,无需您手动调用,且在实际使用前不会消耗 Token。

一旦请求与技能匹配,模型就会自动加载 Code To Video Previz。

兼容任何 AI 模型

AI 技能是纯 Markdown 指令,而非特定提供商的代码,因此 Code To Video Previz 不局限于最初适配的模型。只需在 TypingMind 中安装一次,即可搭配 GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama 或您自行运行的本地模型使用,全程使用您自己的 API 密钥。

  • 仅在需要时加载

    系统提示词中仅包含技能名称和描述。首次遇到匹配的请求时才会加载完整指令,因此技能未使用时,这些指令不会消耗 Token。

  • 在聊天中切换模型

    技能是指令而非代码,因此切换模型不会导致技能失效,新模型会读取同一个 SKILL.md。

技能指令

这是模型会加载的 SKILL.md 内容。请在安装前阅读,因为技能就是模型将遵循的指令。

Code to video: a prototype in 3D, then a real video

Step 6 of 10 in How to make a video with an AI agent in ten steps. The full guide, with every test and source: https://varg.ai/how-to/previz-a-video-in-threejs-or-blender (as Markdown: add .md).

Video models redraw the world on every call, so cameras wander, counts change and rooms rearrange. A prototype fixes those things for free, before the paid step. The agent can build it, because camera and layout are maths. Three limits decide everything below, so tell the person about them:

  • Agents can't watch video. They check frames and numbers. Pacing and feel stay a human call.
  • Agents block well and model badly. Cameras, layout and scale come out right. Curves, faces and hero objects don't.
  • The video model copies what you show, bad motion included. A crude clip is an advantage, not a compromise.

1 · Does this shot need a prototype?

Find the one hard thing in the shot, then use the cheapest prototype that pins it down. People who tested previz and say to use it selectively give the same order: words, then images, then references, then previz, each only when the last one fails.

the hard thingusewhy
nothing exact: one or two subjects, randomness welcomeno prototype: prompt + start framea previz adds cost and can make motion worse
the idea and look of a sequencestoryboard stillsfast to redo, and stills are the cheapest place to find problems
timing, tempo, positions, crowd paths, side-on shots2.5D conte in Remotion or HyperFramesminutes to make. Not for orbits, occlusion, height or hands
an exact camera path, exact counts, spatial continuity, long takes3D prototype: section 2this is what 3D is for
a human performance and a real camera could shoot itphone act-outcarries weight and timing better than any stand-in
a performance and an impossible cameraact-out → mocap → 3DMotion2MixamoRig, Move.ai or DeepMotion, then Blender

No same-shot test of act-out against 3D has been published, so say that if asked. Faces are unsolved on every route.

2 · Pick the 3D tool

pickwhenthe catch
Three.js (default)rough placement and the model fills in the rest; live and editable; no install, weak laptop, a phone; many shots in one diffable file; a code-rendered finalno rigs; agent-written human animation looks stiff
Blenderyou must lock acting, camera and timing yourself; rigs, Mixamo or mocap, real assets; heavy sets; stills for storyboards; an artist will open the filemore tokens (one report, on a finished render: $20.39 vs $0.97 for the same prompt and model); needs a local install or bpy
Cinema 4D (Maxon's MCP)you already own and know it, and a hero object needs a real rig and motion blurpaid; the GUI stays open; no headless path
Unreal + MetaHumanfast human bodies, big casts, and you work on a Windows GPUagent + Unreal + Seedance has not been shown joined end to end
Gaussian splat world (Marble)the place itself is the hard part and nothing touches the setone full report only, from a World Labs employee

Nobody was found using Unity, Godot, Houdini (except simulation), Rhino or SketchUp for this. Skip them unless you already live there. HyperFrames, After Effects and DaVinci belong after generation, for type and finish.

You don't have to commit. Write the scene as data (staging.json) and both Three.js and Blender render it, with the same lens maths. Start in Three.js. Move to Blender (--blend scene.blend) when you need a rig or an asset. For Blender setup, MCP vs headless and what to do by hand: references/blender.md.

3 · Name the object you're making

objectforlooks like
guide clipa video model, as @video1crude and flat-lit, no text, no shadows, stand-ins. Exact seconds
storyboard pagespeople, or a model as key framesstills from the shot cameras, 2 to 4 per shot, captions
code-rendered filmthe audiencetextures, light, a pure function of time. No video model

No video model named? A plain "render it as a clip" means a code-rendered film, so keep the light. One file can't be all three. An animatic with outlines, text and hard shadows has to be rebuilt before it can be a guide clip, because "the reference video is a pixel channel, not a spec channel": whatever is visible can come back in the film.

4 · The loop

  1. Write the brief down in the person's words, dated, with format, length, and what the shot must achieve.
  2. Write beats in seconds and metres. Who, where, doing what, which way they face, the end state of each beat, one camera move per beat. "The parts you can't write are the parts that are vague in your own head."
  3. Write staging.json, not a new engine. → references/staging-format.md
  4. Run the numbers: python3 scripts/check_staging.py staging.json. Fix every ERROR.
  5. Render stills, first, middle and last frame of each shot, and look at every one. Fix one thing at a time.
  6. Have a fresh agent review it. A builder rates its own work too high. Give the reviewer only the frames, the reference and the beats, and ask for the biggest gap, not a score. Check its claims against an overlay before acting: reviewers are wrong too. To rank several takes: references/judging.md. Never a 1 to 10 score, and never "which is better?" with no criteria.
  7. The person approves the stills, then the clip. Stop here for notes: they cost nothing now. If nobody can reply, make the call and say so in your report.
  8. Render the clip frame by frame, never by screen recording.
  9. Hand it off (section 7), one short test first, with a price and a yes from whoever pays.

Stop rule: 3 rounds without progress on one problem, then change the approach. A round should move a named number or fix a named gap. Matching a painting's colour takes more: sample the colours instead of guessing. Add nothing the beats don't ask for.

5 · Staging rules

Geometry. Build as little as explains the action. Same prompt, two previzes: "barebones won. The more detail you put into the previs, the more literally Seedance follows it." Simplify by event, though: keep the heading, openings, joints that bear on the action, contact surfaces and a signature silhouette. Use real metres and put a 1.75 m person beside anything without a familiar scale. Round head on a capsule is enough for people unless the pose is the point. Ambiguity ruins a pass, crudeness doesn't. A bent lamppost comes back as a snake, and loose blocks near a figure come back as extra people. Mark a vehicle's front. Don't model hero props: get them from Tripo, Meshy or a sketch, or say them in the prompt.

Stand-ins: unsettled. Capsules let the model invent the gait, jointed mannequins hand it a gait to copy, and half-animated limbs are the bad middle ("toy soldiers"). Several creators report stiff results from posed figures. Start with capsules. Use joints only when a specific pose must survive. Run a 4 to 6 s test on your model before a long pass.

Blocking. Block the action once in world time and make every shot a camera on it, so continuity comes free. Replace hard animation with a before pose, an after pose and a cut: "let the cut sell the speed". Keep poses clean: models copy tangled arms literally. For speed, remember that a slow proxy gives sluggish output and a slow move is ambiguous, so write its state in words.

Camera. Only what a real camera could do: "We try not to do anything a real camera couldn't physically do" (Patrick Lin, Pixar). The "magic camera" is the known previs failure, and an 18 mm close-up of a face is what drives Roger Deakins "insane". One move per shot, each with a job: "every shot was a zoom" is the common complaint. Vary the coverage and check it: the audit warns when all moves match.

wantlens
wide interiors, orbits24 to 30 mm
neutral, walking35 mm
over the shoulder32 to 45 mm (Deakins: 32 or 35)
closer shot, medium40 to 50 mm (Deakins: "But I have no rule")
close-up, compression65 to 85 mm

Choose the lens from what the scene is about, not from what fits the frame. With a wide lens, boom instead of tilting, so verticals stay straight.

Write orbits as arcs ("path": "arc"), because a straight line between two orbit keys goes through the subject. Keep the 180° line in dialogue. Frame one size tighter than you want: generated framing comes back looser. Stiff camera? Don't animate jitter in; write "handheld" in the prompt, or add noise in Blender.

Light. A guide clip says nothing about light. Keep it flat and put light in the image references and prompt, and tell the model to reject viewport lighting. The exception is a shot whose composition is the light, such as a painted reference: then block one hard source and its shadow edge, and use it for stills and look approval, not for the clip. Work in order: shadow, then separation, then fill (Stephen Burum, ASC). One clear direction, or you get "a mushy light sandwich". Night is more black in the frame, not lower exposure. Write light as numbers: direction, height, ratio (2:1, 4:1, 8:1), Kelvin (candle 1,850, tungsten 3,200, daylight 5,600). Words such as "Rembrandt" and "chiaroscuro" did not read reliably in the one test found, while backlight, silhouette and rim did.

Order. "Block it out first without animation", in static compositions with posed figures, then timing, which "needs to be dead on or pretty close" (fxguide's notes on the previs guide by Chris Edwards of The Third Floor). Pixar's order is "camera, action, lights". Leave lights last.

Determinism. What's on screen is a pure function of t. No clocks, no unseeded random, no state between frames.

Leave out text, subtitles, labels, UI, TV static and glitter: Seedance read a subtitle in a previz and spoke it.

6 · References

you havedodetails
a reference videodecide what you take. Same camera with a new look: feed the clip directly. Change the camera, the count or the set: split it, measure the camera, stage from picture coordinates, compare by overlay and by numbersreferences/reference-video.md
a painting or a stillread it for light and structure. Use a grid, get lens and eye height from a known size, place everything from picture coordinates, compare by overlayreferences/paintings.md
nothinggenerate a reference image first, because with none the output is generic. Or ask for 3 named camera options as moving stand-ins and pick onereferences/no-reference.md

References fix the look, not the structure. Giving an agent a nice picture won't produce the right meshes, so structure comes from the beats and the numbers.

7 · Turn it into a real video

Three routes, from people who have run them:

  • Guide clip to @video1. Most common. Keeps camera, positions and cut timing. Also keeps stiffness.
  • Storyboard pages as image references. PJ Ace's team swapped to this on one film because Blender motion felt stiff and reference images cost less, then said it was a per-shot choice. Fuller control over look, looser over motion.
  • Code-rendered final. No video model. Suits machines, products, diagrams and flat characters, not people.

Division of labour, reached separately by users writing in three languages: video = camera, path, position, timing. Images = identity and look. Text = what boxes can't show.

What we measured on our own 10-shot run (Seedance 2.5, grey previz, one film, not a controlled test):

  • Cuts land on the planned frame, within one frame.
  • Framing mostly holds, one size looser.
  • When the words disagreed with the previz, the words won. In 2 of 2 shots where the prompt said "the android's face" or "close-up of the woman" over a previz from behind, the model turned the character to camera. So describe each shot as the previz shows it.
  • Camera moves are not guaranteed. Of 7 shots with enough tracking to measure, 4 kept the direction, often with close numbers (zoom 1.124 vs 1.125), 1 stopped moving and 2 reversed. The one shot whose prompt named its move kept it. So name the move in the words for every shot, and measure the result: uv run scripts/measure_shot.py.

Other limits people measured: 10 to 15 s clips hold and 20 to 30 s drift (28 renders, Scenario); 16 s with 7 shots hit 6 of 6 cuts within 0.07 s, and a 28 s piece lost 3 and added 4 (VLM harness). Keep runs short and in one location. Kling 4 tended to ignore the previz in the one test found. Contact, fast action and identity in fights stay weak everywhere.

Grey or colour: unsettled. Grey: a colour previz once came back as the output, unchanged, and several people report that grey adheres cleanly. Colour: Scenario reports an all-grey clip losing identity and a bare grey mannequin being refused by a provider, and users map saturated colours to @image refs with success. Nobody has published a controlled test. Default: greyscale with characters separated by brightness. Use identity colours with a written legend when characters must stay apart. Test both on one short window before a long pass, because results vary by model.

The prompt: references/handoff.md. Copy-paste prompts for every step: references/prompts.md. For the full animation pass after this (model per shot, takes, sync, plates), use video-animate.

8 · Say honestly

  • Report what you looked at and what you only measured. Passing a check doesn't mean it matches the reference, or that it's good.
  • Never call a film "pure code" if a video model drew any of it.
  • Generation costs money: quote with estimate_cost, get a yes, run one test first, report the billed cost.
  • Study by copying, publish by transforming. Take a shot's move, height and rhythm into your own scene, never a sequence's staging plus its look. Tell the person when a reference is someone else's work. Details: references/reference-video.md.
  • A person picks frames from ShotDeck and Shot Cafe: their terms ban automated tools.

Files

pathwhat
references/staging-format.mdthe scene file and every command
references/blender.mdsetup, MCP or headless, Workbench, what to do by hand
references/reference-video.mdCase A: copy a reference video
references/paintings.mdCase B: stage from a painting or still
references/no-reference.mdCase C: no reference at all
references/handoff.mdprompts and rules for Seedance and other models
references/prompts.mdpaste-ready prompts
references/judging.mdrank takes with an LLM judge: what we measured, the biases, gate and pair prompts, what a judge can't see
references/sources.mdwho said what, with links
scripts/check_staging.pynumber audit, standard library only
scripts/stage_three.ts, stage_three.html, cdp.tsthree.js renderer (Bun, Chrome, ffmpeg)
scripts/stage_blender.pyBlender renderer (bpy)
scripts/shots.py, grid.py, compare.pysplit a video, read a picture, compare a render (ffmpeg)
scripts/measure_shot.pyread a shot's move as a picture: pan, tilt, zoom, roll (uv, OpenCV)
scripts/solve_camera.py, solved_to_staging.pyrecover a shot's real 3D camera with Blender's tracker, then turn it into a camera path
scripts/place.pypicture coordinates to world coordinates
scripts/judge_pack.pya blind judging round: random names, both orders, a copy that must tie, scoring
example/calling/Caravaggio's The Calling of Saint Matthew, staged from the picture
example/ab-test/one 5 s shot as 4 variants (grey or colour, capsule or joints), to settle the open questions on your model

Related skills

threejs-animatic and varg-previz (a full three.js film with a review UI and pack builder), video-animate (animate from an approved previz, model per shot), varg-video-prompting (prompting a shot), video-moodboard and find-references (look and references), varg-consistent-characters (identity), varg-ai (generation), hyperframes (type and finish on top of the video).

附带文件

技能加载后,模型会按需读取这些文件。它们仅作为可读文件提供,绝不会被执行。

常见问题

Code To Video Previz AI 技能有什么作用?

与智能体一起用代码制作视频原型。判断镜头是否需要 3D 原型,并选择合适的工具(Three.js、Blender、手机实拍演示、分镜、Remotion、Cinema 4D、Unreal);以真实米制单位布置几何体、人物、摄像机和灯光;逐镜头复刻参考视频,并求解 3D 摄像机参数;根据绘画或静帧布置镜头;没有参考时则创作新镜头;用数字和画面检查结果;并编写交接给 Seedance 或其他视频模型的说明。同一场景文件可在 Three.js 和无头 Blender 中渲染。适用于“预演”“粗略布局”“3D 动态分镜”“three.js 还是 blender”“为这个视频制作原型”“复刻这个镜头”“用 3D 重现这个视频”“布置这幅画”“用 Claude 或 Codex 设计镜头调度”“代码转视频”“为不同版本排序”“LLM 评审”等需求,或生成的镜头总是偏离预期时。不适用于带有审核 UI 的完整多镜头 three.js 电影(threejs-animatic、varg-previz)、不做原型而直接为镜头编写提示词(varg-video-prompting)或完整动画制作流程(video-animate)。

为什么在 TypingMind 中使用 Code To Video Previz?

因为您只需安装一次,就能搭配任何模型使用。Code To Video Previz 采用纯 Markdown 格式,而非特定提供商专用的代码,因此同一技能可用于 GPT-5、Claude、Gemini、Grok 或本地模型。您甚至可以在聊天中途切换模型,而不会影响技能的正常使用。TypingMind 使用您自己的 API 密钥,因此您直接向提供商付费,而不是按席位订阅;您的技能和聊天记录也都保留在您自己的存储空间中。

如何在 TypingMind 中安装 Code To Video Previz?

在 TypingMind 中打开“插件 → 技能 → 从 GitHub 安装”,然后粘贴 https://github.com/vargHQ/skills/tree/main/code-to-video-previz。TypingMind 会读取其中的 SKILL.md,打包相关文件,并将其安装为技能,供您在各个聊天中按需启用。

哪些 AI 模型可以使用 Code To Video Previz?

您在 TypingMind 中连接的任何模型都可以。AI 技能采用纯 Markdown 指令,而非特定提供商专用的代码,因此 GPT、Claude、Gemini、Grok 和本地模型都能在请求匹配时加载此技能。

Code To Video Previz 可以搭配多少个 AI 模型使用?

数量不限。只要模型支持技能,您就可以将它与 Code To Video Previz 搭配使用。GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llama 等模型都可以通过您自己的 API 密钥接入 TypingMind。

Code To Video Previz AI 技能免费吗?

是的。vargHQ 已在 GitHub 上根据 MIT 许可证发布了该技能。您只需向自己的 AI 提供商支付所用 Token 的费用。

什么是 AI 技能?

AI 技能是一组可复用的指令,用于教会 AI 模型完成某项特定任务。它遵循开放的 Agent Skills 格式:包含名称和描述的 SKILL.md 文件,以及模型可能需要的脚本、模板或参考文件。模型仅在您的请求与技能匹配时才会读取这些指令,因此已安装的技能在使用前不会产生任何费用。

AI 技能与插件或 MCP 服务器有何不同?

插件或 MCP 服务器为模型提供可调用的新工具,也就是在某处运行并返回结果的代码。AI 技能则为模型提供知识和流程:如何处理任务、遵循哪些步骤,以及怎样的输出才算优质。技能采用纯 Markdown 格式,因此不需要服务器、API 密钥或运行时环境,并且适用于任何模型。

查看全部

立即创建您自己的 AI 工作区

订阅我们的电子简报,获取新功能和后续赠奖活动的通知 👇