aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/chatbot/tools/NoTool.ts
blob: edd3160ec96b5021e13a5df8e135aadaadd0c9c9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// tools/NoTool.ts
import { BaseTool } from './BaseTool';

export class NoTool extends BaseTool<Record<string, unknown>> {
    constructor() {
        super(
            'no_tool',
            'Use this when no external tool or action is required to answer the question.',
            {},
            'When using the "no_tool" action, simply provide an empty <action_input> element. The observation will always be "No tool used. Proceed with answering the question."',
            'Use when no external tool or action is required to answer the question.'
        );
    }

    // eslint-disable-next-line @typescript-eslint/no-unused-vars
    async execute(args: object): Promise<unknown> {
        return [{ type: 'text', text: 'No tool used. Proceed with answering the question.' }];
    }
}