n8n-nodes-simple 0.2.3 → 0.3.1
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/credentials/SimpleOpenAiApi.credentials.d.ts +2 -2
- package/dist/credentials/SimpleOpenAiApi.credentials.js +1 -1
- package/dist/credentials/SimpleOpenAiApi.credentials.js.map +1 -1
- package/dist/nodes/CoreAgent/CoreAgent.node.d.ts +2 -3
- package/dist/nodes/CoreAgent/CoreAgent.node.js +2 -14
- package/dist/nodes/CoreAgent/CoreAgent.node.js.map +1 -1
- package/dist/nodes/CoreAgent/descriptions.d.ts +2 -0
- package/dist/nodes/CoreAgent/descriptions.js +21 -0
- package/dist/nodes/CoreAgent/descriptions.js.map +1 -0
- package/dist/nodes/Subagent/Subagent.node.d.ts +3 -4
- package/dist/nodes/Subagent/Subagent.node.js +4 -17
- package/dist/nodes/Subagent/Subagent.node.js.map +1 -1
- package/dist/nodes/Subagent/descriptions.d.ts +2 -0
- package/dist/nodes/Subagent/descriptions.js +22 -0
- package/dist/nodes/Subagent/descriptions.js.map +1 -0
- package/dist/nodes/shared/actions/message.operation.js +58 -38
- package/dist/nodes/shared/actions/message.operation.js.map +1 -1
- package/dist/nodes/shared/actions/router.js +1 -1
- package/dist/nodes/shared/actions/router.js.map +1 -1
- package/dist/nodes/shared/actions/tool.d.ts +2 -0
- package/dist/nodes/shared/actions/{asTool.js → tool.js} +9 -9
- package/dist/nodes/shared/actions/tool.js.map +1 -0
- package/dist/nodes/shared/{helpers/api → api}/errorHandling.js +6 -9
- package/dist/nodes/shared/api/errorHandling.js.map +1 -0
- package/dist/nodes/shared/{helpers/api/apiRequest.d.ts → api/openAiApiRequest.d.ts} +1 -1
- package/dist/nodes/shared/{helpers/api/apiRequest.js → api/openAiApiRequest.js} +3 -3
- package/dist/nodes/shared/api/openAiApiRequest.js.map +1 -0
- package/dist/nodes/shared/{helpers/api/interfaces.js → api/types.js} +1 -1
- package/dist/nodes/shared/api/types.js.map +1 -0
- package/dist/nodes/shared/{helpers/api → api}/utils.js +13 -10
- package/dist/nodes/shared/api/utils.js.map +1 -0
- package/dist/nodes/shared/constants.js.map +1 -0
- package/dist/nodes/shared/createNodeTypeDescription.js +14 -48
- package/dist/nodes/shared/createNodeTypeDescription.js.map +1 -1
- package/dist/nodes/shared/message/processor.d.ts +7 -0
- package/dist/nodes/shared/{helpers/asCoreNode/chatUnpacker.js → message/processor.js} +27 -3
- package/dist/nodes/shared/message/processor.js.map +1 -0
- package/dist/nodes/shared/{helpers/asCoreNode/messageModel.d.ts → message/types.d.ts} +3 -0
- package/dist/nodes/shared/{helpers/asCoreNode/messageModel.js → message/types.js} +1 -1
- package/dist/nodes/shared/message/types.js.map +1 -0
- package/dist/nodes/shared/methods/listSearch.js +2 -2
- package/dist/nodes/shared/methods/listSearch.js.map +1 -1
- package/dist/nodes/shared/properties.js +135 -128
- package/dist/nodes/shared/properties.js.map +1 -1
- package/dist/nodes/shared/tool/customFields.js.map +1 -0
- package/dist/nodes/shared/{helpers/asTool/toolSchemaParsing.js → tool/schemaGenerator.js} +1 -1
- package/dist/nodes/shared/tool/schemaGenerator.js.map +1 -0
- package/dist/nodes/shared/{helpers/asTool → tool}/subagentTool.js +3 -2
- package/dist/nodes/shared/tool/subagentTool.js.map +1 -0
- package/dist/nodes/shared/{helpers/asToolUser/langchainHelpers.js → toolManager/getConnectedTools.js} +4 -4
- package/dist/nodes/shared/toolManager/getConnectedTools.js.map +1 -0
- package/dist/nodes/shared/{helpers/asToolUser/N8nTool.d.ts → toolManager/n8nTool.d.ts} +2 -2
- package/dist/nodes/shared/{helpers/asToolUser/N8nTool.js → toolManager/n8nTool.js} +3 -3
- package/dist/nodes/shared/toolManager/n8nTool.js.map +1 -0
- package/dist/package.json +6 -6
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +6 -6
- package/dist/credentials/gradientOpenAi.svg +0 -9
- package/dist/nodes/shared/actions/asTool.d.ts +0 -2
- package/dist/nodes/shared/actions/asTool.js.map +0 -1
- package/dist/nodes/shared/gradientRobot.svg +0 -11
- package/dist/nodes/shared/gradientRobotRed.svg +0 -11
- package/dist/nodes/shared/helpers/api/apiRequest.js.map +0 -1
- package/dist/nodes/shared/helpers/api/errorHandling.js.map +0 -1
- package/dist/nodes/shared/helpers/api/interfaces.js.map +0 -1
- package/dist/nodes/shared/helpers/api/utils.js.map +0 -1
- package/dist/nodes/shared/helpers/asCoreNode/chatUnpacker.d.ts +0 -6
- package/dist/nodes/shared/helpers/asCoreNode/chatUnpacker.js.map +0 -1
- package/dist/nodes/shared/helpers/asCoreNode/constants.js.map +0 -1
- package/dist/nodes/shared/helpers/asCoreNode/messageModel.js.map +0 -1
- package/dist/nodes/shared/helpers/asCoreNode/stepsExtractor.d.ts +0 -6
- package/dist/nodes/shared/helpers/asCoreNode/stepsExtractor.js +0 -27
- package/dist/nodes/shared/helpers/asCoreNode/stepsExtractor.js.map +0 -1
- package/dist/nodes/shared/helpers/asTool/customFields.js.map +0 -1
- package/dist/nodes/shared/helpers/asTool/subagentTool.js.map +0 -1
- package/dist/nodes/shared/helpers/asTool/toolSchemaParsing.js.map +0 -1
- package/dist/nodes/shared/helpers/asToolUser/N8nTool.js.map +0 -1
- package/dist/nodes/shared/helpers/asToolUser/langchainHelpers.js.map +0 -1
- /package/dist/nodes/shared/{helpers/api → api}/errorHandling.d.ts +0 -0
- /package/dist/nodes/shared/{helpers/api/interfaces.d.ts → api/types.d.ts} +0 -0
- /package/dist/nodes/shared/{helpers/api → api}/utils.d.ts +0 -0
- /package/dist/nodes/shared/{helpers/asCoreNode/constants.d.ts → constants.d.ts} +0 -0
- /package/dist/nodes/shared/{helpers/asCoreNode/constants.js → constants.js} +0 -0
- /package/dist/nodes/shared/{helpers/asTool → tool}/customFields.d.ts +0 -0
- /package/dist/nodes/shared/{helpers/asTool → tool}/customFields.js +0 -0
- /package/dist/nodes/shared/{helpers/asTool/toolSchemaParsing.d.ts → tool/schemaGenerator.d.ts} +0 -0
- /package/dist/nodes/shared/{helpers/asTool → tool}/subagentTool.d.ts +0 -0
- /package/dist/nodes/shared/{helpers/asToolUser/langchainHelpers.d.ts → toolManager/getConnectedTools.d.ts} +0 -0
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.getProperties = getProperties;
|
|
4
|
-
const constants_1 = require("./
|
|
4
|
+
const constants_1 = require("./constants");
|
|
5
5
|
function getProperties(agentType = 'coreAgent') {
|
|
6
6
|
return [
|
|
7
7
|
{
|
|
8
8
|
displayName: 'Model',
|
|
9
9
|
name: 'modelId',
|
|
10
10
|
type: 'resourceLocator',
|
|
11
|
-
default: { mode: 'list', value: 'gpt-
|
|
11
|
+
default: { mode: 'list', value: 'gpt-4.1-mini' },
|
|
12
12
|
required: true,
|
|
13
13
|
description: 'Read the <a href="https://platform.openai.com/docs/models" target="_blank">models overview</a> and <a href="https://openai.com/api/pricing/" target="_blank">pricing</a>',
|
|
14
14
|
modes: [
|
|
@@ -25,7 +25,7 @@ function getProperties(agentType = 'coreAgent') {
|
|
|
25
25
|
displayName: 'ID',
|
|
26
26
|
name: 'id',
|
|
27
27
|
type: 'string',
|
|
28
|
-
placeholder: 'e.g. gpt-
|
|
28
|
+
placeholder: 'e.g. gpt-4.1-mini',
|
|
29
29
|
},
|
|
30
30
|
],
|
|
31
31
|
},
|
|
@@ -40,14 +40,6 @@ function getProperties(agentType = 'coreAgent') {
|
|
|
40
40
|
},
|
|
41
41
|
},
|
|
42
42
|
},
|
|
43
|
-
{
|
|
44
|
-
displayName: 'Temperature',
|
|
45
|
-
name: 'temperature',
|
|
46
|
-
default: 1,
|
|
47
|
-
typeOptions: { maxValue: 2, minValue: 0, numberPrecision: 1 },
|
|
48
|
-
description: 'What sampling temperature to use, between 0 and 2. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. Read the <a href="https://platform.openai.com/docs/api-reference/chat/create" target="_blank">API Reference docs</a>',
|
|
49
|
-
type: 'number',
|
|
50
|
-
},
|
|
51
43
|
{
|
|
52
44
|
displayName: 'Type',
|
|
53
45
|
name: 'agentType',
|
|
@@ -64,100 +56,12 @@ function getProperties(agentType = 'coreAgent') {
|
|
|
64
56
|
name: '🛠️ Subagent',
|
|
65
57
|
value: 'subAgent',
|
|
66
58
|
description: "Sub-node usable as a tool"
|
|
67
|
-
}
|
|
59
|
+
}
|
|
68
60
|
],
|
|
69
61
|
default: agentType
|
|
70
62
|
},
|
|
71
63
|
{
|
|
72
|
-
displayName:
|
|
73
|
-
name: 'notice',
|
|
74
|
-
type: 'notice',
|
|
75
|
-
default: '',
|
|
76
|
-
displayOptions: {
|
|
77
|
-
show: {
|
|
78
|
-
agentType: ['flexAgent']
|
|
79
|
-
},
|
|
80
|
-
},
|
|
81
|
-
},
|
|
82
|
-
{
|
|
83
|
-
displayName: 'Messages',
|
|
84
|
-
name: 'messagesToSend',
|
|
85
|
-
type: 'fixedCollection',
|
|
86
|
-
typeOptions: {
|
|
87
|
-
sortable: true,
|
|
88
|
-
multipleValues: true,
|
|
89
|
-
},
|
|
90
|
-
placeholder: 'Add Message',
|
|
91
|
-
default: { values: [{ content: '' }] },
|
|
92
|
-
options: [
|
|
93
|
-
{
|
|
94
|
-
displayName: 'Values',
|
|
95
|
-
name: 'values',
|
|
96
|
-
values: [
|
|
97
|
-
{
|
|
98
|
-
displayName: 'Role',
|
|
99
|
-
name: 'role',
|
|
100
|
-
type: 'options',
|
|
101
|
-
options: [
|
|
102
|
-
{
|
|
103
|
-
name: '🤖 Assistant',
|
|
104
|
-
value: 'assistant',
|
|
105
|
-
},
|
|
106
|
-
{
|
|
107
|
-
name: '🖥️ System',
|
|
108
|
-
value: 'system',
|
|
109
|
-
},
|
|
110
|
-
{
|
|
111
|
-
name: '🙋♂️ User',
|
|
112
|
-
value: 'user',
|
|
113
|
-
},
|
|
114
|
-
{
|
|
115
|
-
name: '💬 Chat History',
|
|
116
|
-
value: 'chatHistoryRole',
|
|
117
|
-
},
|
|
118
|
-
{
|
|
119
|
-
name: '💭 Chat Memory',
|
|
120
|
-
value: 'chatMemoryRole',
|
|
121
|
-
},
|
|
122
|
-
],
|
|
123
|
-
default: 'user',
|
|
124
|
-
},
|
|
125
|
-
{
|
|
126
|
-
displayName: 'Content',
|
|
127
|
-
name: 'content',
|
|
128
|
-
type: 'string',
|
|
129
|
-
default: '',
|
|
130
|
-
description: "The message's content. Supports ={{ $json.chatInput }}",
|
|
131
|
-
typeOptions: {
|
|
132
|
-
rows: 2,
|
|
133
|
-
},
|
|
134
|
-
displayOptions: {
|
|
135
|
-
hide: {
|
|
136
|
-
'role': ['chatHistoryRole', 'chatMemoryRole']
|
|
137
|
-
}
|
|
138
|
-
}
|
|
139
|
-
},
|
|
140
|
-
{
|
|
141
|
-
displayName: 'JSON Messages',
|
|
142
|
-
name: 'chatHistoryJson',
|
|
143
|
-
type: 'json',
|
|
144
|
-
default: '',
|
|
145
|
-
description: "A JSON array of objects with 'role' and 'content' keys. Invalid syntax defaults to user message content. Supports ={{ $json.chat_history }}",
|
|
146
|
-
typeOptions: {
|
|
147
|
-
rows: 2,
|
|
148
|
-
},
|
|
149
|
-
displayOptions: {
|
|
150
|
-
show: {
|
|
151
|
-
'role': ['chatHistoryRole']
|
|
152
|
-
}
|
|
153
|
-
}
|
|
154
|
-
}
|
|
155
|
-
],
|
|
156
|
-
},
|
|
157
|
-
],
|
|
158
|
-
},
|
|
159
|
-
{
|
|
160
|
-
displayName: 'Name',
|
|
64
|
+
displayName: 'Subagent Name',
|
|
161
65
|
name: 'name',
|
|
162
66
|
type: 'string',
|
|
163
67
|
default: '',
|
|
@@ -165,7 +69,7 @@ function getProperties(agentType = 'coreAgent') {
|
|
|
165
69
|
description: `Unique name of the subagent to be called by another agent. Can contain letters, numbers and underscores only. Example: <i>"web_searcher"</i>.`,
|
|
166
70
|
displayOptions: {
|
|
167
71
|
show: {
|
|
168
|
-
agentType: ["subAgent"
|
|
72
|
+
agentType: ["subAgent"],
|
|
169
73
|
},
|
|
170
74
|
},
|
|
171
75
|
},
|
|
@@ -180,7 +84,7 @@ function getProperties(agentType = 'coreAgent') {
|
|
|
180
84
|
},
|
|
181
85
|
displayOptions: {
|
|
182
86
|
show: {
|
|
183
|
-
agentType: ["subAgent"
|
|
87
|
+
agentType: ["subAgent"],
|
|
184
88
|
},
|
|
185
89
|
},
|
|
186
90
|
},
|
|
@@ -192,27 +96,27 @@ function getProperties(agentType = 'coreAgent') {
|
|
|
192
96
|
noDataExpression: true,
|
|
193
97
|
options: [
|
|
194
98
|
{
|
|
195
|
-
name: '
|
|
99
|
+
name: 'Custom Fields',
|
|
196
100
|
value: 'inputCustomFields',
|
|
197
101
|
},
|
|
198
102
|
{
|
|
199
|
-
name: '
|
|
103
|
+
name: 'JSON Example',
|
|
200
104
|
value: 'inputJsonExample',
|
|
201
105
|
},
|
|
202
106
|
{
|
|
203
|
-
name: '
|
|
107
|
+
name: 'JSON Schema',
|
|
204
108
|
value: 'inputJsonSchema',
|
|
205
109
|
},
|
|
206
110
|
{
|
|
207
111
|
name: 'None',
|
|
208
112
|
value: 'default',
|
|
209
|
-
description: '
|
|
113
|
+
description: 'Append {{input}} as a user message'
|
|
210
114
|
}
|
|
211
115
|
],
|
|
212
116
|
default: 'default',
|
|
213
117
|
displayOptions: {
|
|
214
118
|
show: {
|
|
215
|
-
agentType: ["subAgent"
|
|
119
|
+
agentType: ["subAgent"],
|
|
216
120
|
},
|
|
217
121
|
},
|
|
218
122
|
},
|
|
@@ -231,7 +135,7 @@ function getProperties(agentType = 'coreAgent') {
|
|
|
231
135
|
},
|
|
232
136
|
displayOptions: {
|
|
233
137
|
show: {
|
|
234
|
-
agentType: ["subAgent"
|
|
138
|
+
agentType: ["subAgent"],
|
|
235
139
|
inputSchemaType: ['inputJsonExample']
|
|
236
140
|
},
|
|
237
141
|
},
|
|
@@ -259,7 +163,7 @@ function getProperties(agentType = 'coreAgent') {
|
|
|
259
163
|
},
|
|
260
164
|
displayOptions: {
|
|
261
165
|
show: {
|
|
262
|
-
agentType: ["subAgent"
|
|
166
|
+
agentType: ["subAgent"],
|
|
263
167
|
inputSchemaType: ['inputJsonSchema']
|
|
264
168
|
},
|
|
265
169
|
},
|
|
@@ -315,20 +219,112 @@ function getProperties(agentType = 'coreAgent') {
|
|
|
315
219
|
],
|
|
316
220
|
displayOptions: {
|
|
317
221
|
show: {
|
|
318
|
-
agentType: ["subAgent"
|
|
222
|
+
agentType: ["subAgent"],
|
|
319
223
|
inputSchemaType: ['inputCustomFields']
|
|
320
224
|
},
|
|
321
225
|
},
|
|
322
226
|
},
|
|
323
227
|
{
|
|
324
|
-
displayName: '
|
|
325
|
-
name: '
|
|
326
|
-
type: '
|
|
327
|
-
|
|
328
|
-
|
|
228
|
+
displayName: 'Messages',
|
|
229
|
+
name: 'messagesToSend',
|
|
230
|
+
type: 'fixedCollection',
|
|
231
|
+
typeOptions: {
|
|
232
|
+
sortable: true,
|
|
233
|
+
multipleValues: true,
|
|
234
|
+
},
|
|
235
|
+
placeholder: 'Add Message',
|
|
236
|
+
default: { values: [{ content: '' }] },
|
|
237
|
+
options: [
|
|
238
|
+
{
|
|
239
|
+
displayName: 'Values',
|
|
240
|
+
name: 'values',
|
|
241
|
+
values: [
|
|
242
|
+
{
|
|
243
|
+
displayName: 'Role',
|
|
244
|
+
name: 'role',
|
|
245
|
+
type: 'options',
|
|
246
|
+
options: [
|
|
247
|
+
{
|
|
248
|
+
name: '🤖 Assistant',
|
|
249
|
+
value: 'assistant',
|
|
250
|
+
},
|
|
251
|
+
{
|
|
252
|
+
name: '🖥️ System',
|
|
253
|
+
value: 'system',
|
|
254
|
+
},
|
|
255
|
+
{
|
|
256
|
+
name: '🙋♂️ User',
|
|
257
|
+
value: 'user',
|
|
258
|
+
},
|
|
259
|
+
{
|
|
260
|
+
name: '💬 Chat History',
|
|
261
|
+
value: 'chatHistoryRole',
|
|
262
|
+
},
|
|
263
|
+
{
|
|
264
|
+
name: '💭 Chat Memory',
|
|
265
|
+
value: 'chatMemoryRole',
|
|
266
|
+
},
|
|
267
|
+
],
|
|
268
|
+
default: 'user',
|
|
269
|
+
},
|
|
270
|
+
{
|
|
271
|
+
displayName: 'Content',
|
|
272
|
+
name: 'content',
|
|
273
|
+
type: 'string',
|
|
274
|
+
default: '',
|
|
275
|
+
description: "The message's content. Supports ={{ $json.chatInput }}",
|
|
276
|
+
typeOptions: {
|
|
277
|
+
rows: 2,
|
|
278
|
+
},
|
|
279
|
+
displayOptions: {
|
|
280
|
+
hide: {
|
|
281
|
+
'role': ['chatHistoryRole', 'chatMemoryRole']
|
|
282
|
+
}
|
|
283
|
+
}
|
|
284
|
+
},
|
|
285
|
+
{
|
|
286
|
+
displayName: 'JSON Messages',
|
|
287
|
+
name: 'chatHistoryJson',
|
|
288
|
+
type: 'json',
|
|
289
|
+
default: '',
|
|
290
|
+
description: "A JSON array of objects with 'role' and 'content' keys. Invalid syntax defaults to user message content. Supports ={{ $json.chat_history }}",
|
|
291
|
+
typeOptions: {
|
|
292
|
+
rows: 2,
|
|
293
|
+
},
|
|
294
|
+
displayOptions: {
|
|
295
|
+
show: {
|
|
296
|
+
'role': ['chatHistoryRole']
|
|
297
|
+
}
|
|
298
|
+
}
|
|
299
|
+
}
|
|
300
|
+
],
|
|
301
|
+
},
|
|
302
|
+
],
|
|
303
|
+
},
|
|
304
|
+
{
|
|
305
|
+
displayName: 'Response Format',
|
|
306
|
+
name: 'responseFormat',
|
|
307
|
+
description: 'The format that the model must output. JSON Mode ensures the message the model generates is valid JSON. Structured Output ensures the model will match your supplied JSON schema; it is compatible with gpt-4o-mini-2024-07-18, gpt-4o-2024-08-06, and later. Read the <a href="https://platform.openai.com/docs/guides/structured-outputs" target="_blank">docs</a>.',
|
|
308
|
+
type: 'options',
|
|
309
|
+
noDataExpression: true,
|
|
310
|
+
options: [
|
|
311
|
+
{
|
|
312
|
+
name: 'Plain Text',
|
|
313
|
+
value: 'plainText',
|
|
314
|
+
},
|
|
315
|
+
{
|
|
316
|
+
name: 'JSON Mode',
|
|
317
|
+
value: 'jsonMode',
|
|
318
|
+
},
|
|
319
|
+
{
|
|
320
|
+
name: 'Structured Output',
|
|
321
|
+
value: 'structuredOutput',
|
|
322
|
+
}
|
|
323
|
+
],
|
|
324
|
+
default: 'plainText',
|
|
329
325
|
displayOptions: {
|
|
330
326
|
show: {
|
|
331
|
-
agentType: ["coreAgent"
|
|
327
|
+
agentType: ["coreAgent"],
|
|
332
328
|
},
|
|
333
329
|
},
|
|
334
330
|
},
|
|
@@ -345,7 +341,8 @@ function getProperties(agentType = 'coreAgent') {
|
|
|
345
341
|
description: 'Generate a schema <a href="https://platform.openai.com/docs/guides/structured-outputs" target="_blank">here</a>',
|
|
346
342
|
displayOptions: {
|
|
347
343
|
show: {
|
|
348
|
-
|
|
344
|
+
agentType: ["coreAgent"],
|
|
345
|
+
responseFormat: ["structuredOutput"],
|
|
349
346
|
}
|
|
350
347
|
}
|
|
351
348
|
},
|
|
@@ -361,25 +358,25 @@ function getProperties(agentType = 'coreAgent') {
|
|
|
361
358
|
description: 'All messages, including the final assistant message',
|
|
362
359
|
},
|
|
363
360
|
{
|
|
364
|
-
name: '
|
|
361
|
+
name: 'Response',
|
|
365
362
|
value: 'fullResponse',
|
|
366
|
-
description: 'The
|
|
363
|
+
description: 'The final HTTP response from the model',
|
|
367
364
|
},
|
|
368
365
|
{
|
|
369
366
|
name: 'Request',
|
|
370
367
|
value: 'request',
|
|
371
|
-
description: 'The
|
|
368
|
+
description: 'The final HTTP request sent to the model',
|
|
372
369
|
},
|
|
373
370
|
{
|
|
374
|
-
name: '
|
|
375
|
-
value: '
|
|
376
|
-
description: "The
|
|
371
|
+
name: 'Tool Calls',
|
|
372
|
+
value: 'tool_calls',
|
|
373
|
+
description: "The model's intermediate steps (tools inputs and outputs)",
|
|
377
374
|
},
|
|
378
375
|
],
|
|
379
376
|
default: ['request'],
|
|
380
377
|
displayOptions: {
|
|
381
378
|
show: {
|
|
382
|
-
agentType: ["coreAgent"
|
|
379
|
+
agentType: ["coreAgent"],
|
|
383
380
|
},
|
|
384
381
|
},
|
|
385
382
|
},
|
|
@@ -391,18 +388,20 @@ function getProperties(agentType = 'coreAgent') {
|
|
|
391
388
|
description: "Whether to include system messages in the Chat History",
|
|
392
389
|
displayOptions: {
|
|
393
390
|
show: {
|
|
391
|
+
agentType: ["coreAgent"],
|
|
394
392
|
addToOutput: ['chatHistory'],
|
|
395
393
|
},
|
|
396
394
|
},
|
|
397
395
|
},
|
|
398
396
|
{
|
|
399
|
-
displayName: 'Include
|
|
400
|
-
name: '
|
|
397
|
+
displayName: 'Include Tool Calls in Chat History',
|
|
398
|
+
name: 'includeToolCallsInChatHistory',
|
|
401
399
|
type: 'boolean',
|
|
402
400
|
default: true,
|
|
403
|
-
description: "Whether to include
|
|
401
|
+
description: "Whether to include tool calls (function-calling assistant messages and tool messages) in the Chat History",
|
|
404
402
|
displayOptions: {
|
|
405
403
|
show: {
|
|
404
|
+
agentType: ["coreAgent"],
|
|
406
405
|
addToOutput: ['chatHistory'],
|
|
407
406
|
},
|
|
408
407
|
},
|
|
@@ -464,6 +463,14 @@ function getProperties(agentType = 'coreAgent') {
|
|
|
464
463
|
description: "Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics",
|
|
465
464
|
type: 'number',
|
|
466
465
|
},
|
|
466
|
+
{
|
|
467
|
+
displayName: 'Temperature',
|
|
468
|
+
name: 'temperature',
|
|
469
|
+
default: 1,
|
|
470
|
+
typeOptions: { maxValue: 1, minValue: 0, numberPrecision: 1 },
|
|
471
|
+
description: 'What sampling temperature to use, between 0 and 1. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. Read the <a href="https://platform.openai.com/docs/api-reference/chat/create" target="_blank">API Reference docs</a>',
|
|
472
|
+
type: 'number',
|
|
473
|
+
},
|
|
467
474
|
{
|
|
468
475
|
displayName: 'Top P',
|
|
469
476
|
name: 'top_p',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"properties.js","sourceRoot":"","sources":["../../../nodes/shared/properties.ts"],"names":[],"mappings":";;AAKA,
|
|
1
|
+
{"version":3,"file":"properties.js","sourceRoot":"","sources":["../../../nodes/shared/properties.ts"],"names":[],"mappings":";;AAKA,sCA+fC;AAlgBD,2CAAgE;AAGhE,SAAgB,aAAa,CAAC,YAAoB,WAAW;IAC3D,OAAO;QACR;YACC,WAAW,EAAE,OAAO;YACpB,IAAI,EAAE,SAAS;YACf,IAAI,EAAE,iBAAiB;YACvB,OAAO,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,cAAc,EAAE;YAChD,QAAQ,EAAE,IAAI;YACd,WAAW,EAAE,0KAA0K;YACvL,KAAK,EAAE;gBACN;oBACC,WAAW,EAAE,WAAW;oBACxB,IAAI,EAAE,MAAM;oBACZ,IAAI,EAAE,MAAM;oBACZ,WAAW,EAAE;wBACZ,gBAAgB,EAAE,aAAa;wBAC/B,UAAU,EAAE,IAAI;qBAChB;iBACD;gBACD;oBACC,WAAW,EAAE,IAAI;oBACjB,IAAI,EAAE,IAAI;oBACV,IAAI,EAAE,QAAQ;oBACd,WAAW,EAAE,mBAAmB;iBAChC;aACD;SACD;QACD;YACC,WAAW,EAAE,6DAA6D;YAC1E,IAAI,EAAE,aAAa;YACnB,IAAI,EAAE,QAAQ;YACd,OAAO,EAAE,EAAE;YACX,cAAc,EAAE;gBACf,IAAI,EAAE;oBACL,OAAO,EAAE,6CAAiC;iBAC1C;aACD;SACD;QACD;YACC,WAAW,EAAE,MAAM;YACnB,IAAI,EAAE,WAAW;YACjB,IAAI,EAAE,SAAS;YACf,WAAW,EAAE,uEAAuE;YACpF,gBAAgB,EAAE,IAAI;YACtB,OAAO,EAAE;gBACR;oBACC,IAAI,EAAE,eAAe;oBACrB,KAAK,EAAE,WAAW;oBAClB,WAAW,EAAE,4CAA4C;iBACzD;gBACD;oBACC,IAAI,EAAE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AC3C,CAAC;QAED,UAAU,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,QAAQ,CAAC;QAClC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IAC5B,CAAC;IAED,OAAO;QACL,IAAI,EAAE,QAAQ;QACd,UAAU;QACV,QAAQ;QACR,oBAAoB,EAAE,KAAK;KAC5B,CAAC;AACH,CAAC"}
|
|
@@ -20,4 +20,4 @@ function throwIfToolSchema(ctx, error) {
|
|
|
20
20
|
This is most likely because some of your tools are configured to require a specific schema. This is not supported by Conversational Agent. Remove the schema from the tool configuration or use Tools agent instead.`);
|
|
21
21
|
}
|
|
22
22
|
}
|
|
23
|
-
//# sourceMappingURL=
|
|
23
|
+
//# sourceMappingURL=schemaGenerator.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schemaGenerator.js","sourceRoot":"","sources":["../../../../nodes/shared/tool/schemaGenerator.ts"],"names":[],"mappings":";;AAWA,wCAIC;AAED,wDAEC;AAED,8CAQC;AA3BD,gEAA0D;AAG1D,+CAA6D;AAG7D,qDAA6D;AAG7D,SAAgB,cAAc,CAAC,YAAoB;IAClD,MAAM,YAAY,GAAG,IAAA,wBAAS,EAAe,YAAY,CAAC,CAAC;IAE3D,OAAO,IAAA,sBAAkB,EAAC,YAAY,CAAgB,CAAC;AACxD,CAAC;AAED,SAAgB,sBAAsB,CAAwC,MAAmB;IAChG,OAAO,IAAA,oCAAe,EAAI,MAAM,CAAC,CAAC;AACnC,CAAC;AAED,SAAgB,iBAAiB,CAAC,GAAsB,EAAE,KAAY;;IACrE,IAAI,MAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,OAAO,0CAAE,QAAQ,CAAC,0CAA0C,CAAC,EAAE,CAAC;QAC1E,MAAM,IAAI,iCAAkB,CAC3B,GAAG,CAAC,OAAO,EAAE,EACb,GAAG,KAAK,CAAC,OAAO;wNACqM,CACrN,CAAC;IACH,CAAC;AACF,CAAC"}
|
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.SubagentTool = void 0;
|
|
4
4
|
const tools_1 = require("@langchain/core/tools");
|
|
5
5
|
const n8n_workflow_1 = require("n8n-workflow");
|
|
6
|
-
const router_1 = require("
|
|
6
|
+
const router_1 = require("../actions/router");
|
|
7
7
|
class SubagentTool extends tools_1.Tool {
|
|
8
8
|
static lc_name() {
|
|
9
9
|
return "SubagentTool";
|
|
@@ -48,7 +48,8 @@ class SubagentTool extends tools_1.Tool {
|
|
|
48
48
|
}
|
|
49
49
|
}
|
|
50
50
|
catch (error) {
|
|
51
|
-
|
|
51
|
+
console.log("Error in subagentTool:", error);
|
|
52
|
+
return "Error: I couldn't generate a response.";
|
|
52
53
|
}
|
|
53
54
|
}
|
|
54
55
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"subagentTool.js","sourceRoot":"","sources":["../../../../nodes/shared/tool/subagentTool.ts"],"names":[],"mappings":";;;AAAA,iDAA6C;AAC7C,+CAAqE;AAErE,8CAA2C;AAI3C,MAAa,YAAa,SAAQ,YAAI;IACpC,MAAM,CAAC,OAAO;QACZ,OAAO,cAAc,CAAC;IACxB,CAAC;IAED,IAAI,YAAY;QACd,OAAO,CAAC,GAAG,KAAK,CAAC,YAAY,EAAE,cAAc,CAAC,CAAC;IACjD,CAAC;IAQD,YAAY,gBAAmC;QAC7C,KAAK,EAAE,CAAC;QANV,SAAI,GAAG,kBAAkB,CAAC;QAC3B,gBAAW,GAAG,yBAAyB,CAAC;QAMrC,IAAI,CAAC,gBAAgB,GAAG,gBAAgB,CAAC;IAC3C,CAAC;IAED,KAAK,CAAC,KAAK,CAAC,uBAAwC,EAAE;QAEtD,IAAI,CAAC;YAEJ,IAAI,uBAAuB,GAAW,EAAE,CAAA;YACxC,IAAI,uBAAuB,GAAW,EAAE,CAAA;YAGxC,IAAI,OAAO,oBAAoB,KAAK,QAAQ,EAAE,CAAC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EAAE,CAAC;YAClB,OAAO,CAAC,GAAG,CAAC,wBAAwB,EAAE,KAAK,CAAC,CAAC;YAC1C,OAAO,wCAAwC,CAAC;QAClD,CAAC;IACH,CAAC;CACF;AA1DD,oCA0DC"}
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.getConnectedTools = void 0;
|
|
4
4
|
const n8n_workflow_1 = require("n8n-workflow");
|
|
5
|
-
const
|
|
5
|
+
const n8nTool_1 = require("./n8nTool");
|
|
6
6
|
const getConnectedTools = async (ctx, enforceUniqueNames, convertStructuredTool = true) => {
|
|
7
|
-
const connectedTools = (await ctx.getInputConnectionData(
|
|
7
|
+
const connectedTools = (await ctx.getInputConnectionData(n8n_workflow_1.NodeConnectionTypes.AiTool, 0)) || [];
|
|
8
8
|
if (!enforceUniqueNames)
|
|
9
9
|
return connectedTools;
|
|
10
10
|
const seenNames = new Set();
|
|
@@ -15,7 +15,7 @@ const getConnectedTools = async (ctx, enforceUniqueNames, convertStructuredTool
|
|
|
15
15
|
throw new n8n_workflow_1.NodeOperationError(ctx.getNode(), `You have multiple tools with the same name: '${name}', please rename them to avoid conflicts`);
|
|
16
16
|
}
|
|
17
17
|
seenNames.add(name);
|
|
18
|
-
if (convertStructuredTool && tool instanceof
|
|
18
|
+
if (convertStructuredTool && tool instanceof n8nTool_1.N8nTool) {
|
|
19
19
|
finalTools.push(tool.asDynamicTool());
|
|
20
20
|
}
|
|
21
21
|
else {
|
|
@@ -25,4 +25,4 @@ const getConnectedTools = async (ctx, enforceUniqueNames, convertStructuredTool
|
|
|
25
25
|
return finalTools;
|
|
26
26
|
};
|
|
27
27
|
exports.getConnectedTools = getConnectedTools;
|
|
28
|
-
//# sourceMappingURL=
|
|
28
|
+
//# sourceMappingURL=getConnectedTools.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getConnectedTools.js","sourceRoot":"","sources":["../../../../nodes/shared/toolManager/getConnectedTools.ts"],"names":[],"mappings":";;;AAEA,+CAA+F;AAG/F,uCAAoC;AAE7B,MAAM,iBAAiB,GAAG,KAAK,EACrC,GAAsB,EACtB,kBAA2B,EAC3B,wBAAiC,IAAI,EACpC,EAAE;IACH,MAAM,cAAc,GAClB,CAAC,MAAM,GAAG,CAAC,sBAAsB,CAAC,kCAAmB,CAAC,MAAM,EAAE,CAAC,CAAC,CAAY,IAAI,EAAE,CAAC;IAErF,IAAI,CAAC,kBAAkB;QAAE,OAAO,cAAc,CAAC;IAE/C,MAAM,SAAS,GAAG,IAAI,GAAG,EAAU,CAAC;IAEpC,MAAM,UAAU,GAAG,EAAE,CAAC;IAEtB,KAAK,MAAM,IAAI,IAAI,cAAc,EAAE,CAAC;QACnC,MAAM,EAAE,IAAI,EAAE,GAAG,IAAI,CAAC;QACtB,IAAI,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC;YACzB,MAAM,IAAI,iCAAkB,CAC3B,GAAG,CAAC,OAAO,EAAE,EACb,gDAAgD,IAAI,0CAA0C,CAC9F,CAAC;QACH,CAAC;QACD,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;QAEpB,IAAI,qBAAqB,IAAI,IAAI,YAAY,iBAAO,EAAE,CAAC;YACtD,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE,CAAC,CAAC;QACvC,CAAC;aAAM,CAAC;YACP,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QACvB,CAAC;IACF,CAAC;IAED,OAAO,UAAU,CAAC;AACnB,CAAC,CAAC;AAhCW,QAAA,iBAAiB,qBAgC5B"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { type
|
|
1
|
+
import { type ISupplyDataFunctions } from 'n8n-workflow';
|
|
2
2
|
import { DynamicTool, DynamicStructuredTool, DynamicStructuredToolInput } from '@langchain/core/tools';
|
|
3
3
|
import { ZodObject } from 'zod';
|
|
4
4
|
export declare const prepareFallbackToolDescription: (toolDescription: string, schema: ZodObject<any>) => string;
|
|
5
5
|
export declare class N8nTool extends DynamicStructuredTool {
|
|
6
6
|
private context;
|
|
7
|
-
constructor(context:
|
|
7
|
+
constructor(context: ISupplyDataFunctions, fields: DynamicStructuredToolInput);
|
|
8
8
|
asDynamicTool(): DynamicTool;
|
|
9
9
|
}
|
|
@@ -75,8 +75,8 @@ class N8nTool extends tools_1.DynamicStructuredTool {
|
|
|
75
75
|
return result;
|
|
76
76
|
}
|
|
77
77
|
catch (e) {
|
|
78
|
-
const { index } = context.addInputData(
|
|
79
|
-
void context.addOutputData(
|
|
78
|
+
const { index } = context.addInputData(n8n_workflow_1.NodeConnectionTypes.AiTool, [[{ json: { query } }]]);
|
|
79
|
+
void context.addOutputData(n8n_workflow_1.NodeConnectionTypes.AiTool, index, e);
|
|
80
80
|
return e.toString();
|
|
81
81
|
}
|
|
82
82
|
};
|
|
@@ -88,4 +88,4 @@ class N8nTool extends tools_1.DynamicStructuredTool {
|
|
|
88
88
|
}
|
|
89
89
|
}
|
|
90
90
|
exports.N8nTool = N8nTool;
|
|
91
|
-
//# sourceMappingURL=
|
|
91
|
+
//# sourceMappingURL=n8nTool.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"n8nTool.js","sourceRoot":"","sources":["../../../../nodes/shared/toolManager/n8nTool.ts"],"names":[],"mappings":";;;AAEA,+CAMsB;AACtB,iDAAuG;AACvG,mEAAwE;AACxE,6BAAkG;AAElG,MAAM,iBAAiB,GAAG,CAAC,MAAkB,EAAE,EAAE;IAChD,IAAI,MAAM,YAAY,eAAS,EAAE,CAAC;QACjC,OAAO,QAAQ,CAAC;IACjB,CAAC;SAAM,IAAI,MAAM,YAAY,eAAS,EAAE,CAAC;QACxC,OAAO,QAAQ,CAAC;IACjB,CAAC;SAAM,IAAI,MAAM,YAAY,gBAAU,EAAE,CAAC;QACzC,OAAO,SAAS,CAAC;IAClB,CAAC;SAAM,IAAI,MAAM,Y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,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC;gBAC5F,KAAK,OAAO,CAAC,aAAa,CAAC,kCAAmB,CAAC,MAAM,EAAE,KAAK,EAAE,CAAC,CAAC,CAAC;gBAEjE,OAAO,CAAC,CAAC,QAAQ,EAAE,CAAC;YACrB,CAAC;QACF,CAAC,CAAC;QAEF,OAAO,IAAI,mBAAW,CAAC;YACtB,IAAI;YACJ,WAAW,EAAE,IAAA,sCAA8B,EAAC,WAAW,EAAE,MAAM,CAAC;YAChE,IAAI,EAAE,WAAW;SACjB,CAAC,CAAC;IACJ,CAAC;CACD;AAtED,0BAsEC"}
|
package/dist/package.json
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "n8n-nodes-simple",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.1",
|
|
4
4
|
"description": "Simple",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"n8n-community-node-package"
|
|
7
7
|
],
|
|
8
8
|
"license": "MIT",
|
|
9
9
|
"homepage": "https://github.com/igor2c/n8n-custom-openai-node#readme",
|
|
10
|
-
"author": { "name": "Igor
|
|
10
|
+
"author": { "name": "Igor C" },
|
|
11
11
|
"repository": {
|
|
12
12
|
"type": "git",
|
|
13
13
|
"url": "git+https://github.com/igor2c/n8n-custom-openai-node.git"
|
|
@@ -50,15 +50,15 @@
|
|
|
50
50
|
"typescript": "^5.5.3"
|
|
51
51
|
},
|
|
52
52
|
"dependencies": {
|
|
53
|
-
"@langchain/core": "0.3.
|
|
54
|
-
"@langchain/openai": "0.3.
|
|
53
|
+
"@langchain/core": "0.3.30",
|
|
54
|
+
"@langchain/openai": "0.3.17",
|
|
55
55
|
"langchain": "0.3.15",
|
|
56
56
|
"@n8n/json-schema-to-zod": "1.1.0",
|
|
57
57
|
"@types/json-schema": "^7.0.15",
|
|
58
58
|
"braces": ">=3.0.3",
|
|
59
59
|
"micromatch": ">=4.0.8",
|
|
60
|
-
"n8n-core": "1.
|
|
61
|
-
"n8n-workflow": "1.
|
|
60
|
+
"n8n-core": "1.88.0",
|
|
61
|
+
"n8n-workflow": "1.87.0",
|
|
62
62
|
"handlebars": "^4.7.8"
|
|
63
63
|
},
|
|
64
64
|
"peerDependencies": {
|