export type ProposalDecision = "accept" | "reject" | "cancel"; export interface ProposalResolution { decision: ProposalDecision; body?: string; outcome?: string; } export type { ProposalProjection as PendingProposal } from "@plurnk/plurnk-contracts"; export type { ClientInteractionProjection as PendingClientInteraction } from "@plurnk/plurnk-contracts"; import type { ClientDisplayCapabilities, ClientInteractionProjection, ClientInteractionResolution, EntryReadResult, ModelCatalogPage, ModelCatalogQuery, ModelRoute, ProposalProjection } from "@plurnk/plurnk-contracts"; import type { OperationResult } from "@plurnk/plurnk-contracts"; import type { PlurnkStatement } from "@plurnk/plurnk-contracts"; import type { ReasoningPolicy } from "@plurnk/plurnk-contracts"; export type { PlurnkStatement }; export type ModuleActionContext = { readonly scope: "worldless"; } | { readonly scope: "workspace"; readonly workspaceId: number; }; export interface ModuleActionDescriptor { readonly name: string; readonly scope: ModuleActionContext["scope"]; } export type LogEntryWire = Record; export interface DaemonSeam { listClientDisplayCapabilities(): Promise; listModuleActions(): ModuleActionDescriptor[]; invokeModuleAction(name: string, params: Readonly>, context: ModuleActionContext): Promise; subscribeToEvents(handler: (workspaceId: number | null, method: string, params: unknown) => void): () => void; pendingProposals(workspaceId: number): Promise; resolveProposal(logEntryId: number, resolution: ProposalResolution): void; pendingClientInteractions(workspaceId: number): Promise; resolveClientInteraction(interactionId: number, resolution: ClientInteractionResolution): Promise; ensureModelWorker(workspaceId: number, settings?: { requestUserInput?: boolean; }): Promise; runLoop(args: { workspaceId: number; workerId: number; prompt: string; maxTurns?: number; flags?: { auto?: boolean; }; openPaths?: string[]; selector?: string; childSelector?: string | null; }): Promise; cancelDrain(workerId: number, reason?: string): boolean; dispatchClientAction(args: { workspaceId: number; workerId: number; statements: PlurnkStatement[]; }): Promise; readLog(args: { workspaceId: number; workerId: number; loopId?: number; turnId?: number; sinceId?: number; limit?: number; loopSeq?: number; turnSeq?: number; sequence?: number; }): Promise; listProviders(): { aliases: Array<{ alias: string; provider: string; model: string; active: boolean; inputCapacity: number | null; }>; }; listModels(query: ModelCatalogQuery): ModelCatalogPage; createWorkspace(args: { name?: string; projectRoot?: string | null; settings?: string | object; constraints?: Array<{ effect: string; glob: string; }>; }): Promise; attachWorkspace(args: { workspaceId: number; workerId?: number; workerName?: string; }): Promise; listWorkspaces(): Promise>; listWorkers(workspaceId: number): Promise>; listPrompts(workspaceId: number, limit?: number): Promise; renameWorkspace(workspaceId: number, name: string): Promise<{ id: number; name: string; }>; constrain(workspaceId: number, effect: string, glob: string): Promise<{ effect: string; glob: string; }>; unconstrain(workspaceId: number, effect: string, glob: string): Promise<{ effect: string; glob: string; }>; listConstraints(workspaceId: number): Promise> | Array<{ effect: string; glob: string; }>; workspaceDerivationStatus(workspaceId: number): { phase: "preparing" | "indexing" | "complete" | "failed"; completed: number; total: number; percent: number; message: string; level: "info" | "error"; } | null; listMembers(workspaceId: number): Promise<{ members: Array<{ path: string; effect: string; }>; hidden: string[]; }>; look(args: { workspaceId: number; workerId: number; statement: PlurnkStatement; }): Promise<{ status: number; [key: string]: unknown; }>; readEntry(args: { workspaceId: number; workerId: number; target: string; channel?: string; offset?: number; }): Promise; forkWorker(args: { workspaceId: number; workerId: number; name?: string; }): Promise<{ workerId: number; workerName: string | null; parentWorkerId: number; }>; createConversationWorker(args: { workspaceId: number; name?: string; settings?: { requestUserInput?: boolean; }; }): Promise<{ workerId: number; workerName: string; }>; readWorkerModel(args: { workspaceId: number; workerId: number; }): Promise<{ model: ModelRoute | null; spawnModel: ModelRoute | null; }>; setWorkerModel(args: { workspaceId: number; workerId: number; selector: string; }): Promise; setWorkerSpawnModel(args: { workspaceId: number; workerId: number; selector: string | null; }): Promise; readWorkerReasoning(args: { workspaceId: number; workerId: number; }): Promise<{ policy: ReasoningPolicy | null; supportedPolicies: readonly ReasoningPolicy[]; }>; setWorkerReasoning(args: { workspaceId: number; workerId: number; policy: unknown; }): Promise<{ policy: ReasoningPolicy; supportedPolicies: readonly ReasoningPolicy[]; }>; readWorkerSettings(args: { workspaceId: number; workerId: number; }): Promise<{ requestUserInput: boolean; }>; setWorkerSettings(args: { workspaceId: number; workerId: number; settings: { requestUserInput?: boolean; }; }): Promise<{ requestUserInput: boolean; }>; } export interface ClientEnvelope { workspaceId: number; workspaceName: string; projectRoot: string | null; workerId: number; workerName: string; } //# sourceMappingURL=DaemonSeam.d.ts.map