Feat: Save the agent tool data to the node #3221 (#8364)

### What problem does this PR solve?

Feat: Save the agent tool data to the node #3221

### Type of change


- [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
balibabu
2025-06-19 16:38:59 +08:00
committed by GitHub
parent 7e87eb2e23
commit 403efe81a1
6 changed files with 91 additions and 12 deletions

View File

@ -139,6 +139,29 @@ export interface ICodeForm {
script?: string;
}
export interface IAgentForm {
sys_prompt: string;
prompts: Array<{
role: string;
content: string;
}>;
max_retries: number;
delay_after_error: number;
visual_files_var: string;
max_rounds: number;
exception_method: Nullable<'comment' | 'go'>;
exception_comment: any;
exception_goto: any;
tools: Array<{
component_name: string;
params: Record<string, any>;
}>;
outputs: {
structured_output: Record<string, Record<string, any>>;
content: Record<string, any>;
};
}
export type BaseNodeData<TForm extends any> = {
label: string; // operator type
name: string; // operator name
@ -167,7 +190,7 @@ export type IIterationStartNode = BaseNode;
export type IKeywordNode = BaseNode;
export type ICodeNode = BaseNode<ICodeForm>;
export type IAgentNode = BaseNode;
export type IToolNode = BaseNode;
export type IToolNode = BaseNode<IAgentForm>;
export type RAGFlowNodeType =
| IBeginNode