import { t } from "structural"; import { ToolResult } from "./common.ts"; import { SequenceIdTagged } from "../history.ts"; import { Config } from "../config.ts"; import { Transport } from "../transports/transport-common.ts"; export { ToolError } from "./common.ts"; export * from "./tool-defs/index.ts"; export declare const ALL_TOOLS: (t.Type; arguments: t.Struct<{ filePath: t.Type; }>; }>> | t.Type; arguments: t.OptionalKey>; }>>; }>> | t.Type; arguments: t.Struct<{ cmd: t.Type; timeout: t.Type; }>; }>> | t.Struct<{ name: t.Value<"edit">; arguments: t.Type; replace: t.Type; filePath: t.Type; }>>; }> | t.Type; arguments: t.Struct<{ filePath: t.Type; content: t.Type; }>; }>> | t.Type; arguments: t.Struct<{ server: t.Type; tool: t.Type; arguments: t.OptionalKey>; }>; }>> | t.Type; arguments: t.Struct<{ url: t.Type; includeMarkup: t.OptionalKey>; }>; }>> | t.Struct<{ name: t.Value<"append">; arguments: t.Type; text: t.Type; }>>; }> | t.Struct<{ name: t.Value<"prepend">; arguments: t.Type; text: t.Type; }>>; }> | t.Struct<{ name: t.Value<"rewrite">; arguments: t.Type; text: t.Type; }>>; }>)[]; export declare const ToolCallSchema: t.Type; arguments: t.Struct<{ filePath: t.Type; }>; }> | t.UnwrappedTypeStruct<{ name: t.Value<"list">; arguments: t.OptionalKey>; }>>; }> | t.UnwrappedTypeStruct<{ name: t.Value<"shell">; arguments: t.Struct<{ cmd: t.Type; timeout: t.Type; }>; }> | t.UnwrappedTypeStruct<{ name: t.Value<"edit">; arguments: t.Type; replace: t.Type; filePath: t.Type; }>>; }> | t.UnwrappedTypeStruct<{ name: t.Value<"create">; arguments: t.Struct<{ filePath: t.Type; content: t.Type; }>; }> | t.UnwrappedTypeStruct<{ name: t.Value<"mcp">; arguments: t.Struct<{ server: t.Type; tool: t.Type; arguments: t.OptionalKey>; }>; }> | t.UnwrappedTypeStruct<{ name: t.Value<"fetch">; arguments: t.Struct<{ url: t.Type; includeMarkup: t.OptionalKey>; }>; }> | t.UnwrappedTypeStruct<{ name: t.Value<"append">; arguments: t.Type; text: t.Type; }>>; }> | t.UnwrappedTypeStruct<{ name: t.Value<"prepend">; arguments: t.Type; text: t.Type; }>>; }> | t.UnwrappedTypeStruct<{ name: t.Value<"rewrite">; arguments: t.Type; text: t.Type; }>>; }>>; export declare const SKIP_CONFIRMATION: Array["name"]>; export declare function runTool(abortSignal: AbortSignal, transport: Transport, call: SequenceIdTagged<{ tool: t.GetType; }>, config: Config, modelOverride: string | null): Promise; export declare function validateTool(abortSignal: AbortSignal, transport: Transport, tool: t.GetType, config: Config): Promise;