/**
 * DeepSeekAdapter -- DeepSeek REST API transport adapter.
 *
 * Implements LlmProviderAdapter for the DeepSeek chat-completions wire
 * format. DeepSeek's HTTP API is OpenAI-compatible, but this adapter
 * implements the wire shape directly (rather than reusing OpenAIAdapter)
 * so that:
 *   - provider-compliance binds 'deepseek' as a separate providerId
 *     (sovereignty: 'cn'). Pack rules can target DeepSeek independently
 *     of OpenAI / Azure.
 *   - the fail-closed `blockedProviders: ['deepseek', ...]` policy on
 *     DORA, EU MDR/IVDR, US FDA 21 CFR 56, UK AI Framework, Illinois
 *     AIVIA, EU DSA, NIS2, NHS DTAC, ISO 20022, UK Equality Act, and
 *     others fires through BaseProviderAdapter.initialize() on
 *     activePacks consultation.
 *   - the spec-compliance suite + provider-compliance registry can audit
 *     DeepSeek the same way they audit Anthropic / OpenAI / Bedrock /
 *     Google / Ollama.
 *
 * Wire format:
 *   POST <baseUrl>/chat/completions
 *   GET  <baseUrl>/models
 *
 * Auth:
 *   Authorization: Bearer <apiKey>  (required)
 *
 * Streaming: Server-Sent Events. Each `data:` line carries a JSON chunk
 * matching the OpenAI streaming shape; final marker is `data: [DONE]`.
 *
 * Tool use: OpenAI-shape tools array in request, tool_calls array in
 * response (function calling). Same wire format as the openai npm SDK
 * because DeepSeek is OpenAI-compatible by design.
 *
 * BAA / Sovereignty:
 *   - DeepSeek does NOT offer a HIPAA BAA.
 *   - sovereignty: 'cn' (data sovereignty under PRC jurisdiction).
 *   - PRC National Intelligence Law concerns mean multiple regulated
 *     packs block this provider entirely. The pack-binding gate runs
 *     in BaseProviderAdapter.initialize() and refuses to construct an
 *     adapter instance when a blocking pack is active.
 *
 * Spec: P3-SUB-01 AC 1-3, 22-27 (LLM Provider Adapter SDK contract)
 * Closes: F-NEW-DEEPSEEK-ADAPTER (source-side adapter parity with
 *         Anthropic / OpenAI / Bedrock / Google / Gemma / Ollama).
 *
 * @connexum/ai-governance
 */
import { BaseProviderAdapter, getProviderCompliance } from './base';
import type { LlmAdapterConfig, LlmAdapterCapabilities, LlmChatRequest, LlmChatResponse, LlmStreamChunk, LlmToolUseRequest, LlmToolUseResponse, LlmModelDescriptor } from './index';
import { LlmProviderError } from './index';
/**
 * DeepSeek API version this adapter was tested against.
 *
 * DeepSeek does not publish a formal versioned URL prefix or
 * `Api-Version` response header; the public docs simply reference the
 * `/chat/completions` endpoint at `api.deepseek.com`. We pin to the
 * docs revision date the wire shape was captured against. Re-verify
 * against https://api-docs.deepseek.com/ when bumping.
 *
 * TODO (Vera/Legal, Wire): Confirm pinned date matches the live
 * upstream docs page on the next quarterly review. Flag
 * DEFERRED-DEEPSEEK-API-VERSION.
 */
export declare const TESTED_API_VERSION = "2025-01-20";
/** Look up reasoning-mode flag for a given model id. */
export declare function isDeepSeekReasoningModel(modelId: string): boolean;
export interface DeepSeekAdapterConfig extends LlmAdapterConfig {
    /** DeepSeek API key (required). Bearer token in Authorization header. */
    apiKey: string;
    /**
     * Base URL override. Default: https://api.deepseek.com. Customers
     * proxying DeepSeek through an internal gateway supply this.
     */
    baseUrl?: string;
}
export declare class DeepSeekAdapter extends BaseProviderAdapter {
    readonly adapterId = "deepseek";
    readonly providerId = "deepseek";
    private deepseekConfig;
    initialize(config: LlmAdapterConfig): void;
    private buildUrl;
    private authHeaders;
    private convertMessages;
    private validateModelId;
    chat(request: LlmChatRequest): Promise<LlmChatResponse>;
    private chatOnce;
    chatStream(request: LlmChatRequest): AsyncIterable<LlmStreamChunk>;
    invokeToolUse(request: LlmToolUseRequest): Promise<LlmToolUseResponse>;
    private invokeToolUseOnce;
    enumerateModels(): Promise<LlmModelDescriptor[]>;
    translateError(raw: unknown): LlmProviderError;
    getCapabilities(): LlmAdapterCapabilities;
    private handleHttpErrors;
    private mapFinishReason;
}
export declare const DEEPSEEK_KNOWN_MODEL_IDS: ReadonlySet<string>;
/**
 * Test-only re-export of `getProviderCompliance` bound to the same
 * module instance that ran `registerProviderCompliance()` at load time.
 *
 * Required because under tsx --test, importing
 * `getProviderCompliance` from `'../../../../src/llm-adapters/base'`
 * may resolve to a different module instance than the one
 * `deepseek.ts` imports as `'./base'` -- the in-process registry Map
 * is then split across instances and the registration is invisible
 * to the test.
 *
 * Production code should always import `getProviderCompliance` from
 * `@connexum/ai-governance/adapters` (the barrel) -- that single
 * canonical export point guarantees a single Map instance.
 */
export declare const __getProviderComplianceForTests: typeof getProviderCompliance;
//# sourceMappingURL=deepseek.d.ts.map