import type { ExportParam } from "../agency.js"; import type { Signature, ToolRef } from "./types.js"; /** One parameter a workflow step can pass to a tool. */ export type CatalogParam = ExportParam & { schema: unknown; }; /** One tool a workflow may call. `module` is what a step's `module` field * says. `returns` is null when the tool declares no return type. */ export type CatalogEntry = { module: string; name: string; description: string; params: CatalogParam[]; returns: string | null; /** The JSON Schema of the value a reference into this tool's step reads: * the declared return type, or the success type inside a `Result`. Null * when the tool declares no return type, or its return type holds a * function or a `regex` (which JSON Schema cannot express), or names a * type its module cannot reach at run time (#1371). */ returnSchema: unknown | null; /** What the tool can raise, as `describe` reports it. A tool that uses * `guard` lists `std::guard`. `stepEffects` leaves it out, since a guard * trip is a question about budget, not a permission. */ effects: string[]; /** True for a `handoff def`, so a picker can tell an agent from a function. */ handoff: boolean; }; /** One entry per ref. `toolRefs` returns one ref per tool, in the tool * list's order, so `refs[i]` and `tools[i]` describe the same tool. */ export declare function catalogEntries(tools: unknown[], refs: ToolRef[], signatures: Record): CatalogEntry[];