Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions crates/atlas-cersei/src/provider.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ pub fn openai_base_url(provider: &str) -> Option<&'static str> {
"cerebras" => "https://api.cerebras.ai/v1",
"perplexity" => "https://api.perplexity.ai",
"openrouter" => "https://openrouter.ai/api/v1",
"empero" => "https://free.empero.org/v1",
_ => return None,
})
}
Expand Down Expand Up @@ -96,6 +97,7 @@ pub fn default_model_for(provider: &str) -> Option<&'static str> {
"openrouter" => "anthropic/claude-sonnet-4.6",
"perplexity" => "sonar-reasoning-pro",
"cohere" => "command-a-03-2025",
"empero" => "glm-5.3-flash",
_ => return None,
})
}
Expand All @@ -108,6 +110,7 @@ mod tests {
fn base_url_known_and_unknown() {
assert_eq!(openai_base_url("openai"), Some("https://api.openai.com/v1"));
assert_eq!(openai_base_url("groq"), Some("https://api.groq.com/openai/v1"));
assert_eq!(openai_base_url("empero"), Some("https://free.empero.org/v1"));
// Anthropic is handled natively, not via the OpenAI-compat path.
assert_eq!(openai_base_url("anthropic"), None);
assert_eq!(openai_base_url("nonsense"), None);
Expand All @@ -133,6 +136,7 @@ mod tests {
fn build_provider_known_ok_unknown_err() {
assert!(build_provider("anthropic", "sk-test", "claude-opus-4-8").is_ok());
assert!(build_provider("openai", "sk-test", "gpt-5.1").is_ok());
assert!(build_provider("empero", "free", "glm-5.3-flash").is_ok());
// Google routes to the native Gemini provider (thought-signature support),
// not the OpenAI-compat client.
assert!(build_provider("google", "sk-test", "gemini-3.1-pro-preview").is_ok());
Expand Down
1 change: 1 addition & 0 deletions src-tauri/src/commands/byok.rs
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ const ENV_KEY_VARS: &[(&str, &[&str])] = &[
("huggingface", &["HF_TOKEN", "HUGGING_FACE_HUB_TOKEN", "HUGGINGFACE_API_KEY"]),
("jina", &["JINA_API_KEY"]),
("elevenlabs", &["ELEVENLABS_API_KEY", "ELEVEN_API_KEY", "XI_API_KEY"]),
("empero", &["EMPERO_API_KEY"]),
];

/// One env-imported key: which provider it maps to, the variable it came from,
Expand Down
2 changes: 2 additions & 0 deletions src-tauri/src/commands/modelchat.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ pub(super) fn provider_endpoint(provider: &str) -> Option<(ApiKind, &'static str
"cerebras" => (ApiKind::OpenAi, "https://api.cerebras.ai/v1"),
"perplexity" => (ApiKind::OpenAi, "https://api.perplexity.ai"),
"openrouter" => (ApiKind::OpenAi, "https://openrouter.ai/api/v1"),
"empero" => (ApiKind::OpenAi, "https://free.empero.org/v1"),
_ => return None,
})
}
Expand Down Expand Up @@ -360,6 +361,7 @@ fn fallback_models(provider: &str) -> Vec<&'static str> {
"openai" => vec!["gpt-4o", "gpt-4o-mini", "o3", "o4-mini"],
"google" => vec!["gemini-3.1-pro-preview", "gemini-2.5-pro", "gemini-2.5-flash"],
"cohere" => vec!["command-a-03-2025", "command-r-plus", "command-r"],
"empero" => vec!["glm-5.3-flash"],
_ => vec![],
}
}
Expand Down
1 change: 1 addition & 0 deletions src/features/settings/lib/model-catalog.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ const PREFERRED: Record<string, string[]> = {
openrouter: ["anthropic/claude-sonnet-4.6", "google/gemini-3.1-pro", "qwen/qwen3-coder"],
perplexity: ["sonar-reasoning-pro", "sonar-pro"],
cohere: ["command-a-03-2025"],
empero: ["glm-5.3-flash"],
};

const MAX_MODELS = 18;
Expand Down
9 changes: 9 additions & 0 deletions src/features/settings/lib/providers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,15 @@ export const PROVIDERS: ProviderDef[] = [
placeholder: "pplx-...",
chat: true,
},
{
id: "empero",
name: "Empero",
env: "EMPERO_API_KEY",
category: "Inference",
docsUrl: "https://free.empero.org",
placeholder: "free",
chat: true,
},

// ── Gateways / proxies ───────────────────────────────────────────
{
Expand Down
Loading