@ai-sdk/amazon-bedrock 2.2.10 → 3.0.0-alpha.10

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,48 +1,281 @@
1
1
  # @ai-sdk/amazon-bedrock
2
2
 
3
- ## 2.2.10
3
+ ## 3.0.0-alpha.10
4
4
 
5
5
  ### Patch Changes
6
6
 
7
- - 05b8324: feat (provider/amazon-bedrock): add Claude 4 model ids (claude-sonnet-4-20250514-v1:0, claude-opus-4-20250514-v1:0)
7
+ - Updated dependencies [c4df419]
8
+ - @ai-sdk/provider@2.0.0-alpha.10
9
+ - @ai-sdk/provider-utils@3.0.0-alpha.10
8
10
 
9
- ## 2.2.9
11
+ ## 3.0.0-alpha.9
10
12
 
11
13
  ### Patch Changes
12
14
 
13
- - Updated dependencies [d87b9d1]
14
- - @ai-sdk/provider-utils@2.2.8
15
+ - c87b7e4: feat (provider/amazon-bedrock): add Claude 4 model ids (claude-sonnet-4-20250514-v1:0, claude-opus-4-20250514-v1:0)
16
+ - Updated dependencies [811dff3]
17
+ - @ai-sdk/provider@2.0.0-alpha.9
18
+ - @ai-sdk/provider-utils@3.0.0-alpha.9
15
19
 
16
- ## 2.2.8
20
+ ## 3.0.0-alpha.8
17
21
 
18
22
  ### Patch Changes
19
23
 
20
- - Updated dependencies [beef951]
21
- - @ai-sdk/provider@1.1.3
22
- - @ai-sdk/provider-utils@2.2.7
24
+ - Updated dependencies [4fef487]
25
+ - Updated dependencies [9222aeb]
26
+ - @ai-sdk/provider-utils@3.0.0-alpha.8
27
+ - @ai-sdk/provider@2.0.0-alpha.8
23
28
 
24
- ## 2.2.7
29
+ ## 3.0.0-alpha.7
25
30
 
26
31
  ### Patch Changes
27
32
 
28
- - Updated dependencies [013faa8]
29
- - @ai-sdk/provider@1.1.2
30
- - @ai-sdk/provider-utils@2.2.6
33
+ - Updated dependencies [5c56081]
34
+ - @ai-sdk/provider@2.0.0-alpha.7
35
+ - @ai-sdk/provider-utils@3.0.0-alpha.7
31
36
 
32
- ## 2.2.6
37
+ ## 3.0.0-alpha.6
33
38
 
34
39
  ### Patch Changes
35
40
 
36
- - Updated dependencies [c21fa6d]
37
- - @ai-sdk/provider-utils@2.2.5
38
- - @ai-sdk/provider@1.1.1
41
+ - Updated dependencies [0d2c085]
42
+ - @ai-sdk/provider@2.0.0-alpha.6
43
+ - @ai-sdk/provider-utils@3.0.0-alpha.6
39
44
 
40
- ## 2.2.5
45
+ ## 3.0.0-alpha.4
41
46
 
42
47
  ### Patch Changes
43
48
 
