export declare const DEEPSEEK_OPENAI_BASE = "https://api.deepseek.com"; export declare const DEEPSEEK_ANTHROPIC_BASE = "https://api.deepseek.com/anthropic"; /** Beta base for strict tools, FIM, and chat prefix completion. */ export declare const DEEPSEEK_BETA_BASE = "https://api.deepseek.com/beta"; export type DeepSeekApiDialect = 'openai' | 'anthropic'; /** * DeepSeek OpenAI-compat thinking effort map (pi ThinkingLevel → API * `reasoning_effort` / Anthropic `output_config.effort`). * Official efforts: low / high / max. `medium` (Agim UI) → high. */ export declare const DEEPSEEK_THINKING_LEVEL_MAP: { readonly minimal: null; readonly low: "low"; readonly medium: "high"; readonly high: "high"; readonly xhigh: "max"; }; /** * Build a DeepSeek `user_id` for content-safety / KV-cache / scheduling * isolation. Must match `[a-zA-Z0-9\-_]+` (max 512) and must NOT contain PII — * we hash `platform:userId` and prefix with `agim-`. */ export declare function hashDeepSeekUserId(platform: string | undefined | null, userId: string | undefined | null): string | undefined; export declare function isDeepSeekAnthropicBaseUrl(baseUrl: string | undefined | null): boolean; /** Chat Completions base: beta when strict tools / prefix / FIM are active. */ export declare function resolveDeepSeekOpenAiBaseUrl(opts: { strictTools?: boolean; beta?: boolean; }): string; /** Inject OpenAI-format top-level `user_id` when absent. */ export declare function withDeepSeekUserId(payload: Record, userId: string | undefined): Record; /** Inject Anthropic-format `metadata.user_id` when absent. */ export declare function withDeepSeekAnthropicUserId(payload: Record, userId: string | undefined): Record; /** * Normalize a JSON Schema so DeepSeek `strict: true` (beta) accepts it: * - every object has `additionalProperties: false` * - every object property is listed in `required` * - strip unsupported keywords (min/max length/items, pattern, …) */ export declare function normalizeJsonSchemaForStrict(schema: unknown): Record; /** Rewrite OpenAI Chat Completions `tools[]` for DeepSeek strict mode. */ export declare function applyStrictToolsToOpenAiPayload(payload: Record): Record; /** * DeepSeek Anthropic dialect: strip budget_tokens/display; keep * thinking.type enabled|disabled; attach output_config.effort when enabled. */ export declare function normalizeDeepSeekAnthropicThinkingPayload(payload: Record, effort: string | undefined): Record; /** Env / config: enable DeepSeek beta strict tools. */ export declare function isDeepSeekStrictToolsEnabled(backendFlag: boolean | undefined): boolean; //# sourceMappingURL=deepseek-compat.d.ts.map