Skip to content

Commit f8f7e4d

Browse files
committed
refactor(provider): rename grok 4.6 identifiers to include 4.7
1 parent b771e27 commit f8f7e4d

2 files changed

Lines changed: 5 additions & 4 deletions

File tree

‎src/config/xai-providers.test.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ describe("xAI OAuth provider projection", () => {
2020
"grok-4.7",
2121
"grok-composer-2.5-fast",
2222
]);
23+
expect(models.filter((m) => m === "grok-4.7")).toHaveLength(1);
2324
expect(models[0]).toBe("grok-4.5");
2425
});
2526

‎src/provider/reasoning-effort.ts‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,8 @@ function isMuseSparkModel(model: string): boolean {
8383

8484
// grok-4.6 and grok-4.7 accept xhigh — the same ladder as CODEX_EFFORTS above;
8585
// grok-4.5 and composer stay on the unknown-model subset.
86-
const GROK_46_EFFORTS: readonly ReasoningEffort[] = CODEX_EFFORTS;
87-
const GROK_46_MODELS: readonly string[] = ["grok-4.6", "grok-4.7"];
86+
const GROK_46_AND_47_EFFORTS: readonly ReasoningEffort[] = CODEX_EFFORTS;
87+
const GROK_46_AND_47_MODELS: readonly string[] = ["grok-4.6", "grok-4.7"];
8888

8989
// GPT-6 Astra accepts low through max on both the OpenAI API and Codex surfaces.
9090
// Not ultra (gpt-5.6 Codex-only), not minimal, not none.
@@ -153,8 +153,8 @@ export function supportedEfforts(
153153
if (isKnownOpenAIReasoningModel(model)) {
154154
return [...DEFAULT_EFFORTS];
155155
}
156-
if (GROK_46_MODELS.includes(model)) {
157-
return [...GROK_46_EFFORTS];
156+
if (GROK_46_AND_47_MODELS.includes(model)) {
157+
return [...GROK_46_AND_47_EFFORTS];
158158
}
159159
if (GLM_53_MODELS.includes(model)) {
160160
return [...GLM_53_EFFORTS];

0 commit comments

Comments
 (0)