Skip to content

Commit 6269f2d

Browse files
Alex-yang00forge-code-agentamitksingh1490
authored
feat: add Novita AI as LLM provider (#2687)
Co-authored-by: ForgeCode <noreply@forgecode.dev> Co-authored-by: Amit Singh <amitksingh1490@gmail.com>
1 parent 53fe783 commit 6269f2d

2 files changed

Lines changed: 52 additions & 0 deletions

File tree

‎crates/forge_domain/src/provider.rs‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ impl ProviderId {
7070
pub const MINIMAX: ProviderId = ProviderId(Cow::Borrowed("minimax"));
7171
pub const CODEX: ProviderId = ProviderId(Cow::Borrowed("codex"));
7272
pub const OPENCODE_ZEN: ProviderId = ProviderId(Cow::Borrowed("opencode_zen"));
73+
pub const NOVITA: ProviderId = ProviderId(Cow::Borrowed("novita"));
7374

7475
/// Returns all built-in provider IDs
7576
///
@@ -100,6 +101,7 @@ impl ProviderId {
100101
ProviderId::MINIMAX,
101102
ProviderId::CODEX,
102103
ProviderId::OPENCODE_ZEN,
104+
ProviderId::NOVITA,
103105
]
104106
}
105107

@@ -123,6 +125,7 @@ impl ProviderId {
123125
"io_intelligence" => "IOIntelligence".to_string(),
124126
"minimax" => "MiniMax".to_string(),
125127
"codex" => "Codex".to_string(),
128+
"novita" => "Novita".to_string(),
126129
_ => {
127130
// For other providers, use UpperCamelCase conversion
128131
use convert_case::{Case, Casing};
@@ -165,6 +168,7 @@ impl std::str::FromStr for ProviderId {
165168
"io_intelligence" => ProviderId::IO_INTELLIGENCE,
166169
"minimax" => ProviderId::MINIMAX,
167170
"codex" => ProviderId::CODEX,
171+
"novita" => ProviderId::NOVITA,
168172
// For custom providers, use Cow::Owned to avoid memory leaks
169173
custom => ProviderId(Cow::Owned(custom.to_string())),
170174
};

‎crates/forge_repo/src/provider/provider.json‎

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2474,5 +2474,53 @@
24742474
}
24752475
],
24762476
"auth_methods": ["api_key"]
2477+
},
2478+
{
2479+
"id": "novita",
2480+
"api_key_vars": "NOVITA_API_KEY",
2481+
"url_param_vars": [],
2482+
"response_type": "OpenAI",
2483+
"url": "https://api.novita.ai/openai/v1/chat/completions",
2484+
"models": [
2485+
{
2486+
"id": "moonshotai/kimi-k2.5",
2487+
"name": "Kimi K2.5",
2488+
"description": "Moonshot AI's flagship MoE model with 262K context, function calling, structured output, reasoning, and vision capabilities",
2489+
"context_length": 262144,
2490+
"tools_supported": true,
2491+
"supports_parallel_tool_calls": true,
2492+
"supports_reasoning": true,
2493+
"input_modalities": ["text", "image"]
2494+
},
2495+
{
2496+
"id": "zai-org/glm-5",
2497+
"name": "GLM-5",
2498+
"description": "Zhipu AI's flagship MoE model with 202K context, function calling, structured output, and reasoning capabilities",
2499+
"context_length": 202800,
2500+
"tools_supported": true,
2501+
"supports_parallel_tool_calls": true,
2502+
"supports_reasoning": true,
2503+
"input_modalities": ["text"]
2504+
},
2505+
{
2506+
"id": "minimax/minimax-m2.5",
2507+
"name": "MiniMax M2.5",
2508+
"description": "MiniMax's MoE model with 204K context, function calling, structured output, and reasoning capabilities",
2509+
"context_length": 204800,
2510+
"tools_supported": true,
2511+
"supports_parallel_tool_calls": true,
2512+
"supports_reasoning": true,
2513+
"input_modalities": ["text"]
2514+
},
2515+
{
2516+
"id": "qwen/qwen3-embedding-0.6b",
2517+
"name": "Qwen3 Embedding 0.6B",
2518+
"description": "Qwen3 embedding model with 1024 dimensions and 8K max input",
2519+
"context_length": 8192,
2520+
"tools_supported": false,
2521+
"input_modalities": ["text"]
2522+
}
2523+
],
2524+
"auth_methods": ["api_key"]
24772525
}
24782526
]

0 commit comments

Comments
 (0)