適応型メール自動返信(GPT-4、RAG、および人間フィードバックループ)

上級

これはContent Creation, Multimodal AI分野の自動化ワークフローで、38個のノードを含みます。主にIf, Set, Gmail, Switch, Markdownなどのノードを使用。 適応型メール自動返信機能(GPT-4、RAG、人間フィードバックループ)

前提条件
  • Googleアカウント + Gmail API認証情報
  • Google Sheets API認証情報
  • OpenAI API Key
  • Supabase URL と API Key
ワークフロープレビュー
ノード接続関係を可視化、ズームとパンをサポート
ワークフローをエクスポート
以下のJSON設定をn8nにインポートして、このワークフローを使用できます
{
  "meta": {
    "instanceId": "205780d3749915e5b72849aad8492ed96140f3a3cf0d7f077a27e6df51ded409",
    "templateCredsSetupCompleted": true
  },
  "nodes": [
    {
      "id": "e432c58f-163b-4a96-8a23-5c2749c2bcd1",
      "name": "Embeddings OpenAI",
      "type": "@n8n/n8n-nodes-langchain.embeddingsOpenAi",
      "position": [
        368,
        960
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "25b0117a-152b-4ad3-9114-606d42a8d7f1",
      "name": "Supabase Vector Store",
      "type": "@n8n/n8n-nodes-langchain.vectorStoreSupabase",
      "position": [
        400,
        800
      ],
      "parameters": {},
      "typeVersion": 1.1
    },
    {
      "id": "8fbca9a7-f3cc-4d13-ba37-427d62cedc9d",
      "name": "OpenAI Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        176,
        800
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "d67fb10b-10f5-4d02-9a9d-1d69c07fd658",
      "name": "AIエージェント",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        384,
        416
      ],
      "parameters": {},
      "typeVersion": 1.8
    },
    {
      "id": "0b7e252b-8e97-4ec7-9d9e-2ee120cb09a7",
      "name": "自動修正出力パーサー",
      "type": "@n8n/n8n-nodes-langchain.outputParserAutofixing",
      "position": [
        720,
        800
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "8156059d-5ae2-41a4-bc27-92ff8f2a46b7",
      "name": "OpenAI Chat Model1",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        656,
        960
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "f543ac29-3eb4-4554-b6aa-0e2285cdfb6b",
      "name": "構造化出力パーサー",
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "position": [
        848,
        960
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "85b72d77-0541-45e6-b037-770acec610e9",
      "name": "条件分岐",
      "type": "n8n-nodes-base.if",
      "position": [
        1040,
        416
      ],
      "parameters": {},
      "typeVersion": 2.2
    },
    {
      "id": "dc370570-4695-4ba9-9c46-8f08472bc910",
      "name": "動的プロンプト取得",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        -448,
        416
      ],
      "parameters": {},
      "typeVersion": 4.6
    },
    {
      "id": "a064b42d-5aba-4745-8ed5-4adde17b1dd4",
      "name": "フィールド編集",
      "type": "n8n-nodes-base.set",
      "position": [
        16,
        416
      ],
      "parameters": {},
      "typeVersion": 3.4
    },
    {
      "id": "d8cec49d-2aa5-413e-af1b-9c77895e91d5",
      "name": "Gmail",
      "type": "n8n-nodes-base.gmail",
      "position": [
        1296,
        656
      ],
      "webhookId": "82b32cdc-6587-4822-bfdc-03ea10edba0e",
      "parameters": {},
      "typeVersion": 2.1
    },
    {
      "id": "55196c92-edcd-4dc7-ad96-48ab287d81bf",
      "name": "Google Sheets",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1488,
        352
      ],
      "parameters": {},
      "typeVersion": 4.6
    },
    {
      "id": "02fcd994-63fc-4b9c-a9b5-61c6562abb5c",
      "name": "Markdown",
      "type": "n8n-nodes-base.markdown",
      "position": [
        1296,
        352
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "2a83bb18-6ef0-42f2-ab9d-75b3bcc1a35e",
      "name": "Google Sheetsトリガー",
      "type": "n8n-nodes-base.googleSheetsTrigger",
      "position": [
        -944,
        1584
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "0cee2309-721d-4ed9-b1be-9b7607cc22fe",
      "name": "OpenAI Chat Model2",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        -176,
        1792
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "acc3ff75-16c4-4737-a25f-f7527898e387",
      "name": "情報抽出器",
      "type": "@n8n/n8n-nodes-langchain.informationExtractor",
      "position": [
        -160,
        1584
      ],
      "parameters": {},
      "typeVersion": 1.1
    },
    {
      "id": "6605a7d8-cd6c-4260-a698-229139887305",
      "name": "条件分岐1",
      "type": "n8n-nodes-base.if",
      "position": [
        -720,
        1584
      ],
      "parameters": {},
      "typeVersion": 2.2
    },
    {
      "id": "12ea4994-6d77-4094-853c-38c1430bfcc8",
      "name": "オリジナル返信",
      "type": "n8n-nodes-base.markdown",
      "position": [
        -208,
        416
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "5620dca5-25ce-412e-8984-068ae1c8a3fb",
      "name": "条件分岐2",
      "type": "n8n-nodes-base.if",
      "position": [
        -720,
        416
      ],
      "parameters": {},
      "typeVersion": 2.2
    },
    {
      "id": "b0e81371-4e0b-437d-9e9e-17cb4588fd95",
      "name": "動的プロンプト取得1",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        -416,
        1584
      ],
      "parameters": {},
      "typeVersion": 4.6
    },
    {
      "id": "9ce74bbc-bc67-4d71-b137-ccc0f8084195",
      "name": "Markdown1",
      "type": "n8n-nodes-base.markdown",
      "position": [
        448,
        1424
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "b89cfee9-17f4-48b9-a308-6cc81c2ceecc",
      "name": "スイッチ",
      "type": "n8n-nodes-base.switch",
      "position": [
        368,
        1728
      ],
      "parameters": {},
      "typeVersion": 3.2
    },
    {
      "id": "09a6bf0a-af94-42b2-91d1-d642f1b80cf1",
      "name": "Gmail1",
      "type": "n8n-nodes-base.gmail",
      "position": [
        672,
        1424
      ],
      "webhookId": "7582c9f1-a67c-4c9a-a690-2227198d8093",
      "parameters": {},
      "typeVersion": 2.1
    },
    {
      "id": "7771aa20-b79e-40b8-a485-c63e378c72d3",
      "name": "Google Sheets1",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        672,
        1760
      ],
      "parameters": {},
      "typeVersion": 4.6
    },
    {
      "id": "202edba7-7a79-4acd-8107-71067b04ed0f",
      "name": "Supabase Vector Store1",
      "type": "@n8n/n8n-nodes-langchain.vectorStoreSupabase",
      "position": [
        1248,
        1376
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "5fdd5b0f-3b2e-43f3-8bf5-9a70f3807f5f",
      "name": "Embeddings OpenAI1",
      "type": "@n8n/n8n-nodes-langchain.embeddingsOpenAi",
      "position": [
        1184,
        1568
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "cc316e14-9675-4b74-a94c-8bca710b1a0f",
      "name": "デフォルトデータローダー",
      "type": "@n8n/n8n-nodes-langchain.documentDefaultDataLoader",
      "position": [
        1392,
        1504
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "b6b530ef-4720-4fdf-80a6-87c01547b01b",
      "name": "再帰的テキスト分割器",
      "type": "@n8n/n8n-nodes-langchain.textSplitterRecursiveCharacterTextSplitter",
      "position": [
        1344,
        1808
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "8d8e4d6b-86f1-40cb-bf0a-ff92ceac6463",
      "name": "付箋1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1040,
        1424
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "c33f3ce5-ed89-4c8c-92c6-b117313f0251",
      "name": "付箋2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1168,
        192
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "95773e14-3954-4a7a-805d-1f088d8ba01a",
      "name": "付箋3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1168,
        576
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "b38c1b19-1e0a-41d4-8c67-c0b6aa628dac",
      "name": "付箋4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -240,
        1312
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "453f19a5-4378-47a0-bb30-6b13ac1a9216",
      "name": "付箋5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        288,
        1312
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "c33d9300-1069-4e4b-a54d-04d9eb8b0262",
      "name": "付箋6",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        608,
        1648
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "39cffcf5-647b-441c-8a5e-9032a827bbbe",
      "name": "付箋7",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1120,
        1296
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "08939064-db0b-4cc8-9c72-03feed930813",
      "name": "付箋8",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1040,
        32
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "5107b6a4-b428-473b-957f-4c65a90b897b",
      "name": "付箋",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -2512,
        32
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "e8bc49f7-64f1-4cc5-8f81-cf63b2f36840",
      "name": "Gmailトリガー1",
      "type": "n8n-nodes-base.gmailTrigger",
      "position": [
        -960,
        416
      ],
      "parameters": {},
      "typeVersion": 1.2
    }
  ],
  "pinData": {},
  "connections": {
    "85b72d77-0541-45e6-b037-770acec610e9": {
      "main": [
        [
          {
            "node": "02fcd994-63fc-4b9c-a9b5-61c6562abb5c",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "d8cec49d-2aa5-413e-af1b-9c77895e91d5",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "6605a7d8-cd6c-4260-a698-229139887305": {
      "main": [
        [
          {
            "node": "b0e81371-4e0b-437d-9e9e-17cb4588fd95",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "5620dca5-25ce-412e-8984-068ae1c8a3fb": {
      "main": [
        [
          {
            "node": "dc370570-4695-4ba9-9c46-8f08472bc910",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "b89cfee9-17f4-48b9-a308-6cc81c2ceecc": {
      "main": [
        [
          {
            "node": "7771aa20-b79e-40b8-a485-c63e378c72d3",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "202edba7-7a79-4acd-8107-71067b04ed0f",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "d67fb10b-10f5-4d02-9a9d-1d69c07fd658": {
      "main": [
        [
          {
            "node": "85b72d77-0541-45e6-b037-770acec610e9",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "02fcd994-63fc-4b9c-a9b5-61c6562abb5c": {
      "main": [
        [
          {
            "node": "55196c92-edcd-4dc7-ad96-48ab287d81bf",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "9ce74bbc-bc67-4d71-b137-ccc0f8084195": {
      "main": [
        [
          {
            "node": "09a6bf0a-af94-42b2-91d1-d642f1b80cf1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "a064b42d-5aba-4745-8ed5-4adde17b1dd4": {
      "main": [
        [
          {
            "node": "d67fb10b-10f5-4d02-9a9d-1d69c07fd658",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "e8bc49f7-64f1-4cc5-8f81-cf63b2f36840": {
      "main": [
        [
          {
            "node": "5620dca5-25ce-412e-8984-068ae1c8a3fb",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "12ea4994-6d77-4094-853c-38c1430bfcc8": {
      "main": [
        [
          {
            "node": "a064b42d-5aba-4745-8ed5-4adde17b1dd4",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "e432c58f-163b-4a96-8a23-5c2749c2bcd1": {
      "ai_embedding": [
        [
          {
            "node": "25b0117a-152b-4ad3-9114-606d42a8d7f1",
            "type": "ai_embedding",
            "index": 0
          }
        ]
      ]
    },
    "8fbca9a7-f3cc-4d13-ba37-427d62cedc9d": {
      "ai_languageModel": [
        [
          {
            "node": "d67fb10b-10f5-4d02-9a9d-1d69c07fd658",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "5fdd5b0f-3b2e-43f3-8bf5-9a70f3807f5f": {
      "ai_embedding": [
        [
          {
            "node": "202edba7-7a79-4acd-8107-71067b04ed0f",
            "type": "ai_embedding",
            "index": 0
          }
        ]
      ]
    },
    "dc370570-4695-4ba9-9c46-8f08472bc910": {
      "main": [
        [
          {
            "node": "12ea4994-6d77-4094-853c-38c1430bfcc8",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "8156059d-5ae2-41a4-bc27-92ff8f2a46b7": {
      "ai_languageModel": [
        [
          {
            "node": "0b7e252b-8e97-4ec7-9d9e-2ee120cb09a7",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "0cee2309-721d-4ed9-b1be-9b7607cc22fe": {
      "ai_languageModel": [
        [
          {
            "node": "acc3ff75-16c4-4737-a25f-f7527898e387",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "cc316e14-9675-4b74-a94c-8bca710b1a0f": {
      "ai_document": [
        [
          {
            "node": "202edba7-7a79-4acd-8107-71067b04ed0f",
            "type": "ai_document",
            "index": 0
          }
        ]
      ]
    },
    "b0e81371-4e0b-437d-9e9e-17cb4588fd95": {
      "main": [
        [
          {
            "node": "acc3ff75-16c4-4737-a25f-f7527898e387",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "2a83bb18-6ef0-42f2-ab9d-75b3bcc1a35e": {
      "main": [
        [
          {
            "node": "6605a7d8-cd6c-4260-a698-229139887305",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "acc3ff75-16c4-4737-a25f-f7527898e387": {
      "main": [
        [
          {
            "node": "9ce74bbc-bc67-4d71-b137-ccc0f8084195",
            "type": "main",
            "index": 0
          },
          {
            "node": "b89cfee9-17f4-48b9-a308-6cc81c2ceecc",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "25b0117a-152b-4ad3-9114-606d42a8d7f1": {
      "ai_tool": [
        [
          {
            "node": "d67fb10b-10f5-4d02-9a9d-1d69c07fd658",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "f543ac29-3eb4-4554-b6aa-0e2285cdfb6b": {
      "ai_outputParser": [
        [
          {
            "node": "0b7e252b-8e97-4ec7-9d9e-2ee120cb09a7",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "0b7e252b-8e97-4ec7-9d9e-2ee120cb09a7": {
      "ai_outputParser": [
        [
          {
            "node": "d67fb10b-10f5-4d02-9a9d-1d69c07fd658",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "b6b530ef-4720-4fdf-80a6-87c01547b01b": {
      "ai_textSplitter": [
        [
          {
            "node": "cc316e14-9675-4b74-a94c-8bca710b1a0f",
            "type": "ai_textSplitter",
            "index": 0
          }
        ]
      ]
    }
  }
}
よくある質問

このワークフローの使い方は?

上記のJSON設定コードをコピーし、n8nインスタンスで新しいワークフローを作成して「JSONからインポート」を選択、設定を貼り付けて認証情報を必要に応じて変更してください。

このワークフローはどんな場面に適していますか?

上級 - コンテンツ作成, マルチモーダルAI

有料ですか?

このワークフローは完全無料です。ただし、ワークフローで使用するサードパーティサービス(OpenAI APIなど)は別途料金が発生する場合があります。

ワークフロー情報
難易度
上級
ノード数38
カテゴリー2
ノードタイプ18
難易度説明

上級者向け、16ノード以上の複雑なワークフロー

外部リンク
n8n.ioで表示

このワークフローを共有

カテゴリー

カテゴリー: 34