{
  "name": "Build an All-Source Knowledge Assistant with Claude, RAG, Perplexity, and Drive",
  "nodes": [
    {
      "id": "ac90ca65-d732-4358-873a-1275a373bc51",
      "name": "When chat message received",
      "type": "@n8n/n8n-nodes-langchain.chatTrigger",
      "position": [
        160,
        0
      ]
    },
    {
      "id": "9ba4a3b5-5f26-4fe5-a6bd-0ba642d606dd",
      "name": "Postgres Chat Memory",
      "type": "@n8n/n8n-nodes-langchain.memoryPostgresChat",
      "position": [
        416,
        352
      ]
    },
    {
      "id": "46afb445-8969-4589-8168-6371859c33cd",
      "name": "Embeddings OpenAI",
      "type": "@n8n/n8n-nodes-langchain.embeddingsOpenAi",
      "position": [
        1136,
        560
      ]
    },
    {
      "id": "3afefc1e-e9ca-48ca-be50-288da37e3ac3",
      "name": "Reranker Cohere",
      "type": "@n8n/n8n-nodes-langchain.rerankerCohere",
      "position": [
        1296,
        560
      ]
    },
    {
      "id": "c4773b42-0af6-40d0-8700-f13e35c7d446",
      "name": "Anthropic Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatAnthropic",
      "position": [
        240,
        352
      ]
    },
    {
      "id": "98588524-2d9d-473f-b3be-94cc6cd2ccce",
      "name": "structured data",
      "type": "n8n-nodes-base.postgresTool",
      "position": [
        848,
        416
      ]
    },
    {
      "id": "fab6ed46-4d14-4c88-9bce-4e013ef4ac54",
      "name": "General knowledge",
      "type": "@n8n/n8n-nodes-langchain.vectorStoreSupabase",
      "position": [
        1168,
        400
      ]
    },
    {
      "id": "42e3436f-8f91-4ef0-a110-8ed6c8476758",
      "name": "When clicking ‘Execute workflow’",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        144,
        -688
      ]
    },
    {
      "id": "40f20edf-04f5-42b3-9bbb-05bb649909bf",
      "name": "Download file",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        352,
        -688
      ]
    },
    {
      "id": "40f0eb51-de45-49bc-b05d-23bc5876e936",
      "name": "Default Data Loader1",
      "type": "@n8n/n8n-nodes-langchain.documentDefaultDataLoader",
      "position": [
        704,
        -464
      ]
    },
    {
      "id": "de72b0ca-7f48-46dd-9220-f2406ee8070c",
      "name": "Recursive Character Text Splitter1",
      "type": "@n8n/n8n-nodes-langchain.textSplitterRecursiveCharacterTextSplitter",
      "position": [
        784,
        -256
      ]
    },
    {
      "id": "fd2df44b-12e9-40f2-a0e7-29e914c101bf",
      "name": "Add to Supabase Vector DB",
      "type": "@n8n/n8n-nodes-langchain.vectorStoreSupabase",
      "position": [
        592,
        -688
      ]
    },
    {
      "id": "c6831a2b-cbb5-4912-8974-b82f8775d4e7",
      "name": "Embeddings OpenAI1",
      "type": "@n8n/n8n-nodes-langchain.embeddingsOpenAi",
      "position": [
        576,
        -464
      ]
    },
    {
      "id": "eb4b1d52-5b49-42d1-b65d-881c23d549da",
      "name": "Think",
      "type": "@n8n/n8n-nodes-langchain.toolThink",
      "position": [
        576,
        352
      ]
    },
    {
      "id": "425e6a03-b840-44d3-bd9e-b414f4dcfa8f",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1664,
        -48
      ],
      "parameters": {
        "width": 380,
        "height": 100,
        "content": "### Always Authenticate Your Server!\nBefore going to production, it's always advised to enable authentication on your MCP server trigger."
      }
    },
    {
      "id": "1f269b19-3bb3-4bc4-9eb5-e46b8a50bf77",
      "name": "When Executed by Another Workflow",
      "type": "n8n-nodes-base.executeWorkflowTrigger",
      "position": [
        2112,
        448
      ]
    },
    {
      "id": "9d2d569d-366a-47a8-8919-8ee100bbe11d",
      "name": "Google Drive MCP Server",
      "type": "@n8n/n8n-nodes-langchain.mcpTrigger",
      "position": [
        1712,
        64
      ]
    },
    {
      "id": "bd3b79b3-3080-4e72-8091-5baaa1f17388",
      "name": "Download File1",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        2464,
        448
      ]
    },
    {
      "id": "c6e7ed75-10b7-4be6-b398-0c5172daf9f9",
      "name": "FileType",
      "type": "n8n-nodes-base.switch",
      "position": [
        2656,
        400
      ]
    },
    {
      "id": "af4a67ae-e328-4aa8-80fe-104ef97db2e0",
      "name": "Operation",
      "type": "n8n-nodes-base.switch",
      "position": [
        2288,
        448
      ]
    },
    {
      "id": "9097988d-c8a4-47d3-a202-7108e967087d",
      "name": "Extract from PDF",
      "type": "n8n-nodes-base.extractFromFile",
      "position": [
        2928,
        160
      ]
    },
    {
      "id": "884950de-d4d6-4c86-b56c-c97dbc54e9aa",
      "name": "Extract from CSV",
      "type": "n8n-nodes-base.extractFromFile",
      "position": [
        2928,
        352
      ]
    },
    {
      "id": "04d9c541-5f77-4891-bef8-e2fb7b6a4fa7",
      "name": "Get PDF Response",
      "type": "n8n-nodes-base.set",
      "position": [
        3088,
        160
      ]
    },
    {
      "id": "68455a41-eb83-4435-bd16-41660100a544",
      "name": "Get CSV Response",
      "type": "n8n-nodes-base.set",
      "position": [
        3088,
        352
      ]
    },
    {
      "id": "d7914110-a00d-429a-83c5-f616a42279de",
      "name": "Read File From GDrive",
      "type": "@n8n/n8n-nodes-langchain.toolWorkflow",
      "position": [
        1968,
        256
      ]
    },
    {
      "id": "fe6779a1-b38d-41f1-97ec-d4502627d538",
      "name": "Search Files from Gdrive",
      "type": "n8n-nodes-base.googleDriveTool",
      "position": [
        1776,
        288
      ]
    },
    {
      "id": "63050b0b-f63c-4842-9410-fa58d3aa4f23",
      "name": "Analyse Image",
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "position": [
        2928,
        528
      ]
    },
    {
      "id": "ee58e63a-9262-4c2c-b7b3-e5d4554f49f7",
      "name": "Transcribe Audio",
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "position": [
        2928,
        704
      ]
    },
    {
      "id": "f28c8080-ec2b-493c-b611-7b806153e105",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        768,
        368
      ],
      "parameters": {
        "width": null,
        "height": 176,
        "content": "It can be google sheets/ airtable ..."
      }
    },
    {
      "id": "05989746-b87c-49cb-9c41-360de1c12848",
      "name": "Sticky Note5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2080,
        -112
      ],
      "parameters": {
        "width": 480,
        "height": null,
        "content": "## https://n8n.io/creators/jimleuk/ (Jimleuk build this)\n\n- https://n8n.io/workflows/3634-build-your-own-google-drive-mcp-server/ (click the link for more detailed explanation)\n"
      }
    },
    {
      "id": "5c723a04-c8a3-4bc0-8824-c074261b6471",
      "name": "search  about any doc in google drive",
      "type": "@n8n/n8n-nodes-langchain.mcpClientTool",
      "position": [
        1600,
        176
      ]
    },
    {
      "id": "ec2c314e-1663-4bae-81b0-82d178127dba",
      "name": "Sticky Note6",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        112,
        272
      ],
      "parameters": {
        "width": null,
        "height": 224,
        "content": "### Advanced model of claude or Grok 4 for better results "
      }
    },
    {
      "id": "978c81d5-f666-43a6-9264-9afe2a2ef90b",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2080,
        48
      ],
      "parameters": {
        "width": 1180,
        "height": 812,
        "content": "## 2. Handle Multiple Binary Formats via Conversion and AI\n[Read more about the PostgreSQL Node](https://docs.n8n.io/integrations/builtin/app-nodes/n8n-nodes-base.postgres/)\n\nMCP clients (or rather, t"
      }
    },
    {
      "id": "4fbb6c1f-7d48-461e-9f40-b511643ab0de",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        64,
        -848
      ],
      "parameters": {
        "width": 1072,
        "height": 720,
        "content": "## Load data to vector store"
      }
    },
    {
      "id": "5057d61a-b3e1-4954-aeab-af772966ef5a",
      "name": "Knowledge Agent",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        464,
        0
      ]
    },
    {
      "id": "e0341ead-2135-442d-a515-4b0c42d63cf9",
      "name": "Message a model in Perplexity",
      "type": "n8n-nodes-base.perplexityTool",
      "position": [
        656,
        752
      ]
    },
    {
      "id": "71203174-b2c1-4fd9-8abb-4f254124f72e",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        576,
        688
      ],
      "parameters": {
        "width": null,
        "height": 224,
        "content": "### Search for live data in the Web"
      }
    },
    {
      "id": "c7638349-2fc9-4cc7-8b87-3f7acb7973d8",
      "name": "Sticky Note7",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -880,
        -848
      ],
      "parameters": {
        "width": 896,
        "height": 1872,
        "content": "# 📜 Detailed n8n Workflow Description\n\n## Main Flow\n\nThe workflow operates through a three-step process that handles incoming chat messages with intelligent tool orchestration:\n\n1. **Message Trigger**"
      }
    },
    {
      "id": "49a2978b-75b9-4968-80cb-3269644348f9",
      "name": "Sticky Note8",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1168,
        -672
      ],
      "parameters": {
        "width": 576,
        "height": 560,
        "content": "## Need a tailor-made workflow? Tell me about your business and get a free proposal:\n\n**[Start here → Custom Automation Form](https://taskmorphr.com/contact)**\n\n---\n## 📈 Cost-Savings Snapshot  \nCuriou"
      }
    },
    {
      "id": "d52649d2-518b-4b54-81bc-df42774ea5f7",
      "name": "Sticky Note9",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1488,
        -272
      ],
      "parameters": {
        "width": 224,
        "height": 128,
        "content": "### 🛠️ Build it yourself  \nBrowse every ready-made workflow:  \n[Full Template Pack — coming soon](https://n8n.io/creators/diagopl/)\n"
      }
    }
  ],
  "connections": {
    "Think": {
      "ai_tool": [
        [
          {
            "node": "Knowledge Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "FileType": {
      "main": [
        [
          {
            "node": "Extract from PDF",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Extract from CSV",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Analyse Image",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Transcribe Audio",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Operation": {
      "main": [
        [
          {
            "node": "Download File1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Download file": {
      "main": [
        [
          {
            "node": "Add to Supabase Vector DB",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Download File1": {
      "main": [
        [
          {
            "node": "FileType",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Reranker Cohere": {
      "ai_reranker": [
        [
          {
            "node": "General knowledge",
            "type": "ai_reranker",
            "index": 0
          }
        ]
      ]
    },
    "structured data": {
      "ai_tool": [
        [
          {
            "node": "Knowledge Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Extract from CSV": {
      "main": [
        [
          {
            "node": "Get CSV Response",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract from PDF": {
      "main": [
        [
          {
            "node": "Get PDF Response",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Embeddings OpenAI": {
      "ai_embedding": [
        [
          {
            "node": "General knowledge",
            "type": "ai_embedding",
            "index": 0
          }
        ]
      ]
    },
    "General knowledge": {
      "ai_tool": [
        [
          {
            "node": "Knowledge Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Embeddings OpenAI1": {
      "ai_embedding": [
        [
          {
            "node": "Add to Supabase Vector DB",
            "type": "ai_embedding",
            "index": 0
          }
        ]
      ]
    },
    "Anthropic Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "Knowledge Agent",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Default Data Loader1": {
      "ai_document": [
        [
          {
            "node": "Add to Supabase Vector DB",
            "type": "ai_document",
            "index": 0
          }
        ]
      ]
    },
    "Postgres Chat Memory": {
      "ai_memory": [
        [
          {
            "node": "Knowledge Agent",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "Read File From GDrive": {
      "ai_tool": [
        [
          {
            "node": "Google Drive MCP Server",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Search Files from Gdrive": {
      "ai_tool": [
        [
          {
            "node": "Google Drive MCP Server",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "When chat message received": {
      "main": [
        [
          {
            "node": "Knowledge Agent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Message a model in Perplexity": {
      "ai_tool": [
        [
          {
            "node": "Knowledge Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "When Executed by Another Workflow": {
      "main": [
        [
          {
            "node": "Operation",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Recursive Character Text Splitter1": {
      "ai_textSplitter": [
        [
          {
            "node": "Default Data Loader1",
            "type": "ai_textSplitter",
            "index": 0
          }
        ]
      ]
    },
    "When clicking ‘Execute workflow’": {
      "main": [
        [
          {
            "node": "Download file",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "search  about any doc in google drive": {
      "ai_tool": [
        [
          {
            "node": "Knowledge Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    }
  }
}