@n8n/ai-workflow-builder 0.18.0 → 0.20.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agents/workflow-planner-agent.d.ts +58 -0
- package/dist/agents/workflow-planner-agent.js +269 -0
- package/dist/agents/workflow-planner-agent.js.map +1 -0
- package/dist/ai-workflow-builder-agent.service.d.ts +2 -1
- package/dist/ai-workflow-builder-agent.service.js +6 -3
- package/dist/ai-workflow-builder-agent.service.js.map +1 -1
- package/dist/build.tsbuildinfo +1 -1
- package/dist/chains/parameter-updater.js +5 -1
- package/dist/chains/parameter-updater.js.map +1 -1
- package/dist/chains/prompts/instance-url.d.ts +1 -0
- package/dist/chains/prompts/instance-url.js +16 -0
- package/dist/chains/prompts/instance-url.js.map +1 -0
- package/dist/chains/prompts/prompt-builder.js +1 -1
- package/dist/chains/prompts/prompt-builder.js.map +1 -1
- package/dist/chains/workflow-name.js +1 -1
- package/dist/constants.d.ts +7 -0
- package/dist/constants.js +8 -1
- package/dist/constants.js.map +1 -1
- package/dist/errors/index.d.ts +7 -0
- package/dist/errors/index.js +16 -1
- package/dist/errors/index.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +0 -1
- package/dist/index.js.map +1 -1
- package/dist/llm-config.js +2 -1
- package/dist/llm-config.js.map +1 -1
- package/dist/tools/add-node.tool.d.ts +38 -34
- package/dist/tools/add-node.tool.js +17 -2
- package/dist/tools/add-node.tool.js.map +1 -1
- package/dist/tools/connect-nodes.tool.d.ts +29 -26
- package/dist/tools/connect-nodes.tool.js +7 -2
- package/dist/tools/connect-nodes.tool.js.map +1 -1
- package/dist/tools/get-node-parameter.tool.d.ts +18 -0
- package/dist/tools/get-node-parameter.tool.js +109 -0
- package/dist/tools/get-node-parameter.tool.js.map +1 -0
- package/dist/tools/helpers/progress.d.ts +1 -1
- package/dist/tools/helpers/progress.js +14 -2
- package/dist/tools/helpers/progress.js.map +1 -1
- package/dist/tools/helpers/validation.d.ts +1 -0
- package/dist/tools/helpers/validation.js +13 -0
- package/dist/tools/helpers/validation.js.map +1 -1
- package/dist/tools/node-details.tool.d.ts +20 -17
- package/dist/tools/node-details.tool.js +7 -2
- package/dist/tools/node-details.tool.js.map +1 -1
- package/dist/tools/node-search.tool.d.ts +54 -45
- package/dist/tools/node-search.tool.js +7 -2
- package/dist/tools/node-search.tool.js.map +1 -1
- package/dist/tools/prompts/main-agent.prompt.d.ts +2 -0
- package/dist/tools/prompts/main-agent.prompt.js +96 -41
- package/dist/tools/prompts/main-agent.prompt.js.map +1 -1
- package/dist/tools/remove-node.tool.d.ts +14 -11
- package/dist/tools/remove-node.tool.js +7 -2
- package/dist/tools/remove-node.tool.js.map +1 -1
- package/dist/tools/update-node-parameters.tool.d.ts +19 -16
- package/dist/tools/update-node-parameters.tool.js +60 -38
- package/dist/tools/update-node-parameters.tool.js.map +1 -1
- package/dist/types/index.d.ts +8 -8
- package/dist/types/index.js +0 -22
- package/dist/types/index.js.map +1 -1
- package/dist/types/langchain.d.ts +2 -0
- package/dist/types/langchain.js +7 -0
- package/dist/types/langchain.js.map +1 -0
- package/dist/types/messages.d.ts +1 -7
- package/dist/types/streaming.d.ts +6 -1
- package/dist/types/tools.d.ts +8 -1
- package/dist/utils/stream-processor.d.ts +7 -1
- package/dist/utils/stream-processor.js +121 -63
- package/dist/utils/stream-processor.js.map +1 -1
- package/dist/utils/token-usage.d.ts +14 -0
- package/dist/utils/token-usage.js +27 -0
- package/dist/utils/token-usage.js.map +1 -1
- package/dist/utils/trim-workflow-context.d.ts +2 -0
- package/dist/utils/trim-workflow-context.js +53 -0
- package/dist/utils/trim-workflow-context.js.map +1 -0
- package/dist/workflow-builder-agent.d.ts +11 -1
- package/dist/workflow-builder-agent.js +205 -24
- package/dist/workflow-builder-agent.js.map +1 -1
- package/dist/workflow-state.d.ts +17 -0
- package/dist/workflow-state.js +12 -0
- package/dist/workflow-state.js.map +1 -1
- package/package.json +9 -7
- package/dist/chains/planner.d.ts +0 -4
- package/dist/chains/planner.js +0 -87
- package/dist/chains/planner.js.map +0 -1
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import type { BaseChatModel } from '@langchain/core/language_models/chat_models';
|
|
2
|
+
import type { BaseMessage } from '@langchain/core/messages';
|
|
3
|
+
import { type INodeTypeDescription } from 'n8n-workflow';
|
|
4
|
+
import { z } from 'zod';
|
|
5
|
+
declare const planNodeSchema: z.ZodObject<{
|
|
6
|
+
nodeType: z.ZodString;
|
|
7
|
+
nodeName: z.ZodString;
|
|
8
|
+
reasoning: z.ZodString;
|
|
9
|
+
}, "strip", z.ZodTypeAny, {
|
|
10
|
+
nodeType: string;
|
|
11
|
+
reasoning: string;
|
|
12
|
+
nodeName: string;
|
|
13
|
+
}, {
|
|
14
|
+
nodeType: string;
|
|
15
|
+
reasoning: string;
|
|
16
|
+
nodeName: string;
|
|
17
|
+
}>;
|
|
18
|
+
declare const workflowPlanSchema: z.ZodObject<{
|
|
19
|
+
intro: z.ZodString;
|
|
20
|
+
plan: z.ZodArray<z.ZodObject<{
|
|
21
|
+
nodeType: z.ZodString;
|
|
22
|
+
nodeName: z.ZodString;
|
|
23
|
+
reasoning: z.ZodString;
|
|
24
|
+
}, "strip", z.ZodTypeAny, {
|
|
25
|
+
nodeType: string;
|
|
26
|
+
reasoning: string;
|
|
27
|
+
nodeName: string;
|
|
28
|
+
}, {
|
|
29
|
+
nodeType: string;
|
|
30
|
+
reasoning: string;
|
|
31
|
+
nodeName: string;
|
|
32
|
+
}>, "many">;
|
|
33
|
+
}, "strip", z.ZodTypeAny, {
|
|
34
|
+
intro: string;
|
|
35
|
+
plan: {
|
|
36
|
+
nodeType: string;
|
|
37
|
+
reasoning: string;
|
|
38
|
+
nodeName: string;
|
|
39
|
+
}[];
|
|
40
|
+
}, {
|
|
41
|
+
intro: string;
|
|
42
|
+
plan: {
|
|
43
|
+
nodeType: string;
|
|
44
|
+
reasoning: string;
|
|
45
|
+
nodeName: string;
|
|
46
|
+
}[];
|
|
47
|
+
}>;
|
|
48
|
+
export type WorkflowPlanNode = z.infer<typeof planNodeSchema>;
|
|
49
|
+
export type WorkflowPlan = z.infer<typeof workflowPlanSchema>;
|
|
50
|
+
export declare function createWorkflowPlannerAgent(llm: BaseChatModel, nodeTypes: INodeTypeDescription[]): {
|
|
51
|
+
plan(userRequest: string, previousPlan?: WorkflowPlan, feedback?: string): Promise<{
|
|
52
|
+
plan: WorkflowPlan;
|
|
53
|
+
toolMessages: BaseMessage[];
|
|
54
|
+
} | {
|
|
55
|
+
text: string;
|
|
56
|
+
}>;
|
|
57
|
+
};
|
|
58
|
+
export {};
|
|
@@ -0,0 +1,269 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.createWorkflowPlannerAgent = createWorkflowPlannerAgent;
|
|
4
|
+
const messages_1 = require("@langchain/core/messages");
|
|
5
|
+
const tools_1 = require("@langchain/core/tools");
|
|
6
|
+
const langgraph_1 = require("@langchain/langgraph");
|
|
7
|
+
const prebuilt_1 = require("@langchain/langgraph/prebuilt");
|
|
8
|
+
const n8n_workflow_1 = require("n8n-workflow");
|
|
9
|
+
const zod_1 = require("zod");
|
|
10
|
+
const langchain_1 = require("../types/langchain");
|
|
11
|
+
const errors_1 = require("../errors");
|
|
12
|
+
const node_details_tool_1 = require("../tools/node-details.tool");
|
|
13
|
+
const node_search_tool_1 = require("../tools/node-search.tool");
|
|
14
|
+
const planNodeSchema = zod_1.z.object({
|
|
15
|
+
nodeType: zod_1.z
|
|
16
|
+
.string()
|
|
17
|
+
.describe('The exact n8n node type identifier (e.g., "n8n-nodes-base.httpRequest")'),
|
|
18
|
+
nodeName: zod_1.z
|
|
19
|
+
.string()
|
|
20
|
+
.describe('A descriptive name for this node instance (e.g., "Get Weather Data")'),
|
|
21
|
+
reasoning: zod_1.z
|
|
22
|
+
.string()
|
|
23
|
+
.describe('Brief explanation of why this node is needed and what it will do'),
|
|
24
|
+
});
|
|
25
|
+
const workflowPlanSchema = zod_1.z.object({
|
|
26
|
+
intro: zod_1.z.string().describe('A concise summary of the workflow plan'),
|
|
27
|
+
plan: zod_1.z
|
|
28
|
+
.array(planNodeSchema)
|
|
29
|
+
.min(1)
|
|
30
|
+
.describe('Ordered list of nodes that will be used to build the workflow'),
|
|
31
|
+
});
|
|
32
|
+
const generateWorkflowPlanTool = new tools_1.DynamicStructuredTool({
|
|
33
|
+
name: 'generate_workflow_plan',
|
|
34
|
+
description: 'Create a structured plan of n8n nodes based on user requirements and available node information',
|
|
35
|
+
schema: workflowPlanSchema,
|
|
36
|
+
func: async (input) => {
|
|
37
|
+
return input;
|
|
38
|
+
},
|
|
39
|
+
});
|
|
40
|
+
const SYSTEM_PROMPT = `You are a Workflow Planning Assistant for n8n. Your task is to analyze user requests and create a detailed plan of n8n nodes that will be used to build the workflow.
|
|
41
|
+
|
|
42
|
+
## Your Process
|
|
43
|
+
1. Analyze the user's request to understand what they want to automate
|
|
44
|
+
2. Use the search_nodes tool to find relevant n8n nodes for each part of the workflow
|
|
45
|
+
3. Use the get_node_details tool to understand specific nodes' capabilities
|
|
46
|
+
4. Use the generate_workflow_plan tool to create the final structured plan
|
|
47
|
+
|
|
48
|
+
## Guidelines
|
|
49
|
+
- Be thorough in your search - search for different keywords and concepts
|
|
50
|
+
- Use exact node type identifiers (e.g., "n8n-nodes-base.httpRequest")
|
|
51
|
+
- Order nodes logically from trigger/start to final output
|
|
52
|
+
- Place sub-nodes (e.g., AI tools) immediately after their root node (e.g. AI Agent)
|
|
53
|
+
- Only include nodes that directly fulfill the user's requirements
|
|
54
|
+
- Consider data transformation needs between nodes
|
|
55
|
+
- For AI workflows, search for AI-related nodes and sub-nodes
|
|
56
|
+
- ALWAYS start with a trigger node and workflow configuration node (see Workflow Structure Requirements)
|
|
57
|
+
|
|
58
|
+
## Workflow Structure Requirements
|
|
59
|
+
CRITICAL: Every workflow MUST follow this structure:
|
|
60
|
+
|
|
61
|
+
1. **First Node - Trigger (MANDATORY)**
|
|
62
|
+
- Every workflow MUST start with a trigger node
|
|
63
|
+
- Choose the appropriate trigger based on user intent (see Trigger Selection Logic)
|
|
64
|
+
- If no trigger is specified, intelligently select the most appropriate one
|
|
65
|
+
|
|
66
|
+
2. **Second Node - Workflow Configuration (MANDATORY)**
|
|
67
|
+
- ALWAYS add an Edit Fields (Set) node immediately after the trigger
|
|
68
|
+
- Name it "Workflow Configuration"
|
|
69
|
+
- This node serves as the main configuration point for the workflow
|
|
70
|
+
- Downstream nodes will reference values from this node via expressions
|
|
71
|
+
- This centralizes key workflow parameters and makes configuration easier
|
|
72
|
+
|
|
73
|
+
## Trigger Selection Logic
|
|
74
|
+
Choose the trigger based on the workflow's purpose:
|
|
75
|
+
|
|
76
|
+
### Manual Trigger (n8n-nodes-base.manualTrigger)
|
|
77
|
+
Use when:
|
|
78
|
+
- User wants to test or debug the workflow
|
|
79
|
+
- It's a one-time or ad-hoc process
|
|
80
|
+
- User hasn't specified any trigger requirements
|
|
81
|
+
- The workflow is for data processing or transformation tasks
|
|
82
|
+
|
|
83
|
+
### Chat Trigger (n8n-nodes-langchain.chatTrigger)
|
|
84
|
+
Use when:
|
|
85
|
+
- Building conversational AI or chatbot workflows
|
|
86
|
+
- User mentions chat, conversation, or interactive communication
|
|
87
|
+
- The workflow needs to respond to user messages
|
|
88
|
+
- Building AI agents that interact with users
|
|
89
|
+
|
|
90
|
+
### Webhook Trigger (n8n-nodes-base.webhook)
|
|
91
|
+
Use when:
|
|
92
|
+
- Integrating with external systems or APIs
|
|
93
|
+
- User mentions webhooks, API calls, or external events
|
|
94
|
+
- The workflow needs to be triggered by external applications
|
|
95
|
+
- Building automated responses to system events
|
|
96
|
+
|
|
97
|
+
## Search Strategy
|
|
98
|
+
- Search for nodes by functionality (e.g., "email", "database", "api")
|
|
99
|
+
- Search for specific service names mentioned by the user
|
|
100
|
+
- For AI workflows, search for sub-nodes using connection types:
|
|
101
|
+
- NodeConnectionTypes.AiLanguageModel for LLM providers
|
|
102
|
+
- NodeConnectionTypes.AiTool for AI tools
|
|
103
|
+
- NodeConnectionTypes.AiMemory for memory nodes
|
|
104
|
+
- NodeConnectionTypes.AiEmbedding for embeddings
|
|
105
|
+
- NodeConnectionTypes.AiVectorStore for vector stores
|
|
106
|
+
|
|
107
|
+
## Connection Parameter Rules
|
|
108
|
+
When planning nodes, consider their connection requirements:
|
|
109
|
+
|
|
110
|
+
### Static vs Dynamic Nodes
|
|
111
|
+
- **Static nodes** (standard inputs/outputs): HTTP Request, Set, Code
|
|
112
|
+
- **Dynamic nodes** (parameter-dependent connections): AI nodes, Vector Stores, Document Loaders
|
|
113
|
+
|
|
114
|
+
### Dynamic Node Parameters That Affect Connections
|
|
115
|
+
- AI Agent: hasOutputParser creates additional input for schema
|
|
116
|
+
- Vector Store: mode parameter affects available connections (insert vs retrieve-as-tool)
|
|
117
|
+
- Document Loader: textSplittingMode and dataType affect input structure
|
|
118
|
+
|
|
119
|
+
## AI Node Connection Patterns
|
|
120
|
+
CRITICAL: AI sub-nodes PROVIDE capabilities, making them the SOURCE in connections:
|
|
121
|
+
|
|
122
|
+
### Main AI Connections
|
|
123
|
+
- OpenAI Chat Model → AI Agent [ai_languageModel]
|
|
124
|
+
- Calculator Tool → AI Agent [ai_tool]
|
|
125
|
+
- Window Buffer Memory → AI Agent [ai_memory]
|
|
126
|
+
- Token Splitter → Default Data Loader [ai_textSplitter]
|
|
127
|
+
- Default Data Loader → Vector Store [ai_document]
|
|
128
|
+
- Embeddings OpenAI → Vector Store [ai_embedding]
|
|
129
|
+
|
|
130
|
+
Why: Sub-nodes enhance main nodes with their capabilities
|
|
131
|
+
|
|
132
|
+
## RAG Workflow Pattern
|
|
133
|
+
CRITICAL: For RAG (Retrieval-Augmented Generation) workflows, follow this specific pattern:
|
|
134
|
+
|
|
135
|
+
Main data flow:
|
|
136
|
+
- Data source (e.g., HTTP Request) → Vector Store [main connection]
|
|
137
|
+
- The Vector Store receives the actual data through its main input
|
|
138
|
+
|
|
139
|
+
AI capability connections:
|
|
140
|
+
- Document Loader → Vector Store [ai_document] - provides document processing
|
|
141
|
+
- Embeddings → Vector Store [ai_embedding] - provides embedding generation
|
|
142
|
+
- Text Splitter → Document Loader [ai_textSplitter] - provides text chunking
|
|
143
|
+
|
|
144
|
+
Common mistake to avoid:
|
|
145
|
+
- NEVER connect Document Loader to main data outputs
|
|
146
|
+
- Document Loader is NOT a data processor in the main flow
|
|
147
|
+
- Document Loader is an AI sub-node that gives Vector Store the ability to process documents
|
|
148
|
+
|
|
149
|
+
## Agent Node Distinction
|
|
150
|
+
CRITICAL: Distinguish between two different agent node types:
|
|
151
|
+
|
|
152
|
+
1. **AI Agent** (n8n-nodes-langchain.agent)
|
|
153
|
+
- Main workflow node that orchestrates AI tasks
|
|
154
|
+
- Accepts inputs: trigger data, memory, tools, language models
|
|
155
|
+
- Use for: Primary AI logic, chatbots, autonomous workflows
|
|
156
|
+
|
|
157
|
+
2. **AI Agent Tool** (n8n-nodes-langchain.agentTool)
|
|
158
|
+
- Sub-node that acts as a tool for another AI Agent
|
|
159
|
+
- Provides agent-as-a-tool capability to parent agents
|
|
160
|
+
- Use for: Multi-agent systems where one agent calls another
|
|
161
|
+
|
|
162
|
+
Default assumption: When users ask for "an agent" or "AI agent", they mean the main AI Agent node unless they explicitly mention "tool", "sub-agent", or "agent for another agent".
|
|
163
|
+
|
|
164
|
+
## Output Format
|
|
165
|
+
After searching and analyzing available nodes, use the generate_workflow_plan tool to create a structured plan with:
|
|
166
|
+
- The exact node type to use
|
|
167
|
+
- A descriptive name for the node instance
|
|
168
|
+
- Clear reasoning for why this node is needed AND how it connects to other nodes
|
|
169
|
+
- Consider connection requirements in your reasoning
|
|
170
|
+
|
|
171
|
+
Your plan MUST always include:
|
|
172
|
+
1. An appropriate trigger node as the first node
|
|
173
|
+
2. An Edit Fields (Set) node named "Workflow Configuration" as the second node
|
|
174
|
+
3. All other nodes needed to fulfill the user's requirements
|
|
175
|
+
|
|
176
|
+
After using the generate_workflow_plan tool, only respond with a single word "DONE" to indicate the plan is complete.
|
|
177
|
+
Remember: Be precise about node types, understand connection patterns, and always include trigger and configuration nodes.`;
|
|
178
|
+
function formatPlanFeedback(previousPlan, feedback) {
|
|
179
|
+
return `Previous plan: ${JSON.stringify(previousPlan, null, 2)}\n\nUser feedback: ${feedback}\n\nPlease adjust the plan based on the feedback.`;
|
|
180
|
+
}
|
|
181
|
+
function createWorkflowPlannerAgent(llm, nodeTypes) {
|
|
182
|
+
if (!llm.bindTools) {
|
|
183
|
+
throw new errors_1.LLMServiceError("LLM doesn't support binding tools", { llmModel: llm._llmType() });
|
|
184
|
+
}
|
|
185
|
+
const tools = [
|
|
186
|
+
(0, node_search_tool_1.createNodeSearchTool)(nodeTypes).tool,
|
|
187
|
+
(0, node_details_tool_1.createNodeDetailsTool)(nodeTypes).tool,
|
|
188
|
+
generateWorkflowPlanTool,
|
|
189
|
+
];
|
|
190
|
+
const toolNode = new prebuilt_1.ToolNode(tools);
|
|
191
|
+
const modelWithTools = llm.bindTools(tools);
|
|
192
|
+
const shouldContinue = (state) => {
|
|
193
|
+
const { messages } = state;
|
|
194
|
+
const lastMessage = messages[messages.length - 1];
|
|
195
|
+
if ('tool_calls' in lastMessage &&
|
|
196
|
+
Array.isArray(lastMessage.tool_calls) &&
|
|
197
|
+
lastMessage.tool_calls?.length) {
|
|
198
|
+
const hasPlanTool = lastMessage.tool_calls.some((tc) => tc.name === 'generate_workflow_plan');
|
|
199
|
+
if (hasPlanTool) {
|
|
200
|
+
return 'tools';
|
|
201
|
+
}
|
|
202
|
+
return 'tools';
|
|
203
|
+
}
|
|
204
|
+
return langgraph_1.END;
|
|
205
|
+
};
|
|
206
|
+
const callModel = async (state) => {
|
|
207
|
+
const { messages } = state;
|
|
208
|
+
const response = await modelWithTools.invoke(messages);
|
|
209
|
+
return { messages: [response] };
|
|
210
|
+
};
|
|
211
|
+
const workflow = new langgraph_1.StateGraph(langgraph_1.MessagesAnnotation)
|
|
212
|
+
.addNode('agent', callModel)
|
|
213
|
+
.addNode('tools', toolNode)
|
|
214
|
+
.addEdge(langgraph_1.START, 'agent')
|
|
215
|
+
.addConditionalEdges('agent', shouldContinue, ['tools', langgraph_1.END])
|
|
216
|
+
.addEdge('tools', 'agent');
|
|
217
|
+
const app = workflow.compile();
|
|
218
|
+
return {
|
|
219
|
+
async plan(userRequest, previousPlan, feedback) {
|
|
220
|
+
const systemMessage = new messages_1.SystemMessage(SYSTEM_PROMPT);
|
|
221
|
+
let userMessage = userRequest;
|
|
222
|
+
if (previousPlan && feedback) {
|
|
223
|
+
userMessage += '\n\n';
|
|
224
|
+
userMessage += formatPlanFeedback(previousPlan, feedback);
|
|
225
|
+
}
|
|
226
|
+
const humanMessage = new messages_1.HumanMessage(userMessage);
|
|
227
|
+
const result = await app.invoke({
|
|
228
|
+
messages: [systemMessage, humanMessage],
|
|
229
|
+
});
|
|
230
|
+
const toolMessages = result.messages.filter((msg) => {
|
|
231
|
+
if (['system', 'human'].includes(msg.getType())) {
|
|
232
|
+
return false;
|
|
233
|
+
}
|
|
234
|
+
if ((0, langchain_1.isAIMessage)(msg) && (msg.tool_calls ?? []).length === 0) {
|
|
235
|
+
return false;
|
|
236
|
+
}
|
|
237
|
+
return true;
|
|
238
|
+
});
|
|
239
|
+
const workflowPlanToolCall = result.messages.findLast((msg) => {
|
|
240
|
+
return msg.name === 'generate_workflow_plan';
|
|
241
|
+
});
|
|
242
|
+
if (!workflowPlanToolCall) {
|
|
243
|
+
const lastAiMessage = result.messages.findLast((msg) => {
|
|
244
|
+
return (0, langchain_1.isAIMessage)(msg) && (msg.tool_calls ?? []).length === 0;
|
|
245
|
+
});
|
|
246
|
+
if (lastAiMessage) {
|
|
247
|
+
return {
|
|
248
|
+
text: lastAiMessage.text,
|
|
249
|
+
};
|
|
250
|
+
}
|
|
251
|
+
throw new errors_1.ToolExecutionError('Invalid response from agent - no plan generated');
|
|
252
|
+
}
|
|
253
|
+
try {
|
|
254
|
+
if (typeof workflowPlanToolCall.content !== 'string') {
|
|
255
|
+
throw new errors_1.ToolExecutionError('Workflow plan tool call content is not a string');
|
|
256
|
+
}
|
|
257
|
+
const workflowPlan = (0, n8n_workflow_1.jsonParse)(workflowPlanToolCall.content);
|
|
258
|
+
return {
|
|
259
|
+
plan: workflowPlan,
|
|
260
|
+
toolMessages,
|
|
261
|
+
};
|
|
262
|
+
}
|
|
263
|
+
catch (error) {
|
|
264
|
+
throw new errors_1.ToolExecutionError(`Failed to parse workflow plan: ${error instanceof Error ? error.message : 'Unknown error'}`);
|
|
265
|
+
}
|
|
266
|
+
},
|
|
267
|
+
};
|
|
268
|
+
}
|
|
269
|
+
//# sourceMappingURL=workflow-planner-agent.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"workflow-planner-agent.js","sourceRoot":"","sources":["../../src/agents/workflow-planner-agent.ts"],"names":[],"mappings":";;AAoMA,gEAwIC;AAxUD,uDAAuE;AACvE,iDAA8D;AAC9D,oDAAkF;AAClF,4DAAyD;AACzD,+CAAoE;AACpE,6BAAwB;AAExB,iDAAgD;AAEhD,sCAAgE;AAChE,kEAAmE;AACnE,gEAAiE;AAEjE,MAAM,cAAc,GAAG,OAAC,CAAC,MAAM,CAAC;IAC/B,QAAQ,EAAE,OAAC;SACT,MAAM,EAAE;SACR,QAAQ,CAAC,yEAAyE,CAAC;IACrF,QAAQ,EAAE,OAAC;SACT,MAAM,EAAE;SACR,QAAQ,CAAC,sEAAsE,CAAC;IAClF,SAAS,EAAE,OAAC;SACV,MAAM,EAAE;SACR,QAAQ,CAAC,kEAAkE,CAAC;CAC9E,CAAC,CAAC;AAEH,MAAM,kBAAkB,GAAG,OAAC,CAAC,MAAM,CAAC;IACnC,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,wCAAwC,CAAC;IACpE,IAAI,EAAE,OAAC;SACL,KAAK,CAAC,cAAc,CAAC;SACrB,GAAG,CAAC,CAAC,CA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,CAAC,GAAG,CAAC,UAAU,IAAI,EAAE,CAAC,CAAC,MAAM,KAAK,CAAC,CAAC;gBAChE,CAAC,CAAC,CAAC;gBAEH,IAAI,aAAa,EAAE,CAAC;oBACnB,OAAO;wBACN,IAAI,EAAE,aAAa,CAAC,IAAI;qBACxB,CAAC;gBACH,CAAC;gBAED,MAAM,IAAI,2BAAkB,CAAC,iDAAiD,CAAC,CAAC;YACjF,CAAC;YAED,IAAI,CAAC;gBACJ,IAAI,OAAO,oBAAoB,CAAC,OAAO,KAAK,QAAQ,EAAE,CAAC;oBACtD,MAAM,IAAI,2BAAkB,CAAC,iDAAiD,CAAC,CAAC;gBACjF,CAAC;gBAED,MAAM,YAAY,GAAG,IAAA,wBAAS,EAAe,oBAAoB,CAAC,OAAO,CAAC,CAAC;gBAC3E,OAAO;oBACN,IAAI,EAAE,YAAY;oBAClB,YAAY;iBACZ,CAAC;YACH,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBAChB,MAAM,IAAI,2BAAkB,CAC3B,kCAAkC,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,eAAe,EAAE,CAC5F,CAAC;YACH,CAAC;QACF,CAAC;KACD,CAAC;AACH,CAAC"}
|
|
@@ -7,13 +7,14 @@ export declare class AiWorkflowBuilderService {
|
|
|
7
7
|
private readonly nodeTypes;
|
|
8
8
|
private readonly client?;
|
|
9
9
|
private readonly logger?;
|
|
10
|
+
private readonly instanceUrl?;
|
|
10
11
|
private parsedNodeTypes;
|
|
11
12
|
private llmSimpleTask;
|
|
12
13
|
private llmComplexTask;
|
|
13
14
|
private tracingClient;
|
|
14
15
|
private checkpointer;
|
|
15
16
|
private agent;
|
|
16
|
-
constructor(nodeTypes: INodeTypes, client?: AiAssistantClient | undefined, logger?: Logger | undefined);
|
|
17
|
+
constructor(nodeTypes: INodeTypes, client?: AiAssistantClient | undefined, logger?: Logger | undefined, instanceUrl?: string | undefined);
|
|
17
18
|
private setupModels;
|
|
18
19
|
private getNodeTypes;
|
|
19
20
|
private getAgent;
|
|
@@ -23,16 +23,18 @@ let AiWorkflowBuilderService = class AiWorkflowBuilderService {
|
|
|
23
23
|
nodeTypes;
|
|
24
24
|
client;
|
|
25
25
|
logger;
|
|
26
|
+
instanceUrl;
|
|
26
27
|
parsedNodeTypes = [];
|
|
27
28
|
llmSimpleTask;
|
|
28
29
|
llmComplexTask;
|
|
29
30
|
tracingClient;
|
|
30
31
|
checkpointer = new langgraph_1.MemorySaver();
|
|
31
32
|
agent;
|
|
32
|
-
constructor(nodeTypes, client, logger) {
|
|
33
|
+
constructor(nodeTypes, client, logger, instanceUrl) {
|
|
33
34
|
this.nodeTypes = nodeTypes;
|
|
34
35
|
this.client = client;
|
|
35
36
|
this.logger = logger;
|
|
37
|
+
this.instanceUrl = instanceUrl;
|
|
36
38
|
this.parsedNodeTypes = this.getNodeTypes();
|
|
37
39
|
}
|
|
38
40
|
async setupModels(user) {
|
|
@@ -82,7 +84,7 @@ let AiWorkflowBuilderService = class AiWorkflowBuilderService {
|
|
|
82
84
|
});
|
|
83
85
|
}
|
|
84
86
|
catch (error) {
|
|
85
|
-
const llmError = new errors_1.LLMServiceError('Failed to
|
|
87
|
+
const llmError = new errors_1.LLMServiceError('Failed to connect to LLM Provider', {
|
|
86
88
|
cause: error,
|
|
87
89
|
tags: {
|
|
88
90
|
hasClient: !!this.client,
|
|
@@ -144,6 +146,7 @@ let AiWorkflowBuilderService = class AiWorkflowBuilderService {
|
|
|
144
146
|
tracer: this.tracingClient
|
|
145
147
|
? new tracer_langchain_1.LangChainTracer({ client: this.tracingClient, projectName: 'n8n-workflow-builder' })
|
|
146
148
|
: undefined,
|
|
149
|
+
instanceUrl: this.instanceUrl,
|
|
147
150
|
});
|
|
148
151
|
return this.agent;
|
|
149
152
|
}
|
|
@@ -162,6 +165,6 @@ exports.AiWorkflowBuilderService = AiWorkflowBuilderService;
|
|
|
162
165
|
exports.AiWorkflowBuilderService = AiWorkflowBuilderService = __decorate([
|
|
163
166
|
(0, di_1.Service)(),
|
|
164
167
|
__metadata("design:paramtypes", [Object, ai_assistant_sdk_1.AiAssistantClient,
|
|
165
|
-
backend_common_1.Logger])
|
|
168
|
+
backend_common_1.Logger, String])
|
|
166
169
|
], AiWorkflowBuilderService);
|
|
167
170
|
//# sourceMappingURL=ai-workflow-builder-agent.service.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ai-workflow-builder-agent.service.js","sourceRoot":"","sources":["../src/ai-workflow-builder-agent.service.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,+EAA2E;AAC3E,oDAAmD;AACnD,wDAA6C;AAC7C,gCAAkC;AAClC,+DAA6D;AAC7D,yCAAmC;AAInC,qCAA2C;AAC3C,6CAAiE;AACjE,qEAAkF;AAG3E,IAAM,wBAAwB,GAA9B,MAAM,wBAAwB;IAclB;IACA;IACA;
|
|
1
|
+
{"version":3,"file":"ai-workflow-builder-agent.service.js","sourceRoot":"","sources":["../src/ai-workflow-builder-agent.service.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,+EAA2E;AAC3E,oDAAmD;AACnD,wDAA6C;AAC7C,gCAAkC;AAClC,+DAA6D;AAC7D,yCAAmC;AAInC,qCAA2C;AAC3C,6CAAiE;AACjE,qEAAkF;AAG3E,IAAM,wBAAwB,GAA9B,MAAM,wBAAwB;IAclB;IACA;IACA;IACA;IAhBV,eAAe,GAA2B,EAAE,CAAC;IAE7C,aAAa,CAA4B;IAEzC,cAAc,CAA4B;IAE1C,aAAa,CAAqB;IAElC,YAAY,GAAG,IAAI,uBAAW,EAAE,CAAC;IAEjC,KAAK,CAAmC;IAEhD,YACkB,SAAqB,EACrB,MAA0B,EAC1B,MAAe,EACf,WAAoB;QAHpB,cAAS,GAAT,SAAS,CAAY;QACrB,WAAM,GAAN,MAAM,CAAoB;QAC1B,WAAM,GAAN,MAAM,CAAS;QACf,gBAAW,GAAX,WAAW,CAAS;QAErC,IA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