diff --git a/crates/ui-egui/src/agent_chat/agents.rs b/crates/ui-egui/src/agent_chat/agents.rs index 145b94579..a2b8eceba 100644 --- a/crates/ui-egui/src/agent_chat/agents.rs +++ b/crates/ui-egui/src/agent_chat/agents.rs @@ -305,6 +305,7 @@ pub const OPENAI_PRESETS: &[ApiPreset] = &[ ApiPreset { name: "LM Studio", base_url: "http://localhost:1234/v1" }, ApiPreset { name: "OpenClaw", base_url: "http://localhost:18789/v1" }, ApiPreset { name: "OpenAI", base_url: "https://api.openai.com/v1" }, + ApiPreset { name: "Mistral AI", base_url: "https://api.mistral.ai/v1" }, ApiPreset { name: "Mammouth AI", base_url: "https://api.mammouth.ai/v1" }, ApiPreset { name: "OpenCode Go", base_url: "https://opencode.ai/zen/go/v1" }, ApiPreset { name: "OpenRouter", base_url: "https://openrouter.ai/api/v1" }, @@ -467,6 +468,7 @@ mod tests { assert_eq!(Kind::Anthropic.id(), "anthropic"); assert!(presets(Protocol::OpenAi).iter().all(|p| !p.name.is_empty() && p.base_url.starts_with("http"))); assert!(presets(Protocol::OpenAi).iter().any(|p| p.name == "Mammouth AI" && key_safe_for(p.base_url))); + assert!(presets(Protocol::OpenAi).iter().any(|p| p.name == "Mistral AI" && p.base_url == "https://api.mistral.ai/v1")); assert!(presets(Protocol::Anthropic).iter().any(|p| p.base_url == "https://api.anthropic.com/v1")); } diff --git a/docs/agent-chat.md b/docs/agent-chat.md index c6dc94293..8ad282cb0 100644 --- a/docs/agent-chat.md +++ b/docs/agent-chat.md @@ -277,8 +277,9 @@ Grok Build also supports `XAI_API_KEY` for users who choose API authentication. - **Custom command:** any other program that speaks ACP on stdin and stdout, such as `my-agent --acp`. SolidCraft starts it directly, not through a shell. - **OpenAI-compatible API:** a preset (Ollama `http://localhost:11434/v1`, LM Studio - `http://localhost:1234/v1`, OpenClaw `http://localhost:18789/v1`, OpenAI, Mammouth AI - `https://api.mammouth.ai/v1`, OpenCode Go `https://opencode.ai/zen/go/v1`, OpenRouter + `http://localhost:1234/v1`, OpenClaw `http://localhost:18789/v1`, OpenAI, Mistral AI + `https://api.mistral.ai/v1`, Mammouth AI `https://api.mammouth.ai/v1`, + OpenCode Go `https://opencode.ai/zen/go/v1`, OpenRouter `https://openrouter.ai/api/v1`) or a custom URL, the model name, and an optional key. OpenCode Go models are routed to their endpoint by themselves (`/responses`, `/messages` or Gemini for those families, `/chat/completions` for the rest),