AI 聊天助手:Dumpling AI + GPT-4o 自动保存本地企业数据到 Airtable

中级

这是一个Sales、AI、Marketing领域的自动化工作流,包含 8 个节点。主要使用 AirtableTool、Agent、ChatTrigger、LmChatOpenAi、ToolHttpRequest 等节点,结合人工智能技术实现智能自动化。 AI聊天助手:Dumpling AI + GPT-4o自动保存本地商业数据到Airtable

前置要求
  • Airtable API Key
  • OpenAI API Key
  • 可能需要目标 API 的认证凭证
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
  "id": "MyJ84ASqWdHGYuy0",
  "meta": {
    "instanceId": "a1ae5c8dc6c65e674f9c3947d083abcc749ef2546dff9f4ff01de4d6a36ebfe6",
    "templateCredsSetupCompleted": true
  },
  "name": "AI 聊天助手:Dumpling AI + GPT-4o 自动保存本地企业数据到 Airtable",
  "tags": [
    {
      "id": "TlcNkmb96fUfZ2eA",
      "name": "Tutorials",
      "createdAt": "2025-04-15T17:02:00.249Z",
      "updatedAt": "2025-04-15T17:02:00.249Z"
    }
  ],
  "nodes": [
    {
      "id": "1617006d-20d8-44da-8410-1fbbd6bc317e",
      "name": "当收到聊天消息时",
      "type": "@n8n/n8n-nodes-langchain.chatTrigger",
      "position": [
        -480,
        -40
      ],
      "webhookId": "13e55a07-d144-403b-b465-2a539501b207",
      "parameters": {
        "options": {}
      },
      "typeVersion": 1.1
    },
    {
      "id": "ccb3073d-4c39-44bf-bd7f-05a6ae0550cb",
      "name": "便签",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1200,
        -220
      ],
      "parameters": {
        "width": 660,
        "height": 900,
        "content": "#### 🧠 工作流目的"
      },
      "typeVersion": 1
    },
    {
      "id": "266e0454-5133-4287-a449-2eb1d3d00485",
      "name": "新闻助手",
      "type": "@n8n/n8n-nodes-langchain.toolHttpRequest",
      "position": [
        -20,
        180
      ],
      "parameters": {
        "url": "https://app.dumplingai.com/api/v1/agents/generate-completion",
        "method": "POST",
        "jsonBody": "={\n  \"messages\": [\n    {\n      \"role\": \"user\",\n      \"content\":\"{{ $json.chatInput}}\"\n    }\n  ],\n  \"agentId\": \"\",\n  \"parseJson\": \"True\"\n  }",
        "sendBody": true,
        "specifyBody": "json",
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth",
        "optimizeResponse": true
      },
      "credentials": {
        "httpHeaderAuth": {
          "id": "xamyMqCpAech5BeT",
          "name": "Header Auth account"
        }
      },
      "typeVersion": 1.1
    },
    {
      "id": "b3d834d7-eeb5-4ce8-bb45-2d6b58f8c0a9",
      "name": "本地企业查找助手",
      "type": "@n8n/n8n-nodes-langchain.toolHttpRequest",
      "position": [
        100,
        180
      ],
      "parameters": {
        "url": "https://app.dumplingai.com/api/v1/agents/generate-completion",
        "method": "POST",
        "jsonBody": "={\n  \"messages\": [\n    {\n      \"role\": \"user\",\n      \"content\":\"{{ $json.chatInput}}\"\n    }\n  ],\n  \"agentId\": \"\",\n  \"parseJson\": \"false\"\n  }",
        "sendBody": true,
        "specifyBody": "json",
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth",
        "optimizeResponse": true
      },
      "credentials": {
        "httpHeaderAuth": {
          "id": "xamyMqCpAech5BeT",
          "name": "Header Auth account"
        }
      },
      "typeVersion": 1.1
    },
    {
      "id": "bc75a2b5-8d99-487a-a9fc-12045b555207",
      "name": "跟踪最近10条消息",
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "position": [
        -160,
        180
      ],
      "parameters": {
        "contextWindowLength": 10
      },
      "typeVersion": 1.3
    },
    {
      "id": "0eb2b921-360e-4043-8a2f-301d10113dfc",
      "name": "使用 Dumpling + GPT + 记忆路由 AI 任务",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        -108,
        -40
      ],
      "parameters": {
        "options": {
          "systemMessage": "You are a helpful assistant\nUse the Local Business Finder Agent HTTP request tool to find local business\n\nUse the News agent HTTP request tool to get get news\n\nUse the Create and update Airtable tool to send results from the Local Business Finder Agent HTTP request tool"
        }
      },
      "typeVersion": 1.8
    },
    {
      "id": "948fafa9-6b4c-4656-b27f-ce5b1eb0d363",
      "name": "使用 GPT-4o Mini 处理输入",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        -320,
        180
      ],
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4o-mini"
        },
        "options": {}
      },
      "credentials": {
        "openAiApi": {
          "id": "gY2Jp4ypzmjcwwV6",
          "name": "n8n free OpenAI API credits"
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "4a07cedd-f40e-4123-a894-c53da751263f",
      "name": "保存企业结果",
      "type": "n8n-nodes-base.airtableTool",
      "position": [
        240,
        180
      ],
      "parameters": {
        "base": {
          "__rl": true,
          "mode": "list",
          "value": "",
          "cachedResultUrl": "https://airtable.com/appPSvSKdA6075xJC",
          "cachedResultName": "Testing n8n"
        },
        "table": {
          "__rl": true,
          "mode": "list",
          "value": "",
          "cachedResultUrl": "https://airtable.com/appPSvSKdA6075xJC/tblgxhdRFc2fGLV9o",
          "cachedResultName": "Local business"
        },
        "columns": {
          "value": {
            "id": "=",
            "Rating": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Rating', ``, 'number') }}",
            "Address": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Address', ``, 'string') }}",
            "Website": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Website', ``, 'string') }}",
            "Category": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Category', ``, 'string') }}",
            "Phone Number": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Phone_Number', ``, 'string') }}",
            "Total Reviews": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Total_Reviews', ``, 'number') }}",
            "Name of Restaurant": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Name_of_Restaurant', ``, 'string') }}"
          },
          "schema": [
            {
              "id": "id",
              "type": "string",
              "display": true,
              "removed": false,
              "readOnly": true,
              "required": false,
              "displayName": "id",
              "defaultMatch": true
            },
            {
              "id": "Name of Restaurant",
              "type": "string",
              "display": true,
              "removed": false,
              "readOnly": false,
              "required": false,
              "displayName": "Name of Restaurant",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Rating",
              "type": "number",
              "display": true,
              "removed": false,
              "readOnly": false,
              "required": false,
              "displayName": "Rating",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Total Reviews",
              "type": "number",
              "display": true,
              "removed": false,
              "readOnly": false,
              "required": false,
              "displayName": "Total Reviews",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Address",
              "type": "string",
              "display": true,
              "removed": false,
              "readOnly": false,
              "required": false,
              "displayName": "Address",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Phone Number",
              "type": "string",
              "display": true,
              "removed": false,
              "readOnly": false,
              "required": false,
              "displayName": "Phone Number",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Website",
              "type": "string",
              "display": true,
              "removed": false,
              "readOnly": false,
              "required": false,
              "displayName": "Website",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Category",
              "type": "string",
              "display": true,
              "removed": false,
              "readOnly": false,
              "required": false,
              "displayName": "Category",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [
            "id"
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "upsert"
      },
      "credentials": {
        "airtableTokenApi": {
          "id": "H8PVkBgUPCcUhhRC",
          "name": "Airtable Personal Access Token account"
        }
      },
      "typeVersion": 2.1
    }
  ],
  "active": false,
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "57c6329e-df0b-4eb4-9837-643c7de85e5e",
  "connections": {
    "News Agent": {
      "ai_tool": [
        [
          {
            "node": "Route AI Tasks with Dumpling + GPT + Memory",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Save Business Results": {
      "ai_tool": [
        [
          {
            "node": "Route AI Tasks with Dumpling + GPT + Memory",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Track Last 10 Messages ": {
      "ai_memory": [
        [
          {
            "node": "Route AI Tasks with Dumpling + GPT + Memory",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "When chat message received": {
      "main": [
        [
          {
            "node": "Route AI Tasks with Dumpling + GPT + Memory",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Local Business Finder Agent": {
      "ai_tool": [
        [
          {
            "node": "Route AI Tasks with Dumpling + GPT + Memory",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Process Input with GPT-4o Mini": {
      "ai_languageModel": [
        [
          {
            "node": "Route AI Tasks with Dumpling + GPT + Memory",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Route AI Tasks with Dumpling + GPT + Memory": {
      "main": [
        []
      ]
    }
  }
}
常见问题

如何使用这个工作流?

复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。

这个工作流适合什么场景?

这是一个中级难度的工作流,适用于Sales、AI、Marketing等场景。适合有一定经验的用户,包含 6-15 个节点的中等复杂度工作流

需要付费吗?

本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。

工作流信息
难度等级
中级
节点数量8
分类3
节点类型7
难度说明

适合有一定经验的用户,包含 6-15 个节点的中等复杂度工作流

外部链接
在 n8n.io 上查看 →

分享此工作流