mirror of
https://github.com/tiennm99/ccs.git
synced 2026-07-16 12:15:57 +00:00
feat(cliproxy): rename kimi API preset to km, add kimi to UI
- create config/base-km.settings.json for API-key Kimi users - rename preset id 'kimi' to 'km' in CLI and UI provider presets - add 'ccs km' to help text API section, keep 'ccs kimi' for OAuth - add --km delegation flag for API-key mode, --kimi stays for OAuth - add kimi to UI CLIPROXY_PROVIDERS, assets, colors, names, device code
This commit is contained in:
@@ -0,0 +1,10 @@
|
|||||||
|
{
|
||||||
|
"env": {
|
||||||
|
"ANTHROPIC_BASE_URL": "https://api.kimi.com/coding/",
|
||||||
|
"ANTHROPIC_AUTH_TOKEN": "YOUR_KIMI_API_KEY_HERE",
|
||||||
|
"ANTHROPIC_MODEL": "kimi-k2-thinking-turbo",
|
||||||
|
"ANTHROPIC_DEFAULT_OPUS_MODEL": "kimi-k2-thinking-turbo",
|
||||||
|
"ANTHROPIC_DEFAULT_SONNET_MODEL": "kimi-k2-thinking-turbo",
|
||||||
|
"ANTHROPIC_DEFAULT_HAIKU_MODEL": "kimi-k2-thinking-turbo"
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -93,11 +93,11 @@ export const PROVIDER_PRESETS: ProviderPreset[] = [
|
|||||||
alwaysThinkingEnabled: true,
|
alwaysThinkingEnabled: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: 'kimi',
|
id: 'km',
|
||||||
name: 'Kimi',
|
name: 'Kimi',
|
||||||
description: 'Moonshot AI - Fast reasoning model',
|
description: 'Moonshot AI - Fast reasoning model',
|
||||||
baseUrl: 'https://api.kimi.com/coding/',
|
baseUrl: 'https://api.kimi.com/coding/',
|
||||||
defaultProfileName: 'kimi',
|
defaultProfileName: 'km',
|
||||||
defaultModel: 'kimi-k2-thinking-turbo',
|
defaultModel: 'kimi-k2-thinking-turbo',
|
||||||
apiKeyPlaceholder: 'sk-...',
|
apiKeyPlaceholder: 'sk-...',
|
||||||
apiKeyHint: 'Get your API key from Moonshot AI',
|
apiKeyHint: 'Get your API key from Moonshot AI',
|
||||||
|
|||||||
@@ -131,7 +131,7 @@ Run ${color('ccs config', 'command')} for web dashboard`.trim();
|
|||||||
['ccs', 'Use default Claude account'],
|
['ccs', 'Use default Claude account'],
|
||||||
['ccs glm', 'GLM 5 (API key required)'],
|
['ccs glm', 'GLM 5 (API key required)'],
|
||||||
['ccs glmt', 'GLM with thinking mode'],
|
['ccs glmt', 'GLM with thinking mode'],
|
||||||
['ccs kimi', 'Kimi for Coding (API key)'],
|
['ccs km', 'Kimi for Coding (API key)'],
|
||||||
['ccs ollama', 'Local Ollama (http://localhost:11434)'],
|
['ccs ollama', 'Local Ollama (http://localhost:11434)'],
|
||||||
['ccs ollama-cloud', 'Ollama Cloud (API key required)'],
|
['ccs ollama-cloud', 'Ollama Cloud (API key required)'],
|
||||||
['', ''], // Spacer
|
['', ''], // Spacer
|
||||||
@@ -171,6 +171,7 @@ Run ${color('ccs config', 'command')} for web dashboard`.trim();
|
|||||||
['ccs codex', 'OpenAI Codex (supports -medium/-high/-xhigh model suffixes)'],
|
['ccs codex', 'OpenAI Codex (supports -medium/-high/-xhigh model suffixes)'],
|
||||||
['ccs agy', 'Antigravity (Claude/Gemini models)'],
|
['ccs agy', 'Antigravity (Claude/Gemini models)'],
|
||||||
['ccs qwen', 'Qwen Code (qwen3-coder)'],
|
['ccs qwen', 'Qwen Code (qwen3-coder)'],
|
||||||
|
['ccs kimi', 'Kimi (Moonshot AI K2/K2.5 models)'],
|
||||||
['ccs kiro', 'Kiro (AWS CodeWhisperer Claude models)'],
|
['ccs kiro', 'Kiro (AWS CodeWhisperer Claude models)'],
|
||||||
['ccs ghcp', 'GitHub Copilot (OAuth via CLIProxy Plus)'],
|
['ccs ghcp', 'GitHub Copilot (OAuth via CLIProxy Plus)'],
|
||||||
['', ''], // Spacer
|
['', ''], // Spacer
|
||||||
@@ -255,7 +256,8 @@ Run ${color('ccs config', 'command')} for web dashboard`.trim();
|
|||||||
printSubSection('Delegation (inside Claude Code CLI)', [
|
printSubSection('Delegation (inside Claude Code CLI)', [
|
||||||
['/ccs "task"', 'Delegate task (auto-selects profile)'],
|
['/ccs "task"', 'Delegate task (auto-selects profile)'],
|
||||||
['/ccs --glm "task"', 'Force GLM-5 for simple tasks'],
|
['/ccs --glm "task"', 'Force GLM-5 for simple tasks'],
|
||||||
['/ccs --kimi "task"', 'Force Kimi for long context'],
|
['/ccs --kimi "task"', 'Force Kimi OAuth for long context'],
|
||||||
|
['/ccs --km "task"', 'Force Kimi API key for long context'],
|
||||||
['/ccs:continue "follow-up"', 'Continue last delegation session'],
|
['/ccs:continue "follow-up"', 'Continue last delegation session'],
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
|||||||
@@ -19,6 +19,7 @@ export const CLIPROXY_PROVIDERS = [
|
|||||||
'kiro',
|
'kiro',
|
||||||
'ghcp',
|
'ghcp',
|
||||||
'claude',
|
'claude',
|
||||||
|
'kimi',
|
||||||
] as const;
|
] as const;
|
||||||
|
|
||||||
/** Union type for CLIProxy provider IDs */
|
/** Union type for CLIProxy provider IDs */
|
||||||
@@ -39,6 +40,7 @@ export const PROVIDER_ASSETS: Record<string, string> = {
|
|||||||
kiro: '/assets/providers/kiro.png',
|
kiro: '/assets/providers/kiro.png',
|
||||||
ghcp: '/assets/providers/copilot.svg',
|
ghcp: '/assets/providers/copilot.svg',
|
||||||
claude: '/assets/providers/claude.svg',
|
claude: '/assets/providers/claude.svg',
|
||||||
|
kimi: '/assets/providers/kimi.svg',
|
||||||
};
|
};
|
||||||
|
|
||||||
// Provider brand colors
|
// Provider brand colors
|
||||||
@@ -52,6 +54,7 @@ export const PROVIDER_COLORS: Record<string, string> = {
|
|||||||
kiro: '#4d908e', // Dark Cyan (AWS-inspired)
|
kiro: '#4d908e', // Dark Cyan (AWS-inspired)
|
||||||
ghcp: '#43aa8b', // Seaweed (GitHub-inspired)
|
ghcp: '#43aa8b', // Seaweed (GitHub-inspired)
|
||||||
claude: '#D97757', // Anthropic brand color (matches SVG)
|
claude: '#D97757', // Anthropic brand color (matches SVG)
|
||||||
|
kimi: '#FF6B35', // Moonshot AI brand orange
|
||||||
};
|
};
|
||||||
|
|
||||||
// Provider display names
|
// Provider display names
|
||||||
@@ -65,6 +68,7 @@ const PROVIDER_NAMES: Record<string, string> = {
|
|||||||
kiro: 'Kiro (AWS)',
|
kiro: 'Kiro (AWS)',
|
||||||
ghcp: 'GitHub Copilot (OAuth)',
|
ghcp: 'GitHub Copilot (OAuth)',
|
||||||
claude: 'Claude (Anthropic)',
|
claude: 'Claude (Anthropic)',
|
||||||
|
kimi: 'Kimi (Moonshot)',
|
||||||
};
|
};
|
||||||
|
|
||||||
// Map provider to display name
|
// Map provider to display name
|
||||||
@@ -76,7 +80,7 @@ export function getProviderDisplayName(provider: string): string {
|
|||||||
* Providers that use Device Code OAuth flow instead of Authorization Code flow.
|
* Providers that use Device Code OAuth flow instead of Authorization Code flow.
|
||||||
* Device Code flow requires displaying a user code for manual entry at provider's website.
|
* Device Code flow requires displaying a user code for manual entry at provider's website.
|
||||||
*/
|
*/
|
||||||
export const DEVICE_CODE_PROVIDERS: CLIProxyProvider[] = ['ghcp', 'kiro', 'qwen'];
|
export const DEVICE_CODE_PROVIDERS: CLIProxyProvider[] = ['ghcp', 'kiro', 'qwen', 'kimi'];
|
||||||
|
|
||||||
/** Check if provider uses Device Code flow */
|
/** Check if provider uses Device Code flow */
|
||||||
export function isDeviceCodeProvider(provider: string): boolean {
|
export function isDeviceCodeProvider(provider: string): boolean {
|
||||||
|
|||||||
@@ -90,11 +90,11 @@ export const PROVIDER_PRESETS: ProviderPreset[] = [
|
|||||||
category: 'alternative',
|
category: 'alternative',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: 'kimi',
|
id: 'km',
|
||||||
name: 'Kimi',
|
name: 'Kimi',
|
||||||
description: 'Moonshot AI - Fast reasoning model',
|
description: 'Moonshot AI - Fast reasoning model',
|
||||||
baseUrl: 'https://api.kimi.com/coding/',
|
baseUrl: 'https://api.kimi.com/coding/',
|
||||||
defaultProfileName: 'kimi',
|
defaultProfileName: 'km',
|
||||||
badge: 'Reasoning',
|
badge: 'Reasoning',
|
||||||
icon: '/icons/kimi.svg',
|
icon: '/icons/kimi.svg',
|
||||||
defaultModel: 'kimi-k2-thinking-turbo',
|
defaultModel: 'kimi-k2-thinking-turbo',
|
||||||
@@ -102,6 +102,7 @@ export const PROVIDER_PRESETS: ProviderPreset[] = [
|
|||||||
apiKeyPlaceholder: 'sk-...',
|
apiKeyPlaceholder: 'sk-...',
|
||||||
apiKeyHint: 'Get your API key from Moonshot AI',
|
apiKeyHint: 'Get your API key from Moonshot AI',
|
||||||
category: 'alternative',
|
category: 'alternative',
|
||||||
|
alwaysThinkingEnabled: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: 'foundry',
|
id: 'foundry',
|
||||||
|
|||||||
Reference in New Issue
Block a user