{
  "name": "Fushimi Bot",
  "nodes": [
    {
      "parameters": {
        "httpMethod": "POST",
        "path": "line-bot",
        "options": {
          "responseCode": {
            "values": {}
          }
        }
      },
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 2.1,
      "position": [
        12192,
        2320
      ],
      "id": "917a7b3c-2c29-4aff-9211-7447222d093f",
      "name": "Webhook"
    },
    {
      "parameters": {
        "jsCode": "// Get LINE webhook data with comprehensive error handling\ntry {\n  const body = $input.item.json.body;\n\n  // Validate body exists\n  if (!body) {\n    console.log('No body in webhook request');\n    return [];\n  }\n\n  // Check if events present\n  if (!body.events || !Array.isArray(body.events) || body.events.length === 0) {\n    console.log('No events in webhook request');\n    return [];\n  }\n\n  // Parse first event (LINE sends one event per request typically)\n  const event = body.events[0];\n\n  // Validate event structure\n  if (!event || !event.type) {\n    console.log('Invalid event structure');\n    return [];\n  }\n\n  // Only process text messages\n  if (event.type !== 'message' || event.message?.type !== 'text') {\n    console.log(`Ignoring non-text event: ${event.type}`);\n    return [];\n  }\n\n  // Validate required fields\n  if (!event.replyToken || !event.source?.userId || !event.message?.text) {\n    console.log('Missing required fields in event');\n    return [];\n  }\n\n  // Extract necessary information\n  return {\n    json: {\n      replyToken: event.replyToken,\n      userId: event.source.userId,\n      userMessage: event.message.text,\n      timestamp: event.timestamp || Date.now()\n    }\n  };\n} catch (error) {\n  console.error('Error in Initial Parse:', error);\n  return [];\n}"
      },
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [
        12480,
        2640
      ],
      "id": "8828e85b-dd8e-4fbd-bd66-ad0e0a3dbb5a",
      "name": "Initial Parse"
    },
    {
      "parameters": {
        "promptType": "define",
        "text": "={{ $json.userMessage }}",
        "options": {
          "systemMessage": "=\u4eca\u5929\u65e5\u671f\u662f {{ $now.format('YYYY/MM/DD') }}\n\u76ee\u524d\u4f0f\u898b\u5bb6\u6210\u54e1\u90fd\u5728\u65e5\u672c\u6771\u4eac\n\n\u4f60\u662f\u4f0f\u898b\u5bb6\u5c08\u5c6c\u7684\u5f97\u529bAI\u52a9\u624b\u3002\u8acb\u4e00\u5f8b\u4f7f\u7528\u7e41\u9ad4\u4e2d\u6587\uff08\u53f0\u7063\u7528\u8a9e\uff09\u56de\u8986\u3002"
        }
      },
      "type": "@n8n/n8n-nodes-langchain.agent",
      "typeVersion": 3.1,
      "position": [
        12912,
        2640
      ],
      "id": "55498d4c-867d-441c-9aab-c14098f69c20",
      "name": "AI Agent",
      "onError": "continueErrorOutput"
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "claude-sonnet-4-5-20250929",
          "cachedResultName": "Claude Sonnet 4.5"
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatAnthropic",
      "typeVersion": 1.3,
      "position": [
        12480,
        2880
      ],
      "id": "9d50800d-e5a1-4460-a06f-858fef14694b",
      "name": "Anthropic Chat Model",
      "credentials": {
        "anthropicApi": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "sessionIdType": "customKey",
        "sessionKey": "=line:{{ $('Initial Parse').item.json.userId }}",
        "sessionTTL": 3600
      },
      "type": "@n8n/n8n-nodes-langchain.memoryRedisChat",
      "typeVersion": 1.5,
      "position": [
        12480,
        3088
      ],
      "id": "77db1f6d-520d-4d7e-80c6-ac3cce52c40e",
      "name": "Redis Chat Memory",
      "credentials": {
        "redis": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "jsCode": "// Prepare response text for LINE\ntry {\n  const input = $input.item.json;\n  const initialData = $('Initial Parse').item.json;\n  \n  let responseText = '';\n  \n  // Check for AI Agent output format\n  if (input.output && typeof input.output === 'string') {\n    responseText = input.output;\n  }\n  // Fallback\n  else {\n    responseText = '\u62b1\u6b49\uff0c\u6211\u7121\u6cd5\u751f\u6210\u56de\u61c9\u3002\u8acb\u518d\u8a66\u4e00\u6b21\u3002';\n  }\n\n  // Truncate if too long (LINE has a 5000 character limit)\n  const MAX_LENGTH = 4500;\n  if (responseText.length > MAX_LENGTH) {\n    responseText = responseText.substring(0, MAX_LENGTH) + '...\\n\\n(\u8a0a\u606f\u904e\u9577\uff0c\u5df2\u622a\u65b7)';\n  }\n\n  return {\n    json: {\n      responseText: responseText,\n      replyToken: initialData.replyToken,\n      isError: false\n    }\n  };\n} catch (error) {\n  console.error('Error in Format Response:', error);\n  return {\n    json: {\n      responseText: '\u7cfb\u7d71\u767c\u751f\u932f\u8aa4\uff0c\u8acb\u7a0d\u5f8c\u518d\u8a66\u3002',\n      replyToken: $('Initial Parse').item?.json?.replyToken,\n      isError: true\n    }\n  };\n}"
      },
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [
        13616,
        2624
      ],
      "id": "3d4c1040-5123-4960-bc7e-ca8723947550",
      "name": "Format Response for LINE"
    },
    {
      "parameters": {
        "jsCode": "// Handle AI Agent errors\ntry {\n  const errorInput = $input.item.json;\n  const initialData = $('Initial Parse').item.json;\n\n  let errorMessage = '\u62b1\u6b49\uff0c\u6211\u73fe\u5728\u9047\u5230\u4e00\u4e9b\u554f\u984c\u3002\u8acb\u7a0d\u5f8c\u518d\u8a66\u3002';\n  let errorType = 'unknown';\n\n  if (errorInput.error) {\n    const error = errorInput.error;\n    \n    if (error.response) {\n      const statusCode = error.response.statusCode;\n      \n      if (statusCode === 429) {\n        errorMessage = '\u7cfb\u7d71\u76ee\u524d\u4f7f\u7528\u91cf\u8f03\u5927\uff0c\u8acb\u7a0d\u5f8c\u518d\u8a66\u3002';\n        errorType = 'rate_limit';\n      } else if (statusCode === 401 || statusCode === 403) {\n        errorMessage = '\u7cfb\u7d71\u8a2d\u5b9a\u6709\u8aa4\uff0c\u8acb\u806f\u7d61\u7ba1\u7406\u54e1\u3002';\n        errorType = 'auth_error';\n      } else if (statusCode >= 500) {\n        errorMessage = 'AI\u670d\u52d9\u66ab\u6642\u7121\u6cd5\u4f7f\u7528\uff0c\u8acb\u7a0d\u5f8c\u518d\u8a66\u3002';\n        errorType = 'server_error';\n      } else if (statusCode === 400) {\n        errorMessage = '\u8a0a\u606f\u683c\u5f0f\u6709\u8aa4\uff0c\u8acb\u91cd\u65b0\u8f38\u5165\u3002';\n        errorType = 'bad_request';\n      }\n    } else if (error.code === 'ETIMEDOUT' || error.code === 'ESOCKETTIMEDOUT') {\n      errorMessage = '\u8acb\u6c42\u8d85\u6642\uff0c\u8acb\u7a0d\u5f8c\u518d\u8a66\u3002';\n      errorType = 'timeout';\n    }\n  }\n\n  console.error(`AI Agent Error - Type: ${errorType}, Error:`, errorInput.error);\n\n  return {\n    json: {\n      replyToken: initialData?.replyToken,\n      responseText: errorMessage,\n      errorType: errorType,\n      isError: true\n    }\n  };\n} catch (error) {\n  console.error('Error in Error Handler:', error);\n  return {\n    json: {\n      replyToken: $('Initial Parse').item?.json?.replyToken,\n      responseText: '\u7cfb\u7d71\u767c\u751f\u932f\u8aa4\uff0c\u8acb\u7a0d\u5f8c\u518d\u8a66\u3002',\n      errorType: 'handler_error',\n      isError: true\n    }\n  };\n}"
      },
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [
        13616,
        2848
      ],
      "id": "f4531ae5-c589-402a-b06b-e7219984c98e",
      "name": "Handle Error"
    },
    {
      "parameters": {
        "method": "POST",
        "url": "https://api.line.me/v2/bot/message/reply",
        "authentication": "genericCredentialType",
        "genericAuthType": "httpBearerAuth",
        "sendHeaders": true,
        "headerParameters": {
          "parameters": [
            {
              "name": "Content-Type",
              "value": "application/json"
            }
          ]
        },
        "sendBody": true,
        "specifyBody": "json",
        "jsonBody": "={\n  \"replyToken\": \"{{ $json.replyToken }}\",\n  \"messages\": [\n    {\n      \"type\": \"text\",\n      \"text\": {{ JSON.stringify($json.responseText) }}\n    }\n  ]\n}",
        "options": {
          "timeout": 10000
        }
      },
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 4.3,
      "position": [
        13952,
        2624
      ],
      "id": "ad898e19-ed36-4388-8ba8-3f6ffe167c67",
      "name": "Send back to Line Bot",
      "credentials": {
        "httpBearerAuth": {
          "name": "<your credential>"
        }
      },
      "continueOnFail": true
    },
    {
      "parameters": {
        "description": "\u7576\u7528\u6236\u8a62\u554f\u5929\u6c23\u3001\u6c23\u6eab\u3001\u964d\u96e8\u3001\u6c23\u5019\u7b49\u76f8\u95dc\u554f\u984c\u6642\u547c\u53eb\u6b64\u5de5\u5177\u3002\n\u53ef\u67e5\u8a62\u5168\u7403\u4efb\u4f55\u5730\u9ede\u7684\u5373\u6642\u5929\u6c23\u548c\u672a\u4f86\u9810\u5831\u3002\n\n\u652f\u63f4\u683c\u5f0f\uff1a\n- \u53f0\u7063\u57ce\u5e02\u540d\u7a31\uff1a\u53f0\u5317\u3001\u9ad8\u96c4\u3001\u53f0\u4e2d\u7b49\n- \u570b\u969b\u57ce\u5e02\uff1aTokyo\u3001London\u3001New York \u6216 \u6771\u4eac\u3001\u502b\u6566\u3001\u7d10\u7d04\n- \u4efb\u4f55\u5730\u9ede\u540d\u7a31\uff1a\u6703\u81ea\u52d5\u9032\u884c\u5730\u7406\u7de8\u78bc\u67e5\u8a62\n\n\u63d0\u4f9b\u8cc7\u8a0a\uff1a\n- \u76ee\u524d\u6eab\u5ea6\u3001\u9ad4\u611f\u6eab\u5ea6\u3001\u5929\u6c23\u72c0\u6cc1\n- \u6fd5\u5ea6\u3001\u98a8\u901f\u3001\u6c23\u58d3\u3001\u7d2b\u5916\u7dda\u6307\u6578\n- \u672a\u4f86 6 \u5c0f\u6642\u9010\u6642\u9810\u5831\n- \u672a\u4f86 5 \u5929\u6bcf\u65e5\u9810\u5831\n- \u964d\u96e8\u6a5f\u7387",
        "workflowId": {
          "__rl": true,
          "value": "KoxGKHtAH5p6f3Ql",
          "mode": "list",
          "cachedResultUrl": "/workflow/KoxGKHtAH5p6f3Ql",
          "cachedResultName": "Weather Lookup"
        },
        "workflowInputs": {
          "mappingMode": "defineBelow",
          "value": {
            "lat": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('lat', ``, 'string') }}",
            "lon": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('lon', ``, 'string') }}",
            "location": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('location', ``, 'string') }}"
          },
          "matchingColumns": [],
          "schema": [
            {
              "id": "lat",
              "displayName": "lat",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "canBeUsedToMatch": true,
              "type": "string",
              "removed": false
            },
            {
              "id": "lon",
              "displayName": "lon",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "canBeUsedToMatch": true,
              "type": "string",
              "removed": false
            },
            {
              "id": "location",
              "displayName": "location",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "canBeUsedToMatch": true,
              "type": "string",
              "removed": false
            }
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        }
      },
      "type": "@n8n/n8n-nodes-langchain.toolWorkflow",
      "typeVersion": 2.2,
      "position": [
        12768,
        3232
      ],
      "id": "08116224-d2a9-4e13-bb9f-c410fd33c95c",
      "name": "Weather Lookup"
    },
    {
      "parameters": {
        "description": "\u7576\u7528\u6236\u60f3\u8981\u8a18\u9304\u6d88\u8cbb\u6216\u652f\u51fa\u6642\u547c\u53eb\u6b64\u5de5\u5177\u3002\n\u5c07\u7528\u6236\u63cf\u8ff0\u7684\u6d88\u8cbb\u5167\u5bb9\u89e3\u6790\u5f8c\u5beb\u5165 Google Sheet \u5e33\u672c\u3002\n\n\u91cd\u8981\uff1aDate \u6b04\u4f4d\u6c7a\u5b9a\u5beb\u5165\u54ea\u500b\u6708\u4efd\u7684\u5e33\u672c\uff08\u4f8b\u5982 2026/3/15 \u6703\u5beb\u5165\u300c2026 3\u6708 \u958b\u652f\u6e05\u55ae\u300d\uff09\uff0c\u56e0\u6b64\u5fc5\u9808\u6839\u64da\u7528\u6236\u63cf\u8ff0\u7684\u6d88\u8cbb\u6642\u9593\u6e96\u78ba\u586b\u5165\uff0c\u672a\u6307\u5b9a\u5247\u7528\u4eca\u5929\u65e5\u671f\u3002\n\n\u6b04\u4f4d\u8aaa\u660e\uff1a\n- Title\uff1a\u6d88\u8cbb\u9805\u76ee\u540d\u7a31\u6216\u5e97\u540d\n- Date\uff1a\u6d88\u8cbb\u65e5\u671f\uff0c\u683c\u5f0f YYYY/M/D\uff08\u6b64\u6b04\u4f4d\u6c7a\u5b9a\u5beb\u5165\u54ea\u500b\u6708\u7684\u5e33\u672c\uff0c\u5fc5\u586b\uff09\n- Currency\uff1a\u5e63\u503c\uff0c\u53ea\u80fd\u662f TWD / JPY / USD\uff0c\u672a\u6307\u5b9a\u9810\u8a2d TWD\n- Amount\uff1a\u91d1\u984d\uff0c\u7d14\u6578\u5b57\u4e0d\u542b\u7b26\u865f\n- Category\uff1a\u5206\u985e\uff0c\u53ea\u80fd\u5f9e\u4ee5\u4e0b\u9078\u64c7\uff1a\u5916\u98df\u3001\u4ea4\u901a\u3001\u751f\u6d3b\u958b\u92b7\u3001\u5a1b\u6a02\u3001\u6bcf\u6708\u56fa\u5b9a\u652f\u51fa\u3001\u6295\u8cc7\u5b78\u7fd2\u3001\u5176\u4ed6\n- Comment\uff1a\u5099\u8a3b\u8aaa\u660e\uff0c\u53ef\u4ee5\u70ba\u7a7a",
        "workflowId": {
          "__rl": true,
          "value": "eiN6MVGVBXtsxHcm",
          "mode": "list",
          "cachedResultUrl": "/workflow/eiN6MVGVBXtsxHcm",
          "cachedResultName": "Write Expense Sheet"
        },
        "workflowInputs": {
          "mappingMode": "defineBelow",
          "value": {
            "Amount": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Amount', ``, 'number') }}",
            "Title": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Title', ``, 'string') }}",
            "Date": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Date', ``, 'string') }}",
            "Currency": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Currency', `TWD / JPY / USD`, 'string') }}",
            "Category": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Category', `\u5916\u98df/\u4ea4\u901a/\u751f\u6d3b\u958b\u92b7/\u5a1b\u6a02/\u6bcf\u6708\u56fa\u5b9a\u652f\u51fa/\u6295\u8cc7\u5b78\u7fd2/\u5176\u4ed6`, 'string') }}",
            "Comment": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Comment', ``, 'string') }}"
          },
          "matchingColumns": [],
          "schema": [
            {
              "id": "Title",
              "displayName": "Title",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "canBeUsedToMatch": true,
              "type": "string",
              "removed": false
            },
            {
              "id": "Date",
              "displayName": "Date",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "canBeUsedToMatch": true,
              "type": "string",
              "removed": false
            },
            {
              "id": "Currency",
              "displayName": "Currency",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "canBeUsedToMatch": true,
              "type": "string",
              "removed": false
            },
            {
              "id": "Amount",
              "displayName": "Amount",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "canBeUsedToMatch": true,
              "type": "number",
              "removed": false
            },
            {
              "id": "Category",
              "displayName": "Category",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "canBeUsedToMatch": true,
              "type": "string",
              "removed": false
            },
            {
              "id": "Comment",
              "displayName": "Comment",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "canBeUsedToMatch": true,
              "type": "string",
              "removed": false
            }
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        }
      },
      "type": "@n8n/n8n-nodes-langchain.toolWorkflow",
      "typeVersion": 2.2,
      "position": [
        12928,
        3232
      ],
      "id": "50ef2305-034c-46bc-9a31-c32e9a7bd09c",
      "name": "Write to Google Sheet Accounting"
    },
    {
      "parameters": {
        "description": "\u7576\u8b80\u53d6 Google Sheets \u958b\u92b7\u8a18\u9304\u6642\uff0c\u6bcf\u4e00\u884c\u5305\u542b\u4ee5\u4e0b\u6b04\u4f4d\uff1a\n- \u9805\u76ee (A\u6b04)\n- \u65e5\u671f (B\u6b04) \n- \u5e63\u503c (C\u6b04)\n- \u91d1\u984d (D\u6b04)\n- \u5206\u985e (E\u6b04) - \u53ef\u80fd\u7684\u503c\uff1a\u300c\u751f\u6d3b\u958b\u92b7\u300d\u3001\u300c\u5916\u98df\u300d\u3001\u300c\u4ea4\u901a\u300d\u7b49\n- \u8a3b\u8a18 (F\u6b04)\n\n\u5de5\u5177\u4f7f\u7528\u7bc4\u4f8b\uff1a\n- \"\u4e8c\u6708\u6211\u82b1\u5728\u5916\u98df\u4e0a\u7684\u8cbb\u7528\u6709\u591a\u5c11\uff1f\" \u2192 read_expense_sheet(year=2025, month=2, queryType=\"details\", category=\"\u5916\u98df\")\n- \"\u5e6b\u6211\u770b\u4e00\u6708\u7684\u958b\u652f\u7e3d\u7d50\" \u2192 read_expense_sheet(year=2025, month=1, queryType=\"summary\")\n- \"\u9019\u500b\u6708\u5a1b\u6a02\u82b1\u4e86\u591a\u5c11\uff1f\" \u2192 read_expense_sheet(year=\u7576\u524d\u5e74, month=\u7576\u524d\u6708, queryType=\"details\", category=\"\u5a1b\u6a02\")\n\n\u6ce8\u610f\u4e8b\u9805\uff1a\n1. \u5f9e\u7528\u6236\u554f\u984c\u4e2d\u63d0\u53d6\u5e74\u4efd\u548c\u6708\u4efd\uff0c\u5982\u679c\u6c92\u6709\u6307\u5b9a\u5247\u4f7f\u7528\u7576\u524d\u6642\u9593\n2. \u5224\u65b7\u7528\u6236\u662f\u8981\u770b\u7d30\u9805(details)\u9084\u662f\u7e3d\u7d50(summary)\n3. \u5982\u679c\u7528\u6236\u63d0\u5230\u7279\u5b9a\u985e\u5225\uff08\u5916\u98df\u3001\u4ea4\u901a\u3001\u5a1b\u6a02\u7b49\uff09\uff0c\u8981\u5e36\u5165 category \u53c3\u6578",
        "workflowId": {
          "__rl": true,
          "value": "cQiKWswNrSR08KtJ",
          "mode": "list",
          "cachedResultUrl": "/workflow/cQiKWswNrSR08KtJ",
          "cachedResultName": "Read Expense Sheet"
        },
        "workflowInputs": {
          "mappingMode": "defineBelow",
          "value": {
            "year": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('year', ``, 'string') }}",
            "month": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('month', ``, 'string') }}",
            "queryType": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('queryType', ``, 'string') }}",
            "category": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('category', ``, 'string') }}"
          },
          "matchingColumns": [],
          "schema": [
            {
              "id": "year",
              "displayName": "year",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "canBeUsedToMatch": true,
              "type": "string"
            },
            {
              "id": "month",
              "displayName": "month",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "canBeUsedToMatch": true,
              "type": "string"
            },
            {
              "id": "queryType",
              "displayName": "queryType",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "canBeUsedToMatch": true,
              "type": "string"
            },
            {
              "id": "category",
              "displayName": "category",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "canBeUsedToMatch": true,
              "type": "string"
            }
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        }
      },
      "type": "@n8n/n8n-nodes-langchain.toolWorkflow",
      "typeVersion": 2.2,
      "position": [
        13088,
        3232
      ],
      "id": "a2fe8820-212a-4140-b4f5-912d00cd63e8",
      "name": "Read Google Sheet Accounting"
    }
  ],
  "connections": {
    "Webhook": {
      "main": [
        [
          {
            "node": "Initial Parse",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Initial Parse": {
      "main": [
        [
          {
            "node": "AI Agent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI Agent": {
      "main": [
        [
          {
            "node": "Format Response for LINE",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Handle Error",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Format Response for LINE": {
      "main": [
        [
          {
            "node": "Send back to Line Bot",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Handle Error": {
      "main": [
        [
          {
            "node": "Send back to Line Bot",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Anthropic Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "AI Agent",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Redis Chat Memory": {
      "ai_memory": [
        [
          {
            "node": "AI Agent",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "Weather Lookup": {
      "ai_tool": [
        [
          {
            "node": "AI Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Write to Google Sheet Accounting": {
      "ai_tool": [
        [
          {
            "node": "AI Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Read Google Sheet Accounting": {
      "ai_tool": [
        [
          {
            "node": "AI Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    }
  },
  "active": true,
  "settings": {
    "executionOrder": "v1",
    "availableInMCP": false,
    "timeSavedMode": "fixed",
    "callerPolicy": "workflowsFromSameOwner",
    "saveDataSuccessExecution": "all"
  },
  "versionId": "600ccf80-fe8b-49ab-9083-9a0d6ce348c4",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "id": "HItnbCIwqkOXj3DekxY0x",
  "tags": []
}