UNPKG

@code-yeongyu/senpi

Version:

Coding agent CLI with read, bash, edit, write tools and session management

30 lines • 1.57 kB
import type { CustomMessage } from "./messages.ts"; import { type WaitSourceItems } from "./lifecycle-wait-items.ts"; import type { ObligationKind } from "./session-lifecycle-types.ts"; export interface CustodyPayload { readonly message: Pick<CustomMessage, "customType" | "content" | "display" | "details">; readonly deliverAs?: "steer" | "followUp" | "nextTurn"; /** The item ids of the itemized batch this payload carries, so a restored carrier still knows them (senpi#4106). */ readonly itemIds?: readonly string[]; } /** Mutable only by the registry; every replacement is appended before installation. */ export interface WorkCustodyRecord extends WaitSourceItems { readonly id: string; readonly key: string; readonly kind: ObligationKind; readonly state: "open" | "queued" | "consumed" | "settled" | "held" | "cancelled" | "passive"; readonly source?: string; readonly activeCount?: number; readonly detail?: string; readonly ticketId?: string; readonly payload?: CustodyPayload; readonly runId?: string; readonly transcriptEntryId?: string; readonly noticeId?: string; readonly delivery?: "failed" | "retired"; } export declare function isRecord(value: unknown): value is Record<string, unknown>; /** Parse owned JSONL data once, at restoration; unknown future records fail closed. */ export declare function readWorkCustody(value: unknown): WorkCustodyRecord | undefined; export declare function custodyIsOpen(record: WorkCustodyRecord): boolean; //# sourceMappingURL=work-custody-record.d.ts.map