44
- - Updated dependencies [2c19b9a]
45
- - @ai-sdk/provider-utils@2.2.4
49
+ - Updated dependencies [dc714f3]
50
+ - @ai-sdk/provider@2.0.0-alpha.4
51
+ - @ai-sdk/provider-utils@3.0.0-alpha.4
52
+
53
+ ## 3.0.0-alpha.3
54
+
55
+ ### Patch Changes
56
+
57
+ - Updated dependencies [6b98118]
58
+ - @ai-sdk/provider@2.0.0-alpha.3
59
+ - @ai-sdk/provider-utils@3.0.0-alpha.3
60
+
61
+ ## 3.0.0-alpha.2
62
+
63
+ ### Patch Changes
64
+
65
+ - Updated dependencies [26535e0]
66
+ - @ai-sdk/provider@2.0.0-alpha.2
67
+ - @ai-sdk/provider-utils@3.0.0-alpha.2
68
+
69
+ ## 3.0.0-alpha.1
70
+
71
+ ### Patch Changes
72
+
73
+ - Updated dependencies [3f2f00c]
74
+ - @ai-sdk/provider@2.0.0-alpha.1
75
+ - @ai-sdk/provider-utils@3.0.0-alpha.1
76
+
77
+ ## 3.0.0-canary.19
78
+
79
+ ### Patch Changes
80
+
81
+ - Updated dependencies [faf8446]
82
+ - @ai-sdk/provider-utils@3.0.0-canary.19
83
+
84
+ ## 3.0.0-canary.18
85
+
86
+ ### Patch Changes
87
+
88
+ - Updated dependencies [40acf9b]
89
+ - @ai-sdk/provider-utils@3.0.0-canary.18
90
+
91
+ ## 3.0.0-canary.17
92
+
93
+ ### Patch Changes
94
+
95
+ - Updated dependencies [ea7a7c9]
96
+ - @ai-sdk/provider-utils@3.0.0-canary.17
97
+
98
+ ## 3.0.0-canary.16
99
+
100
+ ### Patch Changes
101
+
102
+ - Updated dependencies [87b828f]
103
+ - @ai-sdk/provider-utils@3.0.0-canary.16
104
+
105
+ ## 3.0.0-canary.15
106
+
107
+ ### Patch Changes
108
+
109
+ - a8c8bd5: feat(embed-many): respect supportsParallelCalls & concurrency
110
+ - 6f231db: fix(providers): always use optional instead of mix of nullish for providerOptions
111
+ - Updated dependencies [a571d6e]
112
+ - Updated dependencies [a8c8bd5]
113
+ - Updated dependencies [7979f7f]
114
+ - Updated dependencies [41fa418]
115
+ - @ai-sdk/provider-utils@3.0.0-canary.15
116
+ - @ai-sdk/provider@2.0.0-canary.14
117
+
118
+ ## 3.0.0-canary.14
119
+
120
+ ### Patch Changes
121
+
122
+ - Updated dependencies [957b739]
123
+ - Updated dependencies [9bd5ab5]
124
+ - @ai-sdk/provider-utils@3.0.0-canary.14
125
+ - @ai-sdk/provider@2.0.0-canary.13
126
+
127
+ ## 3.0.0-canary.13
128
+
129
+ ### Patch Changes
130
+
131
+ - d9209ca: fix (image-model): `specificationVersion: v1` -> `v2`
132
+ - Updated dependencies [7b3ae3f]
133
+ - Updated dependencies [0ff02bb]
134
+ - @ai-sdk/provider@2.0.0-canary.12
135
+ - @ai-sdk/provider-utils@3.0.0-canary.13
136
+
137
+ ## 3.0.0-canary.12
138
+
139
+ ### Patch Changes
140
+
141
+ - Updated dependencies [9bf7291]
142
+ - Updated dependencies [4617fab]
143
+ - Updated dependencies [e030615]
144
+ - @ai-sdk/provider@2.0.0-canary.11
145
+ - @ai-sdk/provider-utils@3.0.0-canary.12
146
+
147
+ ## 3.0.0-canary.11
148
+
149
+ ### Patch Changes
150
+
151
+ - 9301f86: refactor (image-model): rename `ImageModelV1` to `ImageModelV2`
152
+ - Updated dependencies [66962ed]
153
+ - Updated dependencies [9301f86]
154
+ - Updated dependencies [a3f768e]
155
+ - @ai-sdk/provider-utils@3.0.0-canary.11
156
+ - @ai-sdk/provider@2.0.0-canary.10
157
+
158
+ ## 3.0.0-canary.10
159
+
160
+ ### Patch Changes
161
+
162
+ - Updated dependencies [e86be6f]
163
+ - @ai-sdk/provider@2.0.0-canary.9
164
+ - @ai-sdk/provider-utils@3.0.0-canary.10
165
+
166
+ ## 3.0.0-canary.9
167
+
168
+ ### Patch Changes
169
+
170
+ - 92c0b4b: chore(providers/bedrock): update embedding model to use providerOptions
171
+ - Updated dependencies [95857aa]
172
+ - Updated dependencies [7ea4132]
173
+ - @ai-sdk/provider@2.0.0-canary.8
174
+ - @ai-sdk/provider-utils@3.0.0-canary.9
175
+
176
+ ## 3.0.0-canary.8
177
+
178
+ ### Patch Changes
179
+
180
+ - Updated dependencies [5d142ab]
181
+ - Updated dependencies [b6b43c7]
182
+ - Updated dependencies [8aa9e20]
183
+ - Updated dependencies [3795467]
184
+ - @ai-sdk/provider-utils@3.0.0-canary.8
185
+ - @ai-sdk/provider@2.0.0-canary.7
186
+
187
+ ## 3.0.0-canary.7
188
+
189
+ ### Patch Changes
190
+
191
+ - fa49207: feat(providers/openai-compatible): convert to providerOptions
192
+ - 26735b5: chore(embedding-model): add v2 interface
193
+ - Updated dependencies [26735b5]
194
+ - Updated dependencies [443d8ec]
195
+ - Updated dependencies [14c9410]
196
+ - Updated dependencies [d9c98f4]
197
+ - Updated dependencies [c4a2fec]
198
+ - Updated dependencies [0054544]
199
+ - Updated dependencies [9e9c809]
200
+ - Updated dependencies [32831c6]
201
+ - Updated dependencies [d0f9495]
202
+ - Updated dependencies [fd65bc6]
203
+ - Updated dependencies [393138b]
204
+ - Updated dependencies [7182d14]
205
+ - @ai-sdk/provider@2.0.0-canary.6
206
+ - @ai-sdk/provider-utils@3.0.0-canary.7
207
+
208
+ ## 3.0.0-canary.6
209
+
210
+ ### Patch Changes
211
+
212
+ - 97ea26f: chore(providers/bedrock): convert to providerOptions
213
+ - 97ea26f: chore(providers/bedrock): use camelCase for providerOptions
214
+ - Updated dependencies [411e483]
215
+ - Updated dependencies [79457bd]
216
+ - Updated dependencies [ad80501]
217
+ - Updated dependencies [1766ede]
218
+ - Updated dependencies [f10304b]
219
+ - @ai-sdk/provider@2.0.0-canary.5
220
+ - @ai-sdk/provider-utils@3.0.0-canary.6
221
+
222
+ ## 3.0.0-canary.5
223
+
224
+ ### Patch Changes
225
+
226
+ - Updated dependencies [6f6bb89]
227
+ - @ai-sdk/provider@2.0.0-canary.4
228
+ - @ai-sdk/provider-utils@3.0.0-canary.5
229
+
230
+ ## 3.0.0-canary.4
231
+
232
+ ### Patch Changes
233
+
234
+ - Updated dependencies [d1a1aa1]
235
+ - @ai-sdk/provider@2.0.0-canary.3
236
+ - @ai-sdk/provider-utils@3.0.0-canary.4
237
+
238
+ ## 3.0.0-canary.3
239
+
240
+ ### Patch Changes
241
+
242
+ - Updated dependencies [a166433]
243
+ - Updated dependencies [abf9a79]
244
+ - Updated dependencies [9f95b35]
245
+ - Updated dependencies [0a87932]
246
+ - Updated dependencies [6dc848c]
247
+ - @ai-sdk/provider-utils@3.0.0-canary.3
248
+ - @ai-sdk/provider@2.0.0-canary.2
249
+
250
+ ## 3.0.0-canary.2
251
+
252
+ ### Patch Changes
253
+
254
+ - Updated dependencies [c57e248]
255
+ - Updated dependencies [33f4a6a]
256
+ - @ai-sdk/provider@2.0.0-canary.1
257
+ - @ai-sdk/provider-utils@3.0.0-canary.2
258
+
259
+ ## 3.0.0-canary.1
260
+
261
+ ### Patch Changes
262
+
263
+ - Updated dependencies [060370c]
264
+ - Updated dependencies [0c0c0b3]
265
+ - Updated dependencies [63d791d]
266
+ - @ai-sdk/provider-utils@3.0.0-canary.1
267
+
268
+ ## 3.0.0-canary.0
269
+
270
+ ### Major Changes
271
+
272
+ - d5f588f: AI SDK 5
273
+
274
+ ### Patch Changes
275
+
276
+ - Updated dependencies [d5f588f]
277
+ - @ai-sdk/provider-utils@3.0.0-canary.0
278
+ - @ai-sdk/provider@2.0.0-canary.0
46
279
 
