mirror of
https://github.com/Kilo-Org/kilocode.git
synced 2026-09-21 05:52:35 +08:00
24 lines
632 B
TypeScript
24 lines
632 B
TypeScript
import type { StandardSchemaV1 } from "@standard-schema/spec"
|
|
|
|
export namespace Tool {
|
|
export interface Info<
|
|
Parameters extends StandardSchemaV1 = StandardSchemaV1,
|
|
Metadata extends Record<string, any> = Record<string, any>,
|
|
> {
|
|
id: string
|
|
description: string
|
|
parameters: Parameters
|
|
execute(args: StandardSchemaV1.InferOutput<Parameters>): Promise<{
|
|
metadata: Metadata
|
|
output: string
|
|
}>
|
|
}
|
|
|
|
export function define<
|
|
Parameters extends StandardSchemaV1,
|
|
Result extends Record<string, any>,
|
|
>(input: Info<Parameters, Result>): Info<Parameters, Result> {
|
|
return input
|
|
}
|
|
}
|