import { z } from "zod";

//#region src/domain/xling/config.d.ts

/**
* Provider configuration schema
*/
declare const ProviderConfigSchema: z.ZodType<{
  name: string;
  baseUrl: string;
  apiKey: string;
  models: string[];
  priority?: number;
  timeout?: number;
  headers?: Record<string, string>;
}>;
type ProviderConfig = z.infer<typeof ProviderConfigSchema>;
/**
* Retry policy schema
*/
declare const RetryPolicySchema: z.ZodType<{
  maxRetries: number;
  backoffMs: number;
}>;
type RetryPolicy = z.infer<typeof RetryPolicySchema>;
/**
* Prompt configuration schema (AI-related settings)
*/
declare const PromptConfigSchema: z.ZodType<{
  providers: Array<{
    name: string;
    baseUrl: string;
    apiKey: string;
    models: string[];
    priority?: number;
    timeout?: number;
    headers?: Record<string, string>;
  }>;
  defaultModel?: string;
  retryPolicy?: {
    maxRetries: number;
    backoffMs: number;
  };
}>;
type PromptConfig = z.infer<typeof PromptConfigSchema>;
/**
* Platform-specific command/args schema for pipeline steps
*/
declare const PlatformCommandSchema: z.ZodType<{
  win32?: string;
  darwin?: string;
  linux?: string;
  default: string;
}>;
type PlatformCommand = z.infer<typeof PlatformCommandSchema>;
/**
* Platform-specific args schema for pipeline steps
*/
declare const PlatformArgsSchema: z.ZodType<{
  win32?: string[];
  darwin?: string[];
  linux?: string[];
  default: string[];
}>;
type PlatformArgs = z.infer<typeof PlatformArgsSchema>;
/**
* Pipeline step schema
* Supports both simple and platform-specific command/args
*/
declare const PipelineStepSchema: z.ZodType<{
  command: string | PlatformCommand;
  args?: string[] | PlatformArgs;
}>;
type PipelineStep = z.infer<typeof PipelineStepSchema>;
/**
* Platform-specific shell command schema
* Supports platform-specific commands with fallback to default
*/
declare const PlatformShellSchema: z.ZodType<{
  win32?: string;
  darwin?: string;
  linux?: string;
  default: string;
}>;
type PlatformShell = z.infer<typeof PlatformShellSchema>;
/**
* Platform-specific pipeline schema
* Supports platform-specific pipelines with fallback to default
*/
declare const PlatformPipelineSchema: z.ZodType<{
  win32?: PipelineStep[];
  darwin?: PipelineStep[];
  linux?: PipelineStep[];
  default: PipelineStep[];
}>;
type PlatformPipeline = z.infer<typeof PlatformPipelineSchema>;
/**
* Shortcut configuration schema
* Supports three types:
* 1. Command: Execute xling command with args
* 2. Shell: Execute arbitrary shell command (string or platform-specific object)
* 3. Pipeline: Execute a series of commands with piped output (array or platform-specific object)
*/
type ShortcutConfig = {
  command?: string;
  args?: string[];
  shell?: string | PlatformShell;
  pipeline?: PipelineStep[] | PlatformPipeline;
  description?: string;
};
declare const ShortcutConfigSchema: z.ZodType<ShortcutConfig>;
/**
* Xling configuration type
*/
interface XlingConfig {
  prompt: PromptConfig;
  shortcuts?: Record<string, ShortcutConfig>;
}
/**
* Xling configuration schema
*/
declare const XlingConfigSchema: z.ZodType<XlingConfig>;
/**
* Validate and parse Xling configuration
* Automatically migrates old format to new format
*/
declare function validateXlingConfig(data: unknown): XlingConfig;
/**
* Validate provider models uniqueness within the array
*/
declare function validateProviderModels(provider: ProviderConfig): string[] | null;
/**
* Get normalized priority (undefined becomes MAX_SAFE_INTEGER)
*/
declare function getNormalizedPriority(priority?: number): number;
//#endregion
export { validateXlingConfig as C, validateProviderModels as S, ShortcutConfig as _, PlatformCommand as a, XlingConfigSchema as b, PlatformPipelineSchema as c, PromptConfig as d, PromptConfigSchema as f, RetryPolicySchema as g, RetryPolicy as h, PlatformArgsSchema as i, PlatformShell as l, ProviderConfigSchema as m, PipelineStepSchema as n, PlatformCommandSchema as o, ProviderConfig as p, PlatformArgs as r, PlatformPipeline as s, PipelineStep as t, PlatformShellSchema as u, ShortcutConfigSchema as v, getNormalizedPriority as x, XlingConfig as y };