Skip to content

Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS

Test a card render's audio-reactive and performance prompt paths

Claudebcaaeee9cb7c
diff --git a/client/src/components/musicVideo/SceneRenderInputs.test.jsx b/client/src/components/musicVideo/SceneRenderInputs.test.jsx
index 304c502e71..cfe10da7b9 100644
--- a/client/src/components/musicVideo/SceneRenderInputs.test.jsx
+++ b/client/src/components/musicVideo/SceneRenderInputs.test.jsx
@@ -24,6 +24,14 @@ describe('shotCardRenderRequest', () => {
expect(shotCardRenderRequest({ ...base, inputs: { endFrame: false } }).endFrame.state).toBe('off');
});
+ // Review on #11280: an audio-reactive render hears the song through its LoRA, so the card must say so and never stack a supplied window.
+ it('shows an audio-reactive render as hearing the song, with its guard in the prompt', () => {
+ const request = shotCardRenderRequest({ scene: scene(), settings: { backend: 'local', modelId: 'ltx25_example', generationMode: 'audioReactive' }, models,
+ inputs: { songAudio: false } });
+ expect(request.songAudio.state).toBe('required');
+ expect(request.prompt).toMatch(/No singing, lip-sync/);
+ });
+
it('requires the song for a performance shot and flags a prompt over the fal model limit', () => {
expect(shotCardRenderRequest({ scene: scene(), performance: true, settings: { backend: 'local' }, models }).songAudio.state).toBe('required');
const long = shotCardRenderRequest({ scene: scene({ prompt: 'x'.repeat(2100) }), settings: { backend: 'fal' } });
diff --git a/server/services/videoGen/submitJob.test.js b/server/services/videoGen/submitJob.test.js
index 8ac0bd6f5f..4c4a588832 100644
--- a/server/services/videoGen/submitJob.test.js
+++ b/server/services/videoGen/submitJob.test.js
@@ -436,6 +436,18 @@ describe('shot intent at the video submission boundary', () => {
expect(params.shotInstruction.actionContract).toEqual(contract);
});
+ it('still re-times a card-typed performance prompt to its padded song slice', async () => {
+ mocks.prepareVideoGenParams.mockResolvedValue({ backend: 'fal', cleanupStaged: vi.fn(), sourceImagePath: '/example/frame.png' });
+ mocks.preparePerformanceShot.mockResolvedValue({ audioFilePath: '/example/audio.wav', modelId: 'lip-sync', resolution: '1080P',
+ shotInstruction: { version: 1, shotMode: 'performance', songInterval: { startSec: 10, endSec: 14 }, edit: { inSec: 1.5, outSec: 5.5 } } });
+ await submitVideoGenJob({ prompt: 'Typed\nShot intent (clip-relative seconds):\nAction 0.000s–1.000s: Singer\nEnd shot intent.', backend: 'fal',
+ musicVideo: { projectId: 'p', sceneId: 's', promptAsTyped: true } }, {});
+ const { params } = mocks.enqueueJob.mock.calls[0][0];
+ expect(params.prompt.startsWith('Typed\n')).toBe(true);
+ expect(params.prompt).toContain('Action 1.500s–2.500s: Singer');
+ expect(params.prompt).not.toContain('Action 0.000s–1.000s');
+ });
+
it('shifts contract and words into a padded performance window exactly once', async () => {
mocks.prepareVideoGenParams.mockResolvedValue({ backend: 'fal', cleanupStaged: vi.fn(), sourceImagePath: '/example/frame.png' });
mocks.preparePerformanceShot.mockResolvedValue({ audioFilePath: '/example/audio.wav', modelId: 'lip-sync', resolution: '1080P',