/**
 * Shared UAP config loading utility.
 * Replaces 20+ duplicate config-loading patterns across CLI modules.
 */
import type { AgentContextConfig } from '../types/index.js';
/**
 * Find the .uap.json config file path, searching cwd and parent directories.
 * Supports worktree layouts where .uap.json is in the project root above .worktrees/.
 */
export declare function findUapConfigPath(cwd?: string): string | null;
/**
 * Load and parse .uap.json config from a project directory.
 * Returns null if the config file doesn't exist or fails to parse.
 * Searches parent directories for worktree support.
 */
export declare function loadUapConfig(cwd?: string): AgentContextConfig | null;
/**
 * Load .uap.json config or return a minimal default config.
 * Never returns null — always provides a usable config object.
 */
export declare function loadUapConfigOrDefault(cwd?: string): AgentContextConfig;
/**
 * Load raw .uap.json as untyped JSON (for read-modify-write operations).
 * Preserves unknown fields that AgentContextConfigSchema.parse() would strip.
 * Returns null if the file doesn't exist.
 */
export declare function loadUapConfigRaw(cwd?: string): Record<string, unknown> | null;
/**
 * Load, modify, and save .uap.json (for read-modify-write operations).
 * The modifier function receives the raw JSON and returns the modified version.
 * Preserves unknown fields and formatting.
 */
export declare function modifyUapConfig(cwd: string, modifier: (config: Record<string, unknown>) => Record<string, unknown>): void;
//# sourceMappingURL=config-loader.d.ts.map