import { type CatalogueCondition, type InterrogationReport } from '../interrogate-command.js'; import { type ToolResult, type ToolWorkspace } from './workspace.js'; /** * One step of the design interview (ADR 0156): what `yarramate design * --json` prints, over a store. The CLI renders the human form * from the same core (`designStepDetailed`), so the two cannot drift. */ export interface DesignStep { readonly questionId: string; readonly wave: string; readonly scope: 'workspace' | 'subject'; readonly authority: 'human' | 'agent' | 'either'; readonly question: string; readonly askPlain?: string; readonly materiality: string; readonly resolution: string; /** The catalogue trigger, verbatim: the question's answer shape (#289). */ readonly trigger: readonly CatalogueCondition[]; readonly subject?: { readonly id: string; readonly name?: string; }; readonly remainingSubjects?: number; readonly openSubjects?: readonly string[]; readonly since?: string; } /** The published `yarramate/design-step/v1` document. */ export interface DesignStepResult { readonly format: 'yarramate/design-step/v1'; readonly workspace: string; readonly catalogue: string; readonly progress: { readonly questions: number; readonly openQuestions: number; readonly open: number; readonly waves: readonly { readonly id: string; readonly open: number; }[]; }; readonly step: DesignStep | null; /** The subject's neighbourhood as a brief, when the step has a subject. */ readonly slice?: string; } export interface DesignStepOptions { /** A globally qualified subject id; narrows the interview to it. `refused` if unknown. */ readonly subject?: string; } /** The result plus the report it was cut from, for a renderer that needs wave state. */ export interface DesignStepDetailed { readonly result: DesignStepResult; readonly report: Omit; } export declare const selectStep: (report: Omit, subjectFilter: string | undefined, askPlainById: ReadonlyMap) => DesignStep | null; export declare const designStepDetailed: (workspace: ToolWorkspace, options?: DesignStepOptions) => ToolResult; /** `yarramate design [--subject] --json`, path-free. */ export declare const designStep: (workspace: ToolWorkspace, options?: DesignStepOptions) => ToolResult;