/**
 * Capability validation utilities for ensuring bidirectional consistency.
 *
 * Validates that:
 * 1. All `provides` surface references point to existing specs
 * 2. All specs with `capability` fields are listed in their capability's `provides`
 *
 * @module capabilities/validation
 */
import type { EventRegistry } from '../events';
import type { OperationSpecRegistry } from '../operations/registry';
import type { PresentationRegistry } from '../presentations';
import type { CapabilityRegistry, CapabilitySurface } from './capabilities';
/** Single validation error describing an inconsistency. */
export interface CapabilityValidationError {
    /** Type of validation error. */
    type: 'missing_surface_spec' | 'orphan_spec' | 'capability_not_found' | 'surface_not_in_provides';
    /** Human-readable error message. */
    message: string;
    /** Capability key involved (if applicable). */
    capabilityKey?: string;
    /** Surface type involved (if applicable). */
    surface?: CapabilitySurface;
    /** Spec key involved (if applicable). */
    specKey?: string;
}
/** Result of capability consistency validation. */
export interface CapabilityValidationResult {
    /** Whether validation passed with no errors. */
    valid: boolean;
    /** List of validation errors found. */
    errors: CapabilityValidationError[];
    /** List of warnings (non-blocking issues). */
    warnings: CapabilityValidationError[];
}
/** Registries needed for full bidirectional validation. */
export interface CapabilityValidationDeps {
    capabilities: CapabilityRegistry;
    operations?: OperationSpecRegistry;
    events?: EventRegistry;
    presentations?: PresentationRegistry;
}
/**
 * Validates bidirectional consistency between capabilities and their surfaces.
 *
 * Checks:
 * 1. Forward validation: Every surface ref in capability `provides` exists
 * 2. Reverse validation: Every spec with `capability` field is in that capability's `provides`
 *
 * @param deps - Registries to validate against
 * @returns Validation result with errors and warnings
 *
 * @example
 * ```typescript
 * const result = validateCapabilityConsistency({
 *   capabilities: capabilityRegistry,
 *   operations: operationRegistry,
 *   events: eventRegistry,
 * });
 *
 * if (!result.valid) {
 *   console.error('Capability validation failed:', result.errors);
 * }
 * ```
 */
export declare function validateCapabilityConsistency(deps: CapabilityValidationDeps): CapabilityValidationResult;
/**
 * Finds specs that have no capability assignment (orphan specs).
 * This is informational - orphan specs are allowed but may indicate
 * incomplete capability modeling.
 *
 * @param deps - Registries to check
 * @returns List of spec keys without capability assignment
 */
export declare function findOrphanSpecs(deps: CapabilityValidationDeps): {
    operations: string[];
    events: string[];
    presentations: string[];
};
