fix(canvas): 视频生成 - 显式 @文本 引用内联真实内容

普通模型视频渠道 promptOnly 门槛此前连显式 @文本N 引用一并拦截,
提示词只剩【文本N】占位符、文本节点正文未进上游报文。现 textBlocks
始终追加;promptOnly 拦自动上游连线文本的 8d4f656a 语义保持不变。
补 3 例专项测试并同步 pending-test 待验收清单。
This commit is contained in:
VicoHu
2026-09-11 18:05:38 +08:00
committed by ddCat
parent 1de105b537
commit 7ebbd9e003
4 changed files with 46 additions and 2 deletions

View File

@@ -229,7 +229,8 @@ function buildComposerGenerationContext(
}
nextPrompt += normalizedPrompt.slice(lastIndex);
if (textBlocks.length && !promptOnly) nextPrompt = `${nextPrompt.trim()}\n\n${textBlocks.join("\n\n")}`;
// 显式 @文本 引用是用户写进输入框的内容,必须内联真实文本;promptOnly 只拦自动上游文本。
if (textBlocks.length) nextPrompt = `${nextPrompt.trim()}\n\n${textBlocks.join("\n\n")}`;
if (autoIncludeWorkflowMedia) {
// RunningHub/ComfyUI 工作流按保存的字段槽位接收图片、视频和音频;
// 配置节点不能因为提示词里没有逐个 @ 就丢失已连接媒体。