@ai-sdk/groq 4.0.0-beta.9 → 4.0.0-canary.36

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,241 @@
1
1
  # @ai-sdk/groq
2
2
 
3
+ ## 4.0.0-canary.36
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [5463d0d]
8
+ - @ai-sdk/provider-utils@5.0.0-canary.32
9
+ - @ai-sdk/provider@4.0.0-canary.16
10
+
11
+ ## 4.0.0-canary.35
12
+
13
+ ### Patch Changes
14
+
15
+ - 0c4c275: trigger initial canary release
16
+ - Updated dependencies [0c4c275]
17
+ - @ai-sdk/provider-utils@5.0.0-canary.31
18
+ - @ai-sdk/provider@4.0.0-canary.15
19
+
20
+ ## 4.0.0-beta.34
21
+
22
+ ### Major Changes
23
+
24
+ - 04e9009: chore: make provider implementations code patterns more consistent, including renaming certain exported symbols
25
+
26
+ For all externally exported symbols that were renamed, the old names continue to work via deprecated aliases.
27
+
28
+ ### Patch Changes
29
+
30
+ - Updated dependencies [08d2129]
31
+ - @ai-sdk/provider-utils@5.0.0-beta.30
32
+
33
+ ## 4.0.0-beta.33
34
+
35
+ ### Patch Changes
36
+
37
+ - 9bd6512: feat(provider): change file part data property to be tagged with a type and remove the image part type
38
+ - 258c093: chore: ensure consistent import handling and avoid import duplicates or cycles
39
+ - Updated dependencies [9bd6512]
40
+ - Updated dependencies [258c093]
41
+ - Updated dependencies [b6783da]
42
+ - @ai-sdk/provider-utils@5.0.0-beta.29
43
+ - @ai-sdk/provider@4.0.0-beta.14
44
+
45
+ ## 4.0.0-beta.32
46
+
47
+ ### Patch Changes
48
+
49
+ - 9f0e36c: trigger release for all packages after provenance setup
50
+ - Updated dependencies [9f0e36c]
51
+ - @ai-sdk/provider@4.0.0-beta.13
52
+ - @ai-sdk/provider-utils@5.0.0-beta.28
53
+
54
+ ## 4.0.0-beta.31
55
+
56
+ ### Patch Changes
57
+
58
+ - 58a2ad7: fix: more precise default message for tool execution denial
59
+ - Updated dependencies [785fe16]
60
+ - Updated dependencies [67df0a0]
61
+ - Updated dependencies [befb78c]
62
+ - Updated dependencies [0458559]
63
+ - Updated dependencies [5852c0a]
64
+ - Updated dependencies [fc92055]
65
+ - @ai-sdk/provider-utils@5.0.0-beta.27
66
+
67
+ ## 4.0.0-beta.30
68
+
69
+ ### Patch Changes
70
+
71
+ - Updated dependencies [2e98477]
72
+ - @ai-sdk/provider-utils@5.0.0-beta.26
73
+
74
+ ## 4.0.0-beta.29
75
+
76
+ ### Patch Changes
77
+
78
+ - Updated dependencies [eea8d98]
79
+ - @ai-sdk/provider-utils@5.0.0-beta.25
80
+
81
+ ## 4.0.0-beta.28
82
+
83
+ ### Patch Changes
84
+
85
+ - f807e45: Extract shared `StreamingToolCallTracker` class into `@ai-sdk/provider-utils` to deduplicate streaming tool call handling across OpenAI-compatible providers. Also adds missing `generateId()` fallback for `toolCallId` in Alibaba's `doGenerate` path and ensures all providers finalize unfinished tool calls during stream flush.
86
+ - Updated dependencies [f807e45]
87
+ - @ai-sdk/provider-utils@5.0.0-beta.24
88
+
89
+ ## 4.0.0-beta.27
90
+
91
+ ### Patch Changes
92
+
93
+ - Updated dependencies [350ea38]
94
+ - @ai-sdk/provider-utils@5.0.0-beta.23
95
+
96
+ ## 4.0.0-beta.26
97
+
98
+ ### Patch Changes
99
+
100
+ - Updated dependencies [083947b]
101
+ - @ai-sdk/provider-utils@5.0.0-beta.22
102
+
103
+ ## 4.0.0-beta.25
104
+
105
+ ### Patch Changes
106
+
107
+ - Updated dependencies [add1126]
108
+ - @ai-sdk/provider-utils@5.0.0-beta.21
109
+
110
+ ## 4.0.0-beta.24
111
+
112
+ ### Patch Changes
113
+
114
+ - b3976a2: Add workflow serialization support to all provider models.
115
+
116
+ **`@ai-sdk/provider-utils`:** New `serializeModel()` helper that extracts only serializable properties from a model instance, filtering out functions and objects containing functions. Third-party provider authors can use this to add workflow support to their own models.
117
+
118
+ **All providers:** `headers` is now optional in provider config types. This is non-breaking — existing code that passes `headers` continues to work. Custom provider implementations that construct model configs manually can now omit `headers`, which is useful when models are deserialized from a workflow step boundary where auth is provided separately.
119
+
120
+ All provider model classes now include `WORKFLOW_SERIALIZE` and `WORKFLOW_DESERIALIZE` static methods, enabling them to cross workflow step boundaries without serialization errors.
121
+
122
+ - Updated dependencies [b3976a2]
123
+ - Updated dependencies [ff5eba1]
124
+ - @ai-sdk/provider-utils@5.0.0-beta.20
125
+ - @ai-sdk/provider@4.0.0-beta.12
126
+
127
+ ## 4.0.0-beta.23
128
+
129
+ ### Major Changes
130
+
131
+ - ef992f8: Remove CommonJS exports from all packages. All packages are now ESM-only (`"type": "module"`). Consumers using `require()` must switch to ESM `import` syntax.
132
+
133
+ ### Patch Changes
134
+
135
+ - Updated dependencies [ef992f8]
136
+ - @ai-sdk/provider@4.0.0-beta.11
137
+ - @ai-sdk/provider-utils@5.0.0-beta.19
138
+
139
+ ## 4.0.0-beta.22
140
+
141
+ ### Patch Changes
142
+
143
+ - 90e2d8a: chore: fix unused vars not being flagged by our lint tooling
144
+ - Updated dependencies [90e2d8a]
145
+ - @ai-sdk/provider-utils@5.0.0-beta.18
146
+
147
+ ## 4.0.0-beta.21
148
+
149
+ ### Patch Changes
150
+
151
+ - Updated dependencies [3ae1786]
152
+ - @ai-sdk/provider-utils@5.0.0-beta.17
153
+
154
+ ## 4.0.0-beta.20
155
+
156
+ ### Patch Changes
157
+
158
+ - Updated dependencies [176466a]
159
+ - @ai-sdk/provider@4.0.0-beta.10
160
+ - @ai-sdk/provider-utils@5.0.0-beta.16
161
+
162
+ ## 4.0.0-beta.19
163
+
164
+ ### Patch Changes
165
+
166
+ - Updated dependencies [e311194]
167
+ - @ai-sdk/provider@4.0.0-beta.9
168
+ - @ai-sdk/provider-utils@5.0.0-beta.15
169
+
170
+ ## 4.0.0-beta.18
171
+
172
+ ### Patch Changes
173
+
174
+ - Updated dependencies [34bd95d]
175
+ - Updated dependencies [008271d]
176
+ - @ai-sdk/provider@4.0.0-beta.8
177
+ - @ai-sdk/provider-utils@5.0.0-beta.14
178
+
179
+ ## 4.0.0-beta.17
180
+
181
+ ### Patch Changes
182
+
183
+ - Updated dependencies [b0c2869]
184
+ - Updated dependencies [7e26e81]
185
+ - @ai-sdk/provider-utils@5.0.0-beta.13
186
+
187
+ ## 4.0.0-beta.16
188
+
189
+ ### Patch Changes
190
+
191
+ - Updated dependencies [46d1149]
192
+ - @ai-sdk/provider-utils@5.0.0-beta.12
193
+
194
+ ## 4.0.0-beta.15
195
+
196
+ ### Patch Changes
197
+
198
+ - 6fd51c0: fix(provider): preserve error type prefix in getErrorMessage
199
+ - Updated dependencies [6fd51c0]
200
+ - @ai-sdk/provider-utils@5.0.0-beta.11
201
+ - @ai-sdk/provider@4.0.0-beta.7
202
+
203
+ ## 4.0.0-beta.14
204
+
205
+ ### Patch Changes
206
+
207
+ - c29a26f: feat(provider): add support for provider references and uploading files as supported per provider
208
+ - Updated dependencies [c29a26f]
209
+ - @ai-sdk/provider-utils@5.0.0-beta.10
210
+ - @ai-sdk/provider@4.0.0-beta.6
211
+
212
+ ## 4.0.0-beta.13
213
+
214
+ ### Patch Changes
215
+
216
+ - 38fc777: Add AI Gateway hint to provider READMEs
217
+
218
+ ## 4.0.0-beta.12
219
+
220
+ ### Patch Changes
221
+
222
+ - Updated dependencies [2e17091]
223
+ - @ai-sdk/provider-utils@5.0.0-beta.9
224
+
225
+ ## 4.0.0-beta.11
226
+
227
+ ### Patch Changes
228
+
229
+ - Updated dependencies [986c6fd]
230
+ - Updated dependencies [493295c]
231
+ - @ai-sdk/provider-utils@5.0.0-beta.8
232
+
233
+ ## 4.0.0-beta.10
234
+
235
+ ### Patch Changes
236
+
237
+ - 7bf717f: feat: Groq support for performance service tier
238
+
3
239
  ## 4.0.0-beta.9
