/** * v2.15.0 follow-up — G6: slice cross-integration verifier. * * The 12 Gaps memory: in the layered-parallel execution model (G12), multiple * slices can complete out of order. The question is: do their public * contracts still line up when integrated together? * * This service takes a list of slice contracts (already written via * `peaks contract write`) and produces a cross-integration report: * - missing exports: an export declared by slice A but not consumed by slice B * - type mismatches: types used across slice boundaries * - signature drift: function signatures changed * * Pure function. No I/O. The CLI is `peaks slice integrate`. */ import type { SliceContract } from '../dispatch/contract-store.js'; export interface IntegrationFinding { /** Severity: 'error' (blocks integration), 'warning' (informational), 'info' (noted). */ readonly severity: 'error' | 'warning' | 'info'; /** The slice that owns the export. */ readonly ownerSliceId: string; /** The slice that consumes the export. */ readonly consumerSliceId: string; /** Type of finding. */ readonly kind: 'missing-export' | 'type-mismatch' | 'signature-drift' | 'duplicate-export'; /** Human-readable description. */ readonly message: string; } export interface IntegrationReport { readonly sliceIds: readonly string[]; readonly totalContracts: number; readonly findings: readonly IntegrationFinding[]; readonly summary: { readonly errors: number; readonly warnings: number; readonly info: number; }; readonly ok: boolean; } export interface IntegrateOptions { readonly contracts: readonly SliceContract[]; } export declare function integrateSlices(opts: IntegrateOptions): IntegrationReport;