fix(ai): remove Grok Build 0.1 from built-in xAI model catalog (#9093)

Add grok-build-0.1 to XAI_BUILTIN_EXCLUDED_MODEL_IDS so the generated xAI
catalog only lists grok-4.3, grok-4.5 and grok-4.6. Update the exclusion
test and drop the thinking-level assertion for the removed model.

Co-authored-by: Jaaneek <Jaaneek@users.noreply.github.com>
This commit is contained in:
Milosz Jankiewicz 2026-09-04 10:18:26 +02:00 • committed by GitHub
parent 6aedd1066e
commit 0dbf2b76fe
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 4 additions and 3 deletions

View file

@ -419,6 +419,7 @@ const XAI_BUILTIN_EXCLUDED_MODEL_IDS = new Set([
"grok-3-fast",
"grok-4.20-0309-non-reasoning",
"grok-4.20-0309-reasoning",
"grok-build-0.1",
"grok-code-fast-1",
]);
const XAI_RESPONSES_COMPAT: OpenAIResponsesCompat = {
@ -876,8 +877,8 @@ function applyThinkingLevelMetadata(model: Model<any>): void {
) {
mergeThinkingLevelMap(model, { off: "none" });
}
// xAI models without verified effort options (e.g. grok-build-0.1) must not
// send the undocumented "none"/"minimal" efforts.
// xAI models without verified effort options must not send the undocumented
// "none"/"minimal" efforts.
if (model.provider === "xai" && model.api === "openai-responses" && model.thinkingLevelMap === undefined) {
mergeThinkingLevelMap(model, { off: null, minimal: null });
}

View file

@ -118,6 +118,7 @@ describe("xAI Responses provider", () => {
"grok-3-fast",
"grok-4.20-0309-non-reasoning",
"grok-4.20-0309-reasoning",
"grok-build-0.1",
"grok-code-fast-1",
]) {
expect(Object.keys(XAI_MODELS)).not.toContain(modelId);
@ -131,7 +132,6 @@ describe("xAI Responses provider", () => {
expect(getSupportedThinkingLevels(XAI_MODELS["grok-4.5"])).toEqual(["low", "medium", "high"]);
expect(getSupportedThinkingLevels(XAI_MODELS["grok-4.6"])).toEqual(["low", "medium", "high", "xhigh"]);
expect(getSupportedThinkingLevels(XAI_MODELS["grok-4.3"])).toEqual(["off", "low", "medium", "high"]);
expect(getSupportedThinkingLevels(XAI_MODELS["grok-build-0.1"])).toEqual(["low", "medium", "high"]);
});
it("uses /responses with bearer auth and xAI-compatible request fields", async () => {