{
  "id": "nd6AMUkZTTyLUCao",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "name": "Vector Store",
  "tags": [
    {
      "id": "0CVNvLkMsFx0fYp2",
      "name": "vector",
      "createdAt": "2025-08-12T15:02:22.969Z",
      "updatedAt": "2025-08-12T15:02:22.969Z"
    },
    {
      "id": "AGb9sgonhJTDopA7",
      "name": "agent",
      "createdAt": "2025-08-12T15:02:28.571Z",
      "updatedAt": "2025-08-12T15:02:28.571Z"
    },
    {
      "id": "7KrXwk3m9PhErl7A",
      "name": "memory",
      "createdAt": "2025-08-12T15:02:37.615Z",
      "updatedAt": "2025-08-12T15:02:37.615Z"
    }
  ],
  "nodes": [
    {
      "id": "3de1a952-043a-46cc-be79-7e314399351a",
      "name": "When chat message received",
      "type": "@n8n/n8n-nodes-langchain.chatTrigger",
      "position": [
        -592,
        -848
      ],
      "parameters": {
        "options": {}
      },
      "typeVersion": 1.1
    },
    {
      "id": "0513d68e-6da9-4dae-8afb-1dc02223e727",
      "name": "AI Agent",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        -256,
        -848
      ],
      "parameters": {
        "options": {}
      },
      "typeVersion": 2.1
    },
    {
      "id": "213e8d03-3414-4b87-8374-4bb56179695c",
      "name": "Google Gemini Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatGoogleGemini",
      "position": [
        -272,
        -672
      ],
      "parameters": {
        "options": {}
      },
      "credentials": {
        "googlePalmApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "79899926-cff5-45eb-af1e-f468e427dfda",
      "name": "Get row(s) in sheet1",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        -576,
        -272
      ],
      "parameters": {
        "options": {},
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "gid=0",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1gORnXWKOs9ENYCUki_9hLE_H3bZVKnerZqOPhNzVMRc/edit#gid=0",
          "cachedResultName": "Birthday"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1gORnXWKOs9ENYCUki_9hLE_H3bZVKnerZqOPhNzVMRc",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1gORnXWKOs9ENYCUki_9hLE_H3bZVKnerZqOPhNzVMRc/edit?usp=drivesdk",
          "cachedResultName": "Personal Birthday"
        }
      },
      "credentials": {
        "googleSheetsOAuth2Api": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "a7f53efa-8819-4b5a-9489-20fe543b2624",
      "name": "Supabase Vector Store",
      "type": "@n8n/n8n-nodes-langchain.vectorStoreSupabase",
      "position": [
        -32,
        -720
      ],
      "parameters": {
        "mode": "retrieve-as-tool",
        "options": {
          "queryName": "match_personal_data"
        },
        "tableName": {
          "__rl": true,
          "mode": "list",
          "value": "personal_data",
          "cachedResultName": "personal_data"
        },
        "toolDescription": "Personal details table"
      },
      "credentials": {
        "supabaseApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1.3
    },
    {
      "id": "8510b172-bfe6-4aab-8ca0-c6437e66b766",
      "name": "Default Data Loader2",
      "type": "@n8n/n8n-nodes-langchain.documentDefaultDataLoader",
      "position": [
        96,
        -32
      ],
      "parameters": {
        "loader": "csvLoader",
        "options": {},
        "dataType": "binary"
      },
      "typeVersion": 1.1
    },
    {
      "id": "b178e5a3-3fad-457d-85e1-60505dda4bdd",
      "name": "Postgres Chat Memory",
      "type": "@n8n/n8n-nodes-langchain.memoryPostgresChat",
      "position": [
        -160,
        -640
      ],
      "parameters": {},
      "credentials": {
        "postgres": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1.3
    },
    {
      "id": "89597607-b666-4b6b-8f55-63b8bf6f44db",
      "name": "Embeddings OpenAI",
      "type": "@n8n/n8n-nodes-langchain.embeddingsOpenAi",
      "position": [
        -112,
        -80
      ],
      "parameters": {
        "options": {}
      },
      "credentials": {
        "openAiApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "b8c7629a-1ff0-401c-888d-b79def975fe3",
      "name": "Embeddings OpenAI1",
      "type": "@n8n/n8n-nodes-langchain.embeddingsOpenAi",
      "position": [
        -32,
        -592
      ],
      "parameters": {
        "options": {}
      },
      "credentials": {
        "openAiApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "b0d9356b-9899-4a6b-8ed3-7251dd95907b",
      "name": "Convert to File",
      "type": "n8n-nodes-base.convertToFile",
      "position": [
        -368,
        -272
      ],
      "parameters": {
        "options": {}
      },
      "typeVersion": 1.1
    },
    {
      "id": "88200923-f5f3-433e-aa50-1cdd05b9d178",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -784,
        -384
      ],
      "parameters": {
        "width": 1024,
        "height": 528,
        "content": "## Vector Store Load :file_folder:\n### Insert Personal Data to Vector Store"
      },
      "typeVersion": 1
    },
    {
      "id": "00c44b09-2c0f-4a23-8360-77e681be263e",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -784,
        -1024
      ],
      "parameters": {
        "color": 5,
        "width": 1024,
        "height": 592,
        "content": "## Agent :information_desk_person:\n### Agent can answer any personal information on Vector Store"
      },
      "typeVersion": 1
    },
    {
      "id": "bc8e0fe2-5d56-4cfc-9eb8-b8c6c75b6cee",
      "name": "Vector Store",
      "type": "@n8n/n8n-nodes-langchain.vectorStoreSupabase",
      "position": [
        -112,
        -272
      ],
      "parameters": {
        "mode": "insert",
        "options": {
          "queryName": "match_personal_data"
        },
        "tableName": {
          "__rl": true,
          "mode": "list",
          "value": "personal_data",
          "cachedResultName": "personal_data"
        }
      },
      "credentials": {
        "supabaseApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1.3
    }
  ],
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "6ff1646e-f18a-4228-8d17-bd22b50b2bdb",
  "connections": {
    "Convert to File": {
      "main": [
        [
          {
            "node": "Vector Store",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Embeddings OpenAI": {
      "ai_embedding": [
        [
          {
            "node": "Vector Store",
            "type": "ai_embedding",
            "index": 0
          }
        ]
      ]
    },
    "Embeddings OpenAI1": {
      "ai_embedding": [
        [
          {
            "node": "Supabase Vector Store",
            "type": "ai_embedding",
            "index": 0
          }
        ]
      ]
    },
    "Default Data Loader2": {
      "ai_document": [
        [
          {
            "node": "Vector Store",
            "type": "ai_document",
            "index": 0
          }
        ]
      ]
    },
    "Get row(s) in sheet1": {
      "main": [
        [
          {
            "node": "Convert to File",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Postgres Chat Memory": {
      "ai_memory": [
        [
          {
            "node": "AI Agent",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "Supabase Vector Store": {
      "ai_tool": [
        [
          {
            "node": "AI Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Google Gemini Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "AI Agent",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "When chat message received": {
      "main": [
        [
          {
            "node": "AI Agent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}