재귀적 멀티 에이전트 템플릿
중급
이것은AI, Marketing분야의자동화 워크플로우로, 11개의 노드를 포함합니다.주로 If, Set, Code, Agent, ChatTrigger 등의 노드를 사용하며인공지능 기술을 결합하여 스마트 자동화를 구현합니다. GPT-4o 재귀 작성 및 편집 대리인을 사용하여 서면 내용 생성
사전 요구사항
- •OpenAI API Key
워크플로우 미리보기
노드 연결 관계를 시각적으로 표시하며, 확대/축소 및 이동을 지원합니다
워크플로우 내보내기
다음 JSON 구성을 복사하여 n8n에 가져오면 이 워크플로우를 사용할 수 있습니다
{
"id": "UnFtEvTPouN6XIIH",
"meta": {
"instanceId": "ea11c547d31842d8c1ffb2f9490761ea576cf90dbdb1ce86a951bf99131d1a44",
"templateCredsSetupCompleted": true
},
"name": "Recursive Multi-Agent TEMPLATE",
"tags": [],
"nodes": [
{
"id": "84b115d5-0c47-4bc9-8997-e45c16e3aa18",
"name": "채팅 메시지 수신 시",
"type": "@n8n/n8n-nodes-langchain.chatTrigger",
"position": [
40,
0
],
"webhookId": "037b5b5d-7a59-4812-8327-42f9c7812d5d",
"parameters": {
"options": {}
},
"typeVersion": 1.1
},
{
"id": "085fd153-5564-4920-b278-e5fc93f32134",
"name": "윈도우 버퍼 메모리",
"type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
"position": [
920,
280
],
"parameters": {
"sessionKey": "={{ $('When chat message received').item.json.sessionId }}",
"sessionIdType": "customKey",
"contextWindowLength": 10
},
"typeVersion": 1.3
},
{
"id": "0220fe2a-8e8e-4d11-803e-b942f1cf16c5",
"name": "set variables",
"type": "n8n-nodes-base.set",
"position": [
1380,
0
],
"parameters": {
"options": {},
"assignments": {
"assignments": [
{
"id": "25fcda79-c515-4e2e-bfc0-3b13259c33a0",
"name": "status",
"type": "string",
"value": "={{ $json.output.status }}"
},
{
"id": "26f212df-ed09-4372-ad2f-e069698ab33c",
"name": "edits",
"type": "string",
"value": "={{ $json.output.edits }}"
}
]
}
},
"typeVersion": 3.4
},
{
"id": "0dc0e194-4129-42e3-aedd-6fbd6b875338",
"name": "chatInput",
"type": "n8n-nodes-base.set",
"position": [
260,
0
],
"parameters": {
"options": {},
"assignments": {
"assignments": [
{
"id": "709fb115-0654-48f6-bbdd-d0661b1135ba",
"name": "chatInput",
"type": "string",
"value": "={{ $json.chatInput }}"
}
]
}
},
"typeVersion": 3.4
},
{
"id": "426831d6-2ddb-4ede-99a7-c0c504e6687f",
"name": "구조화된 출력 파서",
"type": "@n8n/n8n-nodes-langchain.outputParserStructured",
"position": [
1200,
280
],
"parameters": {
"schemaType": "manual",
"inputSchema": "{\n\t\"type\": \"object\",\n\t\"properties\": {\n\t\t\"status\": {\n\t\t\t\"type\": \"string\"\n\t\t},\n\t\t\"edits\": {\n\t\t\t\"type\": \"string\"\n\t\t}\n\t}\n}"
},
"typeVersion": 1.2
},
{
"id": "4be8a98c-c01f-4e8c-bec7-c6ef4119c392",
"name": "OpenAI 채팅 모델",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"position": [
680,
280
],
"parameters": {
"model": "gpt-4o",
"options": {}
},
"credentials": {
"openAiApi": {
"id": "93qOKf12nDGJSW30",
"name": "OpenAi account"
}
},
"typeVersion": 1.1
},
{
"id": "b22dd35c-5df2-4966-a7b6-4b146c5d9a09",
"name": "handle edits",
"type": "n8n-nodes-base.code",
"position": [
460,
0
],
"parameters": {
"jsCode": "let edits = \"\";\ntry {\n\t// Try to retrieve the edits from the node named \"Edit Fields\"\n\tedits = $node[\"set variables\"].json[\"edits\"] || \"\";\n} catch (err) {\n\t// If the node hasn't executed or its data isn't available, default to empty string\n\tedits = \"\";\n}\nreturn { edits };"
},
"typeVersion": 2
},
{
"id": "85524870-798a-4561-a227-06c8f0aa3c26",
"name": "If Status Complete",
"type": "n8n-nodes-base.if",
"position": [
1600,
0
],
"parameters": {
"options": {},
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "d2c4ff3a-1674-4edf-b0a0-153543f52900",
"operator": {
"type": "string",
"operation": "equals"
},
"leftValue": "={{ $('Editing Agent').item.json.output.status }}",
"rightValue": "complete"
}
]
}
},
"typeVersion": 2.2
},
{
"id": "e28c4317-1e16-445f-8119-7d53937b651b",
"name": "Writing 에이전트",
"type": "@n8n/n8n-nodes-langchain.agent",
"position": [
660,
0
],
"parameters": {
"text": "=Always review chat history.\n\nWrite a blurb based on my input topic:\n{{ $('chatInput').item.json.chatInput }}\n\nIf there are any suggested edits, make sure to incorporated them into the blurb:\n{{ $json.edits }}\n\nONLY OUTPUT THE BLURB, NO ADDITIONAL WORDS. ",
"options": {
"systemMessage": "=You are a writer. Write a short blurb about the topic given to you by the user. "
},
"promptType": "define"
},
"typeVersion": 1.7
},
{
"id": "fe9d9f32-8be3-49a7-8699-322192e16474",
"name": "Editing 에이전트",
"type": "@n8n/n8n-nodes-langchain.agent",
"maxTries": 5,
"position": [
1020,
0
],
"parameters": {
"text": "=You are an editor. \n\nReview the input and recommend specific edits to improve the writing. \n\nYou are working with a writing agent that should implement your edits. \n\nHere are the variables that you output and what they mean:\n- status: this is either \"complete\" or \"incomplete\" output string. Once the writing agent implements your edits, you should set \"status\" = \"complete\". If this is the first time you've reviewed their work, status should be set to \"incomplete\". If the writing agent did not correctly implement your edits, you should set status to \"incomplete\".\n- edits: this is your specific suggested edits. The writing agent will be able to see these edits and update the text to incorporate the edits.\n\nUse the structured output parser and output clean JSON in this format (example):\n{\n\"status\": \"complete\",\n\"edits\": \"The writing agent has successfully implemented all the suggested edits. The text is now concise, informative, and focused on the main point while providing a brief introduction to AI. No further edits are necessary at this time.\"\n}\n\nDO NOT INCLUDE ANY OTHER TEXT BESIDES THE JSON OUTPUT.\n\nHere is the input text from the writing agent:\n{{ $json.output }}",
"options": {},
"promptType": "define",
"hasOutputParser": true
},
"retryOnFail": false,
"typeVersion": 1.7
},
{
"id": "e77541dd-0774-4545-a846-0106aa79fbf5",
"name": "chatOutput",
"type": "n8n-nodes-base.set",
"position": [
1820,
0
],
"parameters": {
"options": {},
"assignments": {
"assignments": [
{
"id": "753c404e-fce4-4173-95d2-6fde9c543d5f",
"name": "output",
"type": "string",
"value": "={{ $('Writing Agent').first().json.output }}"
}
]
}
},
"typeVersion": 3.4
},
{
"id": "549707c8-55db-4e8e-aecc-68615b6034ee",
"name": "메모",
"type": "n8n-nodes-base.stickyNote",
"position": [
600,
-160
],
"parameters": {
"color": 4,
"width": 340,
"height": 320,
"content": "## Writing Agent\nThis agent writes and rewrites based on feedback from the editing agent."
},
"typeVersion": 1
},
{
"id": "67c3ebb8-6d81-4add-a882-07fd0cc86f50",
"name": "메모1",
"type": "n8n-nodes-base.stickyNote",
"position": [
980,
-160
],
"parameters": {
"color": 5,
"width": 340,
"height": 320,
"content": "## Editing Agent\nThis agent suggest edits to improve the writing output of the writing agent. It then evaluates whether the edits were incorporated into the writing."
},
"typeVersion": 1
}
],
"active": false,
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"versionId": "8b9969b0-ae7b-45c0-9f41-72ea972d67cb",
"connections": {
"0dc0e194-4129-42e3-aedd-6fbd6b875338": {
"main": [
[
{
"node": "b22dd35c-5df2-4966-a7b6-4b146c5d9a09",
"type": "main",
"index": 0
}
]
]
},
"b22dd35c-5df2-4966-a7b6-4b146c5d9a09": {
"main": [
[
{
"node": "Writing Agent",
"type": "main",
"index": 0
}
]
]
},
"Editing Agent": {
"main": [
[
{
"node": "0220fe2a-8e8e-4d11-803e-b942f1cf16c5",
"type": "main",
"index": 0
}
]
]
},
"Writing Agent": {
"main": [
[
{
"node": "Editing Agent",
"type": "main",
"index": 0
}
]
]
},
"0220fe2a-8e8e-4d11-803e-b942f1cf16c5": {
"main": [
[
{
"node": "85524870-798a-4561-a227-06c8f0aa3c26",
"type": "main",
"index": 0
}
]
]
},
"OpenAI Chat Model": {
"ai_languageModel": [
[
{
"node": "Writing Agent",
"type": "ai_languageModel",
"index": 0
},
{
"node": "Editing Agent",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"85524870-798a-4561-a227-06c8f0aa3c26": {
"main": [
[
{
"node": "e77541dd-0774-4545-a846-0106aa79fbf5",
"type": "main",
"index": 0
}
],
[
{
"node": "b22dd35c-5df2-4966-a7b6-4b146c5d9a09",
"type": "main",
"index": 0
}
]
]
},
"Window Buffer Memory": {
"ai_memory": [
[
{
"node": "Editing Agent",
"type": "ai_memory",
"index": 0
},
{
"node": "Writing Agent",
"type": "ai_memory",
"index": 0
}
]
]
},
"Structured Output Parser": {
"ai_outputParser": [
[
{
"node": "Editing Agent",
"type": "ai_outputParser",
"index": 0
}
]
]
},
"When chat message received": {
"main": [
[
{
"node": "0dc0e194-4129-42e3-aedd-6fbd6b875338",
"type": "main",
"index": 0
}
]
]
}
}
}자주 묻는 질문
이 워크플로우를 어떻게 사용하나요?
위의 JSON 구성 코드를 복사하여 n8n 인스턴스에서 새 워크플로우를 생성하고 "JSON에서 가져오기"를 선택한 후, 구성을 붙여넣고 필요에 따라 인증 설정을 수정하세요.
이 워크플로우는 어떤 시나리오에 적합한가요?
중급 - 인공지능, 마케팅
유료인가요?
이 워크플로우는 완전히 무료이며 직접 가져와 사용할 수 있습니다. 다만, 워크플로우에서 사용하는 타사 서비스(예: OpenAI API)는 사용자 직접 비용을 지불해야 할 수 있습니다.
관련 워크플로우 추천
HDW 리드 베이비
AI 에이전트를 사용한 자동화된 LinkedIn 리드 생성, 점수 매기기 및 소통
If
Code
Sort
+
If
Code
Sort
86 노드Andrey
영업
브랜드화 AI 추동 웹사이트 채팅 로봇 생성
브랜드화된 AI 드라이브드 웹사이트 채팅 로봇 생성
If
Set
Code
+
If
Set
Code
24 노드Wayne Simpson
제품
면접 스케줄러
GPT-4o와 Google Calendar 챗봇을 사용한 면접 자동 일정安排
If
Set
Code
+
If
Set
Code
25 노드Robert Breen
인사
LinkedIn 인재 파이프라인: AI로운 지원자 검색 및 등급 (GPT-4o)
LinkedIn 인재 파이프라인: AI로운 지원자 검색 및 등급 (GPT-4o)
If
Set
Code
+
If
Set
Code
24 노드Badr
인사
AI 자동화 및 에이전트 구축 및 판매
构建与판매AI자동화与스마트体
If
Set
Wait
+
If
Set
Wait
74 노드NICKYAI
기타
AI视频생성기 - OpenAI、ElevenLabs与Telegram YouTube게시
통합OpenAI、ElevenLabs并통해Telegram게시至YouTube의AI视频생성기
If
Set
Wait
+
If
Set
Wait
68 노드FRANK LIN
영업