add kimi k2.5
Browse filesFiles changed (5)
97 unmodified lines989910010110210310488 unmodified lines19319419519619719819997 unmodified lines# Define models and languages here to avoid importing Gradio UIAVAILABLE_MODELS = [{"name": "GLM-4.7-Flash ⚡", "id": "zai-org/GLM-4.7-Flash", "description": "GLM-4.7-Flash - Ultra-fast GLM model via HuggingFace Router with Novita provider (Default)", "supports_images": False},{"name": "GLM-4.7", "id": "zai-org/GLM-4.7", "description": "GLM-4.7 - Latest GLM model via HuggingFace Router with Cerebras provider", "supports_images": False},{"name": "MiniMax M2.1", "id": "MiniMaxAI/MiniMax-M2.1", "description": "MiniMax M2.1 - Enhanced model via HuggingFace Router", "supports_images": False},{"name": "GLM-4.6", "id": "zai-org/GLM-4.6", "description": "GLM-4.6 model via HuggingFace with Cerebras provider", "supports_images": False},88 unmodified linesclass CodeGenerationRequest(BaseModel):query: strlanguage: str = "html"model_id: str = "zai-org/GLM-4.7-Flash"provider: str = "auto"history: List[List[str]] = []agent_mode: bool = False97 unmodified lines989910010110210310410588 unmodified lines19419519619719819920097 unmodified lines# Define models and languages here to avoid importing Gradio UIAVAILABLE_MODELS = [{"name": "Kimi-K2.5 🧠", "id": "moonshotai/Kimi-K2.5", "description": "Kimi-K2.5 - New powerful reasoning model via HuggingFace Router with Novita provider (Default)", "supports_images": True},{"name": "GLM-4.7-Flash ⚡", "id": "zai-org/GLM-4.7-Flash", "description": "GLM-4.7-Flash - Ultra-fast GLM model via HuggingFace Router with Novita provider", "supports_images": False},{"name": "GLM-4.7", "id": "zai-org/GLM-4.7", "description": "GLM-4.7 - Latest GLM model via HuggingFace Router with Cerebras provider", "supports_images": False},{"name": "MiniMax M2.1", "id": "MiniMaxAI/MiniMax-M2.1", "description": "MiniMax M2.1 - Enhanced model via HuggingFace Router", "supports_images": False},{"name": "GLM-4.6", "id": "zai-org/GLM-4.6", "description": "GLM-4.6 model via HuggingFace with Cerebras provider", "supports_images": False},88 unmodified linesclass CodeGenerationRequest(BaseModel):query: strlanguage: str = "html"model_id: str = "moonshotai/Kimi-K2.5"provider: str = "auto"history: List[List[str]] = []agent_mode: bool = False
102 unmodified lines103104105106107108102 unmodified lines# GLM-4.7-Flash via HuggingFace Router with Novita providerreturn "zai-org/GLM-4.7-Flash:novita"return model_id102 unmodified lines103104105106107108109110111112102 unmodified lines# GLM-4.7-Flash via HuggingFace Router with Novita providerreturn "zai-org/GLM-4.7-Flash:novita"elif model_id == "moonshotai/Kimi-K2.5":# Kimi K2.5 needs Novita providerreturn "moonshotai/Kimi-K2.5:novita"return model_id
16 unmodified lines1718192021222316 unmodified linesconst [generatedCode, setGeneratedCode] = useState('');const [selectedLanguage, setSelectedLanguage] = useState<Language>('html');const [selectedModel, setSelectedModel] = useState('zai-org/GLM-4.7-Flash');const [models, setModels] = useState<Model[]>([]);const [isGenerating, setIsGenerating] = useState(false);const [isAuthenticated, setIsAuthenticated] = useState(false);16 unmodified lines1718192021222316 unmodified linesconst [generatedCode, setGeneratedCode] = useState('');const [selectedLanguage, setSelectedLanguage] = useState<Language>('html');const [selectedModel, setSelectedModel] = useState('moonshotai/Kimi-K2.5');const [models, setModels] = useState<Model[]>([]);const [isGenerating, setIsGenerating] = useState(false);const [isAuthenticated, setIsAuthenticated] = useState(false);
195 unmodified lines196197198199200201202195 unmodified lines><div className="flex items-center justify-between gap-2"><span className="text-sm text-[#f5f5f7]">{model.name}</span>{['zai-org/GLM-4.7', 'zai-org/GLM-4.7-Flash'].includes(model.id) && (<span className="px-1.5 py-0.5 bg-gradient-to-r from-purple-500 to-pink-500 text-white text-[9px] font-bold rounded uppercase flex-shrink-0">NEW</span>195 unmodified lines196197198199200201202195 unmodified lines><div className="flex items-center justify-between gap-2"><span className="text-sm text-[#f5f5f7]">{model.name}</span>{['moonshotai/Kimi-K2.5', 'zai-org/GLM-4.7', 'zai-org/GLM-4.7-Flash'].includes(model.id) && (<span className="px-1.5 py-0.5 bg-gradient-to-r from-purple-500 to-pink-500 text-white text-[9px] font-bold rounded uppercase flex-shrink-0">NEW</span>
30 unmodified lines31323334353637475 unmodified lines51351451551651751851952037 unmodified lines55855956056156256356456530 unmodified linesonImport,isAuthenticated,initialLanguage = 'html',initialModel = 'zai-org/GLM-4.7-Flash',onAuthChange,setPendingPR,pendingPRRef475 unmodified linesif (onStart) {// Pass duplicated space ID so auto-deploy updates itconsole.log('[Redesign] Calling onStart with duplicated repo ID:', duplicatedRepoId);console.log('[Redesign] Using GLM-4.7-Flash for redesign');onStart(redesignPrompt, result.language || 'html', 'zai-org/GLM-4.7-Flash', undefined, duplicatedRepoId);}}, 100);37 unmodified linesif (onStart) {console.log('[Redesign] Will create PR - not passing repo ID');console.log('[Redesign] Using GLM-4.7-Flash for redesign');onStart(redesignPrompt, result.language || 'html', 'zai-org/GLM-4.7-Flash', undefined, repoId, true); // Pass true for shouldCreatePR}console.log('[Redesign] Will create PR after code generation completes');30 unmodified lines31323334353637475 unmodified lines51351451551651751851952037 unmodified lines55855956056156256356456530 unmodified linesonImport,isAuthenticated,initialLanguage = 'html',initialModel = 'moonshotai/Kimi-K2.5',onAuthChange,setPendingPR,pendingPRRef475 unmodified linesif (onStart) {// Pass duplicated space ID so auto-deploy updates itconsole.log('[Redesign] Calling onStart with duplicated repo ID:', duplicatedRepoId);console.log('[Redesign] Using Kimi-K2.5 for redesign');onStart(redesignPrompt, result.language || 'html', 'moonshotai/Kimi-K2.5', undefined, duplicatedRepoId);}}, 100);37 unmodified linesif (onStart) {console.log('[Redesign] Will create PR - not passing repo ID');console.log('[Redesign] Using Kimi-K2.5 for redesign');onStart(redesignPrompt, result.language || 'html', 'moonshotai/Kimi-K2.5', undefined, repoId, true); // Pass true for shouldCreatePR}console.log('[Redesign] Will create PR after code generation completes');
backend_api.py+3-2
backend_models.py+4
frontend/src/app/page.tsx+1-1
frontend/src/components/ControlPanel.tsx+1-1
frontend/src/components/LandingPage.tsx+5-5