{
  "name": "ADAS Event Annotator",
  "nodes": [
    {
      "parameters": {
        "content": "## ADAS Event Annotator",
        "height": 520,
        "width": 1100
      },
      "id": "d8b2d5dd-eec5-4be6-a731-db7610f15cda",
      "name": "Sticky",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        -500,
        -250
      ]
    },
    {
      "parameters": {
        "httpMethod": "POST",
        "path": "adas_event_annotator"
      },
      "id": "b7650538-2b5e-4c0a-b76b-cafbe17c7379",
      "name": "Webhook",
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 1,
      "position": [
        -300,
        0
      ]
    },
    {
      "parameters": {
        "chunkSize": 400,
        "chunkOverlap": 40
      },
      "id": "acf9f8f1-18a7-4252-9bbe-d790944659b7",
      "name": "Splitter",
      "type": "@n8n/n8n-nodes-langchain.textSplitterCharacterTextSplitter",
      "typeVersion": 1,
      "position": [
        -100,
        0
      ]
    },
    {
      "parameters": {
        "model": "default"
      },
      "id": "d8155b88-15fa-4d24-8456-f17814229f46",
      "name": "Embeddings",
      "type": "@n8n/n8n-nodes-langchain.embeddingsCohere",
      "typeVersion": 1,
      "position": [
        100,
        0
      ],
      "credentials": {
        "cohereApi": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "mode": "insert",
        "indexName": "adas_event_annotator"
      },
      "id": "3b95c190-406c-4bab-ac90-b44c606862fd",
      "name": "Insert",
      "type": "@n8n/n8n-nodes-langchain.vectorStoreSupabase",
      "typeVersion": 1,
      "position": [
        300,
        0
      ],
      "credentials": {
        "supabaseApi": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "indexName": "adas_event_annotator"
      },
      "id": "6ec5ac90-10ad-437b-b0b6-38185d6e1f53",
      "name": "Query",
      "type": "@n8n/n8n-nodes-langchain.vectorStoreSupabase",
      "typeVersion": 1,
      "position": [
        300,
        -180
      ],
      "credentials": {
        "supabaseApi": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "name": "Supabase"
      },
      "id": "5e7dffcb-ddb0-4336-8c7d-644c80bc91ac",
      "name": "Tool",
      "type": "@n8n/n8n-nodes-langchain.toolVectorStore",
      "typeVersion": 1,
      "position": [
        480,
        -180
      ]
    },
    {
      "parameters": {},
      "id": "b128a48a-6322-4e10-afd3-6cb388fb2ca6",
      "name": "Memory",
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "typeVersion": 1.3,
      "position": [
        480,
        -40
      ]
    },
    {
      "parameters": {},
      "id": "77813cb8-5069-4cba-b329-8f24b3e680ef",
      "name": "Chat",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1,
      "position": [
        480,
        -340
      ],
      "credentials": {
        "openAiApi": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "promptType": "define",
        "text": "={{ $json }}"
      },
      "id": "2e95e6c3-34d2-4144-807e-6afca51a3e13",
      "name": "Agent",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "typeVersion": 1,
      "position": [
        760,
        -40
      ]
    },
    {
      "parameters": {
        "operation": "append",
        "documentId": "SHEET_ID",
        "sheetName": "Log"
      },
      "id": "0e18d385-0727-47f8-8cc8-d4729e36782d",
      "name": "Sheet",
      "type": "n8n-nodes-base.googleSheets",
      "typeVersion": 4,
      "position": [
        960,
        -40
      ],
      "credentials": {
        "googleSheetsOAuth2Api": {
          "name": "<your credential>"
        }
      }
    }
  ],
  "connections": {
    "Webhook": {
      "main": [
        [
          {
            "node": "Splitter",
            "type": "main",
            "index": 0
          },
          {
            "node": "Memory",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Splitter": {
      "main": [
        [
          {
            "node": "Embeddings",
            "type": "main",
            "index": 0
          }
        ]
      ],
      "ai_textSplitter": [
        [
          {
            "node": "Insert",
            "type": "ai_textSplitter",
            "index": 0
          }
        ]
      ]
    },
    "Embeddings": {
      "ai_embedding": [
        [
          {
            "node": "Insert",
            "type": "ai_embedding",
            "index": 0
          },
          {
            "node": "Query",
            "type": "ai_embedding",
            "index": 0
          }
        ]
      ]
    },
    "Insert": {
      "ai_document": [
        []
      ]
    },
    "Query": {
      "ai_vectorStore": [
        [
          {
            "node": "Tool",
            "type": "ai_vectorStore",
            "index": 0
          }
        ]
      ]
    },
    "Tool": {
      "ai_tool": [
        [
          {
            "node": "Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Memory": {
      "ai_memory": [
        [
          {
            "node": "Agent",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "Chat": {
      "ai_languageModel": [
        [
          {
            "node": "Agent",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Agent": {
      "main": [
        [
          {
            "node": "Sheet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "settings": {
    "executionOrder": "v1"
  }
}