{
  "name": "Automate GPT-4o fine-tuning with Google Sheets or Airtable data",
  "nodes": [
    {
      "id": "fc478cd0-8d84-4e8a-b0d8-7b2a4bb6b65c",
      "name": "Wait",
      "type": "n8n-nodes-base.wait",
      "position": [
        1560,
        0
      ]
    },
    {
      "id": "4a6895a6-5a5c-48f2-98ea-2c6ed1d428e3",
      "name": "Schedule Trigger",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        -180,
        0
      ]
    },
    {
      "id": "dec836ff-a0fb-4b6c-9ea6-e7a383343a2b",
      "name": "Set GPT Model",
      "type": "n8n-nodes-base.set",
      "position": [
        1020,
        0
      ]
    },
    {
      "id": "f349a57b-0720-4ef1-8b0c-4d07c7908c73",
      "name": "Begin Fine-tune Job",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1300,
        0
      ]
    },
    {
      "id": "857dd175-1d8b-4b11-aabd-27a9ed9519a8",
      "name": "Upload JSONL File",
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "position": [
        740,
        0
      ]
    },
    {
      "id": "5b297840-c851-42a0-8490-6b8c2f77e6d2",
      "name": "Create JSONL File",
      "type": "n8n-nodes-base.code",
      "position": [
        440,
        0
      ]
    },
    {
      "id": "5270eae1-1218-4ef6-b423-b4267df04c2f",
      "name": "Check Fine-Tune Job",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1740,
        0
      ]
    },
    {
      "id": "3a2349ac-836a-4145-b0f9-cf1814db5180",
      "name": "If Succeeded",
      "type": "n8n-nodes-base.if",
      "position": [
        1920,
        0
      ]
    },
    {
      "id": "5ab2283c-3c25-4c4a-a786-3bb4c7c68702",
      "name": "If Failed",
      "type": "n8n-nodes-base.if",
      "position": [
        2120,
        100
      ]
    },
    {
      "id": "18b2ad15-896b-48b9-a3fd-fc10214172a2",
      "name": "Error: FAILED",
      "type": "n8n-nodes-base.stopAndError",
      "position": [
        2300,
        100
      ]
    },
    {
      "id": "992ac7d4-c889-4d5c-8359-e85f82068144",
      "name": "Add Fine-Tuned Model to Airtable",
      "type": "n8n-nodes-base.airtable",
      "position": [
        2620,
        80
      ]
    },
    {
      "id": "b0af9c97-b6e2-466d-9961-925685a6eb9d",
      "name": "Add  Fine-Tuned Model to Sheet",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        2620,
        -120
      ]
    },
    {
      "id": "abd193e2-472b-4bee-a4d5-8d78327eebe9",
      "name": "Get Examples from Sheet",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        120,
        -100
      ]
    },
    {
      "id": "cc556207-aa3f-4eaa-a8f6-1bec94c055fc",
      "name": "Get Examples from Airtable",
      "type": "n8n-nodes-base.airtable",
      "position": [
        120,
        120
      ]
    },
    {
      "id": "3d97f4cf-135c-49ba-b47c-43bfdf7ebb18",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -220,
        -280
      ],
      "parameters": {
        "width": null,
        "height": null,
        "content": ""
      }
    },
    {
      "id": "06bc45b5-f279-4154-b3a5-bc7690019a64",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        360,
        -280
      ],
      "parameters": {
        "width": null,
        "height": null,
        "content": ""
      }
    },
    {
      "id": "8d11924b-c641-40e7-8b0b-fee2db50a9c7",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        940,
        -280
      ],
      "parameters": {
        "width": null,
        "height": null,
        "content": ""
      }
    },
    {
      "id": "bad9fdb4-b769-48f2-9335-3b1a3a2236f5",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1500,
        -280
      ],
      "parameters": {
        "width": null,
        "height": null,
        "content": ""
      }
    },
    {
      "id": "2cce770f-eb21-4c86-8a19-16a2c0e37f2b",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2480,
        -280
      ],
      "parameters": {
        "width": null,
        "height": null,
        "content": ""
      }
    }
  ],
  "connections": {
    "Wait": {
      "main": [
        [
          {
            "node": "Check Fine-Tune Job",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "If Failed": {
      "main": [
        [
          {
            "node": "Error: FAILED",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Wait",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "If Succeeded": {
      "main": [
        [
          {
            "node": "Add Fine-Tuned Model to Airtable",
            "type": "main",
            "index": 0
          },
          {
            "node": "Add  Fine-Tuned Model to Sheet",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "If Failed",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Set GPT Model": {
      "main": [
        [
          {
            "node": "Begin Fine-tune Job",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Schedule Trigger": {
      "main": [
        [
          {
            "node": "Get Examples from Sheet",
            "type": "main",
            "index": 0
          },
          {
            "node": "Get Examples from Airtable",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create JSONL File": {
      "main": [
        [
          {
            "node": "Upload JSONL File",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Upload JSONL File": {
      "main": [
        [
          {
            "node": "Set GPT Model",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Begin Fine-tune Job": {
      "main": [
        [
          {
            "node": "Wait",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Check Fine-Tune Job": {
      "main": [
        [
          {
            "node": "If Succeeded",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Examples from Sheet": {
      "main": [
        [
          {
            "node": "Create JSONL File",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Examples from Airtable": {
      "main": [
        [
          {
            "node": "Create JSONL File",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}