Skip to content

Commit a9b821d

Browse files
author
jack
committed
Add xAI to supported providers documentation
1 parent 98a75e7 commit a9b821d

3 files changed

Lines changed: 11 additions & 9 deletions

File tree

crates/goose/src/providers/xai.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,8 @@ impl XaiProvider {
7979
} else {
8080
format!("{}/", self.host)
8181
};
82-
let base_url = Url::parse(&host).map_err(|e| ProviderError::RequestFailed(format!("Invalid base URL: {e}")))?;
82+
let base_url = Url::parse(&host)
83+
.map_err(|e| ProviderError::RequestFailed(format!("Invalid base URL: {e}")))?;
8384
let url = base_url.join("chat/completions").map_err(|e| {
8485
ProviderError::RequestFailed(format!("Failed to construct endpoint URL: {e}"))
8586
})?;

documentation/docs/getting-started/providers.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ Goose relies heavily on tool calling capabilities and currently works best with
3333
| [OpenRouter](https://openrouter.ai/) | API gateway for unified access to various models with features like rate-limiting management. | `OPENROUTER_API_KEY` |
3434
| [Snowflake](https://docs.snowflake.com/user-guide/snowflake-cortex/aisql#choosing-a-model) | Access the latest models using Snowflake Cortex services, including Claude models. **Requires a Snowflake account and programmatic access token (PAT)**. | `SNOWFLAKE_HOST`, `SNOWFLAKE_TOKEN` |
3535
| [Venice AI](https://venice.ai/home) | Provides access to open source models like Llama, Mistral, and Qwen while prioritizing user privacy. **Requires an account and an [API key](https://docs.venice.ai/overview/guides/generating-api-key)**. | `VENICE_API_KEY`, `VENICE_HOST` (optional), `VENICE_BASE_PATH` (optional), `VENICE_MODELS_PATH` (optional) |
36+
| [xAI](https://x.ai/) | Access to xAI's Grok models including grok-3, grok-3-mini, and grok-3-fast with 131,072 token context window. | `XAI_API_KEY`, `XAI_HOST` (optional) |
3637

3738

3839
## Configure Provider

ui/desktop/src/components/settings/providers/modal/subcomponents/ProviderLogo.tsx

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -35,20 +35,20 @@ export default function ProviderLogo({ providerName }: ProviderLogoProps) {
3535
// Special handling for xAI logo
3636
const isXai = logoKey === 'xai';
3737
const imageStyle = isXai ? { filter: 'invert(1)', opacity: 0.9 } : {};
38-
38+
3939
// Use smaller size for xAI logo to fit better in circle
40-
const imageClassName = isXai
41-
? "w-8 h-8 object-contain" // Smaller size for xAI
42-
: "w-16 h-16 object-contain"; // Default size for others
40+
const imageClassName = isXai
41+
? 'w-8 h-8 object-contain' // Smaller size for xAI
42+
: 'w-16 h-16 object-contain'; // Default size for others
4343

4444
return (
4545
<div className="flex justify-center mb-2">
4646
<div className="w-12 h-12 bg-black rounded-full overflow-hidden flex items-center justify-center">
47-
<img
48-
src={logo}
49-
alt={`${providerName} logo`}
47+
<img
48+
src={logo}
49+
alt={`${providerName} logo`}
5050
className={imageClassName}
51-
style={imageStyle}
51+
style={imageStyle}
5252
/>
5353
</div>
5454
</div>

0 commit comments

Comments
 (0)