47
280
  ## 2.2.4
48
281
 
package/dist/index.d.mts CHANGED
@@ -1,38 +1,43 @@
1
- import { ProviderV1, LanguageModelV1, EmbeddingModelV1, ImageModelV1 } from '@ai-sdk/provider';
1
+ import { ProviderV2, LanguageModelV2, EmbeddingModelV2, ImageModelV2 } from '@ai-sdk/provider';
2
2
  import { FetchFunction } from '@ai-sdk/provider-utils';
3
+ import { z } from 'zod';
3
4
 
4
5
  type BedrockChatModelId = 'amazon.titan-tg1-large' | 'amazon.titan-text-express-v1' | 'anthropic.claude-v2' | 'anthropic.claude-v2:1' | 'anthropic.claude-instant-v1' | 'anthropic.claude-sonnet-4-20250514-v1:0' | 'anthropic.claude-opus-4-20250514-v1:0' | 'anthropic.claude-3-7-sonnet-20250219-v1:0' | 'anthropic.claude-3-5-sonnet-20240620-v1:0' | 'anthropic.claude-3-5-sonnet-20241022-v2:0' | 'anthropic.claude-3-5-haiku-20241022-v1:0' | 'anthropic.claude-3-sonnet-20240229-v1:0' | 'anthropic.claude-3-haiku-20240307-v1:0' | 'anthropic.claude-3-opus-20240229-v1:0' | 'cohere.command-text-v14' | 'cohere.command-light-text-v14' | 'cohere.command-r-v1:0' | 'cohere.command-r-plus-v1:0' | 'meta.llama3-70b-instruct-v1:0' | 'meta.llama3-8b-instruct-v1:0' | 'meta.llama3-1-405b-instruct-v1:0' | 'meta.llama3-1-70b-instruct-v1:0' | 'meta.llama3-1-8b-instruct-v1:0' | 'meta.llama3-2-11b-instruct-v1:0' | 'meta.llama3-2-1b-instruct-v1:0' | 'meta.llama3-2-3b-instruct-v1:0' | 'meta.llama3-2-90b-instruct-v1:0' | 'mistral.mistral-7b-instruct-v0:2' | 'mistral.mixtral-8x7b-instruct-v0:1' | 'mistral.mistral-large-2402-v1:0' | 'mistral.mistral-small-2402-v1:0' | 'amazon.titan-text-express-v1' | 'amazon.titan-text-lite-v1' | (string & {});
