{
  "name": "OpenAI examples: ChatGPT, DALLE-2, Whisper-1 – 5-in-1",
  "nodes": [
    {
      "id": "ad6dc2cd-21cc-4563-86ba-f78cc4a55543",
      "name": "When clicking \"Execute Workflow\"",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        -640,
        380
      ]
    },
    {
      "id": "b370da23-ead4-4221-b7fe-a9d943f7fbb9",
      "name": "davinci-003-complete",
      "type": "n8n-nodes-base.openAi",
      "position": [
        1160,
        60
      ]
    },
    {
      "id": "5e04f355-36c0-4540-8e65-68118cb73135",
      "name": "ChatGPT-ex2",
      "type": "n8n-nodes-base.openAi",
      "position": [
        1160,
        740
      ]
    },
    {
      "id": "16a7cf80-16e3-44f9-b15c-7501417fe38f",
      "name": "davinci-003-edit",
      "type": "n8n-nodes-base.openAi",
      "position": [
        1340,
        60
      ]
    },
    {
      "id": "95254870-65c3-4714-83fb-20ba2c0ca007",
      "name": "ChatGPT-ex1.1",
      "type": "n8n-nodes-base.openAi",
      "position": [
        1160,
        380
      ]
    },
    {
      "id": "be9c4820-18b0-46fd-a5a0-51a5dc3ebed5",
      "name": "ChatGPT-ex1.2",
      "type": "n8n-nodes-base.openAi",
      "position": [
        1340,
        380
      ]
    },
    {
      "id": "c52c875b-5270-44ac-bfca-ce25124e3d04",
      "name": "Text-example",
      "type": "n8n-nodes-base.code",
      "position": [
        540,
        380
      ]
    },
    {
      "id": "45d3bad7-0e9a-426b-b4e9-b3568181d9dc",
      "name": "Code-ex3.1",
      "type": "n8n-nodes-base.code",
      "position": [
        1160,
        1100
      ]
    },
    {
      "id": "4db3de05-51a7-46ea-a818-508bdcb04582",
      "name": "ChatGPT-ex3.1",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1340,
        1100
      ]
    },
    {
      "id": "709fcd7c-deb3-469d-b16b-62d4d36d100d",
      "name": "ChatGPT-ex3.2",
      "type": "n8n-nodes-base.openAi",
      "position": [
        1880,
        1100
      ]
    },
    {
      "id": "6b32cc45-5ba2-4605-b690-3929ec9acecf",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        900,
        -60
      ],
      "parameters": {
        "width": 746.6347949130579,
        "height": 295.50954755505853,
        "content": "## The old way of using text completion and text edit\n### Davinci model is 10 times more expensive then ChatGPT, consider switching to the new API:\nhttps://openai.com/blog/introducing-chatgpt-and-whis"
      }
    },
    {
      "id": "3cc74d77-7b02-40fd-83d8-f540d5ff34ab",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -160,
        260
      ],
      "parameters": {
        "width": 428.4578974150008,
        "height": 316.6202633391793,
        "content": "## Whisper-1 example\n### Prepare your audio file and send it to whisper-1 transcription model"
      }
    },
    {
      "id": "6ba8069a-485c-497c-8b27-4c7562fbccab",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        380,
        280
      ],
      "parameters": {
        "width": 421.9002034748082,
        "height": 302.4086532331564,
        "content": "## An example of transcribed text\n### Please pause this node when using real audio files"
      }
    },
    {
      "id": "c71001e6-b80f-41dd-bcdd-10927014b374",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        900,
        280
      ],
      "parameters": {
        "width": 747.8556016477869,
        "height": 288.18470714667706,
        "content": "## ChatGPT example 1.1 and 1.2 \n### Write a Tl;dr of the text input\n### Translate it to German\n### only user content provided"
      }
    },
    {
      "id": "4605be68-4c57-404f-8624-e095c8e86ff9",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        900,
        620
      ],
      "parameters": {
        "width": 742.9723747088658,
        "height": 288.18470714667706,
        "content": "## ChatGPT example 2 \n### Use system content to provide general instruction\n### Manual setup of system and user content"
      }
    },
    {
      "id": "f5b72d7a-655a-4cc9-b722-b75429889d1d",
      "name": "Sticky Note5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        900,
        960
      ],
      "parameters": {
        "width": 739.309954504675,
        "height": 288.18470714667706,
        "content": "## ChatGPT example 3.1\n### When using ChatGPT programmatically, create an array of system / user / assistant contents and append them one after another\n### Call ChatGPT API via HTTP Request node to pr"
      }
    },
    {
      "id": "a003a4db-1960-4867-8dfe-3114cf0742f3",
      "name": "DALLE-ex3.3",
      "type": "n8n-nodes-base.openAi",
      "position": [
        2060,
        1100
      ]
    },
    {
      "id": "d71a01ff-4d47-4675-964c-c47820d3989b",
      "name": "Sticky Note6",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1720,
        960
      ],
      "parameters": {
        "width": 611.1252473579985,
        "height": 284.52228694248623,
        "content": "## ChatGPT example 3.2 & DALLE-2 example 3.3\n### Use ChatGPT to create a prompt for a cover image of the Tl;dr message\n### Use OpenAI node to generate 4 images using the auto-generated prompt"
      }
    },
    {
      "id": "f5a55cfe-c110-4833-9668-1f1ba895860f",
      "name": "ChatGPT-ex4",
      "type": "n8n-nodes-base.openAi",
      "position": [
        1240,
        1420
      ]
    },
    {
      "id": "8a9f7a20-187c-4494-8005-b10d066d04e2",
      "name": "Set-ex4",
      "type": "n8n-nodes-base.set",
      "position": [
        1060,
        1420
      ]
    },
    {
      "id": "68fcc6a2-761c-42ac-8778-313c8db7d53c",
      "name": "HTML-ex4",
      "type": "n8n-nodes-base.html",
      "position": [
        1420,
        1420
      ]
    },
    {
      "id": "1f70cf3f-b6a9-4ea7-9486-c7565e6951b7",
      "name": "Sticky Note7",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        900,
        1300
      ],
      "parameters": {
        "width": 739.309954504675,
        "height": 288.18470714667706,
        "content": "## ChatGPT example 4\n### Generate HTML code that contains SVG image"
      }
    },
    {
      "id": "d857acd9-ea74-44d2-ac89-66b1fac4645f",
      "name": "Sticky Note8",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        900,
        1640
      ],
      "parameters": {
        "width": 739.309954504675,
        "height": 288.18470714667706,
        "content": "## ChatGPT example 5\n### Provide several outputs. Useful for quick replies (i.e. in Gmail / Outlook)"
      }
    },
    {
      "id": "fe64533a-4cd4-4adc-a48a-8abf3f2d61d7",
      "name": "ChatGPT-ex",
      "type": "n8n-nodes-base.openAi",
      "position": [
        1160,
        1760
      ]
    },
    {
      "id": "6c9f8a70-99ae-4310-8e6a-26cc6f75b3a2",
      "name": "LoadMP3",
      "type": "n8n-nodes-base.readBinaryFiles",
      "position": [
        -80,
        380
      ]
    },
    {
      "id": "0edc1996-6484-4e62-a47b-5666dfbb3546",
      "name": "Whisper-transcribe",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        100,
        380
      ]
    },
    {
      "id": "c12ba294-bdcd-4ece-8370-fa6a83a8ef0b",
      "name": "Sticky Note9",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -840,
        260
      ],
      "parameters": {
        "width": 596.9600747621192,
        "height": 320.63203364295396,
        "content": "## Do not run the whole workflow, it's rather slow\n### Better execute the last node of each branch or simply disconnect branches that are not needed"
      }
    }
  ],
  "connections": {
    "LoadMP3": {
      "main": [
        [
          {
            "node": "Whisper-transcribe",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Set-ex4": {
      "main": [
        [
          {
            "node": "ChatGPT-ex4",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Code-ex3.1": {
      "main": [
        [
          {
            "node": "ChatGPT-ex3.1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "ChatGPT-ex4": {
      "main": [
        [
          {
            "node": "HTML-ex4",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Text-example": {
      "main": [
        [
          {
            "node": "davinci-003-complete",
            "type": "main",
            "index": 0
          },
          {
            "node": "ChatGPT-ex1.1",
            "type": "main",
            "index": 0
          },
          {
            "node": "ChatGPT-ex2",
            "type": "main",
            "index": 0
          },
          {
            "node": "Code-ex3.1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "ChatGPT-ex1.1": {
      "main": [
        [
          {
            "node": "ChatGPT-ex1.2",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "ChatGPT-ex3.1": {
      "main": [
        [
          {
            "node": "ChatGPT-ex3.2",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "ChatGPT-ex3.2": {
      "main": [
        [
          {
            "node": "DALLE-ex3.3",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Whisper-transcribe": {
      "main": [
        [
          {
            "node": "Text-example",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "davinci-003-complete": {
      "main": [
        [
          {
            "node": "davinci-003-edit",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "When clicking \"Execute Workflow\"": {
      "main": [
        [
          {
            "node": "LoadMP3",
            "type": "main",
            "index": 0
          },
          {
            "node": "Set-ex4",
            "type": "main",
            "index": 0
          },
          {
            "node": "ChatGPT-ex",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}