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
2 changes: 1 addition & 1 deletion internal/providercatalog/catalog.go
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ var descriptors = []Descriptor{
openAICompat("github", "GitHub Models", "https://models.inference.ai.azure.com", "openai/gpt-4.1", []string{"GITHUB_TOKEN"}, "github-models"),
transportDescriptor("bedrock", "Amazon Bedrock", TransportBedrock, "https://bedrock-runtime.${AWS_REGION}.amazonaws.com", "anthropic.claude-3-5-sonnet-20241022-v2:0", []string{"AWS_ACCESS_KEY_ID", "AWS_PROFILE"}, []APIFormat{APIFormatBedrockConverse}, true),
transportDescriptor("vertex", "Vertex AI", TransportVertex, "https://aiplatform.googleapis.com", "gemini-2.5-pro", []string{"GOOGLE_APPLICATION_CREDENTIALS"}, []APIFormat{APIFormatVertexGenerateContent}, true),
oauthProvider(openAICompat("xai", "xAI", "https://api.x.ai/v1", "grok-4", []string{"XAI_API_KEY"}), false, true),
oauthProvider(openAICompat("xai", "xAI", "https://api.x.ai/v1", "grok-4.5", []string{"XAI_API_KEY"}), false, true),
Comment thread
coderabbitai[bot] marked this conversation as resolved.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[P2] Confirm grok-4.5 is a live model ID on api.x.ai before merging

This flips the xAI default from grok-4 to grok-4.5 (also in internal/providermodelcatalog/catalog.go). If grok-4.5 is not served by api.x.ai (or the ID differs, e.g. grok-4-5), every default xAI request 404s on first use. grok-4 is retained as "previous flagship" so a revert is trivial. Could not verify without API access.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @gnanam1990 for the review.

grok-4.5 is the live model ID on api.x.ai.
https://docs.x.ai/developers/models

image

@lfaoro lfaoro Jul 15, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

xAI /models endpoint is gated by token/credits but you can see the model ID via openrouter open endpoint.

curl -s https://openrouter.ai/api/v1/models \
  | jq '.data[] | select(.id | startswith("x-ai")) | {id, name}'

openAICompat("venice", "Venice AI", "https://api.venice.ai/api/v1", "qwen-2.5-qwq-32b", []string{"VENICE_API_KEY"}),
openAICompat("xiaomi-mimo", "Xiaomi MiMo", "https://api.mimo.xiaomi.com/openai/v1", "mimo-vl", []string{"MIMO_API_KEY", "XIAOMI_API_KEY"}, "xiaomi mimo"),
openAICompat("bankr", "Bankr", "https://api.bankr.bot/v1", "bankr-large", []string{"BANKR_API_KEY"}),
Expand Down
3 changes: 2 additions & 1 deletion internal/providermodelcatalog/catalog.go
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,8 @@ var curatedModels = map[string][]Model{
{ID: "mistral-ai/codestral-2501", Description: "coding model"},
},
"xai": {
{ID: "grok-4", Description: "catalog default"},
{ID: "grok-4.5", Description: "catalog default"},
{ID: "grok-4", Description: "previous flagship"},
{ID: "grok-3", Description: "general model"},
{ID: "grok-3-mini", Description: "fast reasoning model"},
{ID: "grok-code-fast-1", Description: "coding model"},
Expand Down
2 changes: 1 addition & 1 deletion internal/tui/onboarding_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1373,7 +1373,7 @@ func setupAtOAuthList(t *testing.T) model {
Visible: true,
Providers: []SetupProviderOption{
{ID: "openrouter", Name: "OpenRouter", RequiresAuth: true, EnvVar: "OPENROUTER_API_KEY"},
{ID: "xai", Name: "xAI", DefaultModel: "grok-4", RequiresAuth: true, EnvVar: "XAI_API_KEY"},
{ID: "xai", Name: "xAI", DefaultModel: "grok-4.5", RequiresAuth: true, EnvVar: "XAI_API_KEY"},
},
}})
m.width = 100
Expand Down
Loading