feat(editor): Align DynamicStructuredTool and DynamicTool name fields (#14604)

feat(Code Tool Node): Use node's name instead of separate name field as tool name

feat(Vector Store Tool Node): Use node's name instead of separate name field as tool name

feat(Custom n8n Workflow Tool Node): Use node's name instead of separate name field as tool name
This commit is contained in:
Jaakko Husso
2025-04-16 09:53:53 +03:00
committed by GitHub
parent d42e61bc35
commit 302258dda2
11 changed files with 298 additions and 13 deletions

View File

@@ -8,6 +8,7 @@ import type { BaseChatMemory } from 'langchain/memory';
import { NodeConnectionTypes, NodeOperationError, jsonStringify } from 'n8n-workflow';
import type {
AiEvent,
INode,
IDataObject,
IExecuteFunctions,
ISupplyDataFunctions,
@@ -249,3 +250,7 @@ export function unwrapNestedOutput(output: Record<string, unknown>): Record<stri
return output;
}
export function nodeNameToToolName(node: INode): string {
return node.name.replace(/ /g, '_');
}