Keep family pre/post text on shot queues and wrap the mid prompt at Comfy time.

Later shots were starting a new job without those wrappers, so only the first clip got them.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Towsty
2026-09-03 07:17:00 -05:00
co-authored by Cursor
parent f05f8f3597
commit 1206afe8fd
9 changed files with 86 additions and 32 deletions
+3 -3
View File
@@ -4,7 +4,7 @@ import { listStudioLoras, parsePostedLoraStack, parseShotLoraStacks, persistLora
import { clampVideoCfg } from '~/utils/generationPresets'
import { defaultVideoSteps, isLtxWorkflow, isTextToVideo, LTX_DISABLED_MESSAGE, ltxWorkflowEnabled, parseVideoWorkflow, videoEngineOf } from '~/utils/videoModels'
import { allowIdentityRefs, normalizePermanenceRefs, resolveGlobalLocks, type PermanenceRef } from '~/utils/globalLocks'
import { composePromptParts, joinPromptParts, persistPromptWrappers } from '~/utils/promptParts'
import { composePromptParts, persistPromptWrappers } from '~/utils/promptParts'
import type { QueuedExtension } from '~/server/utils/library'
function parseDuration(raw: unknown) {
@@ -150,7 +150,7 @@ export default defineEventHandler(async (event) => {
throw createError({ statusCode: 400, statusMessage: 'A motion prompt is required' })
}
const resolvedLocks = resolveGlobalLocks(fields.globalLocks || '', promptMid)
const prompt = joinPromptParts(promptPre, resolvedLocks.prompt, promptPost)
const prompt = resolvedLocks.prompt
const globalLocks = resolvedLocks.locks
const extensions = parseExtensions(fields.extensions)
const permanenceRefs = parseFamilyPermanenceRefs(fields.permanenceRefs)
@@ -251,7 +251,7 @@ export default defineEventHandler(async (event) => {
familyId,
payload: {
prompt,
promptMid: promptMid || undefined,
promptMid: prompt || undefined,
promptPre: promptPre || undefined,
promptPost: promptPost || undefined,
name: clipName,