From c82c3be0c8e7073ada0a4800142c15da0a1cc351 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=86=B0=E6=9C=94?= <565183519@qq.com> Date: Sun, 21 Jun 2026 17:42:39 +0800 Subject: [PATCH] =?UTF-8?q?D136+:=20=E4=B8=8A=E4=B8=8B=E6=96=87=E4=BC=A0?= =?UTF-8?q?=E9=80=92=20=E2=80=94=20=E6=AF=8F=E9=95=9C=E5=B8=A6=E5=89=A7?= =?UTF-8?q?=E9=9B=86=E6=91=98=E8=A6=81+=E5=89=8D=E4=B8=80=E9=95=9C?= =?UTF-8?q?=E6=A1=86=E6=9E=B6(=E8=8B=B1=E6=96=87=E7=BC=96=E7=A0=81)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 每镜提示词现在包含: [Ep01 Summary] 15词英文 → Su Bai has system, never despairs... [Previous Shot] 15词英文 → 告诉AI前一镜发生了什么 ⊢ CHAR/PROP/ENV 编码锁定 → 中英混合 ⊢ Scene 场景 → 中文自然语言推理 消除抽卡本质: 以前: 每镜盲抽 → AI不知道它在做什么故事 现在: 每镜知道自己在Ep01→知道前一镜→知道自己接着拍什么 跨集压缩规则: 到第10集: 5集合成1句话 到第50集: 10集合成2句话 英文字数上限1000词→空间充足 --- video-ai-system/engines/generate-shots.js | 51 ++++++++++--------- .../付费修仙-ep01-director-encoding.json | 5 ++ 2 files changed, 31 insertions(+), 25 deletions(-) diff --git a/video-ai-system/engines/generate-shots.js b/video-ai-system/engines/generate-shots.js index 0d8e4e2..884c8e7 100644 --- a/video-ai-system/engines/generate-shots.js +++ b/video-ai-system/engines/generate-shots.js @@ -65,48 +65,50 @@ async function main() { function buildPrompt(shot, encoding) { const locks = encoding.continuity_locks; - // ═══ 编码+自然语言 双层协议 ═══ + // ═══ 上下文+编码+自然语言 三层协议 ═══ // - // ⊢ 编码层: 锁死不可变的 - // CHAR(人物) + PROP(道具) + ENV(环境·空间·背景) - // 这些在任何镜头里都不能变。精简,只锁关键属性。 + // [Context] 英文编码 · 告诉AI前面发生了什么 + 这个故事是什么 + // 50词以内 → AI理解上下文 → 不自盲抽 // - // ⊢ 场景层: 自然语言 → AI自己推理 - // 情节内容 + 为什么(动机·情感·因果关系) - // 让AI理解原因→自己推理→生成有灵魂的画面 + // ⊢ 编码层: CHAR+PROP+ENV锁定 + // + // ⊢ 场景层: 中文自然语言 → AI推理情节+原因 let prompt = ''; - // ─── 编码层: CHAR+PROP+ENV全部锁定 ─── + // ─── 上下文层: 英文编码 → 告诉AI前面发生了什么 ─── + // 每镜都带:剧集摘要 + 前一个镜头的框架 + if (encoding.episode_summary) { + prompt += `[Ep${encoding.episode} Summary] ${encoding.episode_summary}\n`; + } + if (encoding.prev_shots?.[shot.id]) { + prompt += `[Previous Shot] ${encoding.prev_shots[shot.id]}\n`; + } + if (prompt.length > 0) prompt += '\n'; + + // ─── 编码层: CHAR+PROP+ENV ─── if (shot.char_ref && locks?.characters?.[shot.char_ref]) { - prompt += `⊢ CHAR-003 · 苏白 · 锁定\n`; - prompt += ` 18岁男性·白色长衫·黑色长发半束·175cm挺拔\n`; + prompt += `⊢ CHAR-003 Su Bai: 18yr male, white robe, black hair half-up, 175cm\n`; } if (shot.prop_ref && locks?.props?.[shot.prop_ref]) { - prompt += `⊢ PROP · 锁定\n`; - prompt += ` 竖式悬挂·破旧木质·【天道宗】\n`; + prompt += `⊢ PROP: vertical hanging wood sign, worn edges, 【天道宗】\n`; } if (shot.prop_ref_2 && locks?.props?.[shot.prop_ref_2]) { - const propLock2 = locks.props[shot.prop_ref_2]; - prompt += `⊢ PROP · 锁定\n`; - prompt += ` 横式立地·破旧木板·招生广告\n`; + prompt += `⊢ PROP: horizontal floor board, recruitment ad\n`; } - // 环境锁定 if (shot.env && locks?.environments?.[shot.env]) { - prompt += `⊢ ENV-002 · 锁定\n`; - prompt += ` 修仙世界·百宗会广场·人群边缘角落·白天金色阳光\n`; + prompt += `⊢ ENV: cultivation square, edge corner, golden sunlight\n`; } // ─── 场景层: 情节+原因 → AI推理 ─── if (encoding.scene) { - prompt += `\n⊢ 场景\n`; - prompt += ` ${encoding.scene}\n`; + prompt += `\n⊢ Scene:\n ${encoding.scene}\n`; } - // ─── 动作: 自然语言 → AI发挥 ─── - prompt += `\n→ 景别: ${shot.framing}`; + // ─── 动作: 当前镜头 ─── + prompt += `\n→ Shot: ${shot.framing}`; if (shot.emotion?.type) prompt += ` | ${shot.emotion.type}`; prompt += `\n`; @@ -114,9 +116,8 @@ function buildPrompt(shot, encoding) { prompt += `→ ${shot.action}\n`; } - // ─── 风格 ─── - prompt += `⊢ 风格: 3D动画渲染·中国风仙侠·电影级光影\n`; - prompt += `⊢ 禁止: 真人写实·卡通·现代元素·水印`; + prompt += `⊢ Style: 3D animation, Chinese cultivation, cinematic lighting\n`; + prompt += `⊢ No: photorealism, cartoon, modern elements, watermark`; return prompt; } diff --git a/video-ai-system/outputs/付费修仙-ep01-director-encoding.json b/video-ai-system/outputs/付费修仙-ep01-director-encoding.json index bf5d20a..44f5396 100644 --- a/video-ai-system/outputs/付费修仙-ep01-director-encoding.json +++ b/video-ai-system/outputs/付费修仙-ep01-director-encoding.json @@ -3,6 +3,11 @@ "episode": "ep01", "tempo": "slow_build", "emotion_main": "悬", + "episode_summary": "Su Bai has system, never despairs. Worst booth in cultivation square corner. Broken wood sign. Recruiting disciples. Mocked but undeterred.", + "prev_shots": { + "S1-01": "Cultivators fly into square. Push from front-row LingXiao (gold sign, long queue) to back corner TianDao (broken vertical sign, nobody).", + "S1-02": "follows S1-01: mid-shot of Su Bai standing under broken vertical sign, hands on hips, confident smile, shouting." + }, "scene": "修仙界高空云层之上,今天是宗门招新收徒的日子。无数修仙者御剑飞行,从四面八方涌入百宗会广场。广场上就像摆摊——靠前的位置最显眼,排队的人最多。灵霄宗在最前面,鎏金大字,门庭若市,队伍排到望不到头。一路往后,摊位越来越偏僻,人群越来越稀疏。到最角落——天道宗。只有一块破旧的竖式木质牌匾,无人问津。但苏白有系统,他知道自己早晚是世界第一宗。他站在破牌匾下大声吆喝——不是因为绝望,是因为笃定。他的喊话不是乞求,是宣言。围观的人嘲笑他,讽刺完散去,风吹起落叶。苏白叹气——不是认命,是系统进度条走太慢的烦躁。", "emotion_curve": [ { "pos": "0-5s", "intensity": 3, "type": "悬", "role": "建立" },