route-claudecode
Version:
Advanced routing and transformation system for Claude Code outputs to multiple AI providers
40 lines • 1.41 kB
JavaScript
;
/**
* CodeWhisperer Provider Types
* 重构优化版本 - 基于demo2兼容性设计
* 项目所有者: Jason Zhang
*/
Object.defineProperty(exports, "__esModule", { value: true });
exports.getDefaultModelMapping = getDefaultModelMapping;
exports.createCodeWhispererConfig = createCodeWhispererConfig;
exports.validateConfig = validateConfig;
/**
* 获取默认模型映射(仅作为fallback,实际使用路由引擎的映射)
*/
function getDefaultModelMapping() {
return {
'claude-sonnet-4-20250514': 'CLAUDE_SONNET_4_20250514_V1_0',
'claude-3-5-haiku-20241022': 'CLAUDE_3_7_SONNET_20250219_V1_0',
};
}
// ============================================================================
// Configuration Constants - 重构版本
// ============================================================================
/**
* CodeWhisperer服务默认配置
*/
function createCodeWhispererConfig() {
return {
endpoint: 'https://codewhisperer.us-east-1.amazonaws.com/generateAssistantResponse',
profileArn: 'arn:aws:codewhisperer:us-east-1:699475941385:profile/EHGA3GRVQMUK',
origin: 'AI_EDITOR',
chatTriggerType: 'MANUAL',
};
}
/**
* 验证配置完整性
*/
function validateConfig(config) {
return !!(config.endpoint && config.profileArn && config.origin && config.chatTriggerType);
}
//# sourceMappingURL=types.js.map