4
240
 
5
241
  ### Patch Changes
package/README.md CHANGED
@@ -3,6 +3,8 @@
3
3
  The **[Groq provider](https://ai-sdk.dev/providers/ai-sdk-providers/groq)** for the [AI SDK](https://ai-sdk.dev/docs)
4
4
  contains language model support for the Groq chat and completion APIs, transcription support, and browser search tool.
5
5
 
6
+ > **Deploying to Vercel?** With Vercel's AI Gateway you can access Groq (and hundreds of models from other providers) — no additional packages, API keys, or extra cost. [Get started with AI Gateway](https://vercel.com/ai-gateway).
7
+
6
8
  ## Setup
7
9
 
8
10
  The Groq provider is available in the `@ai-sdk/groq` module. You can install it with
package/dist/index.d.ts CHANGED
@@ -4,7 +4,7 @@ import { InferSchema, FetchFunction } from '@ai-sdk/provider-utils';
4
4
  import { z } from 'zod/v4';
5
5
 
6
6
  type GroqChatModelId = 'gemma2-9b-it' | 'llama-3.1-8b-instant' | 'llama-3.3-70b-versatile' | 'meta-llama/llama-guard-4-12b' | 'openai/gpt-oss-120b' | 'openai/gpt-oss-20b' | 'deepseek-r1-distill-llama-70b' | 'meta-llama/llama-4-maverick-17b-128e-instruct' | 'meta-llama/llama-4-scout-17b-16e-instruct' | 'meta-llama/llama-prompt-guard-2-22m' | 'meta-llama/llama-prompt-guard-2-86m' | 'moonshotai/kimi-k2-instruct-0905' | 'qwen/qwen3-32b' | 'llama-guard-3-8b' | 'llama3-70b-8192' | 'llama3-8b-8192' | 'mixtral-8x7b-32768' | 'qwen-qwq-32b' | 'qwen-2.5-32b' | 'deepseek-r1-distill-qwen-32b' | (string & {});
7
- declare const groqLanguageModelOptions: z.ZodObject<{
7
+ declare const groqLanguageModelChatOptions: z.ZodObject<{
8
8
  reasoningFormat: z.ZodOptional<z.ZodEnum<{
9
9
  parsed: "parsed";
10
10
  raw: "raw";
@@ -23,11 +23,12 @@ declare const groqLanguageModelOptions: z.ZodObject<{
23
23
  strictJsonSchema: z.ZodOptional<z.ZodBoolean>;
24
24
  serviceTier: z.ZodOptional<z.ZodEnum<{
25
25
  on_demand: "on_demand";
26
+ performance: "performance";
26
27
  flex: "flex";
27
28
  auto: "auto";
28
29
  }>>;
29
30
  }, z.core.$strip>;
30
- type GroqLanguageModelOptions = z.infer<typeof groqLanguageModelOptions>;
31
+ type GroqLanguageModelChatOptions = z.infer<typeof groqLanguageModelChatOptions>;
31
32
 
32
33
  type GroqTranscriptionModelId = 'whisper-large-v3-turbo' | 'whisper-large-v3' | (string & {});
33
34
  declare const groqTranscriptionModelOptions: _ai_sdk_provider_utils.LazySchema<{
@@ -40,7 +41,7 @@ declare const groqTranscriptionModelOptions: _ai_sdk_provider_utils.LazySchema<{
40
41
  type GroqTranscriptionModelOptions = InferSchema<typeof groqTranscriptionModelOptions>;
41
42
 
42
43
  declare const groqTools: {
43
- browserSearch: _ai_sdk_provider_utils.ProviderToolFactory<{}, {}>;
44
+ browserSearch: _ai_sdk_provider_utils.ProviderExecutedToolFactory<{}, {}, {}, {}>;
44
45
  };
45
46
 
46
47
  interface GroqProvider extends ProviderV4 {
@@ -105,8 +106,8 @@ declare const groq: GroqProvider;
105
106
  *
106
107
  * @see https://console.groq.com/docs/browser-search
107
108
  */
108
- declare const browserSearch: _ai_sdk_provider_utils.ProviderToolFactory<{}, {}>;
109
+ declare const browserSearch: _ai_sdk_provider_utils.ProviderExecutedToolFactory<{}, {}, {}, {}>;
109
110
 
110
111
  declare const VERSION: string;
111
112
 
112
- export { type GroqLanguageModelOptions, type GroqProvider, type GroqLanguageModelOptions as GroqProviderOptions, type GroqProviderSettings, type GroqTranscriptionModelOptions, VERSION, browserSearch, createGroq, groq };
113
+ export { type GroqLanguageModelChatOptions, type GroqLanguageModelChatOptions as GroqLanguageModelOptions, type GroqProvider, type GroqLanguageModelChatOptions as GroqProviderOptions, type GroqProviderSettings, type GroqTranscriptionModelOptions, VERSION, browserSearch, createGroq, groq };