{
  "name": "Generate cinematic videos from text prompts with GPT-4o, Fal.AI Seedance & Audio",
  "nodes": [
    {
      "id": "00c39b14-561e-4217-81c5-693cfea0f5ee",
      "name": "Structured Output Parser",
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "position": [
        100,
        -180
      ]
    },
    {
      "id": "d7d2e2a8-8515-4406-9b4b-48e363a15c96",
      "name": "Structured Output Parser1",
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "position": [
        440,
        -160
      ]
    },
    {
      "id": "736ee87b-08fd-438e-aabf-f6a3a7e02f35",
      "name": "Split Out",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        940,
        -180
      ]
    },
    {
      "id": "81b11247-8002-487b-a50f-7669e89fbb14",
      "name": "OpenAI Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        -60,
        -160
      ]
    },
    {
      "id": "3ffdfc3f-7e33-43a9-9990-82873291d992",
      "name": "OpenAI Chat Model1",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        -300,
        100
      ]
    },
    {
      "id": "d4611c08-9d64-4d55-a2d1-778ca51d45f5",
      "name": "Structured Output Parser2",
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "position": [
        -120,
        100
      ]
    },
    {
      "id": "d0982700-b832-4bb8-8322-56077fe3f4bc",
      "name": "Wait for the video",
      "type": "n8n-nodes-base.wait",
      "position": [
        380,
        80
      ]
    },
    {
      "id": "2b7da46b-f063-4c88-aa28-13769564cef8",
      "name": "Get the video status",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        540,
        80
      ]
    },
    {
      "id": "b9b2a0d9-65d3-4e25-b3cd-baab375a93b1",
      "name": "Video status",
      "type": "n8n-nodes-base.switch",
      "position": [
        700,
        80
      ]
    },
    {
      "id": "e8907f8b-9afa-4775-ab7d-77ba09f2ea00",
      "name": "Get the  video",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        920,
        60
      ]
    },
    {
      "id": "02b6f642-f1f0-4524-8af8-5693d56c3af6",
      "name": "Loop Over Items",
      "type": "n8n-nodes-base.splitInBatches",
      "position": [
        200,
        40
      ]
    },
    {
      "id": "5c22a8e1-9394-431f-be1c-1ee4c5ddf3cf",
      "name": "Get audio status",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -320,
        460
      ]
    },
    {
      "id": "b993b68f-3698-499f-a847-a5bb18afac99",
      "name": "Get video with audio",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -120,
        320
      ]
    },
    {
      "id": "b2e1ac2f-ae1e-4dc1-8cf6-58f02085408b",
      "name": "Start adding audio to the video",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -540,
        340
      ]
    },
    {
      "id": "6a802e7d-7de7-4fad-a614-ad32949551fe",
      "name": "Wait for adding the audio",
      "type": "n8n-nodes-base.wait",
      "position": [
        -320,
        320
      ]
    },
    {
      "id": "d11f1211-015d-40d1-8789-889f6592b129",
      "name": "Audio status",
      "type": "n8n-nodes-base.switch",
      "position": [
        -120,
        460
      ]
    },
    {
      "id": "d79854b0-b7f3-46d6-80f0-3b90f9d99889",
      "name": "Loop Over Items1",
      "type": "n8n-nodes-base.splitInBatches",
      "position": [
        -540,
        520
      ]
    },
    {
      "id": "30094be7-d29c-457e-badc-8795c18ead3e",
      "name": "Start merging videos",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        400,
        320
      ]
    },
    {
      "id": "2d8ada58-7d79-4949-97bb-842103c60cf0",
      "name": "Wait for the merge to complete",
      "type": "n8n-nodes-base.wait",
      "position": [
        620,
        320
      ]
    },
    {
      "id": "57398a78-a190-4ad6-96e9-a581a12acc20",
      "name": "Merge videos status",
      "type": "n8n-nodes-base.switch",
      "position": [
        960,
        320
      ]
    },
    {
      "id": "d6f4680c-7529-492c-8874-41495623d51e",
      "name": "Get merge videos status",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        780,
        320
      ]
    },
    {
      "id": "a3c0f988-fe00-4f5c-a32e-992e5fa9f507",
      "name": "Get merged video",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        400,
        480
      ]
    },
    {
      "id": "af84d7a6-b3af-4172-9700-320a07406a3c",
      "name": "Aggregate videos with audio",
      "type": "n8n-nodes-base.aggregate",
      "position": [
        200,
        500
      ]
    },
    {
      "id": "f144eb30-1d37-4d66-8c71-f6875626fd92",
      "name": "OpenAI Chat Model2",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        260,
        -160
      ]
    },
    {
      "id": "03af94eb-ce5a-4bf6-931c-ffe9c793a596",
      "name": "When clicking ‘Execute workflow’",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        -340,
        -220
      ]
    },
    {
      "id": "0b2c7943-2b56-4f83-892d-2136361ed24e",
      "name": "Get Data",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        -200,
        -220
      ]
    },
    {
      "id": "10532f87-9662-4c50-a314-ecd558b57230",
      "name": "Verify number of scene",
      "type": "n8n-nodes-base.code",
      "position": [
        600,
        -220
      ]
    },
    {
      "id": "bab94a54-bc4f-4b74-a42c-7d18d2324689",
      "name": "Generate Full Narrative from Prompt",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        -60,
        -220
      ]
    },
    {
      "id": "4aa3acce-76cd-437b-938e-1daaedd3d9d7",
      "name": "Break Narrative into {{n}} Scenes",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        260,
        -220
      ]
    },
    {
      "id": "52dabb38-9c47-4e05-a52c-c45022ea4f58",
      "name": "Describe Each Scene for Video",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        -300,
        40
      ]
    },
    {
      "id": "f0ab8b68-99ee-45cc-9337-393c7cce3c37",
      "name": "Call Fal.ai API (Seedance)",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        20,
        40
      ]
    },
    {
      "id": "f3e869f9-e3b0-4854-a5ba-ea03f30d629d",
      "name": "Scene count",
      "type": "n8n-nodes-base.if",
      "position": [
        760,
        -220
      ]
    },
    {
      "id": "9b4fc0d5-6aac-45c4-bf95-ca5987af22a7",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -720,
        -240
      ],
      "parameters": {
        "width": 1840,
        "height": 240,
        "content": "### 🟨 Zone 1: Prompt Input & Story-to-Scenes\n\n1. **When clicking 'Execute workflow**\n2. **Get Data (Google Sheets)**\n3. **Generate Full Narrative from Prompt**\n4. **Break Narrative into {{n}} Scenes**"
      }
    },
    {
      "id": "0053d123-eca8-4bf0-9f39-74828c064588",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -720,
        20
      ],
      "parameters": {
        "width": 1840,
        "height": 240,
        "content": "### 🟫 Zone 2: Create Scene Prompts & Generate Video\n\n1. **Split Out**\n2. **Describe Each Scene for Video**\n3. **Call Fal.ai API (Seedance)**\n4. **Loop Over Items**\n5. **Wait for the video / Get the vi"
      }
    },
    {
      "id": "bde2f1bf-2565-4f74-93c5-0b2cddfc9b02",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -720,
        280
      ],
      "parameters": {
        "width": 780,
        "height": 400,
        "content": "### 🟥 Zone 3: Add Audio to Video with Fal AI\n1. **Start adding audio to the video**\n2. **Loop Over Items1**\n"
      }
    },
    {
      "id": "73d36aac-1900-41ac-9e48-e314bf8725cd",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        80,
        280
      ],
      "parameters": {
        "width": 1040,
        "height": 400,
        "content": "### 🟩 Zone 4: Merge Videos & Download Final Output\n\n1. **Aggregate videos with audio**\n2. **Start merging videos ffmpeg**\n3. **Wait for the merge to complete**\n4. **Get merged video**\n"
      }
    },
    {
      "id": "7a8d7f32-698e-40fd-a485-e422bacda446",
      "name": "YouTube",
      "type": "n8n-nodes-base.youTube",
      "position": [
        780,
        540
      ]
    },
    {
      "id": "1cb21431-1cb8-4170-90f4-bb4153619c6d",
      "name": "Get the  video1",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        600,
        540
      ]
    }
  ],
  "connections": {
    "Get Data": {
      "main": [
        [
          {
            "node": "Generate Full Narrative from Prompt",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out": {
      "main": [
        [
          {
            "node": "Describe Each Scene for Video",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Scene count": {
      "main": [
        [
          {
            "node": "Break Narrative into {{n}} Scenes",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Split Out",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Audio status": {
      "main": [
        [
          {
            "node": "Get video with audio",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Wait for adding the audio",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Wait for adding the audio",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Video status": {
      "main": [
        [
          {
            "node": "Get the  video",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Wait for the video",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Wait for the video",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get the  video": {
      "main": [
        [
          {
            "node": "Loop Over Items",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get the  video1": {
      "main": [
        [
          {
            "node": "YouTube",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Loop Over Items": {
      "main": [
        [
          {
            "node": "Start adding audio to the video",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Wait for the video",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get audio status": {
      "main": [
        [
          {
            "node": "Audio status",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get merged video": {
      "main": [
        [
          {
            "node": "Get the  video1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Loop Over Items1": {
      "main": [
        [
          {
            "node": "Aggregate videos with audio",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Wait for adding the audio",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "Generate Full Narrative from Prompt",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model1": {
      "ai_languageModel": [
        [
          {
            "node": "Describe Each Scene for Video",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model2": {
      "ai_languageModel": [
        [
          {
            "node": "Break Narrative into {{n}} Scenes",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Wait for the video": {
      "main": [
        [
          {
            "node": "Get the video status",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Merge videos status": {
      "main": [
        [
          {
            "node": "Get merged video",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Wait for the merge to complete",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Wait for the merge to complete",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get the video status": {
      "main": [
        [
          {
            "node": "Video status",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get video with audio": {
      "main": [
        [
          {
            "node": "Loop Over Items1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Start merging videos": {
      "main": [
        [
          {
            "node": "Wait for the merge to complete",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Verify number of scene": {
      "main": [
        [
          {
            "node": "Scene count",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get merge videos status": {
      "main": [
        [
          {
            "node": "Merge videos status",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Structured Output Parser": {
      "ai_outputParser": [
        [
          {
            "node": "Generate Full Narrative from Prompt",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "Structured Output Parser1": {
      "ai_outputParser": [
        [
          {
            "node": "Break Narrative into {{n}} Scenes",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "Structured Output Parser2": {
      "ai_outputParser": [
        [
          {
            "node": "Describe Each Scene for Video",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "Wait for adding the audio": {
      "main": [
        [
          {
            "node": "Get audio status",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Call Fal.ai API (Seedance)": {
      "main": [
        [
          {
            "node": "Loop Over Items",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Aggregate videos with audio": {
      "main": [
        [
          {
            "node": "Start merging videos",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Describe Each Scene for Video": {
      "main": [
        [
          {
            "node": "Call Fal.ai API (Seedance)",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Wait for the merge to complete": {
      "main": [
        [
          {
            "node": "Get merge videos status",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Start adding audio to the video": {
      "main": [
        [
          {
            "node": "Loop Over Items1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Break Narrative into {{n}} Scenes": {
      "main": [
        [
          {
            "node": "Verify number of scene",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Generate Full Narrative from Prompt": {
      "main": [
        [
          {
            "node": "Break Narrative into {{n}} Scenes",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "When clicking ‘Execute workflow’": {
      "main": [
        [
          {
            "node": "Get Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}