{"name": "AI 对话（webhook → Agent → 模型 + 记忆）", "nodes": [{"id": "webhook1", "name": "对话入口", "type": "n8n-nodes-base.webhook", "typeVersion": 2, "position": [250, 300], "parameters": {"path": "ai-chat", "httpMethod": "POST", "responseMode": "lastNode"}}, {"id": "agent1", "name": "AI 助手", "type": "@n8n/n8n-nodes-langchain.agent", "typeVersion": 1.7, "position": [450, 300], "parameters": {"promptType": "define", "text": "={{ $json.body.question }}", "options": {"systemMessage": "你是运维助手，用中文简明回答。"}}}, {"id": "model1", "name": "DeepSeek Chat Model", "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi", "typeVersion": 1, "position": [450, 480], "parameters": {"model": "deepseek-chat", "options": {}}, "credentials": {"openAiApi": {"id": "REPLACE_WITH_CREDENTIAL_ID", "name": "REPLACE_WITH_CREDENTIAL_NAME"}}}, {"id": "memory1", "name": "会话记忆", "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow", "typeVersion": 1.3, "position": [650, 480], "parameters": {"contextWindowLength": 10}}], "connections": {"对话入口": {"main": [[{"node": "AI 助手", "type": "main", "index": 0}]]}, "DeepSeek Chat Model": {"ai_languageModel": [[{"node": "AI 助手", "type": "ai_languageModel", "index": 0}]]}, "会话记忆": {"ai_memory": [[{"node": "AI 助手", "type": "ai_memory", "index": 0}]]}}, "settings": {"executionOrder": "v1"}}
