8
n8n 中文网amn8n.com

Slack项目更新RAG代理

中级

这是一个AI RAG, Multimodal AI领域的自动化工作流,包含 11 个节点。主要使用 Slack, SlackTrigger, Agent, LmChatOpenAi, EmbeddingsOpenAi 等节点。 使用GPT和Pinecone向量RAG上下文自动回复Slack消息

前置要求
  • Slack Bot Token 或 Webhook URL
  • OpenAI API Key
  • Pinecone API Key
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
  "id": "mB32fQ5OyrLgbIIZ",
  "meta": {
    "instanceId": "1c7b08fed4406d546caf4a44e8b942ca317e7e207bb9a5701955a1a6e1ce1843"
  },
  "name": "Slack Project Update RAG Agent",
  "tags": [],
  "nodes": [
    {
      "id": "44bc7fc6-9736-48e9-90dc-3098047abdc7",
      "name": "Slack Trigger",
      "type": "n8n-nodes-base.slackTrigger",
      "position": [
        880,
        160
      ],
      "parameters": {
        "options": {
          "userIds": "==[\"User_ID\"]"
        },
        "trigger": [
          "any_event",
          "app_mention"
        ],
        "watchWorkspace": true
      },
      "typeVersion": 1
    },
    {
      "id": "aabbb277-80f5-4316-8845-f34bce33261b",
      "name": "OpenAI Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        1100,
        380
      ],
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-5",
          "cachedResultName": "gpt-5"
        },
        "options": {}
      },
      "typeVersion": 1.2
    },
    {
      "id": "14cb0538-fe7e-4739-9de9-129723400e44",
      "name": "Simple Memory",
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "position": [
        1280,
        380
      ],
      "parameters": {
        "sessionKey": "={{ $json.channel }}",
        "sessionIdType": "customKey"
      },
      "typeVersion": 1.3
    },
    {
      "id": "92db15e1-3228-476f-a3da-1736e8f34d53",
      "name": "Send a message",
      "type": "n8n-nodes-base.slack",
      "position": [
        1840,
        160
      ],
      "parameters": {
        "text": "={{ $json.output }}",
        "select": "channel",
        "channelId": {
          "__rl": true,
          "mode": "id",
          "value": "={{ $('Slack Trigger').item.json.channel }}"
        },
        "otherOptions": {
          "sendAsUser": "Jacob",
          "includeLinkToWorkflow": false
        }
      },
      "typeVersion": 2.3
    },
    {
      "id": "24714547-eecf-4b11-a58f-c394dc7bc9e4",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1760,
        0
      ],
      "parameters": {
        "color": 3,
        "width": 304,
        "height": 624,
        "content": "Slack Respond as a User"
      },
      "typeVersion": 1
    },
    {
      "id": "387b6478-c255-42ba-b456-8b90d889e261",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1040,
        0
      ],
      "parameters": {
        "color": 4,
        "width": 704,
        "height": 624,
        "content": "GPT-5 Agent"
      },
      "typeVersion": 1
    },
    {
      "id": "d4e0c080-fdcc-45b9-89ac-da6ff9d1de4e",
      "name": "GPT 5 Slack Agent",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        1200,
        160
      ],
      "parameters": {
        "text": "={{ $json.text }}",
        "options": {
          "systemMessage": "You are Jacob, an Engineer at Purple Unicorn IT Solutions. Respond to your members' message on Jacob's behalf on Slack. Sound friendly and natural in a typical tech working environment. \n\n##Tool\nUse the Pinecone Vector Store Tool when asked about Project Updates"
        },
        "promptType": "define"
      },
      "typeVersion": 2
    },
    {
      "id": "7070bd4b-bc9e-426b-a6d9-074d386d86dd",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        780,
        0
      ],
      "parameters": {
        "color": 5,
        "height": 624,
        "content": "Slack Trigger"
      },
      "typeVersion": 1
    },
    {
      "id": "d8e65fda-3927-4404-accf-300c30ebef8e",
      "name": "Pinecone Vector Store",
      "type": "@n8n/n8n-nodes-langchain.vectorStorePinecone",
      "position": [
        1440,
        340
      ],
      "parameters": {
        "mode": "retrieve-as-tool",
        "options": {},
        "pineconeIndex": {
          "__rl": true,
          "mode": "list",
          "value": "test",
          "cachedResultName": "test"
        },
        "toolDescription": "Refer to Database for Work Related Information"
      },
      "typeVersion": 1.3
    },
    {
      "id": "fe5ef41c-9496-461a-b44a-5bb34aca4967",
      "name": "Embeddings OpenAI",
      "type": "@n8n/n8n-nodes-langchain.embeddingsOpenAi",
      "position": [
        1580,
        500
      ],
      "parameters": {
        "options": {}
      },
      "typeVersion": 1.2
    },
    {
      "id": "c11871c8-557c-42f6-ab82-f287b1178798",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        0,
        0
      ],
      "parameters": {
        "color": 2,
        "width": 752,
        "height": 1008,
        "content": "🛠 GPT-5 + Pinecone-Powered Slack Auto-Responder — Real-Time, Context-Aware Replies for IT & Engineering Teams\n\nDescription\nCut down on context-switching and keep your Slack threads moving with an AI agent that responds on your behalf, pulling real-time knowledge from a Pinecone vector database. Built for IT, DevOps, and engineering environments, this n8n workflow ensures every reply is accurate, context-aware, and instantly available—without you lifting a finger.\n\nCheck out step-by-step video build of workflows like these here:\nhttps://www.youtube.com/@automatewithmarc\n\nHow It Works\n\nSlack Listener: Triggers when you’re mentioned or messaged in relevant channels.\n\nPinecone RAG Retrieval: Pulls the most relevant technical details from your indexed documents, architecture notes, or runbooks.\n\nGPT-5 Processing: Formats the retrieved data into a clear, concise, and technically accurate reply.\n\nThread-Aware Memory: Maintains the conversation state to avoid repeating answers.\n\nSlack Send-as-User: Posts the message under your identity for seamless integration into team workflows.\n\nWhy IT Teams Will Love It\n\n📚 Always up-to-date — If your Pinecone index is refreshed with system docs, runbooks, or KB articles, the bot will always deliver the latest info.\n\n🏗 Technical context retention — Perfect for answering ongoing infrastructure or incident threads.\n\n⏱ Reduced interruption time — No more breaking focus to answer “quick questions.”\n\n🔐 Controlled outputs — Tune GPT-5 to deliver fact-based, low-fluff responses for critical environments.\n\nCommon Use Cases\n\nDevOps: Automated responses to common CI/CD, deployment, or incident queries.\n\nSupport Engineering: Pulling troubleshooting steps directly from KB entries.\n\nProject Coordination: Instant status updates pulled from sprint or release notes.\n\nPro Tips for Deployment\n\nKeep your Pinecone vector DB updated with the latest architecture diagrams, release notes, and SOPs.\n\nUse embeddings tuned for technical documentation to improve retrieval accuracy.\n\nAdd channel-specific prompts if different teams require different response styles (e.g., #devops vs #product)."
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "5a498f5f-a962-44c6-ada3-7426d2cb62c3",
  "connections": {
    "Simple Memory": {
      "ai_memory": [
        [
          {
            "node": "GPT 5 Slack Agent",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "Slack Trigger": {
      "main": [
        [
          {
            "node": "GPT 5 Slack Agent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Embeddings OpenAI": {
      "ai_embedding": [
        [
          {
            "node": "Pinecone Vector Store",
            "type": "ai_embedding",
            "index": 0
          }
        ]
      ]
    },
    "GPT 5 Slack Agent": {
      "main": [
        [
          {
            "node": "Send a message",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "GPT 5 Slack Agent",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Pinecone Vector Store": {
      "ai_tool": [
        [
          {
            "node": "GPT 5 Slack Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    }
  }
}
常见问题

如何使用这个工作流?

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

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

中级 - AI RAG 检索增强, 多模态 AI

需要付费吗?

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

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

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

作者
Automate With Marc

Automate With Marc

@marconi

Automating Start-Up and Business processes. Helping non-techies understand and leverage Agentic AI with easy to understand step-by-step tutorials. Check out my educational content: https://www.youtube.com/@Automatewithmarc

外部链接
在 n8n.io 查看

分享此工作流