{
  "name": "Hackathon CP3 - Slack Summary on Done",
  "nodes": [
    {
      "parameters": {},
      "id": "c60af19e-c90c-44b2-aae1-0f0d55cc1fe3",
      "name": "When Tested",
      "type": "n8n-nodes-base.manualTrigger",
      "typeVersion": 1,
      "position": [
        0,
        304
      ]
    },
    {
      "parameters": {
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1onDtz4TeM0SmJD7-QCV_QzCJXyQptbt4YnAAbwJaew4",
          "cachedResultName": "Jobs - Hackathon Sample"
        },
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "921304816",
          "cachedResultName": "Jobs"
        },
        "options": {}
      },
      "id": "8a8851e6-d1c4-44ab-ba1f-a82b284a2005",
      "name": "Read Jobs from Sheet",
      "type": "n8n-nodes-base.googleSheets",
      "typeVersion": 4.7,
      "position": [
        224,
        304
      ],
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "LgZBokt9Y0FRPq87",
          "name": "Google Sheets account"
        }
      }
    },
    {
      "parameters": {
        "maxItems": 3
      },
      "id": "0eb58c1f-85c2-409a-8eec-8f6fc746638d",
      "name": "Limit to First 3 (Demo Cap)",
      "type": "n8n-nodes-base.limit",
      "typeVersion": 1,
      "position": [
        448,
        304
      ]
    },
    {
      "parameters": {
        "assignments": {
          "assignments": [
            {
              "id": "s1",
              "name": "reviewed_count",
              "type": "number",
              "value": "={{ $('Limit to First 3 (Demo Cap)').all().length }}"
            },
            {
              "id": "s2",
              "name": "summary_message",
              "type": "string",
              "value": "=:white_check_mark: *Job Review Complete*\n\nReviewed *{{ $('Limit to First 3 (Demo Cap)').all().length }}* job postings. The AI notes have been written back to the sheet.\n\n:link: <https://docs.google.com/spreadsheets/d/1onDtz4TeM0SmJD7-QCV_QzCJXyQptbt4YnAAbwJaew4/edit?gid=921304816|Open the reviewed jobs sheet>"
            }
          ]
        },
        "options": {}
      },
      "id": "4b8a9cf9-f758-47cb-afa0-1b17290baf0a",
      "name": "Compose Summary Message",
      "type": "n8n-nodes-base.set",
      "typeVersion": 3.4,
      "position": [
        896,
        0
      ]
    },
    {
      "parameters": {
        "select": "user",
        "user": {
          "__rl": true,
          "mode": "id",
          "value": ""
        },
        "text": "={{ $json.summary_message }}",
        "otherOptions": {
          "includeLinkToWorkflow": false,
          "mrkdwn": true
        }
      },
      "id": "b2687582-7683-4035-9b97-c9ede8884909",
      "name": "DM Summary to Yourself",
      "type": "n8n-nodes-base.slack",
      "typeVersion": 2.4,
      "position": [
        1184,
        0
      ],
      "webhookId": "1e7f770c-f18f-4dda-aa29-c274c40911ff"
    },
    {
      "parameters": {
        "amount": 2
      },
      "id": "1cb6d267-dbbc-44dc-a0df-2ec522da4171",
      "name": "Throttle (Respect API Limits)",
      "type": "n8n-nodes-base.wait",
      "typeVersion": 1.1,
      "position": [
        896,
        304
      ],
      "webhookId": "a3f39a39-cfe3-4c05-b93a-6426debb7bbf"
    },
    {
      "parameters": {
        "promptType": "define",
        "text": "=You are a senior recruiter reviewing a job posting before it goes live on Indeed.\nWrite a single concise review note (4-7 sentences, plain prose, no bullets, no JSON, no markdown headers)\ncovering exactly these points in this order:\n\n1. Salary realism. Is the pay range realistic for this role and location? If not, say why and suggest a realistic range.\n2. Inclusive language. Flag any discriminatory or non-inclusive wording. Quote the phrase if found. If clean, say \"Language looks inclusive.\"\n3. Description quality. Suggest one specific improvement.\n4. End with: \"Top qualifications: X, Y, Z.\"\n\nBe direct and constructive. Do not hedge.\n\nJob Title: {{ $('Loop Over Jobs').item.json['Job Title'] }}\nCompany: {{ $('Loop Over Jobs').item.json.Company }}\nLocation: {{ $('Loop Over Jobs').item.json.Location }}\nPay Range: {{ $('Loop Over Jobs').item.json['Pay Range'] }}\nDescription: {{ $('Loop Over Jobs').item.json['Job Description'] }}",
        "batching": {}
      },
      "id": "6838bc54-c2c4-4246-b897-680165d4487e",
      "name": "Review Job with AI",
      "type": "@n8n/n8n-nodes-langchain.chainLlm",
      "typeVersion": 1.9,
      "position": [
        1120,
        304
      ]
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-5-mini",
          "cachedResultName": "gpt-5-mini"
        },
        "builtInTools": {},
        "options": {
          "temperature": 0.3
        }
      },
      "id": "05dfab1f-4ed6-4b4c-9c7b-4d35f8913ed1",
      "name": "OpenAI Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.3,
      "position": [
        1200,
        528
      ],
      "credentials": {
        "openAiApi": {
          "id": "eF2vCCF9GqRUBBR7",
          "name": "OpenAI account"
        }
      }
    },
    {
      "parameters": {
        "assignments": {
          "assignments": [
            {
              "id": "a1",
              "name": "Job Title",
              "type": "string",
              "value": "={{ $('Loop Over Jobs').item.json['Job Title'] }}"
            },
            {
              "id": "a2",
              "name": "AI Note",
              "type": "string",
              "value": "={{ $json.text }}"
            }
          ]
        },
        "options": {}
      },
      "id": "854e8ca0-e6b5-44ef-99ba-9bad1cfc1799",
      "name": "Compose AI Note",
      "type": "n8n-nodes-base.set",
      "typeVersion": 3.4,
      "position": [
        1472,
        304
      ]
    },
    {
      "parameters": {
        "operation": "update",
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1onDtz4TeM0SmJD7-QCV_QzCJXyQptbt4YnAAbwJaew4",
          "cachedResultName": "Jobs - Hackathon Sample"
        },
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "921304816",
          "cachedResultName": "Jobs"
        },
        "columns": {
          "mappingMode": "defineBelow",
          "value": {
            "Job Title": "={{ $json['Job Title'] }}",
            "AI Note": "={{ $json['AI Note'] }}"
          },
          "matchingColumns": [
            "Job Title"
          ]
        },
        "options": {}
      },
      "id": "d6b13db0-ac26-488f-9e5d-d7bf3e7b5832",
      "name": "Write AI Note Back to Sheet",
      "type": "n8n-nodes-base.googleSheets",
      "typeVersion": 4.7,
      "position": [
        1696,
        416
      ],
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "LgZBokt9Y0FRPq87",
          "name": "Google Sheets account"
        }
      }
    },
    {
      "parameters": {
        "options": {}
      },
      "id": "db4ada2c-8d7c-43bc-ba22-5d69c4961559",
      "name": "Loop Over Jobs",
      "type": "n8n-nodes-base.splitInBatches",
      "typeVersion": 3,
      "position": [
        672,
        304
      ]
    },
    {
      "parameters": {
        "content": "## Checkpoint 3: Slack Summary on Done\n\n**Goal:** receive **one** Slack DM at the end summarizing how many job postings were reviewed, with a link back to the sheet.\n\n**What changed since CP2:** wired the loop's **done** branch to a Set + Slack DM. Production pattern (digest after batch) instead of demo theater (DM per item).",
        "height": 200,
        "width": 1980,
        "color": 5
      },
      "id": "0c4b9411-04e0-4ae3-9297-cd2b859f4b9a",
      "name": "Sticky - Overview",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        -96,
        -560
      ]
    },
    {
      "parameters": {
        "content": "**Manual Trigger**\n\nClick *Test workflow* to run.",
        "height": 188,
        "width": 220,
        "color": 3
      },
      "id": "8fb6b843-34b1-4cdd-b308-04d2fabf8fd8",
      "name": "Sticky - Trigger",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        -48,
        672
      ]
    },
    {
      "parameters": {
        "content": "**Read Jobs**\n\nReads every row from your copy of the jobs sheet.",
        "height": 188,
        "width": 220,
        "color": 6
      },
      "id": "9e4b93b5-42e0-4ac1-a5a8-f20199befd7a",
      "name": "Sticky - Read Jobs",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        192,
        672
      ]
    },
    {
      "parameters": {
        "content": "**Limit (Demo Cap)**\n\nFirst **3** rows only.\n\nThe summary count downstream reads `length` from this node.",
        "height": 260,
        "width": 220,
        "color": 4
      },
      "id": "e7d49577-98e1-42a3-b873-1f56108799f7",
      "name": "Sticky - Limit",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        432,
        672
      ]
    },
    {
      "parameters": {
        "content": "**Loop Over Items - Both Outputs Used Now!**\n\n*loop* (top right) -> per-row branch: Wait -> LLM -> Set -> Sheet update -> next row.\n\n*done* (bottom right) -> fires once after every row is processed -> Set + Slack summary. **This is the new bit.**",
        "height": 256,
        "width": 208
      },
      "id": "46f9014e-6049-45c4-a718-bfe8fb02d3b7",
      "name": "Sticky - Loop",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        672,
        672
      ]
    },
    {
      "parameters": {
        "content": "**Done Branch (NEW)**\n\nFires **once** when the loop finishes.\n\n**Compose Summary** builds the Slack text using `$('Limit to First 3 (Demo Cap)').all().length` to count the rows we reviewed.\n\n**DM Summary** sends one DM to your Slack with the count and a link to the sheet. Fill in your **Slack Member ID** and connect the Slack credential.",
        "height": 216,
        "width": 480,
        "color": 4
      },
      "id": "acf801db-2143-4f79-b2b5-c4cf5ba8bc64",
      "name": "Sticky - Done Branch",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        880,
        -256
      ]
    },
    {
      "parameters": {
        "content": "**Set (Compose AI Note)**\n\nPulls `{{ $json.text }}` from the LLM as the AI Note.\n\n`Job Title` references `$( \"Loop Over Jobs\" ).item` so the Sheet update knows which row to match.",
        "height": 200,
        "color": 3
      },
      "id": "252317ec-4a89-48b0-a5ad-65ee9557fd5a",
      "name": "Sticky - Set",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        1392,
        672
      ]
    },
    {
      "parameters": {
        "content": "**Write AI Note Back**\n\nMatches by **Job Title**, writes the AI note into the **AI Note** column.",
        "height": 192,
        "width": 220,
        "color": 6
      },
      "id": "90f25d4d-8541-4f9e-b7d2-e2fdea43c833",
      "name": "Sticky - Write Back",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        1648,
        672
      ]
    },
    {
      "parameters": {
        "content": "**Basic LLM Chain**\n\nUses the **Hackathon 2026** OpenAI credential.\n\nHuman-readable prompt, no parser. Called once per row inside the loop.",
        "height": 200,
        "color": 6
      },
      "id": "d06001d7-55cd-424c-8a04-94721f4ea062",
      "name": "Sticky - LLM",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        1136,
        672
      ]
    },
    {
      "parameters": {
        "content": "**Avoid the Structured Output Parser** for production. Indeed recommends the HTTP Request node against the LLM proxy with a JSON schema. See the wiki link on the next slide."
      },
      "id": "a28148db-74eb-441f-824b-a90c2bf90f85",
      "name": "Sticky - Parser Warning",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        1136,
        896
      ]
    },
    {
      "parameters": {
        "content": "**Wait**\n\nPauses 2 seconds between rows.\n\nWith 300 people running this at once, the OpenAI proxy can throttle. Wait is your good citizen tax.",
        "height": 184,
        "width": 220,
        "color": 3
      },
      "id": "6fe8e8f5-7bbb-4da8-9ccc-87485b3d4fd2",
      "name": "Sticky - Wait",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        896,
        672
      ]
    }
  ],
  "pinData": {},
  "connections": {
    "When Tested": {
      "main": [
        [
          {
            "node": "Read Jobs from Sheet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Read Jobs from Sheet": {
      "main": [
        [
          {
            "node": "Limit to First 3 (Demo Cap)",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Limit to First 3 (Demo Cap)": {
      "main": [
        [
          {
            "node": "Loop Over Jobs",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Compose Summary Message": {
      "main": [
        [
          {
            "node": "DM Summary to Yourself",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Throttle (Respect API Limits)": {
      "main": [
        [
          {
            "node": "Review Job with AI",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Review Job with AI": {
      "main": [
        [
          {
            "node": "Compose AI Note",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Model": {
      "ai_languageModel": [
        [
          {
            "node": "Review Job with AI",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Compose AI Note": {
      "main": [
        [
          {
            "node": "Write AI Note Back to Sheet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Write AI Note Back to Sheet": {
      "main": [
        [
          {
            "node": "Loop Over Jobs",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Loop Over Jobs": {
      "main": [
        [
          {
            "node": "Compose Summary Message",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Throttle (Respect API Limits)",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "active": false,
  "settings": {
    "executionOrder": "v1",
    "binaryMode": "separate",
    "availableInMCP": true
  },
  "versionId": "37f45ee3-4231-4f8d-a15b-9b42c8c59fa4",
  "meta": {
    "aiBuilderAssisted": true,
    "builderVariant": "mcp",
    "instanceId": "61d1ceb8b60d551b2bd6cb318774870200f11403fbfe4e124bc9e07f08b20486"
  },
  "id": "bxGpnJNzXWU9RPzc",
  "tags": [
    {
      "updatedAt": "2026-05-03T08:51:16.018Z",
      "createdAt": "2026-05-03T08:51:16.018Z",
      "id": "FUFolilclluqXrmj",
      "name": "Indeed Hackathon"
    }
  ]
}