/** Resolves umbrella-action arguments from complete planner parameters or one validated model extraction with one repair attempt. */ import type { HandlerOptions } from "../types/components.js"; import type { Memory } from "../types/memory.js"; import type { IAgentRuntime } from "../types/runtime.js"; import type { State } from "../types/state.js"; export interface SubactionSpec> { /** Full description (per-subaction; surfaced into LLM prompt). */ description: string; /** Short description metadata; model prompts use `description`. */ descriptionCompressed: string; /** Required parameter keys; missing any -> triggers extraction. */ required: ReadonlyArray; /** Required array keys whose explicit empty value is valid; omission is still missing. */ allowEmptyArrays?: ReadonlyArray; /** Optional keys; surfaced to extractor as "may extract if obvious". */ optional?: ReadonlyArray; } export type SubactionsMap = { readonly [K in TSubaction]: SubactionSpec; }; export interface ResolveActionArgsInput { runtime: IAgentRuntime; message: Memory; state?: State; options?: HandlerOptions; actionName: string; subactions: SubactionsMap; defaultSubaction?: TSubaction; intentHint?: string; } export type ResolveActionArgsResult = { ok: true; subaction: TSubaction; params: TParams; missing?: never; clarification?: never; } | { ok: false; missing: string[]; clarification: string; partial?: Partial; }; /** * Resolve the (subaction, params) pair for an umbrella action. * * Trusts complete planner-supplied parameters when present; otherwise runs * a single LLM extraction pass (with one repair retry) over the registered * subactions and returns either a fully resolved result or a structured * "missing fields + clarification" failure. */ export declare function resolveActionArgs>(input: ResolveActionArgsInput): Promise>;