{
  "name": "RAG Starter Template using Simple Vector Stores, Form trigger and OpenAI",
  "nodes": [
    {
      "id": "83ed351e-90e8-458f-a01b-73001ef1800f",
      "name": "Upload your file here",
      "type": "n8n-nodes-base.formTrigger",
      "position": [
        220,
        -120
      ]
    },
    {
      "id": "26d63e24-2592-41f9-9b4b-edab81e99f21",
      "name": "Embeddings OpenAI",
      "type": "@n8n/n8n-nodes-langchain.embeddingsOpenAi",
      "position": [
        860,
        360
      ]
    },
    {
      "id": "3a69c8a7-bf95-4de2-84b0-ae2cc3d2e4e7",
      "name": "Default Data Loader",
      "type": "@n8n/n8n-nodes-langchain.documentDefaultDataLoader",
      "position": [
        660,
        40
      ]
    },
    {
      "id": "0b42832b-c9e8-4627-b36c-94fc5e242b33",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -320,
        -180
      ],
      "parameters": {
        "width": 440,
        "height": 300,
        "content": "### Readme\nLoad your data into a vector database with the 📚 **Load Data** flow, and then use your data as chat context with the 🐕 **Retriever** flow.\n\n**Quick start**\n1. Click on the `Execute Workflow"
      }
    },
    {
      "id": "f902ab8f-4620-4a95-86f7-c5857c4d6c4f",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        160,
        -180
      ],
      "parameters": {
        "width": 700,
        "height": 460,
        "content": "### 📚 Load Data Flow"
      }
    },
    {
      "id": "0f4185ea-d7a9-44a9-a824-98f9dc2c2a5d",
      "name": "Insert Data to Store",
      "type": "@n8n/n8n-nodes-langchain.vectorStoreInMemory",
      "position": [
        400,
        -120
      ]
    },
    {
      "id": "ce86b41b-7e1b-458f-ab13-d6b187854ae8",
      "name": "Query Data Tool",
      "type": "@n8n/n8n-nodes-langchain.vectorStoreInMemory",
      "position": [
        1280,
        80
      ]
    },
    {
      "id": "0039537b-558c-4fe8-9716-f8aa13676f4a",
      "name": "AI Agent",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        1280,
        -140
      ]
    },
    {
      "id": "2669a65e-f0f3-45aa-95c0-621b15a4fc67",
      "name": "When chat message received",
      "type": "@n8n/n8n-nodes-langchain.chatTrigger",
      "position": [
        1060,
        -140
      ]
    },
    {
      "id": "d43cf585-4192-4f53-9532-4677923289ba",
      "name": "OpenAI Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        1060,
        80
      ]
    },
    {
      "id": "3d1b3f5a-bc35-4739-a618-9c85820d39a0",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        940,
        -180
      ],
      "parameters": {
        "width": 680,
        "height": 460,
        "content": "### 🐕 2. Retriever Flow"
      }
    },
    {
      "id": "8d4c68cf-64d1-4b3a-bb19-2f003303c1df",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1000,
        320
      ],
      "parameters": {
        "width": 320,
        "height": 240,
        "content": "### Embeddings\n\nThe Insert and Retrieve operation use the same embedding node.\n\nThis is to ensure that they are using the **exact same embeddings and settings**.\n\nDifferent embeddings might not work a"
      }
    }
  ],
  "connections": {
    "Query Data Tool": {
      "ai_tool": [
        [
          {
            "node": "AI Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Embeddings OpenAI": {
      "ai_embedding": [
        [
          {
            "node": "Insert Data to Store",
            "type": "ai_embedding",
            "index": 0
          },
          {
            "node": "Query Data Tool",
            "type": "ai_embedding",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "AI Agent",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Default Data Loader": {
      "ai_document": [
        [
          {
            "node": "Insert Data to Store",
            "type": "ai_document",
            "index": 0
          }
        ]
      ]
    },
    "Upload your file here": {
      "main": [
        [
          {
            "node": "Insert Data to Store",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "When chat message received": {
      "main": [
        [
          {
            "node": "AI Agent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}