{
  "name": "Turn any website into an AI support chatbot with OpenAI and Pinecone",
  "nodes": [
    {
      "id": "8ecff878-cb1f-4e9c-98a0-3727269aee97",
      "name": "When clicking ‘Execute workflow’",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        -1904,
        208
      ]
    },
    {
      "id": "23adecea-f54b-49c7-8ac6-75df99bcc469",
      "name": "Embeddings OpenAI",
      "type": "@n8n/n8n-nodes-langchain.embeddingsOpenAi",
      "position": [
        592,
        384
      ]
    },
    {
      "id": "673fa27a-9f5d-4a3c-8807-64c26aaaa576",
      "name": "Map Website URLs",
      "type": "@mendable/n8n-nodes-firecrawl.firecrawl",
      "position": [
        -1632,
        208
      ]
    },
    {
      "id": "d17427ae-ce8c-4015-af2d-c20a44acc11c",
      "name": "Filter and Normalize URLs",
      "type": "n8n-nodes-base.code",
      "position": [
        -1296,
        208
      ]
    },
    {
      "id": "bd51e7d4-485c-4759-b4f1-63b2d1219c35",
      "name": "Process URLs One by One",
      "type": "n8n-nodes-base.splitInBatches",
      "position": [
        -960,
        208
      ]
    },
    {
      "id": "37897ec6-0cb2-481a-a7ad-15046192720d",
      "name": "Fetch Page Content",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -624,
        128
      ]
    },
    {
      "id": "ddca10bf-eaca-47a3-8a8a-64ad2e247bfc",
      "name": "Extract HTML and URL",
      "type": "n8n-nodes-base.set",
      "position": [
        -368,
        128
      ]
    },
    {
      "id": "e5da4265-7bb0-4b01-b6dd-97ede548b7c3",
      "name": "Clean HTML to Text",
      "type": "n8n-nodes-base.code",
      "position": [
        -176,
        128
      ]
    },
    {
      "id": "f5c3ea61-c855-47e2-9110-3242ca6c0ce3",
      "name": "Check Text Length",
      "type": "n8n-nodes-base.if",
      "position": [
        48,
        128
      ]
    },
    {
      "id": "ba89389e-2dcc-4aa1-8f2a-7746641df62c",
      "name": "Split Text into Chunks",
      "type": "n8n-nodes-base.code",
      "position": [
        272,
        112
      ]
    },
    {
      "id": "a9947307-f9f7-4280-860f-a9f18c81e530",
      "name": "Store in Vector Database",
      "type": "@n8n/n8n-nodes-langchain.vectorStorePinecone",
      "position": [
        624,
        192
      ]
    },
    {
      "id": "faeb8ce7-2e62-4782-840c-fde4f70d1be0",
      "name": "Document Loader",
      "type": "@n8n/n8n-nodes-langchain.documentDefaultDataLoader",
      "position": [
        784,
        400
      ]
    },
    {
      "id": "f13244de-8266-41a1-a918-474ab0021376",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -2720,
        0
      ],
      "parameters": {
        "width": 592,
        "height": 688,
        "content": "## Turn any website into an AI‑powered customer‑support chatbot (Open AI + Pinecone)\n\n### How it works\n1️⃣ **Discover URLs** – Firecrawl reads the sitemap (including sub‑domains) and returns every pag"
      }
    },
    {
      "id": "18ac8782-ba5b-41e6-b45c-161b329c1b7f",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1696,
        80
      ],
      "parameters": {
        "width": null,
        "height": 304,
        "content": "URL Discovery – Firecrawl reads the sitemap (including sub‑domains) and returns every page URL.\n"
      }
    },
    {
      "id": "026d9947-3d50-40f3-a6fd-369101cde755",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1376,
        80
      ],
      "parameters": {
        "width": 560,
        "height": 304,
        "content": "## URL Cleaning & Batching\nJavaScript removes press‑blog, newsletter, assets‑vault, .xml files, trailing slashes and duplicate URLs. \n\nThen SplitInBatches processes the list one‑by‑one.\n"
      }
    },
    {
      "id": "27cd19ce-584d-4f2a-9cf3-af3e6c7644d8",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -704,
        48
      ],
      "parameters": {
        "width": 672,
        "height": 240,
        "content": "Page Fetch & Text Extraction – HTTP request gets the HTML, a Set node normalises fields, and a small JS step strips script/style tags and converts the markup to plain readable text.\n"
      }
    },
    {
      "id": "0d1813dd-26c7-4db4-98b0-07bece863767",
      "name": "When chat message received",
      "type": "@n8n/n8n-nodes-langchain.chatTrigger",
      "position": [
        -1856,
        752
      ]
    },
    {
      "id": "c8283ada-3684-4a1e-b26b-f7c341730c83",
      "name": "Chat Memory",
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "position": [
        -1504,
        976
      ]
    },
    {
      "id": "953a61ab-99c4-437d-b180-9656dfc9ccc6",
      "name": "Customer Support Agent",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        -1600,
        752
      ]
    },
    {
      "id": "a7128a69-d4f9-43e2-af49-3c6b903a0719",
      "name": "OpenAI Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        -1600,
        1168
      ]
    },
    {
      "id": "f1b6383c-14c4-4562-b89f-3c50715e5fca",
      "name": "OpenAI Embeddings",
      "type": "@n8n/n8n-nodes-langchain.embeddingsOpenAi",
      "position": [
        -1328,
        1152
      ]
    },
    {
      "id": "829e903c-08f8-433f-9650-456e3f267f14",
      "name": "Pinecone Vector Storage",
      "type": "@n8n/n8n-nodes-langchain.vectorStorePinecone",
      "position": [
        -1376,
        976
      ]
    },
    {
      "id": "4a195c24-4dbe-47d4-8f0d-9bd64630f55a",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        224,
        -16
      ],
      "parameters": {
        "width": 688,
        "height": 528,
        "content": "## Chunking & Embedding\n\nIf the cleaned text > 50 chars it is split into 1 000‑char chunks (200‑char overlap). Each chunk is sent to OpenAI embeddings and up‑serted into Pinecone.\n"
      }
    }
  ],
  "connections": {
    "Chat Memory": {
      "ai_memory": [
        [
          {
            "node": "Customer Support Agent",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "Document Loader": {
      "ai_document": [
        [
          {
            "node": "Store in Vector Database",
            "type": "ai_document",
            "index": 0
          }
        ]
      ]
    },
    "Map Website URLs": {
      "main": [
        [
          {
            "node": "Filter and Normalize URLs",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Check Text Length": {
      "main": [
        [
          {
            "node": "Split Text into Chunks",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Embeddings OpenAI": {
      "ai_embedding": [
        [
          {
            "node": "Store in Vector Database",
            "type": "ai_embedding",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "Customer Support Agent",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Embeddings": {
      "ai_embedding": [
        [
          {
            "node": "Pinecone Vector Storage",
            "type": "ai_embedding",
            "index": 0
          }
        ]
      ]
    },
    "Clean HTML to Text": {
      "main": [
        [
          {
            "node": "Check Text Length",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Fetch Page Content": {
      "main": [
        [
          {
            "node": "Extract HTML and URL",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract HTML and URL": {
      "main": [
        [
          {
            "node": "Clean HTML to Text",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Text into Chunks": {
      "main": [
        [
          {
            "node": "Store in Vector Database",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Pinecone Vector Storage": {
      "ai_tool": [
        [
          {
            "node": "Customer Support Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Process URLs One by One": {
      "main": [
        [],
        [
          {
            "node": "Fetch Page Content",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Store in Vector Database": {
      "main": [
        [
          {
            "node": "Process URLs One by One",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Filter and Normalize URLs": {
      "main": [
        [
          {
            "node": "Process URLs One by One",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "When chat message received": {
      "main": [
        [
          {
            "node": "Customer Support Agent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "When clicking ‘Execute workflow’": {
      "main": [
        [
          {
            "node": "Map Website URLs",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}