UNPKG

@sema-agent/core

Version:

Stateless, task-oriented AI agent core

19 lines (18 loc) • 1.55 kB
/** * The checkpoint SEAT a run hands its children — the projection of `resolveCheckpointStore(spec, deps)` (the store the * run parks in) plus the caller's own off switch onto the one value both delegation lanes copy verbatim onto a child * spec (`ToolExecuteContext.checkpointStoreForChildren` on the Task lane, `RunWorkflowToolDeps.parentCheckpointStore` * on the workflow lane). Minted once per prepare by the driver; read by the lanes and by the plan-pair face. */ import type { CheckpointStore } from "./checkpoint-store.js"; /** The seat a run hands its children: the store it resolved, or the word `"disabled"` when the caller disarmed the run. */ export type CheckpointSeat = CheckpointStore | "disabled"; /** Project a run's spec + resolved store onto the seat its children inherit: `"disabled"` when the caller disarmed the * run (a removal that presses on the whole subtree), else the resolved store, else NOTHING — an unset spec on a * deployment without a store hands down no seat, and the child's own door resolves its runner's deployment (a split * child-execution runner may carry a store the host has none of; that topology is the deployment's own author). */ export declare function checkpointSeatOf(spec: { checkpointStore?: CheckpointStore | "disabled"; }, resolved: CheckpointStore | undefined): CheckpointSeat | undefined; /** The store a seat names — none for `"disabled"` and for no seat. */ export declare function checkpointStoreOfSeat(seat: CheckpointSeat | undefined): CheckpointStore | undefined;