import { type Edit } from "./apply-edits.js"; import { type FenceParseError } from "./fence-body-parser.js"; import { type BlockStreamMsg } from "./block-stream.js"; export declare const FsApplyFailure: import("arktype/internal/variants/object.ts").ObjectType<{ sectionIndex: number; reason: "multiple-match" | "no-match" | "parse-error"; parseErrorKind?: string | undefined; matchCount?: number | undefined; search?: string | undefined; }, {}>; export type FsApplyFailure = typeof FsApplyFailure.infer; export declare const FsFileSnapshotMsg: import("arktype/internal/variants/object.ts").ObjectType<{ blockId: string; streamId: string; seq: number; timestamp: Date | ((In: string) => import("arktype/internal/attributes.ts").To); type: "fs.file.snapshot"; path: string; content: string; sectionId: string; source: "create" | "replace"; appliedSections: number; }, {}>; export type FsFileSnapshotMsg = typeof FsFileSnapshotMsg.infer; export declare const FsApplyErrorMsg: import("arktype/internal/variants/object.ts").ObjectType<{ blockId: string; streamId: string; seq: number; timestamp: Date | ((In: string) => import("arktype/internal/attributes.ts").To); type: "fs.apply.error"; path: string; sectionId: string; failures: { sectionIndex: number; reason: "multiple-match" | "no-match" | "parse-error"; parseErrorKind?: string | undefined; matchCount?: number | undefined; search?: string | undefined; }[]; }, {}>; export type FsApplyErrorMsg = typeof FsApplyErrorMsg.infer; export declare const FsTurnEndMsg: import("arktype/internal/variants/object.ts").ObjectType<{ blockId: string; streamId: string; seq: number; timestamp: Date | ((In: string) => import("arktype/internal/attributes.ts").To); type: "fs.turn.end"; files: { [x: string]: string; }; errorCount: number; }, {}>; export type FsTurnEndMsg = typeof FsTurnEndMsg.infer; export declare const FsStreamMsg: import("arktype/internal/variants/object.ts").ObjectType<{ blockId: string; streamId: string; seq: number; timestamp: Date | ((In: string) => import("arktype/internal/attributes.ts").To); type: "fs.file.snapshot"; path: string; content: string; sectionId: string; source: "create" | "replace"; appliedSections: number; } | { blockId: string; streamId: string; seq: number; timestamp: Date | ((In: string) => import("arktype/internal/attributes.ts").To); type: "fs.apply.error"; path: string; sectionId: string; failures: { sectionIndex: number; reason: "multiple-match" | "no-match" | "parse-error"; parseErrorKind?: string | undefined; matchCount?: number | undefined; search?: string | undefined; }[]; } | { blockId: string; streamId: string; seq: number; timestamp: Date | ((In: string) => import("arktype/internal/attributes.ts").To); type: "fs.turn.end"; files: { [x: string]: string; }; errorCount: number; }, {}>; export type FsStreamMsg = typeof FsStreamMsg.infer; export declare const isFsFileSnapshot: (msg: unknown, streamId?: string) => msg is FsFileSnapshotMsg; export declare const isFsApplyError: (msg: unknown, streamId?: string) => msg is FsApplyErrorMsg; export declare const isFsTurnEnd: (msg: unknown, streamId?: string) => msg is FsTurnEndMsg; export interface FileSystemStreamOptions { readonly streamId: string; readonly createId: () => string; readonly seed?: ReadonlyMap; } export declare function createFileSystemStream(opts: FileSystemStreamOptions): TransformStream; interface EditCount { readonly creates: number; readonly replaces: number; } export declare function classifyEdits(edits: readonly Edit[]): EditCount; export declare function summarizeFailures(failures: readonly FsApplyFailure[]): readonly string[]; export type { FenceParseError };