/** * turn-options: rendering and validation of per-call turn options into argv. * * This lives separately from argv.ts because argv.ts owns argv *assembly and * ordering* (where the prompt goes, that tools is last, that resume never * inherits launch flags). Turn-option *rendering and validation* - which * flag spells a dimension, how its value is validated and quoted, and when * it must refuse - is a distinct responsibility with its own vocabulary. * Folding it into argv.ts would make the largest interpretation file the * place two unrelated questions are answered. * * The render-to-tokens rule itself has one owner, `tokensFor` in the * knowledge layer (RFC-02 change 1): every arm here validates its value, * resolves the render for the phase, and calls it. */ import type { HarnessDescriptor } from "../knowledge/descriptor.js"; import type { TurnOptions } from "./argv.js"; import { type ArgvParts } from "./inline-settings.js"; /** Render turn options for a given phase, in TURN_OPTION_KEYS order and with * discovery facets in DISCOVERY_FACETS order, de-duplicating by exact token * sequence (first wins) so claude's two facets sharing one flag emit once. * Returns tokens, composable inline JSON settings and spawn-env assignments. * The `env` render kind contributes no tokens - the execution layer merges * `env` over the caller's env at spawn, so a descriptor-derived disable * wins over a contradicting caller-set variable. */ export interface RenderedTurnOptions extends ArgvParts { readonly env: Record; } export declare const renderTurnOptions: (h: HarnessDescriptor, opts: TurnOptions, phase: "launch" | "resume", placement?: "all" | "before-prompt" | "after-prompt") => RenderedTurnOptions; //# sourceMappingURL=turn-options.d.ts.map