A skill that turn any brand into a scrollable 3D world landing page
JavaScript
v0.7.0: Monid is the default chain backend
cyw10062c101934
diff --git a/.claude-plugin/plugin.json b/.claude-plugin/plugin.jsonindex 00c1f12..a59d529 100644--- a/.claude-plugin/plugin.json+++ b/.claude-plugin/plugin.json@@ -1,7 +1,7 @@{"name": "scroll-world","description": "Build an immersive scroll-scrubbed 'fly through the world' landing page for any industry or brand using Higgsfield. As the visitor scrolls, a pre-rendered camera flies from outside each scene into its interior, then flows on to the next scene with no cuts — one continuous connected flight. Interviews the user for the topic, story beats, and brand kit, then generates cohesive scenes + seamless camera clips and wires a portable, framework-agnostic scroll-scrub engine. Use for a '3D world' / 'browse-through-the-industry' hero, a scroll cinematic, or a diorama landing.",- "version": "0.6.0",+ "version": "0.7.0","author": {"name": "cyw","email": "[email protected]"diff --git a/README.md b/README.mdindex c9cc73f..eeab483 100644--- a/README.md+++ b/README.md@@ -46,28 +46,31 @@ cp -R scroll-world/skills/scroll-world ~/.codex/skills/ # Codex## Requirements+- The [Monid CLI](https://monid.ai) with an API key and balance — the **default+ video-chain backend** (Seedance 2.0, billed per clip in USD; see below).- The [Higgsfield CLI](https://higgsfield.ai), authenticated (`higgsfield auth login`),- with credits.+ with credits — renders the scene stills, the `kling3_0` fallback, and the whole+ chain when Monid is absent.- `ffmpeg` / `ffprobe` for frame extraction and encoding.- Python 3 with Pillow (for the mobile portrait canvases; also the optionaltransparent-scene knockout).- The [Codex CLI](https://github.com/openai/codex) (optional) — if present, the scenestills can be generated through Codex's built-in `image_gen` (the same GPT Imagemodel), billed to a ChatGPT subscription instead of Higgsfield credits.-- The [Monid CLI](https://monid.ai) (optional) — a qualified pay-per-clip video- backend: the same Seedance 2.0 chain billed per clip in USD instead of- Higgsfield credits (verified 2026-07-25: first/last-frame conditioning- frame-locks; frames travel via Monid's free workspace file system). Useful as a- no-subscription alternative or a mid-build top-up when credits run dry. The- skill re-checks the endpoint schema each build and keeps qualification probes- in the pipeline for when the catalog changes.+- About the Monid default: verified 2026-07-25 — first/last-frame conditioning+ frame-locks, so it renders the full seamless chain; frames travel via Monid's+ free workspace file system. Pay-per-use with no subscription or monthly expiry+ (a 6-scene 1080p chain ≈ $27). The skill re-checks the endpoint schema each+ build and keeps qualification probes in the pipeline for when the catalog+ changes; Higgsfield credits remain the fallback biller.## What it does-It leans on [Higgsfield](https://higgsfield.ai) for the art: cohesive isometric diorama-scenes (GPT Image 2 — via Higgsfield, or the Codex CLI on a ChatGPT subscription) and the-camera flights themselves (Seedance or Kling image-to-video — only models that can-frame-lock a seam), scrubbed+It generates the art with AI: cohesive isometric diorama scenes (GPT Image 2 — via+Higgsfield, or the Codex CLI on a ChatGPT subscription) and the camera flights+themselves (Seedance image-to-video via **Monid by default**, pay-per-clip; Seedance+or Kling on Higgsfield credits as fallback — only models that can frame-lock a+seam), scrubbedby scroll position — the same technique behind Apple's scroll-through product pages. Thecamera genuinely moves; scroll only drives time. It's **framework-agnostic**: you get theHiggsfield pipeline, the prompt templates, and a portable vanilla-JS scrub engine that@@ -104,11 +107,12 @@ skills/scroll-world/## Notes-- Asset generation costs Higgsfield credits (~N image gens + ~2N-1 video gens for N- scenes; the mobile chain doubles the video gens) and takes a while — the skill runs- generations in the background and polls. Per-generation pricing isn't exposed by the- CLI, so the skill calibrates against your live balance and states the estimated total- before spending.+- Asset generation costs money (~N image gens on Higgsfield credits + ~2N-1 video+ gens billed per clip on Monid by default; the mobile chain doubles the video gens)+ and takes a while — the skill runs generations in the background and polls. Monid+ pricing is per-token and printed per run; Higgsfield pricing isn't exposed by its+ CLI, so the skill calibrates against your live balance. Either way the estimated+ total is stated before spending.- The generated `.mp4`/`.webp` assets are produced per project; they're not shipped here.## Star Historydiff --git a/skills/scroll-world/SKILL.md b/skills/scroll-world/SKILL.mdindex 73cec7a..d016f0b 100644--- a/skills/scroll-world/SKILL.md+++ b/skills/scroll-world/SKILL.md@@ -8,8 +8,9 @@ description: >or any art direction you pick). The skill interviews the user for the topic, thestory beats/sections, and brand kit, then generates cohesive scenes + seamless cameraclips with Higgsfield and wires a portable, framework-agnostic scroll-scrub engine.- Supports the Monid CLI as a qualified pay-per-clip video backend (Seedance 2.0- in USD — capability re-checked each build, see Step 4). Use when the user wants a "3D world" /+ The video chain renders through Monid by default (Seedance 2.0, pay-per-clip+ USD — capability re-checked each build, see Step 4) with Higgsfield credits as+ the fallback biller. Use when the user wants a "3D world" /"browse-through-the-industry" hero, a scroll cinematic, a diorama landing, or toturn a business into a scrollable world.allowed-tools: Bash, Read, Write, Edit, AskUserQuestion, Skill@@ -19,8 +20,9 @@ allowed-tools: Bash, Read, Write, Edit, AskUserQuestion, SkillProduces a landing page where **scroll drives a camera**: it dives from outside a sceneinto its interior, then flies out and into the next scene, continuously, with no visible-cuts. The visuals are AI-generated (Higgsfield); the page just scrubs pre-rendered video-by scroll position. This is the same technique behind Apple's scroll-through product+cuts. The visuals are AI-generated — stills via Higgsfield (or Codex), the video chain+via **Monid by default** (pay-per-clip Seedance 2.0; Higgsfield credits as fallback) —+and the page just scrubs pre-rendered video by scroll position. This is the same technique behind Apple's scroll-through productpages — the camera genuinely moves, scroll only drives time.**What you generate:** N scene stills → N "dive-in" camera clips → N-1 "connector" clips@@ -42,25 +44,27 @@ not the framework.## Step 0 — Bootstrap-1. **Higgsfield CLI.** If `higgsfield` is not on `$PATH`, install per the+1. **Monid CLI — the default video-chain backend.** Check `monid --version`,+ `monid keys list` (active key) and `monid balance` — the chain is billed per+ clip in USD (Step 1.6 has the numbers; a 1080p N=6 chain ≈ $27). If the CLI is+ missing or the balance can't cover the chain, say so and fall back to+ rendering the chain on Higgsfield credits instead — same model, same+ pipeline, different biller (Step 4 → Monid backend).+2. **Higgsfield CLI — still required even on the Monid path**: it renders the+ scene stills (`gpt_image_2`) and is the home of the `kling3_0` NSFW fallback+ and the fallback chain. If `higgsfield` is not on `$PATH`, install per the`higgsfield-generate` skill. If `higgsfield workspace list` fails auth, ask the userto run `higgsfield auth login` (interactive OAuth — you cannot run it) and, if needed,- `higgsfield workspace set <id>`. Confirm there are enough credits: a full run is- roughly `N` image gens + `(2N-1)` video gens.-2. **ffmpeg / ffprobe** on `$PATH` (frame extraction + encoding).-3. **An image tool** for background knockout if you want floating scenes: PIL+ `higgsfield workspace set <id>`. Confirm credits cover the stills (~N image+ gens) — plus `(2N-1)` video gens if the chain falls back here.+3. **ffmpeg / ffprobe** on `$PATH` (frame extraction + encoding).+4. **An image tool** for background knockout if you want floating scenes: PIL(`python3 -c "import PIL"`), or `cwebp`/`sips`. Optional — see Step 3.-4. **(Optional) Codex CLI** — if `codex` is on `$PATH` (≥ 0.125) and+5. **(Optional) Codex CLI** — if `codex` is on `$PATH` (≥ 0.125) and`codex login status` reports a ChatGPT login, the scene stills can be generatedthrough Codex's built-in `image_gen` (the same gpt-image-2 model) billed to theuser's ChatGPT subscription instead of Higgsfield credits — offer it atStep 1.6, command in Step 2. Absence just removes the option.-5. **(Optional) Monid CLI** — if `monid` is on `$PATH` with an active key- (`monid keys list`), Monid's `bytedance /v1/video/seedance-2.0` is a qualified- pay-per-USD chain backend (both probes passed 2026-07-25 — Step 4 → Monid- backend): per-clip dollar billing instead of Higgsfield credits, `monid- balance` for the wallet. Frames travel via Monid's free workspace file system- (`sfs`), not inline base64. Absence just removes the option.6. Caveats: macOS ships **bash 3.2** (no `declare -A`); don't use associative arrays inscripts. Higgsfield generations take **3–8 min each** — always run them detached(background) and poll, never a foreground blocking call. Reference-by-job-UUID is@@ -139,22 +143,24 @@ default. Cover:Draft doubles as the previz path: run the whole chain cheap, approve thejourney, re-render final legs on Standard (pipeline.md Notes) — suggest itunprompted when the balance reads tight.- - **Monid (pay-per-clip USD)** — offer only if bootstrapped (Step 0.5). Same- Seedance 2.0 chain, billed per clip in dollars instead of credits (qualified- 2026-07-25; wiring in pipeline.md → Monid backend). Token-priced:- `width × height × 24 × seconds / 1024` tokens at $7/1M (480p/720p) or- $7.7/1M (1080p) — measured: 1080p 8s dive ≈ $2.99, 5s connector ≈ $1.87,- 720p ≈ $1.21 / $0.76, 480p previz ≈ $0.28 / $0.35. An N=6 desktop chain ≈- $27 at 1080p / ~$11 at 720p vs Higgsfield Plus-monthly ≈ $32 / $16 — ~15%- cheaper per clip, parity with Plus-annual, and the real differences are- structural: pay-per-use (no subscription, no monthly expiry) and a top-up- path when credits run dry mid-build. It's the same underlying model- (`seedance_2_0` ≙ Monid's `seedance-2.0`), so finishing a stranded chain on- Monid is a reasonable rescue — but the serving stacks differ and- cross-provider seam character is **untested**: eyeball the first rescued- seam before rendering the rest, same as any model swap. Check- `monid balance` before promising a build.- - **Stills source** (only offer if the Codex CLI is present, Step 0.4):+ - **Backend — Monid is the DEFAULT biller for the chain** (Step 0.1; wiring+ in pipeline.md → Monid backend). Same Seedance 2.0, per-clip USD instead of+ credits. Token-priced `width × height × 24 × seconds / 1024` at $7/1M+ (480p/720p) or $7.7/1M (1080p) — measured: 1080p 8s dive ≈ $2.99, 5s+ connector ≈ $1.87; 720p ≈ $1.21 / $0.76; 480p ≈ $0.28 / $0.35. An N=6+ desktop chain ≈ $27 at 1080p / ~$11 at 720p vs Higgsfield Plus-monthly ≈+ $32 / $16 — ~15% cheaper per clip, parity with Plus-annual; structurally+ better for one-off builds (pay-per-use, no monthly expiry). On Monid the+ Draft/previz tier is simply the **same endpoint at 480p** — no model swap,+ so previz→final stays one-model by construction. State `monid balance`+ against the estimate; **fall back to Higgsfield credits** (per-model tiers+ above) when the user prefers their subscription, the balance is short, or+ the model must be `kling3_0` (Higgsfield-only). It's the same underlying+ model (`seedance_2_0` ≙ Monid's `seedance-2.0`), so finishing a stranded+ chain on the other biller is a reasonable rescue — but the serving stacks+ differ and cross-provider seam character is **untested**: eyeball the first+ rescued seam before rendering the rest, same as any model swap.+ - **Stills source** (only offer if the Codex CLI is present, Step 0.5):Higgsfield `gpt_image_2` (spends credits) vs **Codex `image_gen`** — the samegpt-image-2 model billed to the ChatGPT subscription (zero credits; countstoward Codex usage limits; 1536×1024 output — exactly 3:2, slightly under@@ -280,18 +286,22 @@ Rules:but the render-character shift reads as a subtle pop. The one sanctioned exception isthe NSFW fallback for a single stubborn clip (Gotchas) — a slight character shift onone 5s connector beats a missing connector.-- Default to `seedance_2_0`; honor a user's stated preference **only if the model- qualifies** (frame-locking). If it doesn't, say so and use a supported model — never- ship a non-seamless build to satisfy a model request.+- Default to `seedance_2_0`, rendered through **Monid by default** (per-clip USD —+ next section) with Higgsfield credits as the fallback biller (Step 0.1/1.6); honor+ a user's stated preference **only if the model qualifies** (frame-locking). If it+ doesn't, say so and use a supported model — never ship a non-seamless build to+ satisfy a model request. `kling3_0` and `seedance_2_0_mini` exist only on the+ Higgsfield side.- The pipeline scripts take the model as `$VMODEL` with per-model flags already casedout (`references/pipeline.md`).-### Monid backend — QUALIFIED for the full chain (2026-07-25)+### Monid backend — the DEFAULT chain biller (qualified 2026-07-25)Monid's **`bytedance /v1/video/seedance-2.0`** passed both paid probes on-2026-07-25 and is a sanctioned chain backend for **both architectures** — it is-the roster's `seedance_2_0` served pay-per-USD (wiring in pipeline.md → "Monid-backend"):+2026-07-25 and is the **default** way this skill renders the chain, for **both+architectures** — it is the roster's `seedance_2_0` served pay-per-USD (wiring in+pipeline.md → "Monid backend"; Higgsfield renders the chain only as the fallback+biller or for Higgsfield-only models):- **Leg probe** (prompt + `first_frame` image): output frame 0 ≡ input still(PSNR 31.6 dB), forward-glide prompt obeyed, billed the advertised celldiff --git a/skills/scroll-world/references/pipeline.md b/skills/scroll-world/references/pipeline.mdindex b7b2dda..de87d77 100644--- a/skills/scroll-world/references/pipeline.md+++ b/skills/scroll-world/references/pipeline.md@@ -12,8 +12,9 @@ NAMES="farm kitchen shop delivery plaza finale" # <-- your section ids, in ord# Must accept --start-image AND --end-image (verify: higgsfield model get <model>):# seedance_2_0 | kling3_0 | seedance_2_0_mini (draft tier). Reference-only models can't# hold a seam; models without --mode (e.g. kling3_0_turbo) need their own flag branch below.-# Pay-per-clip billing instead of credits: same seedance chain via Monid — §7 functions-# (gen_dive_monid/gen_conn_monid with VRES=1080p|720p|480p instead of VOPTS).+# DEFAULT backend: Monid pay-per-clip (§7 — gen_dive_monid/gen_conn_monid with+# VRES=1080p|720p|480p instead of VOPTS). The gen_dive/gen_conn functions in §2/§4+# below are the Higgsfield-credits FALLBACK (and the only home of kling3_0/mini).VMODEL=seedance_2_0case "$VMODEL" in # per-model flags + durations (bash 3.2 safe)kling3_0) VOPTS="--mode std --sound off"; DIVE_DUR=10; CONN_DUR=5 ;; # no --resolution param on Kling@@ -196,11 +197,13 @@ Step 1.5 interview.`stillMobile` so the poster matches the portrait video's frame 0 (no landscape→portraitflash when the clip paints). Engine support: `sections[k].stillMobile`.-## 7. Monid backend — Seedance 2.0 pay-per-clip (qualified 2026-07-25)+## 7. Monid backend — Seedance 2.0 pay-per-clip (the DEFAULT; qualified 2026-07-25)`bytedance /v1/video/seedance-2.0` via Monid is the roster's `seedance_2_0` billed-per clip in USD (SKILL Step 4 → Monid backend; both probes passed). Same chain laws-as everywhere else — only the I/O differs: **frames ride Monid's free `sfs` file+per clip in USD, and the **default** chain backend (SKILL Step 4 → Monid backend;+both probes passed) — use these functions in the §2/§4 loops unless the build fell+back to Higgsfield credits. Same chain laws as everywhere else — only the I/O+differs: **frames ride Monid's free `sfs` filesystem** (inline base64 is rejected), **`ratio` must be explicit** (the adaptivedefault follows the input image's aspect), and runs are fire-and-poll. Token-priced`w×h×24×sec/1024` at $7/1M (480p/720p), $7.7/1M (1080p) — measured: 1080p ≈ $2.99@@ -267,8 +270,9 @@ gen_conn_monid() { # i startPng endPng}```-Drop-in for §2/§4: same loops, `gen_dive_monid`/`gen_conn_monid` instead of-`gen_dive`/`gen_conn` (mobile chain: `ratio:"9:16"` and the §6b portrait canvases).+Default usage in §2/§4: same loops, `gen_dive_monid`/`gen_conn_monid` in place of+the Higgsfield `gen_dive`/`gen_conn` (mobile chain: `ratio:"9:16"` and the §6b+portrait canvases). Previz: same functions with `VRES=480p`.Result URLs expire (~24–48 h) — the functions download immediately. Read the billed`cost.value` per clip (echoed in the ok-line) and `monid balance` between phases; a`BLOCKED` status is a workspace budget/run cap — terminal, surface it to the user.