Decouple http node from workflows (#13272)
- Added a generic HTTP request tool, allowing agents and workflows to make HTTP requests to external APIs with configurable method, headers, and body. - Decoupled HTTP request workflow nodes from workflow-specific types and factories, introducing a generic tool interface. - Updated agent system prompts to include explicit guidance for the HTTP request tool, including when and how to use it, and how to communicate limitations. ### Demo https://github.com/user-attachments/assets/129bc445-a277-4a19-95ab-09f890f8f051
This commit is contained in:
@ -3,6 +3,7 @@ import { getRepositoryToken } from '@nestjs/typeorm';
|
||||
|
||||
import { Repository } from 'typeorm';
|
||||
|
||||
import { ToolAdapterService } from 'src/engine/core-modules/ai/services/tool-adapter.service';
|
||||
import { ToolService } from 'src/engine/core-modules/ai/services/tool.service';
|
||||
import { AgentToolService } from 'src/engine/metadata-modules/agent/agent-tool.service';
|
||||
import { AgentEntity } from 'src/engine/metadata-modules/agent/agent.entity';
|
||||
@ -73,6 +74,10 @@ export const createAgentToolTestModule =
|
||||
provide: ToolService,
|
||||
useClass: ToolService,
|
||||
},
|
||||
{
|
||||
provide: ToolAdapterService,
|
||||
useClass: ToolAdapterService,
|
||||
},
|
||||
],
|
||||
}).compile();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user