Latest Threat Research:SANDWORM_MODE: Shai-Hulud-Style npm Worm Hijacks CI Workflows and Poisons AI Toolchains.Details
Socket
Book a DemoInstallSign in
Socket

@ai-sdk/xai

Package Overview
Dependencies
Maintainers
3
Versions
307
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ai-sdk/xai - npm Package Compare versions

Comparing version
3.0.58
to
3.0.59
+6
-0
CHANGELOG.md
# @ai-sdk/xai
## 3.0.59
### Patch Changes
- 8641667: Added `resolution` provider option (`"1k"` or `"2k"`) for xAI image models, enabling higher resolution output for grok-imagine models.
## 3.0.58

@@ -4,0 +10,0 @@

+4
-0

@@ -81,2 +81,6 @@ import { z } from 'zod/v4';

sync_mode: z.ZodOptional<z.ZodBoolean>;
resolution: z.ZodOptional<z.ZodEnum<{
"1k": "1k";
"2k": "2k";
}>>;
}, z.core.$strip>;

@@ -83,0 +87,0 @@ type XaiImageModelOptions = z.infer<typeof xaiImageModelOptions>;

@@ -81,2 +81,6 @@ import { z } from 'zod/v4';

sync_mode: z.ZodOptional<z.ZodBoolean>;
resolution: z.ZodOptional<z.ZodEnum<{
"1k": "1k";
"2k": "2k";
}>>;
}, z.core.$strip>;

@@ -83,0 +87,0 @@ type XaiImageModelOptions = z.infer<typeof xaiImageModelOptions>;

+5
-5
{
"name": "@ai-sdk/xai",
"version": "3.0.58",
"version": "3.0.59",
"license": "Apache-2.0",

@@ -33,4 +33,4 @@ "sideEffects": false,

"@ai-sdk/openai-compatible": "2.0.30",
"@ai-sdk/provider": "3.0.8",
"@ai-sdk/provider-utils": "4.0.15"
"@ai-sdk/provider-utils": "4.0.15",
"@ai-sdk/provider": "3.0.8"
},

@@ -42,4 +42,4 @@ "devDependencies": {

"zod": "3.25.76",
"@vercel/ai-tsconfig": "0.0.0",
"@ai-sdk/test-server": "1.0.3"
"@ai-sdk/test-server": "1.0.3",
"@vercel/ai-tsconfig": "0.0.0"
},

@@ -46,0 +46,0 @@ "peerDependencies": {

@@ -126,2 +126,6 @@ import { ImageModelV3, SharedV3Warning } from '@ai-sdk/provider';

if (xaiOptions?.resolution != null) {
body.resolution = xaiOptions.resolution;
}
if (imageUrl != null) {

@@ -128,0 +132,0 @@ body.image = { url: imageUrl, type: 'image_url' };

@@ -7,4 +7,5 @@ import { z } from 'zod/v4';

sync_mode: z.boolean().optional(),
resolution: z.enum(['1k', '2k']).optional(),
});
export type XaiImageModelOptions = z.infer<typeof xaiImageModelOptions>;

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display