const CLAUDE_THINKING_OPTIONS = [
    { id: "low", label: "Low" },
    { id: "medium", label: "Medium" },
    { id: "high", label: "High" },
];
const CLAUDE_MODELS = [
    {
        provider: "claude",
        id: "claude-opus-4-6[1m]",
        label: "Opus 4.6 1M",
        description: "Opus 4.6 with 1M context window",
        thinkingOptions: [...CLAUDE_THINKING_OPTIONS],
    },
    {
        provider: "claude",
        id: "claude-opus-4-6",
        label: "Opus 4.6",
        description: "Opus 4.6 · Most capable for complex work",
        isDefault: true,
        thinkingOptions: [...CLAUDE_THINKING_OPTIONS],
    },
    {
        provider: "claude",
        id: "claude-sonnet-4-6",
        label: "Sonnet 4.6",
        description: "Sonnet 4.6 · Best for everyday tasks",
        thinkingOptions: [...CLAUDE_THINKING_OPTIONS],
    },
    {
        provider: "claude",
        id: "claude-haiku-4-5",
        label: "Haiku 4.5",
        description: "Haiku 4.5 · Fastest for quick answers",
    },
];
export function getClaudeModels() {
    return CLAUDE_MODELS.map((model) => ({ ...model }));
}
/**
 * Normalize a runtime model string (from SDK init message) to a known model ID.
 * Handles the `[1m]` suffix that the SDK appends for 1M context sessions.
 */
export function normalizeClaudeRuntimeModelId(value) {
    const trimmed = typeof value === "string" ? value.trim() : "";
    if (!trimmed) {
        return null;
    }
    // Check for exact match first (handles claude-opus-4-6[1m] directly)
    if (CLAUDE_MODELS.some((model) => model.id === trimmed)) {
        return trimmed;
    }
    // Match: claude-{family}-{major}-{minor}[1m]? possibly followed by a date suffix
    const runtimeMatch = trimmed.match(/(?:claude-)?(opus|sonnet|haiku)[-_ ]+(\d+)[-.](\d+)(\[1m\])?/i);
    if (!runtimeMatch) {
        return null;
    }
    const family = runtimeMatch[1].toLowerCase();
    const major = runtimeMatch[2];
    const minor = runtimeMatch[3];
    const suffix = runtimeMatch[4] ?? "";
    return `claude-${family}-${major}-${minor}${suffix}`;
}
//# sourceMappingURL=claude-models.js.map