5
- interface BedrockChatSettings {
6
+ declare const bedrockProviderOptions: z.ZodObject<{
6
7
  /**
7
- Additional inference parameters that the model supports,
8
- beyond the base set of inference parameters that Converse
9
- supports in the inferenceConfig field
10
- */
11
- additionalModelRequestFields?: Record<string, any>;
12
- }
8
+ * Additional inference parameters that the model supports,
9
+ * beyond the base set of inference parameters that Converse
10
+ * supports in the inferenceConfig field
11
+ */
12
+ additionalModelRequestFields: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
13
+ reasoningConfig: z.ZodOptional<z.ZodObject<{
14
+ type: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"enabled">, z.ZodLiteral<"disabled">]>>;
15
+ budgetTokens: z.ZodOptional<z.ZodNumber>;
16
+ }, "strip", z.ZodTypeAny, {
17
+ type?: "enabled" | "disabled" | undefined;
18
+ budgetTokens?: number | undefined;
19
+ }, {
20
+ type?: "enabled" | "disabled" | undefined;
21
+ budgetTokens?: number | undefined;
22
+ }>>;
23
+ }, "strip", z.ZodTypeAny, {
24
+ additionalModelRequestFields?: Record<string, any> | undefined;
25
+ reasoningConfig?: {
26
+ type?: "enabled" | "disabled" | undefined;
27
+ budgetTokens?: number | undefined;
28
+ } | undefined;
29
+ }, {
30
+ additionalModelRequestFields?: Record<string, any> | undefined;
31
+ reasoningConfig?: {
32
+ type?: "enabled" | "disabled" | undefined;
33
+ budgetTokens?: number | undefined;
34
+ } | undefined;
35
+ }>;
36
+ type BedrockProviderOptions = z.infer<typeof bedrockProviderOptions>;
13
37
 
