diff --git a/src/cliproxy/catalog-cache.ts b/src/cliproxy/catalog-cache.ts index 3045bc6a..948f0b75 100644 --- a/src/cliproxy/catalog-cache.ts +++ b/src/cliproxy/catalog-cache.ts @@ -23,6 +23,7 @@ const CHANNEL_TO_PROVIDER: Record = { codex: 'codex', qwen: 'qwen', iflow: 'iflow', + kimi: 'kimi', }; /** CCS provider → channel name mapping (reverse) */ @@ -31,7 +32,7 @@ export const PROVIDER_TO_CHANNEL: Record = Object.fromEntries( ); /** Providers to sync from CLIProxyAPI */ -export const SYNCABLE_PROVIDERS: CLIProxyProvider[] = ['agy', 'gemini', 'codex', 'claude']; +export const SYNCABLE_PROVIDERS: CLIProxyProvider[] = ['agy', 'gemini', 'codex', 'claude', 'kimi']; function getCacheFilePath(): string { return path.join(getCcsDir(), CACHE_FILE_NAME); diff --git a/src/web-server/model-pricing.ts b/src/web-server/model-pricing.ts index 3af43b91..88d008f4 100644 --- a/src/web-server/model-pricing.ts +++ b/src/web-server/model-pricing.ts @@ -450,37 +450,44 @@ const PRICING_REGISTRY: Record = { }, // --------------------------------------------------------------------------- - // Kimi Models (Moonshot AI) - Source: better-ccusage + // Kimi Models (Moonshot AI) - Source: Official Kimi Platform pricing + // inputPerMillion = cache miss price, cacheReadPerMillion = cache hit price // --------------------------------------------------------------------------- - 'kimi-for-coding': { - inputPerMillion: 0.15, - outputPerMillion: 0.6, + 'kimi-k2.5': { + inputPerMillion: 0.6, + outputPerMillion: 3.0, cacheCreationPerMillion: 0.0, - cacheReadPerMillion: 0.0, + cacheReadPerMillion: 0.1, + }, + 'kimi-for-coding': { + inputPerMillion: 0.6, + outputPerMillion: 2.5, + cacheCreationPerMillion: 0.0, + cacheReadPerMillion: 0.15, }, 'kimi-k2-0905-preview': { - inputPerMillion: 0.15, - outputPerMillion: 0.6, + inputPerMillion: 0.6, + outputPerMillion: 2.5, cacheCreationPerMillion: 0.0, - cacheReadPerMillion: 0.0, + cacheReadPerMillion: 0.15, }, 'kimi-k2-turbo-preview': { - inputPerMillion: 0.15, - outputPerMillion: 1.15, + inputPerMillion: 1.15, + outputPerMillion: 8.0, cacheCreationPerMillion: 0.0, - cacheReadPerMillion: 0.0, + cacheReadPerMillion: 0.15, }, 'kimi-k2-thinking': { - inputPerMillion: 0.15, - outputPerMillion: 0.6, + inputPerMillion: 0.6, + outputPerMillion: 2.5, cacheCreationPerMillion: 0.0, - cacheReadPerMillion: 0.0, + cacheReadPerMillion: 0.15, }, 'kimi-k2-thinking-turbo': { - inputPerMillion: 0.15, - outputPerMillion: 1.15, + inputPerMillion: 1.15, + outputPerMillion: 8.0, cacheCreationPerMillion: 0.0, - cacheReadPerMillion: 0.0, + cacheReadPerMillion: 0.15, }, 'kimi-k2-instruct': { inputPerMillion: 1.0, diff --git a/ui/src/components/cliproxy/provider-editor/index.tsx b/ui/src/components/cliproxy/provider-editor/index.tsx index f7a6c172..72a64f5d 100644 --- a/ui/src/components/cliproxy/provider-editor/index.tsx +++ b/ui/src/components/cliproxy/provider-editor/index.tsx @@ -70,6 +70,7 @@ export function ProviderEditor({ iflow: ['iflow'], kiro: ['kiro', 'aws'], ghcp: ['github', 'copilot'], + kimi: ['kimi', 'moonshot'], }; const owners = ownerMap[modelFilterProvider.toLowerCase()] || [ modelFilterProvider.toLowerCase(), diff --git a/ui/src/lib/model-catalogs.ts b/ui/src/lib/model-catalogs.ts index 12aa1df1..1736b19a 100644 --- a/ui/src/lib/model-catalogs.ts +++ b/ui/src/lib/model-catalogs.ts @@ -275,6 +275,40 @@ export const MODEL_CATALOGS: Record = { }, ], }, + kimi: { + provider: 'kimi', + displayName: 'Kimi (Moonshot)', + defaultModel: 'kimi-k2.5', + models: [ + { + id: 'kimi-k2.5', + name: 'Kimi K2.5', + description: 'Latest multimodal model (262K context)', + presetMapping: { + default: 'kimi-k2.5', + opus: 'kimi-k2.5', + sonnet: 'kimi-k2-thinking', + haiku: 'kimi-k2', + }, + }, + { + id: 'kimi-k2-thinking', + name: 'Kimi K2 Thinking', + description: 'Extended reasoning model', + presetMapping: { + default: 'kimi-k2-thinking', + opus: 'kimi-k2.5', + sonnet: 'kimi-k2-thinking', + haiku: 'kimi-k2', + }, + }, + { + id: 'kimi-k2', + name: 'Kimi K2', + description: 'Flagship coding model', + }, + ], + }, kiro: { provider: 'kiro', displayName: 'Kiro (AWS)',