/** * The step's catalog: one table of every entry a model step can reach. Direct * entries go into the model's tool list next to the catalog tools the agent * has: `eve__search` finds entries, `eve__tool` calls deferred entries and * connection tools, and `eve__skill` loads skills. A call resolves to its entry * here and then runs exactly as a direct call would, so only model history * ever names a catalog tool. */ import type { ContextReader } from "#context/key.js"; import type { HarnessToolDefinition } from "#harness/execute-tool.js"; import type { CallResolver, HarnessSession, HarnessToolLookup, HarnessToolMap } from "#harness/types.js"; import type { ResolvedConnectionDefinition } from "#runtime/types.js"; import { type CatalogSkill } from "./skills.js"; export interface StepCatalog extends HarnessToolLookup { /** The model's tool list: direct entries, then the catalog tools the agent has. */ readonly advertised: HarnessToolMap; readonly connections: readonly ResolvedConnectionDefinition[]; /** Entries reached only through `eve__tool`, connection tools aside. */ readonly deferred: HarnessToolMap; /** Every direct and deferred entry the session sees, connection tools aside. */ readonly entries: HarnessToolMap; /** Every skill the session can load, deferred or not. */ readonly skills: ReadonlyMap; /** * Whether the session offers tasks: one of the agent's own tools it sees * starts them, or the agent resolves subagents at runtime. Both are fixed by * the deployment, so the task tools and system block change only on upgrade. */ readonly offersTasks: boolean; /** An entry's description as the model reads it, with the notes eve appends. */ describe(definition: HarnessToolDefinition): string; /** * Resolves a model tool call to the entry it runs. An `eve__tool` call that * names an entry `callableByName` accepts becomes the call to that entry, and * an `eve__skill` call becomes the call to load its skill; any other call runs * the listed tool it names. A call that reaches none of these resolves to * nothing. */ readonly resolve: CallResolver; } /** * Builds the catalog for one step from the agent's tools, the dynamic tools and * subagents resolved for it, and its skills, keeping only what the session sees. */ export declare function buildStepCatalog(input: { readonly agentTools: HarnessToolMap; readonly ctx: ContextReader | undefined; /** Whether `endsTurn` applies: a root turn without an output schema. */ readonly endsTurn: boolean; readonly session: Pick; }): StepCatalog;