diff --git a/docs/concepts/model-providers.md b/docs/concepts/model-providers.md index db155a215a16..21f871914321 100644 --- a/docs/concepts/model-providers.md +++ b/docs/concepts/model-providers.md @@ -298,7 +298,7 @@ messages and normalizes `stats.cached` into `cacheRead`; legacy | Venice | `venice` | `VENICE_API_KEY` | - | | Vercel AI Gateway | `vercel-ai-gateway` | `AI_GATEWAY_API_KEY` | `vercel-ai-gateway/anthropic/claude-opus-4.6` | | Volcano Engine (Doubao) | `volcengine` / `volcengine-plan` | `VOLCANO_ENGINE_API_KEY` | `volcengine-plan/ark-code-latest` | -| xAI | `xai` | SuperGrok/X Premium OAuth or `XAI_API_KEY` | OAuth: `xai/auto`; API key: `xai/grok-4.3` | +| xAI | `xai` | SuperGrok/X Premium OAuth or `XAI_API_KEY` | OAuth: `xai/auto`; API key: `xai/grok-4.5` | | Xiaomi | `xiaomi` / `xiaomi-token-plan` | `XIAOMI_API_KEY` / `XIAOMI_TOKEN_PLAN_API_KEY` | `xiaomi/mimo-v2.5` / `xiaomi-token-plan/mimo-v2.5-pro` | #### Quirks worth knowing @@ -317,7 +317,7 @@ messages and normalizes `stats.cached` into `cacheRead`; legacy Model ids use a `nvidia//` namespace (for example `nvidia/nvidia/nemotron-...`); pickers preserve the literal `/` composition while the canonical key sent to the API stays single-prefixed. - Uses the xAI Responses path. The recommended path is SuperGrok/X Premium OAuth; fresh setup selects `xai/auto`, which follows xAI's authenticated default model without an OpenClaw update. Existing concrete model ids stay pinned. API keys still work via `XAI_API_KEY` or plugin config and keep `grok-4.3` as the regional-safe setup default. Grok `web_search` reuses the same auth profile before API-key fallback. Older `/fast` and `params.fastMode: true` configurations still resolve through xAI's Grok 4.3 compatibility redirects, but new configurations should select a current model directly. `tool_stream` defaults on; disable via `agents.defaults.models["xai/"].params.tool_stream=false`. + Uses the xAI Responses path. The recommended path is SuperGrok/X Premium OAuth; fresh setup selects `xai/auto`, which follows xAI's authenticated default model without an OpenClaw update. Existing concrete model ids stay pinned. API keys still work via `XAI_API_KEY` or plugin config and use `grok-4.5` as the setup default. Grok `web_search` reuses the same auth profile before API-key fallback. Older `/fast` and `params.fastMode: true` configurations still resolve through xAI's Grok 4.3 compatibility redirects, but new configurations should select a current model directly. `tool_stream` defaults on; disable via `agents.defaults.models["xai/"].params.tool_stream=false`. diff --git a/docs/gateway/configuration-reference.md b/docs/gateway/configuration-reference.md index 75da7af69dee..d34e4abd3f6e 100644 --- a/docs/gateway/configuration-reference.md +++ b/docs/gateway/configuration-reference.md @@ -396,7 +396,7 @@ cannot be read, account-wide exposure fails closed. - `timeoutSeconds`: scrape request timeout in seconds (default: `60`). - `plugins.entries.xai.config.xSearch`: xAI X Search (Grok web search) settings. - `enabled`: enable the X Search provider. - - `model`: Grok model to use for search (e.g. `"grok-4.3"`). + - `model`: Grok model to use for search (e.g. `"grok-4.5"`). - `plugins.entries.memory-core.config.dreaming`: memory dreaming settings. See [Dreaming](/concepts/dreaming) for phases and thresholds. - `enabled`: master dreaming switch (default `false`). - `frequency`: cron cadence for each full dreaming sweep (`"0 3 * * *"` by default). diff --git a/docs/providers/xai.md b/docs/providers/xai.md index 0bb4aa3d2edc..6badec874c18 100644 --- a/docs/providers/xai.md +++ b/docs/providers/xai.md @@ -56,8 +56,8 @@ OAuth client. API-key setup still works for xAI Console keys and for media surfaces - that need key-backed provider config. It keeps Grok 4.3 as the - regional-safe setup default: + that need key-backed provider config. It uses Grok 4.5 as the setup + default: ```bash openclaw models auth login --provider xai --method api-key @@ -122,8 +122,8 @@ see [legacy compatibility and moving aliases](#legacy-compatibility-and-moving-a Use `xai/auto` to follow xAI's authenticated OAuth default, or select a concrete -id such as `xai/grok-4.5` to remain pinned. API-key setup keeps Grok 4.3 as the -regional-safe default; `grok-build-0.1` and both dated Grok 4.20 variants remain +id such as `xai/grok-4.5` to remain pinned. API-key setup uses Grok 4.5 by +default; `grok-build-0.1`, Grok 4.3, and both dated Grok 4.20 variants remain selectable. @@ -537,7 +537,7 @@ stale context metadata on active 4.20 rows. It does not pin active 4.20 | Key | Type | Default | Description | | ----------------- | ------- | ------------------------- | ------------------------------------------------ | | `enabled` | boolean | Automatic for xAI models | Disable, or opt in for a known non-xAI provider | - | `model` | string | `grok-4.3` | Model used for x_search requests | + | `model` | string | `grok-4.5` | Model used for x_search requests | | `baseUrl` | string | - | xAI Responses base URL override | | `inlineCitations` | boolean | - | Include inline citations in results | | `maxTurns` | number | - | Maximum conversation turns | @@ -552,7 +552,7 @@ stale context metadata on active 4.20 rows. It does not pin active 4.20 config: { xSearch: { enabled: true, - model: "grok-4.3", + model: "grok-4.5", baseUrl: "https://api.x.ai/v1", inlineCitations: true, }, @@ -574,7 +574,7 @@ stale context metadata on active 4.20 rows. It does not pin active 4.20 | Key | Type | Default | Description | | ---------------- | ------- | ------------------------ | ------------------------------------------------ | | `enabled` | boolean | Automatic for xAI models | Disable, or opt in for a known non-xAI provider | - | `model` | string | `grok-4.3` | Model used for code execution requests | + | `model` | string | `grok-4.5` | Model used for code execution requests | | `maxTurns` | number | - | Maximum conversation turns | | `timeoutSeconds` | number | `30` | Request timeout in seconds | @@ -590,7 +590,7 @@ stale context metadata on active 4.20 rows. It does not pin active 4.20 config: { codeExecution: { enabled: true, - model: "grok-4.3", + model: "grok-4.5", }, }, }, diff --git a/docs/tools/code-execution.md b/docs/tools/code-execution.md index 5d099322bd07..942f3e8ec65f 100644 --- a/docs/tools/code-execution.md +++ b/docs/tools/code-execution.md @@ -21,7 +21,7 @@ registered by the bundled `xai` plugin under the `tools` contract. | Tool name | `code_execution` | | Provider plugin | `xai` (bundled, `enabledByDefault: true`) | | Auth | xAI auth profile, `XAI_API_KEY`, or `plugins.entries.xai.config.webSearch.apiKey` | -| Default model | `grok-4.3` | +| Default model | `grok-4.5` | | Default timeout | 30 seconds | | Default `maxTurns` | unset (xAI applies its own internal limit) | @@ -100,7 +100,7 @@ For local execution, use [`exec`](/tools/exec) instead. config: { codeExecution: { enabled: true, // required for a known non-xAI model provider - model: "grok-4.3", // override the default xAI code-execution model + model: "grok-4.5", // optional explicit model pin maxTurns: 2, // optional cap on internal tool turns timeoutSeconds: 30, // request timeout (default: 30) }, diff --git a/docs/tools/web.md b/docs/tools/web.md index 06601b08b778..80fd433de04f 100644 --- a/docs/tools/web.md +++ b/docs/tools/web.md @@ -532,7 +532,7 @@ every provider. xAI credentials are always required. config: { xSearch: { enabled: true, // required for a known non-xAI model provider - model: "grok-4.3", + model: "grok-4.5", baseUrl: "https://api.x.ai/v1", // optional, overrides webSearch.baseUrl inlineCitations: false, maxTurns: 2, diff --git a/extensions/xai/code-execution.test.ts b/extensions/xai/code-execution.test.ts index fd2004736abc..38436871bddd 100644 --- a/extensions/xai/code-execution.test.ts +++ b/extensions/xai/code-execution.test.ts @@ -155,7 +155,7 @@ describe("xai code_execution tool", () => { expect(mockFetch).toHaveBeenCalled(); expect(firstFetchUrl(mockFetch)).toContain("api.x.ai/v1/responses"); const body = parseFirstRequestBody(mockFetch); - expect(body.model).toBe("grok-4.3"); + expect(body.model).toBe("grok-4.5"); expect(body.store).toBe(false); expect(body.reasoning).toEqual({ effort: "low" }); expect(body.max_turns).toBe(2); diff --git a/extensions/xai/doctor-contract-api.test.ts b/extensions/xai/doctor-contract-api.test.ts index 57ee81e5b563..50291958f4ef 100644 --- a/extensions/xai/doctor-contract-api.test.ts +++ b/extensions/xai/doctor-contract-api.test.ts @@ -64,8 +64,8 @@ describe("xAI doctor contract", () => { expect(result.changes).toHaveLength(4); expect(result.config).not.toBe(config); expect(result.config.plugins?.entries?.xai?.config).toEqual({ - webSearch: { model: "grok-4.3", timeoutSeconds: 60 }, - xSearch: { model: "grok-4.3", inlineCitations: true }, + webSearch: { model: "grok-4.5", timeoutSeconds: 60 }, + xSearch: { model: "grok-4.5", inlineCitations: true }, codeExecution: { model: "grok-build-0.1", maxTurns: 2 }, }); expect(result.config.tools?.web).toEqual(config.tools?.web); diff --git a/extensions/xai/doctor-contract-api.ts b/extensions/xai/doctor-contract-api.ts index da19b81a7306..c710894a3ee0 100644 --- a/extensions/xai/doctor-contract-api.ts +++ b/extensions/xai/doctor-contract-api.ts @@ -1,7 +1,7 @@ // Xai doctor contract repairs plugin-owned model configuration. import type { OpenClawConfig } from "openclaw/plugin-sdk/config-contracts"; import { asObjectRecord } from "openclaw/plugin-sdk/runtime-doctor-migrations"; -import { isLegacyXaiBuiltinModel } from "./model-definitions.js"; +import { isLegacyXaiBuiltinModel, XAI_DEFAULT_MODEL_ID } from "./model-definitions.js"; type LegacyConfigRule = { path: Array; @@ -37,17 +37,17 @@ const PLUGIN_MODEL_MIGRATIONS: PluginModelMigration[] = [ { path: ["plugins", "entries", "xai", "config", "webSearch"], retiredModels: RETIRED_REASONING_MODELS, - targetModel: "grok-4.3", + targetModel: XAI_DEFAULT_MODEL_ID, }, { path: ["plugins", "entries", "xai", "config", "codeExecution"], retiredModels: RETIRED_REASONING_MODELS, - targetModel: "grok-4.3", + targetModel: XAI_DEFAULT_MODEL_ID, }, { path: ["plugins", "entries", "xai", "config", "xSearch"], retiredModels: RETIRED_NON_REASONING_MODELS, - targetModel: "grok-4.3", + targetModel: XAI_DEFAULT_MODEL_ID, }, ...[ ["plugins", "entries", "xai", "config", "webSearch"], diff --git a/extensions/xai/model-definitions.ts b/extensions/xai/model-definitions.ts index 09749e3bdd29..1a8f4b4ac228 100644 --- a/extensions/xai/model-definitions.ts +++ b/extensions/xai/model-definitions.ts @@ -13,7 +13,7 @@ export const XAI_DEFAULT_CONTEXT_WINDOW = 1_000_000; const XAI_GROK_45_CONTEXT_WINDOW = 500_000; const XAI_CODE_CONTEXT_WINDOW = 256_000; export const XAI_DEFAULT_MAX_TOKENS = 64_000; -export const XAI_DEFAULT_MODEL_ID = "grok-4.3"; +export const XAI_DEFAULT_MODEL_ID = "grok-4.5"; type XaiCost = ModelDefinitionConfig["cost"]; @@ -254,12 +254,12 @@ export function buildXaiModelDefinition(): ModelDefinitionConfig { return toModelDefinition( XAI_MODEL_CATALOG.find((entry) => entry.id === XAI_DEFAULT_MODEL_ID) ?? { id: XAI_DEFAULT_MODEL_ID, - name: "Grok 4.3", + name: "Grok 4.5", reasoning: true, input: ["text", "image"], - contextWindow: XAI_DEFAULT_CONTEXT_WINDOW, + contextWindow: XAI_GROK_45_CONTEXT_WINDOW, maxTokens: XAI_DEFAULT_MAX_TOKENS, - cost: XAI_GROK_43_COST, + cost: XAI_GROK_45_COST, }, ); } diff --git a/extensions/xai/onboard.test.ts b/extensions/xai/onboard.test.ts index 6aa5e10fefbd..083bdeefd023 100644 --- a/extensions/xai/onboard.test.ts +++ b/extensions/xai/onboard.test.ts @@ -22,7 +22,7 @@ describe("xai onboard", () => { const cfg = applyXaiConfig({}); expect(cfg.models?.providers?.xai?.baseUrl).toBe("https://api.x.ai/v1"); expect(cfg.models?.providers?.xai?.api).toBe("openai-responses"); - expect(XAI_DEFAULT_MODEL_REF).toBe("xai/grok-4.3"); + expect(XAI_DEFAULT_MODEL_REF).toBe("xai/grok-4.5"); expect(resolveAgentModelPrimaryValue(cfg.agents?.defaults?.model)).toBe(XAI_DEFAULT_MODEL_REF); }); diff --git a/extensions/xai/src/x-search-shared.ts b/extensions/xai/src/x-search-shared.ts index 4822ad8bd791..e63b3c0b2e87 100644 --- a/extensions/xai/src/x-search-shared.ts +++ b/extensions/xai/src/x-search-shared.ts @@ -137,7 +137,7 @@ export async function requestXaiXSearch(params: { inputText: params.options.query, tools: [buildXSearchTool(params.options)], maxTurns: params.maxTurns, - reasoningEffort: params.model === XAI_DEFAULT_X_SEARCH_MODEL ? "none" : undefined, + reasoningEffort: params.model === XAI_DEFAULT_X_SEARCH_MODEL ? "low" : undefined, }), errorLabel: "xAI", }, diff --git a/extensions/xai/web-search.test.ts b/extensions/xai/web-search.test.ts index d5e9c1452601..9eab88e938e7 100644 --- a/extensions/xai/web-search.test.ts +++ b/extensions/xai/web-search.test.ts @@ -244,7 +244,7 @@ describe("xai web search config resolution", () => { it("prefers configured api keys and resolves grok scoped defaults", () => { expect(resolveXaiWebSearchCredential({ grok: { apiKey: "xai-secret" } })).toBe("xai-secret"); - expect(resolveXaiWebSearchModel()).toBe("grok-4.3"); + expect(resolveXaiWebSearchModel()).toBe("grok-4.5"); expect(resolveXaiInlineCitations()).toBe(false); }); @@ -644,8 +644,8 @@ describe("xai web search config resolution", () => { }); it("uses default model when not specified", () => { - expect(resolveXaiWebSearchModel({})).toBe("grok-4.3"); - expect(resolveXaiWebSearchModel(undefined)).toBe("grok-4.3"); + expect(resolveXaiWebSearchModel({})).toBe("grok-4.5"); + expect(resolveXaiWebSearchModel(undefined)).toBe("grok-4.5"); }); it("uses a Grok-specific 60s default timeout while preserving overrides", () => { @@ -676,7 +676,7 @@ describe("xai web search config resolution", () => { expect(firstFetchUrl(mockFetch)).toBe("https://api.x.ai/proxy/v1/responses"); expect(firstFetchBody(mockFetch)).toMatchObject({ - model: "grok-4.3", + model: "grok-4.5", store: false, reasoning: { effort: "low" }, tools: [{ type: "web_search" }], diff --git a/extensions/xai/x-search.live.test.ts b/extensions/xai/x-search.live.test.ts index 8005d4fd71a0..3bbd7a399353 100644 --- a/extensions/xai/x-search.live.test.ts +++ b/extensions/xai/x-search.live.test.ts @@ -67,7 +67,7 @@ describeLive("xai x_search live", () => { expect(details.error, details.message).toBeUndefined(); expect(details.provider).toBe("xai"); - expect(details.model).toBe("grok-4.3"); + expect(details.model).toBe("grok-4.5"); expect(details.content?.trim().length ?? 0).toBeGreaterThan(0); const citationCount = diff --git a/extensions/xai/x-search.test.ts b/extensions/xai/x-search.test.ts index 476576d9f91c..a54b44efbaa0 100644 --- a/extensions/xai/x-search.test.ts +++ b/extensions/xai/x-search.test.ts @@ -291,9 +291,9 @@ describe("xai x_search tool", () => { expect(mockFetch).toHaveBeenCalled(); expect(firstFetchUrl(mockFetch)).toContain("api.x.ai/v1/responses"); const body = parseFirstRequestBody(mockFetch); - expect(body.model).toBe("grok-4.3"); + expect(body.model).toBe("grok-4.5"); expect(body.store).toBe(false); - expect(body.reasoning).toEqual({ effort: "none" }); + expect(body.reasoning).toEqual({ effort: "low" }); expect(body.max_turns).toBe(2); expect(body.tools).toEqual([ { diff --git a/extensions/xai/xai.live.test.ts b/extensions/xai/xai.live.test.ts index 9293a5662491..90f6da06f656 100644 --- a/extensions/xai/xai.live.test.ts +++ b/extensions/xai/xai.live.test.ts @@ -222,7 +222,7 @@ describeLive("xai plugin live", () => { usedCodeExecution?: boolean; }; - expect(details.model).toBe("grok-4.3"); + expect(details.model).toBe("grok-4.5"); expect(details.usedCodeExecution).toBe(true); expect(details.content).toContain("42"); }); @@ -257,7 +257,7 @@ describeLive("xai plugin live", () => { usedCodeExecution?: boolean; }; - expect(details.model).toBe("grok-4.3"); + expect(details.model).toBe("grok-4.5"); expect(details.usedCodeExecution).toBe(true); expect(details.content).toContain("5050"); });