/** * Minimal Rule Bootstrap (Phase 17) * * Bootstraps 1-3 stub Rule entities for high-value deterministic principles. * Selected by: observedViolationCount (descending) + evaluability=deterministic. * Falls back to all deterministic principles if violation data is sparse. * * Rule ID format: {principleId}_stub_bootstrap * Scope: BOOT-03 — bounded, no mass migration, no implementations. * * Usage: * npx vitest run tests/core/bootstrap-rules.test.ts (tests) * npm run bootstrap-rules (production) */ export interface BootstrapResult { principleId: string; ruleId: string; status: 'created' | 'skipped'; } /** * Select principles for bootstrap based on violation count and evaluability. * * @param stateDir - State directory path * @param limit - Maximum number of principles to select (default: 3) * @returns Array of principle IDs sorted by observedViolationCount (descending) * @throws Error if no deterministic principles found */ export declare function selectPrinciplesForBootstrap(stateDir: string, limit?: number): string[]; /** * Bootstrap stub rules for selected principles. * * Creates stub Rule entities with format {principleId}_stub_bootstrap. * Links rules to principles via suggestedRules array. * Idempotent: skips existing rules. * * @param stateDir - State directory path * @param limit - Maximum number of principles to bootstrap (default: 3) * @returns Array of results indicating created or skipped status * @throws Error if no deterministic principles found */ export declare function bootstrapRules(stateDir: string, limit?: number): BootstrapResult[]; /** * Validate that bootstrapped state is correct. * * @param stateDir - State directory path * @param expectedPrincipleIds - Principle IDs that should be bootstrapped * @returns true if validation passes * @throws Error if validation fails */ export declare function validateBootstrap(stateDir: string, expectedPrincipleIds: string[]): boolean;