import type { FeedBlock } from "./feed-blocks.js"; export interface CommitDecision { /** Append-only, in order. `` cannot take content back. */ readonly committed: readonly FeedBlock[]; readonly live: readonly FeedBlock[]; readonly committedCount: number; } export interface CommitInput { readonly blocks: readonly FeedBlock[]; readonly liveBudgetRows: number; readonly committedCount: number; /** True on `turn-start`: everything from an earlier turn commits. */ readonly turnBoundary: boolean; /** Turn the incoming prompt belongs to; blocks older than it commit. */ readonly currentTurnId?: string | undefined; } /** * Split blocks into the append-only committed prefix and the re-renderable * live suffix. * * Rule 1 — monotonic: `committedCount` never decreases. * Rule 2 — whole blocks only: a block is never split. * Rule 3 — commit on budget overflow, turn boundary, or own height. * Rule 4 — an open block is never committed while it is open. */ export declare function decideCommit(input: CommitInput): CommitDecision;