import type { Board } from "./model.js"; /** * How much of what the interview needs it actually has. * * This is deliberately NOT a measure of how well the workflow is understood. Nobody can know the * size of that denominator, and the craft forbids claiming it: "never a job count, turn count or * completeness percentage". What is countable is the interview's own question list — the answers * staves needs before a description can be acted on without coming back to the person. That * denominator is finite, defined here, and checkable by the person reading it. * * So the number is a statement about staves, not a grade on their work. It belongs in the * interface, where the person can open it and see every answer it is counting. It is deliberately * not given to the model: a number on screen is a fact they can check, a number in a sentence is * a claim the model will eventually get wrong. There is no readinessLine() here, and that is the point. * * The four fields a job needs are not invented: they are the fields ops.ts already requires before * a job stops being a draft. This counts the same things the rest of the system counts. */ /** Whether answering would change what anyone builds, or is only interesting. The difference is * what earns staves the right to say "you can stop here" instead of nagging to 100%. */ export type Weight = "changes" | "curious"; /** * How much is being asked for. The denominator has to be a choice rather than a consequence of how big * the board got: the same four fields per job is 16 answers across three jobs and 104 across * twenty-five, and nobody answers a hundred questions. Naming the ask is what keeps the number honest * as a board grows, and what lets someone say "an outline is all I want" and be believed. */ export type Ask = "outline" | "working" | "build"; export declare const ASKS: Ask[]; /** What each ask is for, in the fewest words that are still true. */ export declare const ASK_MEANS: Record; export interface Answer { /** stable across turns, so the interface can keep a row in place while the board moves */ id: string; /** what it is about, in the person's own words */ about: string; /** what staves would ask to get it */ question: string; got: boolean; /** how it was got: read from code, said in the conversation, or agreed by the person */ by?: "derived" | "said" | "confirmed"; weight: Weight; /** which asks want this answer at all; an outline does not care when a job is done */ asks: Ask[]; } export interface Readiness { /** the ask these top-level figures describe */ ask: Ask; have: number; need: number; /** 0–100, rounded. have/need, nothing cleverer. */ percent: number; /** the same sum for every ask, so switching one does not need another round trip */ counts: Record; answers: Answer[]; /** missing, and answering would change what someone builds */ wanted: Answer[]; /** missing, but nothing downstream turns on it — curiosity without a use */ idle: Answer[]; } /** Every answer the interview needs, and which of them it has. Derived from the board, never stored. */ export declare function readiness(b: Board, ask?: Ask): Readiness;