agentleFS
hojiahaohojiahao/cineloom/.agents/skills/spark-local-media-generation/SKILL.md

spark-local-media-generation

Skill4 starsChanged 2 months agoMITView on GitHub

Generate a product hero still, storyboard frames anchored to it, and video clips on the local DGX Spark with the cineloom CLI (ComfyUI running Qwen-Image, Qwen-Image-Edit and Wan2.2 14B) instead of a cloud API. Use when product shots, storyboard frames or shot clips must be produced, when material is confidential or unreleased, or when choosing between local and cloud generation.

The file

We split this skill into the rules it gives an agent

5 rules. About 0 are common, 3 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈3

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Check memory with spark-model-scheduler before each phase.

    line 22
  2. Distinctive:

    If the user supplied real product photos, use those instead and skip this step.

    line 30
  3. Distinctive:

    Only gated frames move on.

    line 40
  4. Very specific:

    Every command prints measured seconds and records the asset with execution: local-dgx-spark.

    line 48
  5. Distinctive:

    Keep numbers and lens specs out of image prompts for the same reason.

    line 64

≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Spark local media generation

Hero still first, frames second, clips last. Each step is anchored to the one before it, so product identity is decided where a retry costs seconds, not minutes.

Workflow

  1. Check memory with spark-model-scheduler before each phase. Only one diffusion family should be resident at a time; run cineloom mem free when switching between them.
  2. Generate the product hero still from the storyboard's product description on a plain backdrop, and gate it:

    cineloom image --out projects/<id>/refs/product.png --size 1328x1328 --prompt "Studio product photograph of <product> ..."
    cineloom qa --frame projects/<id>/refs/product.png --expect "one container, upright, label reads \"<brand>\" clearly"

    If the user supplied real product photos, use those instead and skip this step.

  3. Generate every storyboard frame from the hero still. A reference switches the request to the edit model and keeps the product the same product:

    cineloom image --project <id> --shot 1 --size 1080x1920 \
      --prompt "<image_prompt>. Image 1 is the product: keep its shape, colours and label exactly as in image 1. No captions, no subtitles, no lettering except the product label. <style>" \
      --ref projects/<id>/refs/product.png

    Generate two candidates per shot and let shot-quality-gate pick: the spread between seeds is often larger than what a prompt edit buys.

  4. Only gated frames move on. Generate each clip from its approved frame:

    cineloom video --project <id> --shot 1 --model wan22-14b --duration 5 --ratio 9:16 --resolution 720p \
      --prompt "<video_prompt>" --first-frame projects/<id>/frames/shot_001.png --keep-loaded

    Drop --keep-loaded on the last clip so the video model is released.

  5. Every command prints measured seconds and records the asset with execution: local-dgx-spark. Keep these numbers for the delivery report.

What the models do, measured on this machine

StepModelCost
Frame, no reference, 1080x1920Qwen-Image + 8-step LoRA22.7 s warm, 45.8 s cold
Frame from the hero stillQwen-Image-Edit-2509 + 8-step LoRAabout 77 s
5 s clip, 720p, from a first frameWan2.2 I2V A14B fp8 + 4-step LoRAs (default)353 s
5 s clip, 720pWan2.2 TI2V-5B (also text-to-video)365 s

Sizes above the native budget (1328x1328 pixels in total) are generated natively and upscaled.

Prompting the local models

  • Never ask the image model for captions or slogans. Titles are typeset in post. Measured failures: a caption painted twice, the style token "50mm" painted as text, the rare character "泠" drawn as "冷". The only lettering in a frame is the product label, and it comes from the hero still.
  • Keep numbers and lens specs out of image prompts for the same reason.
  • With references, say what each one is: "Image 1 is the product". At most three; product first.
  • The 14B video model wants one camera move and one action, described plainly. For product-only shots end the prompt with "No people and no hands enter the frame" - otherwise it tends to add a hand reaching for the product. It produces no audio.

When something fails

  • ComfyUI rejected the workflow or a missing model file: run cineloom doctor. It compares every workflow template with the running ComfyUI and lists unknown nodes and missing weights.
  • Connection refused: ComfyUI is not up. See deploy/spark/.
  • Allocation failures in the GPU driver log, or heavy swapping: more than one diffusion family is resident. Run cineloom mem free, then follow spark-model-scheduler.

Model files and graphs behind each route: references/workflows.md.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.