{
  "name": "Amazon Product Name Translator",
  "nodes": [
    {
      "parameters": {},
      "type": "n8n-nodes-base.manualTrigger",
      "typeVersion": 1,
      "position": [
        -3136,
        560
      ],
      "id": "d0dc0ec9-39dc-48d3-81e8-9b923348962e",
      "name": "When clicking ‘Execute workflow’"
    },
    {
      "parameters": {},
      "type": "n8n-nodes-globals.globalConstants",
      "typeVersion": 1,
      "position": [
        -2928,
        560
      ],
      "id": "847ba018-d795-4d17-bb52-522cbb996d8a",
      "name": "Global Constants"
    },
    {
      "parameters": {
        "documentId": {
          "__rl": true,
          "value": "={{ $json.constants.sheet_id }}",
          "mode": "id"
        },
        "sheetName": {
          "__rl": true,
          "value": "={{ $json.constants.sheet1 }}",
          "mode": "name"
        },
        "filtersUI": {
          "values": [
            {
              "lookupColumn": "STATUS",
              "lookupValue": "PENDING"
            }
          ]
        },
        "options": {
          "returnFirstMatch": false
        }
      },
      "type": "n8n-nodes-base.googleSheets",
      "typeVersion": 4.7,
      "position": [
        -2720,
        560
      ],
      "id": "64894496-9ec3-4023-b589-0a78450c3930",
      "name": "Get row(s) in sheet",
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "wZJh4ACm1MD5wdQ9",
          "name": "Google Sheet (Admin Account - Nandy Cyber Success)"
        }
      }
    },
    {
      "parameters": {
        "promptType": "define",
        "text": "=Product Name:\n{{ $('Loop Over Items').item.json.PRODUCT_NAME }}",
        "hasOutputParser": true,
        "options": {
          "systemMessage": "=You are a Translation + e-commerce SEO assistant. The user will provide you with a Product Name available on Amazon.com. This product name will be in English as it is sold on the US Amazon store. Your job will be to use the Google Translate tool that you are attached to and come up with a search term that users are likely to use when looking for this product.\n\nYou need to provide this search term in a language of the user's choice.\n\nThe language of choice is: {{ $('Loop Over Items').item.json.LANGUAGE_2 }}\n\nYou should only generate search terms that are between 2-3 words long\n\nYou are required to use the following resources:\n- The Brave Search Tool you have been provided access to\n- The Google Translate Tool you have been provided access to"
        }
      },
      "type": "@n8n/n8n-nodes-langchain.agent",
      "typeVersion": 2.2,
      "position": [
        -1664,
        704
      ],
      "id": "66171cf9-cdc4-4b52-a5b5-2c330dd9e079",
      "name": "AI Agent"
    },
    {
      "parameters": {
        "operation": "amazon",
        "k": "={{ $json['PRIMARY TRANSLATED KEYWORD'] }}",
        "amazon_domain": "={{ $('Loop Over Items').item.json.AMAZON_DOMAIN }}",
        "additionalFields": {
          "language": "={{ $('Loop Over Items').item.json.AMAZON_LANGUAGE }}"
        },
        "requestOptions": {}
      },
      "type": "n8n-nodes-serpapi.serpApi",
      "typeVersion": 1,
      "position": [
        -1168,
        704
      ],
      "id": "e8d5a0ba-aa1d-40f2-b8d7-5a368cdde03c",
      "name": "Amazon search",
      "credentials": {
        "serpApi": {
          "id": "dnIGIrnfd1ftmOdb",
          "name": "SerpApi account 2"
        }
      }
    },
    {
      "parameters": {
        "sessionIdType": "customKey",
        "sessionKey": "={{$('Code in JavaScript').item.json.randomNumber}}"
      },
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "typeVersion": 1.3,
      "position": [
        -1616,
        880
      ],
      "id": "be28cacf-a2bb-4861-8fb8-3d5fd1d978b4",
      "name": "Simple Memory"
    },
    {
      "parameters": {
        "text": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Text', ``, 'string') }}",
        "translateTo": "={{ $('Loop Over Items').item.json.LANGUAGE }}"
      },
      "type": "n8n-nodes-base.googleTranslateTool",
      "typeVersion": 2,
      "position": [
        -1568,
        1088
      ],
      "id": "db65b3fe-0cf8-4fed-9fe2-2a96d77dde54",
      "name": "Translate a language in Google Translate"
    },
    {
      "parameters": {
        "query": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Query', ``, 'string') }}",
        "count": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Count', ``, 'number') }}",
        "additionalParameters": {
          "country": "={{ $('Loop Over Items').item.json.COUNTRY }}",
          "search_lang": "={{ $('Loop Over Items').item.json.LANGUAGE }}"
        }
      },
      "type": "@brave/n8n-nodes-brave-search.braveSearchTool",
      "typeVersion": 1,
      "position": [
        -1584,
        640
      ],
      "id": "343b43e1-d884-4734-857a-c1c4bc8b9890",
      "name": "Brave Search",
      "credentials": {
        "braveSearchApi": {
          "id": "4yKxSu1Rx4YYMObx",
          "name": "Brave Search Account (Personal)"
        }
      }
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "value": "gpt-4o",
          "mode": "list",
          "cachedResultName": "gpt-4o"
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.2,
      "position": [
        -1664,
        880
      ],
      "id": "b4dcaa05-e364-4a9f-8092-3936c6c4a032",
      "name": "OpenAI Chat Model",
      "credentials": {
        "openAiApi": {
          "id": "OjRKrQXB019XKwdP",
          "name": "OpenAi Account (Personal)"
        }
      }
    },
    {
      "parameters": {
        "schemaType": "manual",
        "inputSchema": "{\n  \"$schema\": \"http://json-schema.org/draft-07/schema#\",\n  \"type\": \"object\",\n  \"required\": [\n    \"originalProductName\",\n    \"targetLanguage\",\n    \"optimizedSearchTerm\"\n  ],\n  \"properties\": {\n    \"originalProductName\": {\n      \"type\": \"string\",\n      \"description\": \"The original product name from Amazon.com in English\"\n    },\n    \"targetLanguage\": {\n      \"type\": \"string\",\n      \"description\": \"The target language for translation (e.g., FR, ES, DE, AR)\"\n    },\n    \"optimizedSearchTerm\": {\n      \"type\": \"string\",\n      \"pattern\": \"^\\\\S+\\\\s+\\\\S+(\\\\s+\\\\S+)?$\",\n      \"description\": \"Optimized 2-3 word search term in the target language that users would use to find this product\"\n    }\n  },\n  \"additionalProperties\": false\n}",
        "autoFix": true
      },
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "typeVersion": 1.3,
      "position": [
        -1600,
        928
      ],
      "id": "1c36f1a8-c5d2-4028-8777-4b7085ba9944",
      "name": "Structured Output Parser"
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4.1-mini"
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.2,
      "position": [
        -1600,
        976
      ],
      "id": "14eaae79-5af0-4f2e-bf34-6b648cfb10d2",
      "name": "OpenAI Chat Model1",
      "credentials": {
        "openAiApi": {
          "id": "OjRKrQXB019XKwdP",
          "name": "OpenAi Account (Personal)"
        }
      }
    },
    {
      "parameters": {
        "jsCode": "const items = $input.all();\nconst grouped = {};\n\n// Group items by ASIN\nfor (const item of items) {\n  const json = item.json;\n  const asin = json.ASIN;\n  \n  if (!grouped[asin]) {\n    grouped[asin] = {\n      ASIN: asin,\n      \"Product Name (English)\": json[\"Product Name (English)\"],\n      items: []\n    };\n  }\n  \n  grouped[asin].items.push({\n    row_number: json.row_number,\n    ID: json.ID,\n    STATUS: json.STATUS,\n    LANGUAGE: json.LANGUAGE,\n    \"Primary Keyword (EN)\": json[\"Primary Keyword (EN)\"],\n    \"TRANSLATED PRODUCT NAME (BEFORE)\": json[\"TRANSLATED PRODUCT NAME (BEFORE)\"],\n    \"TRANSLATED PRODUCT NAME (AFTER)\": json[\"TRANSLATED PRODUCT NAME (AFTER)\"],\n    \"PRIMARY TRANSLATED KEYWORD\": json[\"PRIMARY TRANSLATED KEYWORD\"],\n    PRODUCT_NAME: json['Product Name (English)'],\n    LANGUAGE_2: json.LANGUAGE_2,\n    COUNTRY: json.COUNTRY,\n    AMAZON_DOMAIN: json['amazon domain'],\n    AMAZON_LANGUAGE: json['amazon language'],\n    \"Product Name DB\": json[\"Product Name DB\"]\n  });\n}\n\n// Convert to array\nconst output = [];\nfor (const asin in grouped) {\n  output.push({\n    json: grouped[asin]\n  });\n}\n\nreturn output;"
      },
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [
        -2512,
        560
      ],
      "id": "107c6f92-48f8-40af-976b-2cb333666222",
      "name": "Code in JavaScript1"
    },
    {
      "parameters": {
        "operation": "update",
        "documentId": {
          "__rl": true,
          "value": "={{ $('Global Constants').first().json.constants.sheet_id }}",
          "mode": "id"
        },
        "sheetName": {
          "__rl": true,
          "value": "={{ $('Global Constants').first().json.constants.sheet1 }}",
          "mode": "name"
        },
        "columns": {
          "mappingMode": "defineBelow",
          "value": {
            "row_number": "={{ $('Loop Over Items').item.json.row_number }}",
            "PRIMARY TRANSLATED KEYWORD": "={{ $json.output.optimizedSearchTerm }}"
          },
          "matchingColumns": [
            "row_number"
          ],
          "schema": [
            {
              "id": "ID",
              "displayName": "ID",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "ASIN",
              "displayName": "ASIN",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "STATUS",
              "displayName": "STATUS",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "LANGUAGE",
              "displayName": "LANGUAGE",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "LANGUAGE_2",
              "displayName": "LANGUAGE_2",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "COUNTRY",
              "displayName": "COUNTRY",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "amazon domain",
              "displayName": "amazon domain",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "amazon language",
              "displayName": "amazon language",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Product Name (English)",
              "displayName": "Product Name (English)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "TRANSLATED PRODUCT NAME (BEFORE)",
              "displayName": "TRANSLATED PRODUCT NAME (BEFORE)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": false
            },
            {
              "id": "TRANSLATED PRODUCT NAME (AFTER)",
              "displayName": "TRANSLATED PRODUCT NAME (AFTER)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": false
            },
            {
              "id": "PRIMARY TRANSLATED KEYWORD",
              "displayName": "PRIMARY TRANSLATED KEYWORD",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": false
            },
            {
              "id": "Product Name DB",
              "displayName": "Product Name DB",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "row_number",
              "displayName": "row_number",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "number",
              "canBeUsedToMatch": true,
              "readOnly": true,
              "removed": false
            }
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {}
      },
      "type": "n8n-nodes-base.googleSheets",
      "typeVersion": 4.7,
      "position": [
        -1344,
        704
      ],
      "id": "1935355e-5291-4e55-89d1-9c71af1c3821",
      "name": "Update row in sheet",
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "wZJh4ACm1MD5wdQ9",
          "name": "Google Sheet (Admin Account - Nandy Cyber Success)"
        }
      }
    },
    {
      "parameters": {
        "fieldToSplitOut": "organic_results",
        "options": {}
      },
      "type": "n8n-nodes-base.splitOut",
      "typeVersion": 1,
      "position": [
        -928,
        816
      ],
      "id": "3312c52e-bda9-4ef3-ad4f-5fe0818766ab",
      "name": "Split Out"
    },
    {
      "parameters": {
        "assignments": {
          "assignments": [
            {
              "id": "8ad671c3-7796-4012-ac8b-c98ad59f63c2",
              "name": "title",
              "value": "={{ $json.title }}",
              "type": "string"
            }
          ]
        },
        "options": {}
      },
      "type": "n8n-nodes-base.set",
      "typeVersion": 3.4,
      "position": [
        -784,
        896
      ],
      "id": "dafc4675-337c-462a-b328-846a3790b3d1",
      "name": "Edit Fields1"
    },
    {
      "parameters": {
        "fieldsToAggregate": {
          "fieldToAggregate": [
            {
              "fieldToAggregate": "title"
            }
          ]
        },
        "options": {}
      },
      "type": "n8n-nodes-base.aggregate",
      "typeVersion": 1,
      "position": [
        -496,
        896
      ],
      "id": "9225049a-c381-4cd0-a9b5-302f42c38831",
      "name": "Aggregate"
    },
    {
      "parameters": {
        "promptType": "define",
        "text": "=Product Name:\n{{ $('AI Agent').item.json.output.originalProductName }}",
        "hasOutputParser": true,
        "options": {
          "systemMessage": "=You are a Translation + e-commerce SEO assistant. You receive a product name in English that is being sold on Amazon.com and you are to translate the product name for the same exact product into the following language:\n\n{{ $('Loop Over Items').item.json.LANGUAGE_2 }}\n\nTo aid you in your task you are provided with an Array containing the Top 50 top selling products for this product line on Amazon's {{ $('Loop Over Items').item.json.COUNTRY }} store. You need to use this array to inform you on how to best frame the product name for the people of that country.\n\nYou are, therefore, an extremely capable and effective localising agent that not only translates but understands the context of what they are translating and how to localise product names and titles because you have access to 30-50 similiar product titles on the target country's Amazon store."
        }
      },
      "type": "@n8n/n8n-nodes-langchain.agent",
      "typeVersion": 2.2,
      "position": [
        -48,
        896
      ],
      "id": "79629478-a3ff-4e7a-bff9-67bdb3121845",
      "name": "AI Agent1",
      "retryOnFail": true
    },
    {
      "parameters": {
        "sessionIdType": "customKey",
        "sessionKey": "={{$('Code in JavaScript3').item.json.randomNumber}}"
      },
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "typeVersion": 1.3,
      "position": [
        0,
        1072
      ],
      "id": "c37b0e08-aec7-41f4-80e5-b4cba04a3cc4",
      "name": "Simple Memory1"
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "value": "gpt-4o",
          "mode": "list",
          "cachedResultName": "gpt-4o"
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.2,
      "position": [
        -48,
        1072
      ],
      "id": "3a48e7c8-71b2-4882-926c-65368a6d7305",
      "name": "OpenAI Chat Model2",
      "credentials": {
        "openAiApi": {
          "id": "OjRKrQXB019XKwdP",
          "name": "OpenAi Account (Personal)"
        }
      }
    },
    {
      "parameters": {
        "schemaType": "manual",
        "inputSchema": "{\n  \"$schema\": \"http://json-schema.org/draft-07/schema#\",\n  \"type\": \"object\",\n  \"required\": [\n    \"originalProductName\",\n    \"targetLanguage\",\n    \"targetCountry\",\n    \"localizedProductName\"\n  ],\n  \"properties\": {\n    \"originalProductName\": {\n      \"type\": \"string\",\n      \"description\": \"The original product name from Amazon.com in English\"\n    },\n    \"targetLanguage\": {\n      \"type\": \"string\",\n      \"description\": \"The target language code (e.g., FR, ES, DE, AR)\"\n    },\n    \"targetCountry\": {\n      \"type\": \"string\",\n      \"description\": \"The target country/Amazon marketplace (e.g., France, Spain, Germany, Saudi Arabia)\"\n    },\n    \"localizedProductName\": {\n      \"type\": \"string\",\n      \"minLength\": 10,\n      \"maxLength\": 200,\n      \"description\": \"The localized and optimized product name for the target country's Amazon store, informed by top-selling products in that market\"\n    },\n    \"localizationNotes\": {\n      \"type\": \"string\",\n      \"description\": \"Brief explanation of key localization decisions made based on top-selling products analysis\"\n    }\n  },\n  \"additionalProperties\": false\n}",
        "autoFix": true
      },
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "typeVersion": 1.3,
      "position": [
        -16,
        1120
      ],
      "id": "7322d6c2-a63b-4943-92e6-7e45e529bd9b",
      "name": "Structured Output Parser1"
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4.1-mini"
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.2,
      "position": [
        64,
        1200
      ],
      "id": "1f7f8690-3786-48ac-8eb0-b0cb7b2616a7",
      "name": "OpenAI Chat Model3",
      "credentials": {
        "openAiApi": {
          "id": "OjRKrQXB019XKwdP",
          "name": "OpenAi Account (Personal)"
        }
      }
    },
    {
      "parameters": {
        "fieldToSplitOut": "items",
        "options": {}
      },
      "type": "n8n-nodes-base.splitOut",
      "typeVersion": 1,
      "position": [
        -2336,
        560
      ],
      "id": "98a4f077-468e-47a0-9442-d7d003bada83",
      "name": "Split Out1"
    },
    {
      "parameters": {
        "options": {}
      },
      "type": "n8n-nodes-base.splitInBatches",
      "typeVersion": 3,
      "position": [
        -2160,
        560
      ],
      "id": "990f2c2a-b7d3-44ac-b4a7-75b7e3016e73",
      "name": "Loop Over Items"
    },
    {
      "parameters": {
        "jsCode": "let randomNumber = '';\n\nfor (let i = 0; i < 8; i++) {\n  randomNumber += Math.floor(Math.random() * 10);\n}\n\nreturn [{\n  json: {\n    randomNumber: randomNumber\n  }\n}];"
      },
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [
        -1920,
        704
      ],
      "id": "eb4bab49-66f1-4bd3-8f4f-221732e7e9be",
      "name": "Code in JavaScript"
    },
    {
      "parameters": {
        "operation": "update",
        "documentId": {
          "__rl": true,
          "value": "={{ $('Global Constants').first().json.constants.sheet_id }}",
          "mode": "id"
        },
        "sheetName": {
          "__rl": true,
          "value": "={{ $('Global Constants').first().json.constants.sheet1 }}",
          "mode": "name"
        },
        "columns": {
          "mappingMode": "defineBelow",
          "value": {
            "row_number": "={{ $('Loop Over Items').item.json.row_number }}",
            "Product Name DB": "={{ $json.title }}"
          },
          "matchingColumns": [
            "row_number"
          ],
          "schema": [
            {
              "id": "ID",
              "displayName": "ID",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "ASIN",
              "displayName": "ASIN",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "STATUS",
              "displayName": "STATUS",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "LANGUAGE",
              "displayName": "LANGUAGE",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "LANGUAGE_2",
              "displayName": "LANGUAGE_2",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "COUNTRY",
              "displayName": "COUNTRY",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "amazon domain",
              "displayName": "amazon domain",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "amazon language",
              "displayName": "amazon language",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Product Name (English)",
              "displayName": "Product Name (English)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "TRANSLATED PRODUCT NAME (BEFORE)",
              "displayName": "TRANSLATED PRODUCT NAME (BEFORE)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "TRANSLATED PRODUCT NAME (AFTER)",
              "displayName": "TRANSLATED PRODUCT NAME (AFTER)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "PRIMARY TRANSLATED KEYWORD",
              "displayName": "PRIMARY TRANSLATED KEYWORD",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Product Name DB",
              "displayName": "Product Name DB",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": false
            },
            {
              "id": "row_number",
              "displayName": "row_number",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "number",
              "canBeUsedToMatch": true,
              "readOnly": true,
              "removed": false
            }
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {}
      },
      "type": "n8n-nodes-base.googleSheets",
      "typeVersion": 4.7,
      "position": [
        -352,
        896
      ],
      "id": "db960932-0312-4546-b16a-ef491aaa798b",
      "name": "Update row in sheet2",
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "wZJh4ACm1MD5wdQ9",
          "name": "Google Sheet (Admin Account - Nandy Cyber Success)"
        }
      }
    },
    {
      "parameters": {
        "text": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Text', ``, 'string') }}",
        "translateTo": "={{ $('Loop Over Items').item.json.LANGUAGE }}"
      },
      "type": "n8n-nodes-base.googleTranslateTool",
      "typeVersion": 2,
      "position": [
        144,
        1216
      ],
      "id": "e2363548-41de-4187-a587-4c1486568aff",
      "name": "Translate a language in Google Translate2"
    },
    {
      "parameters": {
        "operation": "update",
        "documentId": {
          "__rl": true,
          "value": "={{ $('Global Constants').first().json.constants.sheet_id }}",
          "mode": "id"
        },
        "sheetName": {
          "__rl": true,
          "value": "={{ $('Global Constants').first().json.constants.sheet1 }}",
          "mode": "name"
        },
        "columns": {
          "mappingMode": "defineBelow",
          "value": {
            "row_number": "={{ $('Loop Over Items').item.json.row_number }}",
            "TRANSLATED PRODUCT NAME (AFTER)": "={{ $json.output.localizedProductName }}"
          },
          "matchingColumns": [
            "row_number"
          ],
          "schema": [
            {
              "id": "ID",
              "displayName": "ID",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "ASIN",
              "displayName": "ASIN",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "STATUS",
              "displayName": "STATUS",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "LANGUAGE",
              "displayName": "LANGUAGE",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "LANGUAGE_2",
              "displayName": "LANGUAGE_2",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "COUNTRY",
              "displayName": "COUNTRY",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "amazon domain",
              "displayName": "amazon domain",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "amazon language",
              "displayName": "amazon language",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Product Name (English)",
              "displayName": "Product Name (English)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "TRANSLATED PRODUCT NAME (BEFORE)",
              "displayName": "TRANSLATED PRODUCT NAME (BEFORE)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "TRANSLATED PRODUCT NAME (AFTER)",
              "displayName": "TRANSLATED PRODUCT NAME (AFTER)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": false
            },
            {
              "id": "PRIMARY TRANSLATED KEYWORD",
              "displayName": "PRIMARY TRANSLATED KEYWORD",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Product Name DB",
              "displayName": "Product Name DB",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "row_number",
              "displayName": "row_number",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "number",
              "canBeUsedToMatch": true,
              "readOnly": true,
              "removed": false
            }
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {}
      },
      "type": "n8n-nodes-base.googleSheets",
      "typeVersion": 4.7,
      "position": [
        224,
        896
      ],
      "id": "56c2940b-3239-4136-879b-698c14c163bc",
      "name": "Update row in sheet3",
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "wZJh4ACm1MD5wdQ9",
          "name": "Google Sheet (Admin Account - Nandy Cyber Success)"
        }
      }
    },
    {
      "parameters": {
        "jsCode": "let randomNumber = '';\n\nfor (let i = 0; i < 8; i++) {\n  randomNumber += Math.floor(Math.random() * 10);\n}\n\nreturn [{\n  json: {\n    randomNumber: randomNumber\n  }\n}];"
      },
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [
        416,
        896
      ],
      "id": "e842dafc-b18f-4d76-9b89-a9e3abf76794",
      "name": "Code in JavaScript2"
    },
    {
      "parameters": {
        "promptType": "define",
        "text": "=Translate the following Product Name:\n\n{{ $('Loop Over Items').item.json['Product Name (English)'] }}\n\nTo the following language:\n\n{{ $('Loop Over Items').item.json.LANGUAGE_2 }}",
        "hasOutputParser": true,
        "options": {
          "systemMessage": "=You are a Translation + e-commerce SEO assistant. You receive a product name in English that is being sold on Amazon.com and you are to translate the product name for the same exact product into the following language:\n\n{{ $('Loop Over Items').item.json.LANGUAGE_2 }}\n\n"
        }
      },
      "type": "@n8n/n8n-nodes-langchain.agent",
      "typeVersion": 2.2,
      "position": [
        688,
        1088
      ],
      "id": "ef7cbb52-700d-48e3-bbf2-c7930674e02a",
      "name": "AI Agent2"
    },
    {
      "parameters": {
        "sessionIdType": "customKey",
        "sessionKey": "={{$('Code in JavaScript2').item.json.randomNumber}}"
      },
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "typeVersion": 1.3,
      "position": [
        736,
        1264
      ],
      "id": "f6e0b43a-6011-4b71-ba47-c26c73319cc8",
      "name": "Simple Memory2"
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "value": "gpt-4o",
          "mode": "list",
          "cachedResultName": "gpt-4o"
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.2,
      "position": [
        688,
        1264
      ],
      "id": "2b546a3d-b952-49ec-b73b-5cb5917f3bfb",
      "name": "OpenAI Chat Model4",
      "credentials": {
        "openAiApi": {
          "id": "OjRKrQXB019XKwdP",
          "name": "OpenAi Account (Personal)"
        }
      }
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4.1-mini"
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.2,
      "position": [
        800,
        1392
      ],
      "id": "6f5812a1-c898-4d16-a1ee-f6b93cae4164",
      "name": "OpenAI Chat Model5",
      "credentials": {
        "openAiApi": {
          "id": "OjRKrQXB019XKwdP",
          "name": "OpenAi Account (Personal)"
        }
      }
    },
    {
      "parameters": {
        "text": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Text', ``, 'string') }}",
        "translateTo": "={{ $('Loop Over Items').item.json.LANGUAGE }}"
      },
      "type": "n8n-nodes-base.googleTranslateTool",
      "typeVersion": 2,
      "position": [
        704,
        1360
      ],
      "id": "19c963cd-a914-4864-8c48-9f28c6c1e236",
      "name": "Translate a language in Google Translate3"
    },
    {
      "parameters": {
        "schemaType": "manual",
        "inputSchema": "{\n  \"$schema\": \"http://json-schema.org/draft-07/schema#\",\n  \"type\": \"object\",\n  \"required\": [\n    \"originalProductName\",\n    \"targetLanguage\",\n    \"targetCountry\",\n    \"localizedProductName\"\n  ],\n  \"properties\": {\n    \"originalProductName\": {\n      \"type\": \"string\",\n      \"description\": \"The original product name from Amazon.com in English\"\n    },\n    \"targetLanguage\": {\n      \"type\": \"string\",\n      \"description\": \"The target language code (e.g., FR, ES, DE, AR)\"\n    },\n    \"targetCountry\": {\n      \"type\": \"string\",\n      \"description\": \"The target country/Amazon marketplace (e.g., France, Spain, Germany, Saudi Arabia)\"\n    },\n    \"localizedProductName\": {\n      \"type\": \"string\",\n      \"minLength\": 10,\n      \"maxLength\": 200,\n      \"description\": \"The localized and optimized product name for the target country's Amazon store, informed by top-selling products in that market\"\n    },\n    \"localizationNotes\": {\n      \"type\": \"string\",\n      \"description\": \"Brief explanation of key localization decisions made based on top-selling products analysis\"\n    }\n  },\n  \"additionalProperties\": false\n}",
        "autoFix": true
      },
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "typeVersion": 1.3,
      "position": [
        784,
        1440
      ],
      "id": "882e8f2e-cb62-400e-bc7a-ac4eed7911c1",
      "name": "Structured Output Parser2"
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4.1-mini"
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.2,
      "position": [
        800,
        1344
      ],
      "id": "e211b640-4860-4c3f-85eb-c716e55413c2",
      "name": "OpenAI Chat Model6",
      "credentials": {
        "openAiApi": {
          "id": "OjRKrQXB019XKwdP",
          "name": "OpenAi Account (Personal)"
        }
      }
    },
    {
      "parameters": {
        "operation": "update",
        "documentId": {
          "__rl": true,
          "value": "={{ $('Global Constants').first().json.constants.sheet_id }}",
          "mode": "id"
        },
        "sheetName": {
          "__rl": true,
          "value": "={{ $('Global Constants').first().json.constants.sheet1 }}",
          "mode": "name"
        },
        "columns": {
          "mappingMode": "defineBelow",
          "value": {
            "row_number": "={{ $('Loop Over Items').item.json.row_number }}",
            "TRANSLATED PRODUCT NAME (BEFORE)": "={{ $json.output.localizedProductName }}",
            "STATUS": "DONE"
          },
          "matchingColumns": [
            "row_number"
          ],
          "schema": [
            {
              "id": "ID",
              "displayName": "ID",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "ASIN",
              "displayName": "ASIN",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "STATUS",
              "displayName": "STATUS",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": false
            },
            {
              "id": "LANGUAGE",
              "displayName": "LANGUAGE",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "LANGUAGE_2",
              "displayName": "LANGUAGE_2",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "COUNTRY",
              "displayName": "COUNTRY",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "amazon domain",
              "displayName": "amazon domain",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "amazon language",
              "displayName": "amazon language",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Product Name (English)",
              "displayName": "Product Name (English)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "TRANSLATED PRODUCT NAME (BEFORE)",
              "displayName": "TRANSLATED PRODUCT NAME (BEFORE)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": false
            },
            {
              "id": "TRANSLATED PRODUCT NAME (AFTER)",
              "displayName": "TRANSLATED PRODUCT NAME (AFTER)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "PRIMARY TRANSLATED KEYWORD",
              "displayName": "PRIMARY TRANSLATED KEYWORD",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Product Name DB",
              "displayName": "Product Name DB",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "row_number",
              "displayName": "row_number",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "number",
              "canBeUsedToMatch": true,
              "readOnly": true,
              "removed": false
            }
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {}
      },
      "type": "n8n-nodes-base.googleSheets",
      "typeVersion": 4.7,
      "position": [
        1136,
        1456
      ],
      "id": "3d21bc95-3f61-436c-ac0b-80bc20b2cec0",
      "name": "Update row in sheet4",
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "wZJh4ACm1MD5wdQ9",
          "name": "Google Sheet (Admin Account - Nandy Cyber Success)"
        }
      }
    },
    {
      "parameters": {
        "jsCode": "let randomNumber = '';\n\nfor (let i = 0; i < 8; i++) {\n  randomNumber += Math.floor(Math.random() * 10);\n}\n\nreturn [{\n  json: {\n    randomNumber: randomNumber\n  }\n}];"
      },
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [
        -208,
        896
      ],
      "id": "bbd52e4b-1d39-48be-b2ac-a0afd7582266",
      "name": "Code in JavaScript3"
    },
    {
      "parameters": {},
      "type": "n8n-nodes-globals.globalConstants",
      "typeVersion": 1,
      "position": [
        -2944,
        48
      ],
      "id": "bee33a6b-61c2-41c8-a04a-51bccbbc0921",
      "name": "Global Constants1"
    },
    {
      "parameters": {
        "documentId": {
          "__rl": true,
          "value": "={{ $json.constants.sheet_id }}",
          "mode": "id"
        },
        "sheetName": {
          "__rl": true,
          "value": "={{ $json.constants.sheet1 }}",
          "mode": "name"
        },
        "filtersUI": {
          "values": [
            {
              "lookupColumn": "STATUS",
              "lookupValue": "DONE"
            }
          ]
        },
        "options": {
          "returnFirstMatch": false
        }
      },
      "type": "n8n-nodes-base.googleSheets",
      "typeVersion": 4.7,
      "position": [
        -2736,
        48
      ],
      "id": "4fba4003-302d-49c8-9859-40f3c65f55fe",
      "name": "Get row(s) in sheet1",
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "wZJh4ACm1MD5wdQ9",
          "name": "Google Sheet (Admin Account - Nandy Cyber Success)"
        }
      }
    },
    {
      "parameters": {
        "rule": {
          "interval": [
            {}
          ]
        }
      },
      "type": "n8n-nodes-base.scheduleTrigger",
      "typeVersion": 1.2,
      "position": [
        -3168,
        48
      ],
      "id": "df07097a-e707-4f97-a0be-e3f70095a31e",
      "name": "Schedule Trigger"
    },
    {
      "parameters": {
        "options": {}
      },
      "type": "n8n-nodes-base.splitInBatches",
      "typeVersion": 3,
      "position": [
        -2240,
        64
      ],
      "id": "951c19e8-7644-4c2e-a5b8-4e10a9d28a25",
      "name": "Loop Over Items1"
    },
    {
      "parameters": {
        "conditions": {
          "options": {
            "caseSensitive": true,
            "leftValue": "",
            "typeValidation": "strict",
            "version": 2
          },
          "conditions": [
            {
              "id": "87c41324-25f6-4e80-bab1-ad66c84654a4",
              "leftValue": "={{ $json.LANGUAGE_2 }}",
              "rightValue": "ENGLISH",
              "operator": {
                "type": "string",
                "operation": "equals",
                "name": "filter.operator.equals"
              }
            }
          ],
          "combinator": "and"
        },
        "options": {}
      },
      "type": "n8n-nodes-base.if",
      "typeVersion": 2.2,
      "position": [
        -2528,
        48
      ],
      "id": "cbefd797-9601-42a6-b0fb-9d398720dea3",
      "name": "If"
    },
    {
      "parameters": {
        "conditions": {
          "options": {
            "caseSensitive": true,
            "leftValue": "",
            "typeValidation": "strict",
            "version": 2
          },
          "conditions": [
            {
              "id": "87c41324-25f6-4e80-bab1-ad66c84654a4",
              "leftValue": "={{ $json.LANGUAGE_2 }}",
              "rightValue": "ENGLISH",
              "operator": {
                "type": "string",
                "operation": "equals",
                "name": "filter.operator.equals"
              }
            }
          ],
          "combinator": "and"
        },
        "options": {}
      },
      "type": "n8n-nodes-base.if",
      "typeVersion": 2.2,
      "position": [
        -2096,
        688
      ],
      "id": "f9e0bc84-71da-4dac-8cd5-0a41bcbfc55f",
      "name": "If1"
    },
    {
      "parameters": {
        "promptType": "define",
        "text": "=YOU ARE TO COMPARE THE FOLLOWING TRANSLATED PRODUCT NAMES AND DECIDE WHICH IS THE BESTTER PRODUCT NAME TRANSLATION AND PROVIDE REASONING.\n\nTRANSLATION 1\n{{ $json['TRANSLATED PRODUCT NAME (BEFORE)'] }}\n\nTRANSLATION 2\n{{ $json['TRANSLATED PRODUCT NAME (AFTER)'] }}\n\nORIGINAL PRODUCT NAME{{ $json['Product Name (English)'] }}\n\nLANGUAGE: {{ $json.LANGUAGE_2 }}",
        "hasOutputParser": true,
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.agent",
      "typeVersion": 2.2,
      "position": [
        -1984,
        128
      ],
      "id": "7d435363-fc64-42ff-a447-302771d48e5e",
      "name": "AI Agent3"
    },
    {
      "parameters": {
        "schemaType": "manual",
        "inputSchema": "{\n  \"$schema\": \"http://json-schema.org/draft-07/schema#\",\n  \"type\": \"object\",\n  \"required\": [\n    \"originalProductName\",\n    \"targetLanguage\",\n    \"translation1\",\n    \"translation2\",\n    \"betterTranslation\",\n    \"reasoning\"\n  ],\n  \"properties\": {\n    \"originalProductName\": {\n      \"type\": \"string\",\n      \"description\": \"The original product name in English from Amazon.com\"\n    },\n    \"targetLanguage\": {\n      \"type\": \"string\",\n      \"description\": \"The target language code (e.g., FR, ES, DE, AR)\"\n    },\n    \"targetCountry\": {\n      \"type\": \"string\",\n      \"description\": \"The target country/Amazon marketplace\"\n    },\n    \"translation1\": {\n      \"type\": \"string\",\n      \"description\": \"First translated product name option\"\n    },\n    \"translation2\": {\n      \"type\": \"string\",\n      \"description\": \"Second translated product name option\"\n    },\n    \"betterTranslation\": {\n      \"type\": \"string\",\n      \"enum\": [\"translation1\", \"translation2\"],\n      \"description\": \"Which translation is better: 'translation1' or 'translation2'\"\n    },\n    \"selectedProductName\": {\n      \"type\": \"string\",\n      \"description\": \"The actual text of the selected better translation\"\n    },\n    \"reasoning\": {\n      \"type\": \"string\",\n      \"minLength\": 50,\n      \"description\": \"Detailed explanation of why one translation is better than the other, considering SEO, localization, cultural relevance, and market conventions\"\n    }\n  },\n  \"additionalProperties\": false\n}",
        "autoFix": true
      },
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "typeVersion": 1.3,
      "position": [
        -1824,
        224
      ],
      "id": "7940790c-888c-466b-aa0b-638d2fc6aea6",
      "name": "Structured Output Parser3"
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4.1-mini"
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.2,
      "position": [
        -1872,
        368
      ],
      "id": "88b77933-9037-44fd-8586-748eb3792bbb",
      "name": "OpenAI Chat Model7",
      "credentials": {
        "openAiApi": {
          "id": "OjRKrQXB019XKwdP",
          "name": "OpenAi Account (Personal)"
        }
      }
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "value": "gpt-4o",
          "mode": "list",
          "cachedResultName": "gpt-4o"
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.2,
      "position": [
        -1984,
        304
      ],
      "id": "2fbf37ce-c06e-4309-acbe-bd5194a125e0",
      "name": "OpenAI Chat Model8",
      "credentials": {
        "openAiApi": {
          "id": "OjRKrQXB019XKwdP",
          "name": "OpenAi Account (Personal)"
        }
      }
    },
    {
      "parameters": {
        "text": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Text', ``, 'string') }}",
        "translateTo": "={{ $('Loop Over Items').item.json.LANGUAGE }}"
      },
      "type": "n8n-nodes-base.googleTranslateTool",
      "typeVersion": 2,
      "position": [
        -1936,
        368
      ],
      "id": "d4a417c3-1813-4781-b346-ae1e41956974",
      "name": "Translate a language in Google Translate1"
    },
    {
      "parameters": {
        "operation": "update",
        "documentId": {
          "__rl": true,
          "value": "={{ $('Global Constants1').first().json.constants.sheet_id }}",
          "mode": "id"
        },
        "sheetName": {
          "__rl": true,
          "value": "={{ $('Global Constants1').first().json.constants.sheet1 }}",
          "mode": "name"
        },
        "columns": {
          "mappingMode": "defineBelow",
          "value": {
            "row_number": "={{ $('Loop Over Items1').item.json.row_number }}",
            "RATING": "={{ $json.output.betterTranslation }}",
            "WINNER": "={{ $json.output.reasoning }}"
          },
          "matchingColumns": [
            "row_number"
          ],
          "schema": [
            {
              "id": "ID",
              "displayName": "ID",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "ASIN",
              "displayName": "ASIN",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "STATUS",
              "displayName": "STATUS",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "LANGUAGE",
              "displayName": "LANGUAGE",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "LANGUAGE_2",
              "displayName": "LANGUAGE_2",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "COUNTRY",
              "displayName": "COUNTRY",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "amazon domain",
              "displayName": "amazon domain",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "amazon language",
              "displayName": "amazon language",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Product Name (English)",
              "displayName": "Product Name (English)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "TRANSLATED PRODUCT NAME (BEFORE)",
              "displayName": "TRANSLATED PRODUCT NAME (BEFORE)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "TRANSLATED PRODUCT NAME (AFTER)",
              "displayName": "TRANSLATED PRODUCT NAME (AFTER)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "PRIMARY TRANSLATED KEYWORD",
              "displayName": "PRIMARY TRANSLATED KEYWORD",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Product Name DB",
              "displayName": "Product Name DB",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "RATING",
              "displayName": "RATING",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": false
            },
            {
              "id": "WINNER",
              "displayName": "WINNER",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": false
            },
            {
              "id": "row_number",
              "displayName": "row_number",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "number",
              "canBeUsedToMatch": true,
              "readOnly": true,
              "removed": false
            }
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {}
      },
      "type": "n8n-nodes-base.googleSheets",
      "typeVersion": 4.7,
      "position": [
        -1488,
        128
      ],
      "id": "1b8bc2e8-32fd-47cb-b330-8f1d240e020e",
      "name": "Update row in sheet1",
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "wZJh4ACm1MD5wdQ9",
          "name": "Google Sheet (Admin Account - Nandy Cyber Success)"
        }
      }
    },
    {
      "parameters": {
        "jsCode": "let randomNumber = '';\n\nfor (let i = 0; i < 8; i++) {\n  randomNumber += Math.floor(Math.random() * 10);\n}\n\nreturn [{\n  json: {\n    randomNumber: randomNumber\n  }\n}];"
      },
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [
        896,
        64
      ],
      "id": "e04ab6c3-34d5-4b58-ae81-c0a5f0d33739",
      "name": "Code in JavaScript4"
    },
    {
      "parameters": {
        "promptType": "define",
        "text": "=Translate the following Product Name:\n{{ $('Loop Over Items2').item.json['Product Name (English)'] }}\n\nTo the following language:\n{{ $('Loop Over Items2').item.json.LANGUAGE_2 }}\n",
        "hasOutputParser": true,
        "options": {
          "systemMessage": "=You are a Translation + e-commerce SEO assistant. You receive a product name in English that is being sold on Amazon.com and you are to translate the product name for the same exact product into the following language:\n\n{{ $('Loop Over Items2').item.json.LANGUAGE_2 }}\n\n"
        }
      },
      "type": "@n8n/n8n-nodes-langchain.agent",
      "typeVersion": 2.2,
      "position": [
        1056,
        64
      ],
      "id": "65cbec62-8cce-4d04-bc85-6af7ada22912",
      "name": "AI Agent4"
    },
    {
      "parameters": {
        "sessionIdType": "customKey",
        "sessionKey": "={{$('Code in JavaScript4').item.json.randomNumber}}",
        "contextWindowLength": 20
      },
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "typeVersion": 1.3,
      "position": [
        1088,
        112
      ],
      "id": "610d7bfa-0bbf-41a1-8866-aaba77955f8e",
      "name": "Simple Memory3"
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "value": "gpt-4o",
          "mode": "list",
          "cachedResultName": "gpt-4o"
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.2,
      "position": [
        1040,
        112
      ],
      "id": "d3e804db-6fa9-4153-8329-30f38d4851c4",
      "name": "OpenAI Chat Model9",
      "credentials": {
        "openAiApi": {
          "id": "OjRKrQXB019XKwdP",
          "name": "OpenAi Account (Personal)"
        }
      }
    },
    {
      "parameters": {
        "text": "={{ $('Loop Over Items2').item.json['Product Name (English)'] }}\n",
        "translateTo": "={{ $('Loop Over Items2').item.json.LANGUAGE }}"
      },
      "type": "n8n-nodes-base.googleTranslateTool",
      "typeVersion": 2,
      "position": [
        1056,
        208
      ],
      "id": "2f371661-ade1-44b5-9ee0-627593de3d02",
      "name": "Translate a language in Google Translate4"
    },
    {
      "parameters": {
        "schemaType": "manual",
        "inputSchema": "{\n  \"$schema\": \"http://json-schema.org/draft-07/schema#\",\n  \"type\": \"object\",\n  \"required\": [\n    \"originalProductName\",\n    \"targetLanguage\",\n    \"targetCountry\",\n    \"localizedProductName\"\n  ],\n  \"properties\": {\n    \"originalProductName\": {\n      \"type\": \"string\",\n      \"description\": \"The original product name from Amazon.com in English\"\n    },\n    \"targetLanguage\": {\n      \"type\": \"string\",\n      \"description\": \"The target language code (e.g., FR, ES, DE, AR)\"\n    },\n    \"targetCountry\": {\n      \"type\": \"string\",\n      \"description\": \"The target country/Amazon marketplace (e.g., France, Spain, Germany, Saudi Arabia)\"\n    },\n    \"localizedProductName\": {\n      \"type\": \"string\",\n      \"minLength\": 10,\n      \"maxLength\": 200,\n      \"description\": \"The localized and optimized product name for the target country's Amazon store, informed by top-selling products in that market\"\n    },\n    \"localizationNotes\": {\n      \"type\": \"string\",\n      \"description\": \"Brief explanation of key localization decisions made based on top-selling products analysis\"\n    }\n  },\n  \"additionalProperties\": false\n}",
        "autoFix": true
      },
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "typeVersion": 1.3,
      "position": [
        1136,
        288
      ],
      "id": "f4c7b0f1-04b2-4eaf-9863-1ef76786a067",
      "name": "Structured Output Parser4"
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4.1-mini"
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.2,
      "position": [
        1152,
        192
      ],
      "id": "5acf1a3d-29a9-430a-8055-ff45fe4d5f71",
      "name": "OpenAI Chat Model11",
      "credentials": {
        "openAiApi": {
          "id": "OjRKrQXB019XKwdP",
          "name": "OpenAi Account (Personal)"
        }
      }
    },
    {
      "parameters": {
        "operation": "update",
        "documentId": {
          "__rl": true,
          "value": "={{ $('Global Constants2').first().json.constants.sheet_id }}",
          "mode": "id"
        },
        "sheetName": {
          "__rl": true,
          "value": "={{ $('Global Constants2').first().json.constants.sheet1 }}",
          "mode": "name"
        },
        "columns": {
          "mappingMode": "defineBelow",
          "value": {
            "row_number": "={{ $('Loop Over Items2').item.json.row_number }}",
            "TRANSLATED PRODUCT NAME (BEFORE)": "={{ $json.output.localizedProductName }}"
          },
          "matchingColumns": [
            "row_number"
          ],
          "schema": [
            {
              "id": "ID",
              "displayName": "ID",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "ASIN",
              "displayName": "ASIN",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "STATUS",
              "displayName": "STATUS",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "LANGUAGE",
              "displayName": "LANGUAGE",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "LANGUAGE_2",
              "displayName": "LANGUAGE_2",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "COUNTRY",
              "displayName": "COUNTRY",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "amazon domain",
              "displayName": "amazon domain",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "amazon language",
              "displayName": "amazon language",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Product Name (English)",
              "displayName": "Product Name (English)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "TRANSLATED PRODUCT NAME (BEFORE)",
              "displayName": "TRANSLATED PRODUCT NAME (BEFORE)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": false
            },
            {
              "id": "TRANSLATED PRODUCT NAME (AFTER)",
              "displayName": "TRANSLATED PRODUCT NAME (AFTER)",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "PRIMARY TRANSLATED KEYWORD",
              "displayName": "PRIMARY TRANSLATED KEYWORD",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Product Name DB",
              "displayName": "Product Name DB",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "RATING",
              "displayName": "RATING",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "WINNER",
              "displayName": "WINNER",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "row_number",
              "displayName": "row_number",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "number",
              "canBeUsedToMatch": true,
              "readOnly": true,
              "removed": false
            }
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {}
      },
      "type": "n8n-nodes-base.googleSheets",
      "typeVersion": 4.7,
      "position": [
        1488,
        256
      ],
      "id": "bb3c56fb-af4c-46c8-b638-696990bac3a9",
      "name": "Update row in sheet5",
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "wZJh4ACm1MD5wdQ9",
          "name": "Google Sheet (Admin Account - Nandy Cyber Success)"
        }
      }
    },
    {
      "parameters": {
        "documentId": {
          "__rl": true,
          "value": "={{ $json.constants.sheet_id }}",
          "mode": "id"
        },
        "sheetName": {
          "__rl": true,
          "value": "={{ $json.constants.sheet1 }}",
          "mode": "name"
        },
        "filtersUI": {
          "values": [
            {
              "lookupColumn": "STATUS",
              "lookupValue": "DONE"
            }
          ]
        },
        "options": {
          "returnFirstMatch": false
        }
      },
      "type": "n8n-nodes-base.googleSheets",
      "typeVersion": 4.7,
      "position": [
        176,
        -48
      ],
      "id": "809aafab-5fba-44b8-bede-e202698d292d",
      "name": "Get row(s) in sheet2",
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "wZJh4ACm1MD5wdQ9",
          "name": "Google Sheet (Admin Account - Nandy Cyber Success)"
        }
      }
    },
    {
      "parameters": {
        "rule": {
          "interval": [
            {}
          ]
        }
      },
      "type": "n8n-nodes-base.scheduleTrigger",
      "typeVersion": 1.2,
      "position": [
        -192,
        -48
      ],
      "id": "0abf2ac3-2cd3-458e-ad03-3072f4200cfc",
      "name": "Schedule Trigger1"
    },
    {
      "parameters": {},
      "type": "n8n-nodes-globals.globalConstants",
      "typeVersion": 1,
      "position": [
        -16,
        -48
      ],
      "id": "4b98973c-373a-4d9c-888d-e176a29fa8c7",
      "name": "Global Constants2"
    },
    {
      "parameters": {
        "conditions": {
          "options": {
            "caseSensitive": true,
            "leftValue": "",
            "typeValidation": "strict",
            "version": 2
          },
          "conditions": [
            {
              "id": "c2b734da-57f8-40f3-8a98-feedebc9f5ff",
              "leftValue": "={{ $json.LANGUAGE_2 }}",
              "rightValue": "ENGLISH",
              "operator": {
                "type": "string",
                "operation": "equals",
                "name": "filter.operator.equals"
              }
            }
          ],
          "combinator": "and"
        },
        "options": {}
      },
      "type": "n8n-nodes-base.if",
      "typeVersion": 2.2,
      "position": [
        384,
        -48
      ],
      "id": "2535beeb-bf9a-4720-b553-f9bb2c08dc4d",
      "name": "If2"
    },
    {
      "parameters": {
        "options": {}
      },
      "type": "n8n-nodes-base.splitInBatches",
      "typeVersion": 3,
      "position": [
        592,
        48
      ],
      "id": "8f96159c-a192-43d0-8e66-8745f8375a17",
      "name": "Loop Over Items2"
    }
  ],
  "pinData": {},
  "connections": {
    "When clicking ‘Execute workflow’": {
      "main": [
        [
          {
            "node": "Global Constants",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Global Constants": {
      "main": [
        [
          {
            "node": "Get row(s) in sheet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get row(s) in sheet": {
      "main": [
        [
          {
            "node": "Code in JavaScript1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI Agent": {
      "main": [
        [
          {
            "node": "Update row in sheet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Amazon search": {
      "main": [
        [
          {
            "node": "Split Out",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Simple Memory": {
      "ai_memory": [
        [
          {
            "node": "AI Agent",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "Translate a language in Google Translate": {
      "ai_tool": [
        [
          {
            "node": "AI Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Brave Search": {
      "ai_tool": [
        [
          {
            "node": "AI Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "AI Agent",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Structured Output Parser": {
      "ai_outputParser": [
        [
          {
            "node": "AI Agent",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model1": {
      "ai_languageModel": [
        [
          {
            "node": "Structured Output Parser",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Code in JavaScript1": {
      "main": [
        [
          {
            "node": "Split Out1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Update row in sheet": {
      "main": [
        [
          {
            "node": "Amazon search",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out": {
      "main": [
        [
          {
            "node": "Edit Fields1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Edit Fields1": {
      "main": [
        [
          {
            "node": "Aggregate",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Aggregate": {
      "main": [
        [
          {
            "node": "Update row in sheet2",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI Agent1": {
      "main": [
        [
          {
            "node": "Update row in sheet3",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Simple Memory1": {
      "ai_memory": [
        [
          {
            "node": "AI Agent1",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model2": {
      "ai_languageModel": [
        [
          {
            "node": "AI Agent1",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Structured Output Parser1": {
      "ai_outputParser": [
        [
          {
            "node": "AI Agent1",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model3": {
      "ai_languageModel": [
        [
          {
            "node": "Structured Output Parser1",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Split Out1": {
      "main": [
        [
          {
            "node": "Loop Over Items",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Loop Over Items": {
      "main": [
        [],
        [
          {
            "node": "If1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Code in JavaScript": {
      "main": [
        [
          {
            "node": "AI Agent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Update row in sheet2": {
      "main": [
        [
          {
            "node": "Code in JavaScript3",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Translate a language in Google Translate2": {
      "ai_tool": [
        [
          {
            "node": "AI Agent1",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Update row in sheet3": {
      "main": [
        [
          {
            "node": "Code in JavaScript2",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Code in JavaScript2": {
      "main": [
        [
          {
            "node": "AI Agent2",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI Agent2": {
      "main": [
        [
          {
            "node": "Update row in sheet4",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Simple Memory2": {
      "ai_memory": [
        [
          {
            "node": "AI Agent2",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model4": {
      "ai_languageModel": [
        [
          {
            "node": "AI Agent2",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Translate a language in Google Translate3": {
      "ai_tool": [
        [
          {
            "node": "AI Agent2",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Structured Output Parser2": {
      "ai_outputParser": [
        [
          {
            "node": "AI Agent2",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model6": {
      "ai_languageModel": [
        [
          {
            "node": "Structured Output Parser2",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Update row in sheet4": {
      "main": [
        [
          {
            "node": "Loop Over Items",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Code in JavaScript3": {
      "main": [
        [
          {
            "node": "AI Agent1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Global Constants1": {
      "main": [
        [
          {
            "node": "Get row(s) in sheet1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get row(s) in sheet1": {
      "main": [
        [
          {
            "node": "If",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Schedule Trigger": {
      "main": [
        [
          {
            "node": "Global Constants1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Loop Over Items1": {
      "main": [
        [],
        [
          {
            "node": "AI Agent3",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "If": {
      "main": [
        [],
        [
          {
            "node": "Loop Over Items1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "If1": {
      "main": [
        [],
        [
          {
            "node": "Code in JavaScript",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI Agent3": {
      "main": [
        [
          {
            "node": "Update row in sheet1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Structured Output Parser3": {
      "ai_outputParser": [
        [
          {
            "node": "AI Agent3",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model7": {
      "ai_languageModel": [
        [
          {
            "node": "Structured Output Parser3",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model8": {
      "ai_languageModel": [
        [
          {
            "node": "AI Agent3",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Translate a language in Google Translate1": {
      "ai_tool": [
        [
          {
            "node": "AI Agent3",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Update row in sheet1": {
      "main": [
        [
          {
            "node": "Loop Over Items1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Code in JavaScript4": {
      "main": [
        [
          {
            "node": "AI Agent4",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI Agent4": {
      "main": [
        [
          {
            "node": "Update row in sheet5",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Simple Memory3": {
      "ai_memory": [
        [
          {
            "node": "AI Agent4",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model9": {
      "ai_languageModel": [
        [
          {
            "node": "AI Agent4",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Translate a language in Google Translate4": {
      "ai_tool": [
        [
          {
            "node": "AI Agent4",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Structured Output Parser4": {
      "ai_outputParser": [
        [
          {
            "node": "AI Agent4",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model11": {
      "ai_languageModel": [
        [
          {
            "node": "Structured Output Parser4",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Update row in sheet5": {
      "main": [
        [
          {
            "node": "Loop Over Items2",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get row(s) in sheet2": {
      "main": [
        [
          {
            "node": "If2",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Schedule Trigger1": {
      "main": [
        [
          {
            "node": "Global Constants2",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Global Constants2": {
      "main": [
        [
          {
            "node": "Get row(s) in sheet2",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "If2": {
      "main": [
        [],
        [
          {
            "node": "Loop Over Items2",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Loop Over Items2": {
      "main": [
        [],
        [
          {
            "node": "Code in JavaScript4",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "active": false,
  "settings": {
    "executionOrder": "v1",
    "availableInMCP": false
  },
  "versionId": "def98192-efa2-419a-89c4-d452aacbc862",
  "meta": {
    "instanceId": "5ff5a5992c4c72af22abbdcfa574d8cdf93dc14d57eb9f66e3d9ef2a3e2dbb6c"
  },
  "id": "RPOFJ4iJRyTmOS7K",
  "tags": []
}