export interface RemediationResult { /** One-line user-facing hint explaining the error and the fix. */ hint: string; /** Optional copy-pasteable store-cli command. Empty string if N/A. */ command: string; } /** * Infer the entity type from an entity name/ID string. * Returns "task" as default if no match. */ export declare function inferEntityType(entity: string): string; /** Parsed breakdown of a validation error string. */ interface ParsedError { field: string; errorKind: "enum" | "required" | "undeclared" | "type" | "pattern" | "datetime" | "length" | "other"; observed?: string; enumValues?: string[]; } /** * Parse a single validation error line from validate.js / store-cli. * * Examples: * 'status: value "verified" not in [reported, triaged, in-progress, fixed]' * 'taskId: missing required field' * 'xyz: undeclared field' * 'sprintId: expected string, got number' * 'title: value length 0 is below minLength 1' * 'createdAt: value "today" is not a valid date-time' * 'prefix: value "AB" does not match pattern ^[A-Z]+-[A-Z]$' */ export declare function parseValidationError(line: string): ParsedError; /** * Given a single validation error line (from validate.js or store-cli), * return a user-facing remediation hint and optional copy-pasteable command. * * @param errorLine A single error line from validate.js / store-cli output. * @param entityType The entity type (task, sprint, bug, feature, event). * @param entityId The entity ID (e.g. "FORGE-S18-T02") — used for commands. * @returns RemediationResult with hint and command. */ export declare function remediateError(errorLine: string, entityType: string, entityId: string): RemediationResult; /** * Parse a multi-line validation output (e.g. from store-cli validate or * validate-store --dry-run) into individual error lines and return * remediation for each. * * @param output Raw multi-line output from validation tool. * @param entityType Override entity type (inferred from output if not provided). * @returns Array of { errorLine, remediation } objects. */ export declare function remediateValidationOutput(output: string, entityType?: string): Array<{ errorLine: string; remediation: RemediationResult; }>; /** * Format a block message for a write-guard violation, appending remediation hints. * Used by hook-dispatcher.ts for store-cli intercept blocks. * * @param rawReason The raw reason string from validateStoreCLIPayload or checkWriteGuard. * @param entityType The entity type if known. * @param entityId The entity ID if known. * @returns Enhanced reason string with remediation hints appended. */ export declare function enhanceBlockMessage(rawReason: string, entityType?: string, entityId?: string): string; export {};