14
38
  type BedrockEmbeddingModelId = 'amazon.titan-embed-text-v1' | 'amazon.titan-embed-text-v2:0' | 'cohere.embed-english-v3' | 'cohere.embed-multilingual-v3' | (string & {});
15
- interface BedrockEmbeddingSettings {
16
- /**
17
- The number of dimensions the resulting output embeddings should have (defaults to 1024).
18
- Only supported in amazon.titan-embed-text-v2:0.
19
- */
20
- dimensions?: 1024 | 512 | 256;
21
- /**
22
- Flag indicating whether or not to normalize the output embeddings. Defaults to true
23
- Only supported in amazon.titan-embed-text-v2:0.
24
- */
25
- normalize?: boolean;
26
- }
27
39
 
28
40
  type BedrockImageModelId = 'amazon.nova-canvas-v1:0' | (string & {});
29
- interface BedrockImageSettings {
30
- /**
31
- * Override the maximum number of images per call (default is dependent on the
32
- * model, or 1 for an unknown model).
33
- */
34
- maxImagesPerCall?: number;
35
- }
36
41
 
37
42
  interface BedrockCredentials {
38
43
  region: string;
@@ -84,12 +89,19 @@ interface AmazonBedrockProviderSettings {
84
89
  credentialProvider?: () => PromiseLike<Omit<BedrockCredentials, 'region'>>;
85
90
  generateId?: () => string;
86
91
  }
87
- interface AmazonBedrockProvider extends ProviderV1 {
88
- (modelId: BedrockChatModelId, settings?: BedrockChatSettings): LanguageModelV1;
89
- languageModel(modelId: BedrockChatModelId, settings?: BedrockChatSettings): LanguageModelV1;
90
- embedding(modelId: BedrockEmbeddingModelId, settings?: BedrockEmbeddingSettings): EmbeddingModelV1<string>;
91
- image(modelId: BedrockImageModelId, settings?: BedrockImageSettings): ImageModelV1;
92
- imageModel(modelId: BedrockImageModelId, settings?: BedrockImageSettings): ImageModelV1;
92
+ interface AmazonBedrockProvider extends ProviderV2 {
93
+ (modelId: BedrockChatModelId): LanguageModelV2;
94
+ languageModel(modelId: BedrockChatModelId): LanguageModelV2;
95
+ embedding(modelId: BedrockEmbeddingModelId): EmbeddingModelV2<string>;
96
+ /**
97
+ Creates a model for image generation.
98
+ @deprecated Use `imageModel` instead.
99
+ */
100
+ image(modelId: BedrockImageModelId): ImageModelV2;
101
+ /**
102
+ Creates a model for image generation.
103
+ */
104
+ imageModel(modelId: BedrockImageModelId): ImageModelV2;
93
105
  }
94
106
  /**
95
107
  Create an Amazon Bedrock provider instance.
@@ -100,4 +112,4 @@ Default Bedrock provider instance.
100
112
  */
101
113
  declare const bedrock: AmazonBedrockProvider;
102
114
 
103
- export { type AmazonBedrockProvider, type AmazonBedrockProviderSettings, bedrock, createAmazonBedrock };
115
+ export { type AmazonBedrockProvider, type AmazonBedrockProviderSettings, type BedrockProviderOptions, bedrock, createAmazonBedrock };
package/dist/index.d.ts CHANGED
@@ -1,38 +1,43 @@
1
- import { ProviderV1, LanguageModelV1, EmbeddingModelV1, ImageModelV1 } from '@ai-sdk/provider';
1
+ import { ProviderV2, LanguageModelV2, EmbeddingModelV2, ImageModelV2 } from '@ai-sdk/provider';
2
2
  import { FetchFunction } from '@ai-sdk/provider-utils';
3
+ import { z } from 'zod';
3
4
 
4
5
  type BedrockChatModelId = 'amazon.titan-tg1-large' | 'amazon.titan-text-express-v1' | 'anthropic.claude-v2' | 'anthropic.claude-v2:1' | 'anthropic.claude-instant-v1' | 'anthropic.claude-sonnet-4-20250514-v1:0' | 'anthropic.claude-opus-4-20250514-v1:0' | 'anthropic.claude-3-7-sonnet-20250219-v1:0' | 'anthropic.claude-3-5-sonnet-20240620-v1:0' | 'anthropic.claude-3-5-sonnet-20241022-v2:0' | 'anthropic.claude-3-5-haiku-20241022-v1:0' | 'anthropic.claude-3-sonnet-20240229-v1:0' | 'anthropic.claude-3-haiku-20240307-v1:0' | 'anthropic.claude-3-opus-20240229-v1:0' | 'cohere.command-text-v14' | 'cohere.command-light-text-v14' | 'cohere.command-r-v1:0' | 'cohere.command-r-plus-v1:0' | 'meta.llama3-70b-instruct-v1:0' | 'meta.llama3-8b-instruct-v1:0' | 'meta.llama3-1-405b-instruct-v1:0' | 'meta.llama3-1-70b-instruct-v1:0' | 'meta.llama3-1-8b-instruct-v1:0' | 'meta.llama3-2-11b-instruct-v1:0' | 'meta.llama3-2-1b-instruct-v1:0' | 'meta.llama3-2-3b-instruct-v1:0' | 'meta.llama3-2-90b-instruct-v1:0' | 'mistral.mistral-7b-instruct-v0:2' | 'mistral.mixtral-8x7b-instruct-v0:1' | 'mistral.mistral-large-2402-v1:0' | 'mistral.mistral-small-2402-v1:0' | 'amazon.titan-text-express-v1' | 'amazon.titan-text-lite-v1' | (string & {});
5
- interface BedrockChatSettings {
6
+ declare const bedrockProviderOptions: z.ZodObject<{
6
7
  /**
7
- Additional inference parameters that the model supports,
8
- beyond the base set of inference parameters that Converse
9
- supports in the inferenceConfig field
10
- */
11
- additionalModelRequestFields?: Record<string, any>;
12
- }
8
+ * Additional inference parameters that the model supports,
9
+ * beyond the base set of inference parameters that Converse
10
+ * supports in the inferenceConfig field
11
+ */
12
+ additionalModelRequestFields: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
13
+ reasoningConfig: z.ZodOptional<z.ZodObject<{
14
+ type: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"enabled">, z.ZodLiteral<"disabled">]>>;
15
+ budgetTokens: z.ZodOptional<z.ZodNumber>;
16
+ }, "strip", z.ZodTypeAny, {
17
+ type?: "enabled" | "disabled" | undefined;
18
+ budgetTokens?: number | undefined;
19
+ }, {
20
+ type?: "enabled" | "disabled" | undefined;
21
+ budgetTokens?: number | undefined;
22
+ }>>;
23
+ }, "strip", z.ZodTypeAny, {
24
+ additionalModelRequestFields?: Record<string, any> | undefined;
25
+ reasoningConfig?: {
26
+ type?: "enabled" | "disabled" | undefined;
27
+ budgetTokens?: number | undefined;
28
+ } | undefined;
29
+ }, {
30
+ additionalModelRequestFields?: Record<string, any> | undefined;
31
+ reasoningConfig?: {
32
+ type?: "enabled" | "disabled" | undefined;
33
+ budgetTokens?: number | undefined;
34
+ } | undefined;
35
+ }>;
36
+ type BedrockProviderOptions = z.infer<typeof bedrockProviderOptions>;
13
37
 
14
38
  type BedrockEmbeddingModelId = 'amazon.titan-embed-text-v1' | 'amazon.titan-embed-text-v2:0' | 'cohere.embed-english-v3' | 'cohere.embed-multilingual-v3' | (string & {});
15
- interface BedrockEmbeddingSettings {
16
- /**
17
- The number of dimensions the resulting output embeddings should have (defaults to 1024).
18
- Only supported in amazon.titan-embed-text-v2:0.
19
- */
20
- dimensions?: 1024 | 512 | 256;
21
- /**
22
- Flag indicating whether or not to normalize the output embeddings. Defaults to true
23
- Only supported in amazon.titan-embed-text-v2:0.
24
- */
25
- normalize?: boolean;
26
- }
27
39
 
28
40
  type BedrockImageModelId = 'amazon.nova-canvas-v1:0' | (string & {});
29
- interface BedrockImageSettings {
30
- /**
31
- * Override the maximum number of images per call (default is dependent on the
32
- * model, or 1 for an unknown model).
33
- */
34
- maxImagesPerCall?: number;
35
- }
36
41
 
37
42
  interface BedrockCredentials {
38
43
  region: string;
@@ -84,12 +89,19 @@ interface AmazonBedrockProviderSettings {
84
89
  credentialProvider?: () => PromiseLike<Omit<BedrockCredentials, 'region'>>;
85
90
  generateId?: () => string;
86
91
  }
87
- interface AmazonBedrockProvider extends ProviderV1 {
88
- (modelId: BedrockChatModelId, settings?: BedrockChatSettings): LanguageModelV1;
89
- languageModel(modelId: BedrockChatModelId, settings?: BedrockChatSettings): LanguageModelV1;
90
- embedding(modelId: BedrockEmbeddingModelId, settings?: BedrockEmbeddingSettings): EmbeddingModelV1<string>;
91
- image(modelId: BedrockImageModelId, settings?: BedrockImageSettings): ImageModelV1;
92
- imageModel(modelId: BedrockImageModelId, settings?: BedrockImageSettings): ImageModelV1;
92
+ interface AmazonBedrockProvider extends ProviderV2 {
93
+ (modelId: BedrockChatModelId): LanguageModelV2;
94
+ languageModel(modelId: BedrockChatModelId): LanguageModelV2;
95
+ embedding(modelId: BedrockEmbeddingModelId): EmbeddingModelV2<string>;
96
+ /**
97
+ Creates a model for image generation.
98
+ @deprecated Use `imageModel` instead.
99
+ */
100
+ image(modelId: BedrockImageModelId): ImageModelV2;
101
+ /**
102
+ Creates a model for image generation.
103
+ */
104
+ imageModel(modelId: BedrockImageModelId): ImageModelV2;
93
105
  }
94
106
  /**
95
107
  Create an Amazon Bedrock provider instance.
@@ -100,4 +112,4 @@ Default Bedrock provider instance.
100
112
  */
101
113
  declare const bedrock: AmazonBedrockProvider;
102
114
 
103
- export { type AmazonBedrockProvider, type AmazonBedrockProviderSettings, bedrock, createAmazonBedrock };
115
+ export { type AmazonBedrockProvider, type AmazonBedrockProviderSettings, type BedrockProviderOptions, bedrock, createAmazonBedrock };