[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M74FE3929KWXZG8RNFG1ZSXJ":3,"skill-same:01M74FE3929KWXZG8RNFG1ZSXJ":57},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":27,"repositoryHtmlUrl":28,"repositoryHomepageUrl":29,"ownerHtmlUrl":30,"ownerBlogUrl":31,"ownerDescription":6,"updatedAt":32,"install":33,"resources":46},"01M74FE3929KWXZG8RNFG1ZSXJ","spark-video-clip-review",null,"Per-clip quality reviewer + render retry state machine. After each rendered shot, score it on 6 axes via `bl omni` (qwen3.5-omni-plus), then decide ACCEPT \u002F REJECT-and-rewrite \u002F REJECT-and-escalate. Handles up to N retry rounds with auto prompt rewriting; escalates to spark-video-director when retries are exhausted.","modelstudioai\u002Fskills","modelstudioai","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F283556804?v=4","01M74FCG3YGPZ2M85A45A5X687","Model Studio ","01M74FCG52YG07R3Y4MSBNS9CG",59,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fmodelstudioai\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fspark-video\u002Freferences\u002Fspark-video-clip-review\u002FSKILL.md",[],[],"2026-11-11 15:11:14",false,"---\nname: spark-video-clip-review\ndescription: Per-clip quality reviewer + render retry state machine. After each rendered shot, score it on 6 axes via `bl omni` (qwen3.5-omni-plus), then decide ACCEPT \u002F REJECT-and-rewrite \u002F REJECT-and-escalate. Handles up to N retry rounds with auto prompt rewriting; escalates to spark-video-director when retries are exhausted.\n---\n\n# Clip Review + Re-Render Skill — spark-video On-Set QA\n\nYou are the **per-clip quality gate** of the pipeline. You run **after**\neach shot is rendered. You catch problems that only surface in the\nactual rendered MP4 — face drift, lip-sync mismatch, physics\nviolations, style drift, etc. — and drive the retry loop.\n\nSet env vars before any work:\n```bash\nexport SPARK_VIDEO_PROJECT=\u003Cproject_id>\nexport SPARK_VIDEO_EPISODE=\u003CNN>\nexport SPARK_VIDEO_SHOT=\u003CS01-001>      # the shot you're reviewing\nexport SPARK_VIDEO_PHASE=review\n```\n\n## Scoring is automatic — you drive the *judgment*, not the mechanics\n\n**`render_shot.py` now scores every clip itself.** As of the Zone-3\nhardening, a successful render is immediately reviewed in the same tool\ncall by `lib\u002Freview.py`: it builds the `bl omni` call, attaches the\ncast portraits for `shot.characters`, parses the 6-axis JSON, averages\nit, writes `reviews\u002F\u003Cshot>-ver\u003CN>.json`, embeds the review into\n`shots_state.json`, and — on ACCEPT (avg ≥ threshold) — promotes the\nversion to winner (`clips\u002F\u003Cshot>.mp4`). You do **not** hand-build the\n`bl omni` call anymore, and you do **not** copy the winner clip. That\ndeterministic spine cannot be skipped.\n\nWhat is left to *you* is exactly the judgment a script can't do:\n- read the REJECT `critique` and rewrite the prompt to fix the specific\n  failure mode (face drift \u002F dialog mismatch \u002F physics …);\n- decide, when retries are exhausted, between best-of-N and re-cutting\n  the shot group;\n- write the escalation report for the director.\n\n## The state machine (single source of truth)\n\nFor each shot the renderer hands you, run this loop:\n\n```\nver = 1\nwhile ver \u003C= max_retry:                # default max_retry = 3, env: SPARK_VIDEO_MAX_RETRY\n    out = render_shot.py --shot \u003Cid> ...          # renders AND scores AND\n                                                  # auto-promotes winner on ACCEPT\n    verdict = out.review.verdict                  # ACCEPT | REJECT | ERROR\n    if verdict == ACCEPT:\n        # render_shot already set winner_version + copied clips\u002F\u003Cid>.mp4. DONE.\n        break\n    elif verdict == ERROR:\n        # the judge was unreachable \u002F returned junk — NOT a content reject.\n        # inspect logs\u002Fmodel_calls.jsonl; re-run render_shot (--force) or, if\n        # the clip looks fine to you, accept it manually with --accept-version.\n        handle and break or retry\n    elif ver \u003C max_retry:                          # REJECT — YOUR judgment here\n        rewrite prompt from out.review.critique (bl text chat)   # SPARK_VIDEO_PHASE=rewrite\n        update scenes\u002Fscene-NN.json with the new prompt\n        ver += 1                                   # next render_shot --force renders ver+1\n    else:                                          # REJECT, retries exhausted\n        best = highest-scoring attempt in shots_state.json\n        render_shot.py --shot \u003Cid> --accept-version \u003Cbest>       # promote best-of-N\n        write reviews\u002Fescalation-\u003Cshot>.md + needs_director_rewrite.json\n        exit with escalation signal\n```\n\nThe producer reads the escalation file and invokes the\n`spark-video-director` skill with it as input.\n\n## How to render + review one attempt\n\n### 1. Render (scoring happens automatically)\n```bash\nexport SPARK_VIDEO_SHOT=S01-002\nexport SPARK_VIDEO_PHASE=render\nuv run scripts\u002Frender_shot.py \\\n  --shot $SPARK_VIDEO_SHOT \\\n  --kind r2v --duration 12 \\\n  --prompt \"\u003Cfrom storyboard.json>\" \\\n  --media projects\u002F$SPARK_VIDEO_PROJECT\u002Fcast\u002F陆辰\u002Fportrait1.png \\\n          projects\u002F$SPARK_VIDEO_PROJECT\u002Fmovie-set\u002F客栈大堂-夜晚\u002Fset1.png\n\n# stdout (JSON) now includes the review verdict:\n# {\"shot_id\":\"S01-002\",\"version\":1,\"video_path\":\"...\",\"duration_s\":12.0,\n#  \"provider\":\"bl\",\"model\":\"happyhorse-1.0-r2v\",\"elapsed_s\":47.2,\n#  \"review\":{\"score\":6.2,\"verdict\":\"REJECT\",\"breakdown\":{...},\"critique\":\"...\"},\n#  \"winner_version\":null,\n#  \"next\":\"rewrite prompt and re-render (--force), or accept best-of-N ...\"}\n```\n\nIn one call the script: writes `clips\u002FS01-002-ver1.mp4`, extracts the\nlast frame, scores the clip on the 6 axes (auto-resolving cast portraits\nfrom `cast.json`), writes `reviews\u002FS01-002-ver1.json`, embeds the review\ninto `shots_state.json`, and — if `verdict == ACCEPT` — promotes the\nversion to winner (`clips\u002FS01-002.mp4`). **You only read the verdict from\nstdout.** You never write `shots_state.json`, build the `bl omni` call,\nor copy the winner clip.\n\nOpt-outs: `--no-review` skips scoring for one render;\n`VIDEOGEN_REVIEW_MODEL=\"\"` disables it globally (falls back to the old\nmanual `--accept-version` flow). `--characters A B` overrides which cast\nportraits feed the `cast_match` axis (default: storyboard's\n`shot.characters`).\n\n### 2. The review record (written for you)\n\n`reviews\u002F\u003Cshot>-ver\u003CN>.json` and `shots_state.json`'s\n`attempts[].review` carry the same object — this is what `viewer.html`\n(and a future progress console) renders:\n\n```json\n{\n  \"shot_id\": \"S01-002\",\n  \"version\": 1,\n  \"score\": 6.2,\n  \"breakdown\": {\n    \"logic\": 7, \"proportion\": 6, \"physics\": 7,\n    \"style\": 8, \"cast_match\": 5, \"dialog_attribution\": 4\n  },\n  \"critique\": \"0:00–0:03 钱夫人脸型偏离参考图(下巴宽 + 发际线高); 0:04 那句\\\"你这小蹄子\\\"应是钱夫人说的, 但视频里嘴动的是郭芙蓉, 属于台词错位 ...\",\n  \"verdict\": \"REJECT\",\n  \"ts\": \"\u003CISO8601>\"\n}\n```\n\n`verdict = \"ACCEPT\"` iff `score >= threshold` (default 7.0, env:\n`SPARK_VIDEO_REVIEW_THRESHOLD` \u002F `VIDEOGEN_REVIEW_THRESHOLD`). The\nthreshold is authoritative — the script ignores a lenient model verdict\nthat disagrees with the arithmetic. A `verdict == \"ERROR\"` means the\njudge couldn't run (timeout \u002F unparseable output); inspect\n`logs\u002Fmodel_calls.jsonl` rather than treating it as a content reject.\n\n### 3. On REJECT — rewrite the prompt (this is YOUR job)\n\n```bash\nexport SPARK_VIDEO_PHASE=rewrite\n.\u002Fscripts\u002Fbl text chat \\\n  --model qwen-plus \\\n  --system \"$(cat references\u002Fspark-video-clip-review\u002Frewrite-system.md)\" \\\n  --message \"Original prompt: \u003Cprompt>\\nScore: 6.2\\nIssues: \u003Ccritique>\\nRewrite the prompt to fix the issues while keeping narrative intent unchanged. Output only the new prompt text, no explanation.\"\n\n# Update scenes\u002Fscene-NN.json's shot with the new prompt, then re-render\n# (the next attempt auto-scores again):\nuv run scripts\u002Frender_shot.py --shot $SPARK_VIDEO_SHOT --kind r2v \\\n  --duration 12 --prompt \"\u003Crewritten>\" --media ... --force\n```\n\n### 4. Best-of-N when retries are exhausted\n\n```bash\n# Promote the highest-scoring attempt (no re-render, no re-score):\nuv run scripts\u002Frender_shot.py --shot $SPARK_VIDEO_SHOT --accept-version 2\n```\n\nThen write the escalation report (next section).\n\n## Scoring rubric (6 axes)\n\n`bl omni` is asked for **six** sub-scores (each 0–10), then averaged\ninto the headline `score`. Cast portraits for every character in\n`shot.characters[]` are attached so the model can match faces 1:1.\n\n| Axis | What it asks |\n|------|--------------|\n| **logic** | Does the action \u002F cut \u002F camera move match the script intent and the shot's `narrative_purpose`? Are continuity props respected? |\n| **proportion** | Anatomy, character size relative to environment, perspective, hands \u002F feet \u002F facial proportions. |\n| **physics** | Gravity, collisions, momentum, cloth, hair, fluid behaviour. |\n| **style** | Matches `lore.mood_anchor` \u002F `visual_style` \u002F `palette`. No `forbidden` term\u002Fasset visible. |\n| **cast_match** | Each visible character's face \u002F hair \u002F costume \u002F build matches the **same-named cast portrait** passed alongside the video. Drift \u002F wrong identity → low score. Named characters not in cast → low score. |\n| **dialog_attribution** | The character actually mouthing \u002F voicing each line is the one the prompt assigned that line to. **A's line delivered by B \u002F B's mouth moves for A's line** is a hard 0-3. Shots with no dialog → 10. |\n\n**Default threshold**: `7.0` (env: `SPARK_VIDEO_REVIEW_THRESHOLD`).\n\nThe detailed rubric the rubric.md system prompt encodes lives in\n`references\u002Fspark-video-clip-review\u002Frubric.md` (you should read \u002F\nmaintain that file separately; this skill summary points at it).\n\n## Escalation — when retries exhausted\n\nAfter `max_retry` REJECT rounds, write a structured handoff for the\ndirector under\n`projects\u002F\u003Cp>\u002F\u003Cep>\u002Freviews\u002Fescalation-\u003Cshot>.md`:\n\n```markdown\n# Escalation to Director · S01-002\n\n## Three scoring rounds\n| ver | score | logic | prop | phys | style | cast | dialog |\n|-----|-------|-------|------|------|-------|------|--------|\n| 1   | 6.2   | 7     | 6    | 7    | 8     | 5    | 4      |\n| 2   | 6.5   | 7.5   | 6    | 7    | 8     | 6    | 4      |\n| 3   | 6.6   | 7     | 6    | 7    | 8     | 6    | 6      |\n\n## Recurring issues\n- (List problems that appeared in all three rounds — one sentence with timecode + frame position)\n- ...\n\n## Fix attempts already tried\n- ver2 → ver3 main prompt changes: ...\n  Result: ...\n\n## Suggested director changes\n- (Specific to storyboard.json fields — prompt \u002F kind \u002F duration \u002F characters \u002F seed \u002F scene.description \u002F set_id \u002F props)\n- Priority order\n```\n\nAlso write `projects\u002F\u003Cp>\u002F\u003Cep>\u002Fneeds_director_rewrite.json`:\n\n```json\n{\n  \"shots\": [\"S01-002\"],\n  \"details\": [\n    {\n      \"shot_id\": \"S01-002\",\n      \"best_version\": 2,\n      \"best_score\": 6.6,\n      \"escalation_report\": \"projects\u002F\u003Cp>\u002F\u003Cep>\u002Freviews\u002Fescalation-S01-002.md\"\n    }\n  ]\n}\n```\n\nThe producer reads this and invokes `spark-video-director` with the\nescalation report as input. After the director edits\n`scenes\u002Fscene-NN.json` and re-compiles, the producer runs\n`render_shot.py --shot \u003Cid> --force --reset-attempts` and the loop\nrestarts at ver=1.\n\n## Where review records live\n\n```\nprojects\u002F\u003Cp>\u002F\u003Cep>\u002F\n├── reviews\u002F\n│   ├── S01-001-ver1.json          ← per-attempt scoring\n│   ├── S01-002-ver1.json\n│   ├── S01-002-ver2.json\n│   ├── S01-002-ver3.json\n│   └── escalation-S01-002.md      ← only when needs_director_rewrite=true\n├── clips\u002F\n│   ├── S01-002-ver1.mp4\n│   ├── S01-002-ver2.mp4\n│   ├── S01-002-ver3.mp4\n│   └── S01-002.mp4                ← copy of winning version\n├── shots_state.json                ← canonical truth (only render_shot.py writes)\n└── needs_director_rewrite.json     ← present only after escalation\n```\n\n`shots_state.json` shape:\n\n```json\n{\n  \"S01-002\": {\n    \"shot_id\": \"S01-002\",\n    \"winner_version\": 2,\n    \"winner_path\": \"\u003C...>\u002Fclips\u002FS01-002.mp4\",\n    \"needs_director_rewrite\": false,\n    \"attempts\": [\n      {\"version\": 1, \"status\": \"SUCCEEDED\", \"review\": {\"score\": 6.5, ...}, ...},\n      {\"version\": 2, \"status\": \"SUCCEEDED\", \"review\": {\"score\": 8.1, ...}, ...}\n    ]\n  }\n}\n```\n\n## Parallelism — fan out across chain groups\n\nThe render_graph script produces parallel chain groups:\n\n```bash\nuv run scripts\u002Fstoryboard.py graph\n# Outputs JSON: [[\"S01-001\",\"S01-002\"], [\"S02-001\"], [\"S03-001\",\"S03-002\",\"S03-003\"], ...]\n# Each inner array is a chain group — must render sequentially internally\n# but groups can run in parallel.\n```\n\nWhen your harness supports parallel tool calls, fan out: one\nclip-review loop per chain group, all running concurrently. The\ndefault cap is `SPARK_VIDEO_MAX_CONCURRENCY=4`.\n\nWithin a chain group, the loop is sequential because shot N+1's\n`use_prev_last_frame_as_first=true` depends on shot N's last frame.\n\nFor full-episode batch rendering, use `render_all.py` instead of\nmanually fanning out per chain group:\n\n```bash\nuv run scripts\u002Frender_all.py --reset\n# Or after prompt rewrites:\nuv run scripts\u002Frender_all.py --rejected-only\n```\n\nIt handles chain-group parallelism, media resolution, and first-frame\nchaining internally. You only intervene for prompt rewrites on REJECT.\n\n## DON'Ts\n\n- ❌ Don't modify `storyboard.json` or `scenes\u002Fscene-NN.json` yourself\n  (except via the auto-rewrite step, which targets one shot's `prompt`\n  field). Structural changes are the director's job.\n- ❌ Don't override `winner_path` manually — `render_shot.py` maintains it.\n- ❌ Don't re-implement scoring by hand. `render_shot.py` already scores\n  every render via `lib\u002Freview.py` (cast portraits, 6-axis parse,\n  averaging, sidecar, promotion). Read the verdict from its stdout. The\n  only reason to call the judge yourself is debugging.\n- ❌ Don't `--no-review` or set `VIDEOGEN_REVIEW_MODEL=\"\"` to \"speed\n  things up\". That silently drops the quality gate — the exact failure\n  this hardening exists to prevent. Disable review only on explicit user\n  request, and tell them.\n- ❌ Don't call `bl` directly — always use `.\u002Fscripts\u002Fbl` so the call\n  lands in `logs\u002Fmodel_calls.jsonl` (every prompt is part of the PE\n  audit trail).\n- ❌ Don't escalate before exhausting `max_retry`. Trust the auto-rewrite.\n- ❌ Don't widen the threshold to mask problems. If the threshold is\n  wrong for the project, change `SPARK_VIDEO_REVIEW_THRESHOLD` and tell\n  the user.\n- ❌ Don't treat a `verdict == \"ERROR\"` as a content REJECT. It means the\n  judge couldn't run — diagnose via `logs\u002Fmodel_calls.jsonl`, don't\n  burn a rewrite round on it.\n","# Clip Review + Re-Render Skill — spark-video On-Set QA\n\nYou are the **per-clip quality gate** of the pipeline. You run **after**\neach shot is rendered. You catch problems that only surface in the\nactual rendered MP4 — face drift, lip-sync mismatch, physics\nviolations, style drift, etc. — and drive the retry loop.\n\nSet env vars before any work:\n```bash\nexport SPARK_VIDEO_PROJECT=\u003Cproject_id>\nexport SPARK_VIDEO_EPISODE=\u003CNN>\nexport SPARK_VIDEO_SHOT=\u003CS01-001>      # the shot you're reviewing\nexport SPARK_VIDEO_PHASE=review\n```\n\n## Scoring is automatic — you drive the *judgment*, not the mechanics\n\n**`render_shot.py` now scores every clip itself.** As of the Zone-3\nhardening, a successful render is immediately reviewed in the same tool\ncall by `lib\u002Freview.py`: it builds the `bl omni` call, attaches the\ncast portraits for `shot.characters`, parses the 6-axis JSON, averages\nit, writes `reviews\u002F\u003Cshot>-ver\u003CN>.json`, embeds the review into\n`shots_state.json`, and — on ACCEPT (avg ≥ threshold) — promotes the\nversion to winner (`clips\u002F\u003Cshot>.mp4`). You do **not** hand-build the\n`bl omni` call anymore, and you do **not** copy the winner clip. That\ndeterministic spine cannot be skipped.\n\nWhat is left to *you* is exactly the judgment a script can't do:\n- read the REJECT `critique` and rewrite the prompt to fix the specific\n  failure mode (face drift \u002F dialog mismatch \u002F physics …);\n- decide, when retries are exhausted, between best-of-N and re-cutting\n  the shot group;\n- write the escalation report for the director.\n\n## The state machine (single source of truth)\n\nFor each shot the renderer hands you, run this loop:\n\n```\nver = 1\nwhile ver \u003C= max_retry:                # default max_retry = 3, env: SPARK_VIDEO_MAX_RETRY\n    out = render_shot.py --shot \u003Cid> ...          # renders AND scores AND\n                                                  # auto-promotes winner on ACCEPT\n    verdict = out.review.verdict                  # ACCEPT | REJECT | ERROR\n    if verdict == ACCEPT:\n        # render_shot already set winner_version + copied clips\u002F\u003Cid>.mp4. DONE.\n        break\n    elif verdict == ERROR:\n        # the judge was unreachable \u002F returned junk — NOT a content reject.\n        # inspect logs\u002Fmodel_calls.jsonl; re-run render_shot (--force) or, if\n        # the clip looks fine to you, accept it manually with --accept-version.\n        handle and break or retry\n    elif ver \u003C max_retry:                          # REJECT — YOUR judgment here\n        rewrite prompt from out.review.critique (bl text chat)   # SPARK_VIDEO_PHASE=rewrite\n        update scenes\u002Fscene-NN.json with the new prompt\n        ver += 1                                   # next render_shot --force renders ver+1\n    else:                                          # REJECT, retries exhausted\n        best = highest-scoring attempt in shots_state.json\n        render_shot.py --shot \u003Cid> --accept-version \u003Cbest>       # promote best-of-N\n        write reviews\u002Fescalation-\u003Cshot>.md + needs_director_rewrite.json\n        exit with escalation signal\n```\n\nThe producer reads the escalation file and invokes the\n`spark-video-director` skill with it as input.\n\n## How to render + review one attempt\n\n### 1. Render (scoring happens automatically)\n```bash\nexport SPARK_VIDEO_SHOT=S01-002\nexport SPARK_VIDEO_PHASE=render\nuv run scripts\u002Frender_shot.py \\\n  --shot $SPARK_VIDEO_SHOT \\\n  --kind r2v --duration 12 \\\n  --prompt \"\u003Cfrom storyboard.json>\" \\\n  --media projects\u002F$SPARK_VIDEO_PROJECT\u002Fcast\u002F陆辰\u002Fportrait1.png \\\n          projects\u002F$SPARK_VIDEO_PROJECT\u002Fmovie-set\u002F客栈大堂-夜晚\u002Fset1.png\n\n# stdout (JSON) now includes the review verdict:\n# {\"shot_id\":\"S01-002\",\"version\":1,\"video_path\":\"...\",\"duration_s\":12.0,\n#  \"provider\":\"bl\",\"model\":\"happyhorse-1.0-r2v\",\"elapsed_s\":47.2,\n#  \"review\":{\"score\":6.2,\"verdict\":\"REJECT\",\"breakdown\":{...},\"critique\":\"...\"},\n#  \"winner_version\":null,\n#  \"next\":\"rewrite prompt and re-render (--force), or accept best-of-N ...\"}\n```\n\nIn one call the script: writes `clips\u002FS01-002-ver1.mp4`, extracts the\nlast frame, scores the clip on the 6 axes (auto-resolving cast portraits\nfrom `cast.json`), writes `reviews\u002FS01-002-ver1.json`, embeds the review\ninto `shots_state.json`, and — if `verdict == ACCEPT` — promotes the\nversion to winner (`clips\u002FS01-002.mp4`). **You only read the verdict from\nstdout.** You never write `shots_state.json`, build the `bl omni` call,\nor copy the winner clip.\n\nOpt-outs: `--no-review` skips scoring for one render;\n`VIDEOGEN_REVIEW_MODEL=\"\"` disables it globally (falls back to the old\nmanual `--accept-version` flow). `--characters A B` overrides which cast\nportraits feed the `cast_match` axis (default: storyboard's\n`shot.characters`).\n\n### 2. The review record (written for you)\n\n`reviews\u002F\u003Cshot>-ver\u003CN>.json` and `shots_state.json`'s\n`attempts[].review` carry the same object — this is what `viewer.html`\n(and a future progress console) renders:\n\n```json\n{\n  \"shot_id\": \"S01-002\",\n  \"version\": 1,\n  \"score\": 6.2,\n  \"breakdown\": {\n    \"logic\": 7, \"proportion\": 6, \"physics\": 7,\n    \"style\": 8, \"cast_match\": 5, \"dialog_attribution\": 4\n  },\n  \"critique\": \"0:00–0:03 钱夫人脸型偏离参考图(下巴宽 + 发际线高); 0:04 那句\\\"你这小蹄子\\\"应是钱夫人说的, 但视频里嘴动的是郭芙蓉, 属于台词错位 ...\",\n  \"verdict\": \"REJECT\",\n  \"ts\": \"\u003CISO8601>\"\n}\n```\n\n`verdict = \"ACCEPT\"` iff `score >= threshold` (default 7.0, env:\n`SPARK_VIDEO_REVIEW_THRESHOLD` \u002F `VIDEOGEN_REVIEW_THRESHOLD`). The\nthreshold is authoritative — the script ignores a lenient model verdict\nthat disagrees with the arithmetic. A `verdict == \"ERROR\"` means the\njudge couldn't run (timeout \u002F unparseable output); inspect\n`logs\u002Fmodel_calls.jsonl` rather than treating it as a content reject.\n\n### 3. On REJECT — rewrite the prompt (this is YOUR job)\n\n```bash\nexport SPARK_VIDEO_PHASE=rewrite\n.\u002Fscripts\u002Fbl text chat \\\n  --model qwen-plus \\\n  --system \"$(cat references\u002Fspark-video-clip-review\u002Frewrite-system.md)\" \\\n  --message \"Original prompt: \u003Cprompt>\\nScore: 6.2\\nIssues: \u003Ccritique>\\nRewrite the prompt to fix the issues while keeping narrative intent unchanged. Output only the new prompt text, no explanation.\"\n\n# Update scenes\u002Fscene-NN.json's shot with the new prompt, then re-render\n# (the next attempt auto-scores again):\nuv run scripts\u002Frender_shot.py --shot $SPARK_VIDEO_SHOT --kind r2v \\\n  --duration 12 --prompt \"\u003Crewritten>\" --media ... --force\n```\n\n### 4. Best-of-N when retries are exhausted\n\n```bash\n# Promote the highest-scoring attempt (no re-render, no re-score):\nuv run scripts\u002Frender_shot.py --shot $SPARK_VIDEO_SHOT --accept-version 2\n```\n\nThen write the escalation report (next section).\n\n## Scoring rubric (6 axes)\n\n`bl omni` is asked for **six** sub-scores (each 0–10), then averaged\ninto the headline `score`. Cast portraits for every character in\n`shot.characters[]` are attached so the model can match faces 1:1.\n\n| Axis | What it asks |\n|------|--------------|\n| **logic** | Does the action \u002F cut \u002F camera move match the script intent and the shot's `narrative_purpose`? Are continuity props respected? |\n| **proportion** | Anatomy, character size relative to environment, perspective, hands \u002F feet \u002F facial proportions. |\n| **physics** | Gravity, collisions, momentum, cloth, hair, fluid behaviour. |\n| **style** | Matches `lore.mood_anchor` \u002F `visual_style` \u002F `palette`. No `forbidden` term\u002Fasset visible. |\n| **cast_match** | Each visible character's face \u002F hair \u002F costume \u002F build matches the **same-named cast portrait** passed alongside the video. Drift \u002F wrong identity → low score. Named characters not in cast → low score. |\n| **dialog_attribution** | The character actually mouthing \u002F voicing each line is the one the prompt assigned that line to. **A's line delivered by B \u002F B's mouth moves for A's line** is a hard 0-3. Shots with no dialog → 10. |\n\n**Default threshold**: `7.0` (env: `SPARK_VIDEO_REVIEW_THRESHOLD`).\n\nThe detailed rubric the rubric.md system prompt encodes lives in\n`references\u002Fspark-video-clip-review\u002Frubric.md` (you should read \u002F\nmaintain that file separately; this skill summary points at it).\n\n## Escalation — when retries exhausted\n\nAfter `max_retry` REJECT rounds, write a structured handoff for the\ndirector under\n`projects\u002F\u003Cp>\u002F\u003Cep>\u002Freviews\u002Fescalation-\u003Cshot>.md`:\n\n```markdown\n# Escalation to Director · S01-002\n\n## Three scoring rounds\n| ver | score | logic | prop | phys | style | cast | dialog |\n|-----|-------|-------|------|------|-------|------|--------|\n| 1   | 6.2   | 7     | 6    | 7    | 8     | 5    | 4      |\n| 2   | 6.5   | 7.5   | 6    | 7    | 8     | 6    | 4      |\n| 3   | 6.6   | 7     | 6    | 7    | 8     | 6    | 6      |\n\n## Recurring issues\n- (List problems that appeared in all three rounds — one sentence with timecode + frame position)\n- ...\n\n## Fix attempts already tried\n- ver2 → ver3 main prompt changes: ...\n  Result: ...\n\n## Suggested director changes\n- (Specific to storyboard.json fields — prompt \u002F kind \u002F duration \u002F characters \u002F seed \u002F scene.description \u002F set_id \u002F props)\n- Priority order\n```\n\nAlso write `projects\u002F\u003Cp>\u002F\u003Cep>\u002Fneeds_director_rewrite.json`:\n\n```json\n{\n  \"shots\": [\"S01-002\"],\n  \"details\": [\n    {\n      \"shot_id\": \"S01-002\",\n      \"best_version\": 2,\n      \"best_score\": 6.6,\n      \"escalation_report\": \"projects\u002F\u003Cp>\u002F\u003Cep>\u002Freviews\u002Fescalation-S01-002.md\"\n    }\n  ]\n}\n```\n\nThe producer reads this and invokes `spark-video-director` with the\nescalation report as input. After the director edits\n`scenes\u002Fscene-NN.json` and re-compiles, the producer runs\n`render_shot.py --shot \u003Cid> --force --reset-attempts` and the loop\nrestarts at ver=1.\n\n## Where review records live\n\n```\nprojects\u002F\u003Cp>\u002F\u003Cep>\u002F\n├── reviews\u002F\n│   ├── S01-001-ver1.json          ← per-attempt scoring\n│   ├── S01-002-ver1.json\n│   ├── S01-002-ver2.json\n│   ├── S01-002-ver3.json\n│   └── escalation-S01-002.md      ← only when needs_director_rewrite=true\n├── clips\u002F\n│   ├── S01-002-ver1.mp4\n│   ├── S01-002-ver2.mp4\n│   ├── S01-002-ver3.mp4\n│   └── S01-002.mp4                ← copy of winning version\n├── shots_state.json                ← canonical truth (only render_shot.py writes)\n└── needs_director_rewrite.json     ← present only after escalation\n```\n\n`shots_state.json` shape:\n\n```json\n{\n  \"S01-002\": {\n    \"shot_id\": \"S01-002\",\n    \"winner_version\": 2,\n    \"winner_path\": \"\u003C...>\u002Fclips\u002FS01-002.mp4\",\n    \"needs_director_rewrite\": false,\n    \"attempts\": [\n      {\"version\": 1, \"status\": \"SUCCEEDED\", \"review\": {\"score\": 6.5, ...}, ...},\n      {\"version\": 2, \"status\": \"SUCCEEDED\", \"review\": {\"score\": 8.1, ...}, ...}\n    ]\n  }\n}\n```\n\n## Parallelism — fan out across chain groups\n\nThe render_graph script produces parallel chain groups:\n\n```bash\nuv run scripts\u002Fstoryboard.py graph\n# Outputs JSON: [[\"S01-001\",\"S01-002\"], [\"S02-001\"], [\"S03-001\",\"S03-002\",\"S03-003\"], ...]\n# Each inner array is a chain group — must render sequentially internally\n# but groups can run in parallel.\n```\n\nWhen your harness supports parallel tool calls, fan out: one\nclip-review loop per chain group, all running concurrently. The\ndefault cap is `SPARK_VIDEO_MAX_CONCURRENCY=4`.\n\nWithin a chain group, the loop is sequential because shot N+1's\n`use_prev_last_frame_as_first=true` depends on shot N's last frame.\n\nFor full-episode batch rendering, use `render_all.py` instead of\nmanually fanning out per chain group:\n\n```bash\nuv run scripts\u002Frender_all.py --reset\n# Or after prompt rewrites:\nuv run scripts\u002Frender_all.py --rejected-only\n```\n\nIt handles chain-group parallelism, media resolution, and first-frame\nchaining internally. You only intervene for prompt rewrites on REJECT.\n\n## DON'Ts\n\n- ❌ Don't modify `storyboard.json` or `scenes\u002Fscene-NN.json` yourself\n  (except via the auto-rewrite step, which targets one shot's `prompt`\n  field). Structural changes are the director's job.\n- ❌ Don't override `winner_path` manually — `render_shot.py` maintains it.\n- ❌ Don't re-implement scoring by hand. `render_shot.py` already scores\n  every render via `lib\u002Freview.py` (cast portraits, 6-axis parse,\n  averaging, sidecar, promotion). Read the verdict from its stdout. The\n  only reason to call the judge yourself is debugging.\n- ❌ Don't `--no-review` or set `VIDEOGEN_REVIEW_MODEL=\"\"` to \"speed\n  things up\". That silently drops the quality gate — the exact failure\n  this hardening exists to prevent. Disable review only on explicit user\n  request, and tell them.\n- ❌ Don't call `bl` directly — always use `.\u002Fscripts\u002Fbl` so the call\n  lands in `logs\u002Fmodel_calls.jsonl` (every prompt is part of the PE\n  audit trail).\n- ❌ Don't escalate before exhausting `max_retry`. Trust the auto-rewrite.\n- ❌ Don't widen the threshold to mask problems. If the threshold is\n  wrong for the project, change `SPARK_VIDEO_REVIEW_THRESHOLD` and tell\n  the user.\n- ❌ Don't treat a `verdict == \"ERROR\"` as a content REJECT. It means the\n  judge couldn't run — diagnose via `logs\u002Fmodel_calls.jsonl`, don't\n  burn a rewrite round on it.\n",{"name":5,"description":7},"main","e396986d3c7d4b668808fa7e7d1b862e8e9e3de1","skills\u002Fspark-video\u002Freferences\u002Fspark-video-clip-review",9,"https:\u002F\u002Fgithub.com\u002Fmodelstudioai\u002Fskills","https:\u002F\u002Fmodelstudioai.github.io\u002Fskills\u002F","https:\u002F\u002Fgithub.com\u002Fmodelstudioai","https:\u002F\u002Fbailian.console.aliyun.com\u002F","2026-11-14 04:33:35",{"source":8,"skillName":5,"commands":34,"prompt":44,"zipAvailable":45},[35,38,41],{"tool":36,"command":37},"npx","npx skills add modelstudioai\u002Fskills --skill spark-video-clip-review",{"tool":39,"command":40},"bunx","bunx skills add modelstudioai\u002Fskills --skill spark-video-clip-review",{"tool":42,"command":43},"pnpm","pnpm dlx skills add modelstudioai\u002Fskills --skill spark-video-clip-review","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fmodelstudioai\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fspark-video\u002Freferences\u002Fspark-video-clip-review\u002FSKILL.md",true,[47,53],{"path":48,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":51,"sourceHtmlUrl":52},"rewrite-system.md","REFERENCE","参考文档",4895,"https:\u002F\u002Fgithub.com\u002Fmodelstudioai\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fspark-video\u002Freferences\u002Fspark-video-clip-review\u002Frewrite-system.md",{"path":54,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":55,"sourceHtmlUrl":56},"rubric.md",7168,"https:\u002F\u002Fgithub.com\u002Fmodelstudioai\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fspark-video\u002Freferences\u002Fspark-video-clip-review\u002Frubric.md",[58,65,72,79,86,93],{"skillNo":59,"name":60,"nameZh":6,"description":61,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":62,"categories":63,"keywords":64,"publishedAt":19},"01M74FEYG88ZVEVSQC85Y97PF7","vox-video-director","Turn ONE topic into a finished Vox-style paper-collage explainer \u002F ad video, end to end with Aliyun Bailian CLI + local ffmpeg — script, collage keyframes, motion, voice-over, music, captions, all automated. Use this whenever the user wants a \"Vox style\" video, a paper\u002Ftorn-paper collage animation, a \"motion collage\", a narrated explainer or short ad built from AI-generated collage posters, a scrapbook-style tribute, or wants to turn a topic \u002F product \u002F person into a punchy narrated collage video — even if they don't say the word \"Vox\". Also use when reproducing Stav Zilber \u002F rom1trs \u002F Higgsfield-style collage ad workflows. Three input modalities: a topic (B-roll), a talking-head video (A-roll mode), or a single photo of a person\u002Fproduct anchored into the collage (C-roll mode). Triggers: \"vox video\", \"collage video\", \"motion collage\", \"paper collage explainer\", \"make a collage ad\", \"turn this topic into a collage video\", \"turn my photo\u002Fthis product shot into a collage video\".","https:\u002F\u002Fgithub.com\u002Fmodelstudioai\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fvox-video-director\u002FSKILL.md",[],[],{"skillNo":66,"name":67,"nameZh":6,"description":68,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":69,"categories":70,"keywords":71,"publishedAt":19},"01M74FESD641YN15106ERYKHD7","spark-video-vfx-review","Pre-render quality gate. Read a finished storyboard.json and produce a structured review report flagging visual inconsistencies, prompt defects, and continuity errors that would waste render budget. You find problems; the director fixes them. Opt-in — bypassed unless the producer explicitly invokes you.","https:\u002F\u002Fgithub.com\u002Fmodelstudioai\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fspark-video\u002Freferences\u002Fspark-video-vfx-review\u002FSKILL.md",[],[],{"skillNo":73,"name":74,"nameZh":6,"description":75,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":76,"categories":77,"keywords":78,"publishedAt":19},"01M74FENAN9G48PFE0292SCJMP","spark-video-screenwriter","Turn a user's premise into a structured screenplay (one scene at a time) for the spark-video pipeline. Wraps Shanyin Super Screenwriting Master when available — that upstream Shanyin SKILL is the single source of truth for craft when present.","https:\u002F\u002Fgithub.com\u002Fmodelstudioai\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fspark-video\u002Freferences\u002Fspark-video-screenwriter\u002FSKILL.md",[],[],{"skillNo":80,"name":81,"nameZh":6,"description":82,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":83,"categories":84,"keywords":85,"publishedAt":19},"01M74FEEZHE6VJQAFWJ66HQDYF","spark-video-episode","One-shot autopilot orchestrator — runs the full spark-video pipeline (screenwriter ↔ director per-scene parallel → render chain-DAG parallel + per-clip review → stitch). User confirms at 4 gates (+ 1 mode gate at start + 1 BGM gate when bgm\u002F folder detected). Use when the user wants \"make me an episode\" in one command.","https:\u002F\u002Fgithub.com\u002Fmodelstudioai\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fspark-video\u002Freferences\u002Fspark-video-episode\u002FSKILL.md",[],[],{"skillNo":87,"name":88,"nameZh":6,"description":89,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":90,"categories":91,"keywords":92,"publishedAt":19},"01M74FE8JQBCHPC2GQHWJDGT55","spark-video-director","Translate a screenplay (one scene at a time) into a provider-agnostic storyboard fragment for the spark-video pipeline. Wraps Shanyin Super Director Master when available — the upstream Shanyin SKILL is the single source of truth for craft when present.","https:\u002F\u002Fgithub.com\u002Fmodelstudioai\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fspark-video\u002Freferences\u002Fspark-video-director\u002FSKILL.md",[],[],{"skillNo":94,"name":95,"nameZh":6,"description":96,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":97,"categories":98,"keywords":99,"publishedAt":19},"01M74FDWYR8F0W6ZT3998PPKT5","spark-video-cast","Scaffold and generate reference assets for characters (cast), locations (movie-set \u002F set dressing), and key props — the three pillars of visual consistency in spark-video. Wraps bl image generate \u002F edit for portrait creation. Use when adding new characters\u002Flocations\u002Fprops or when costume\u002Fstate changes are needed.","https:\u002F\u002Fgithub.com\u002Fmodelstudioai\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fspark-video\u002Freferences\u002Fspark-video-cast\u002FSKILL.md",[],[]]