Skip to content

Commit 441ce01

Browse files
author
awstools
committed
feat(client-bedrock): Provisioned throughput feature with Amazon and third-party base models, and update validators for model identifier and taggable resource ARNs.
1 parent 03d0108 commit 441ce01

18 files changed

+2863
-69
lines changed

clients/client-bedrock/README.md

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,6 +210,14 @@ CreateModelCustomizationJob
210210

211211
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/classes/createmodelcustomizationjobcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/createmodelcustomizationjobcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/createmodelcustomizationjobcommandoutput.html)
212212

213+
</details>
214+
<details>
215+
<summary>
216+
CreateProvisionedModelThroughput
217+
</summary>
218+
219+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/classes/createprovisionedmodelthroughputcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/createprovisionedmodelthroughputcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/createprovisionedmodelthroughputcommandoutput.html)
220+
213221
</details>
214222
<details>
215223
<summary>
@@ -226,6 +234,14 @@ DeleteModelInvocationLoggingConfiguration
226234

227235
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/classes/deletemodelinvocationloggingconfigurationcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/deletemodelinvocationloggingconfigurationcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/deletemodelinvocationloggingconfigurationcommandoutput.html)
228236

237+
</details>
238+
<details>
239+
<summary>
240+
DeleteProvisionedModelThroughput
241+
</summary>
242+
243+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/classes/deleteprovisionedmodelthroughputcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/deleteprovisionedmodelthroughputcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/deleteprovisionedmodelthroughputcommandoutput.html)
244+
229245
</details>
230246
<details>
231247
<summary>
@@ -258,6 +274,14 @@ GetModelInvocationLoggingConfiguration
258274

259275
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/classes/getmodelinvocationloggingconfigurationcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/getmodelinvocationloggingconfigurationcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/getmodelinvocationloggingconfigurationcommandoutput.html)
260276

277+
</details>
278+
<details>
279+
<summary>
280+
GetProvisionedModelThroughput
281+
</summary>
282+
283+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/classes/getprovisionedmodelthroughputcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/getprovisionedmodelthroughputcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/getprovisionedmodelthroughputcommandoutput.html)
284+
261285
</details>
262286
<details>
263287
<summary>
@@ -282,6 +306,14 @@ ListModelCustomizationJobs
282306

283307
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/classes/listmodelcustomizationjobscommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/listmodelcustomizationjobscommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/listmodelcustomizationjobscommandoutput.html)
284308

309+
</details>
310+
<details>
311+
<summary>
312+
ListProvisionedModelThroughputs
313+
</summary>
314+
315+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/classes/listprovisionedmodelthroughputscommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/listprovisionedmodelthroughputscommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/listprovisionedmodelthroughputscommandoutput.html)
316+
285317
</details>
286318
<details>
287319
<summary>
@@ -323,3 +355,11 @@ UntagResource
323355
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/classes/untagresourcecommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/untagresourcecommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/untagresourcecommandoutput.html)
324356

325357
</details>
358+
<details>
359+
<summary>
360+
UpdateProvisionedModelThroughput
361+
</summary>
362+
363+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/classes/updateprovisionedmodelthroughputcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/updateprovisionedmodelthroughputcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-bedrock/interfaces/updateprovisionedmodelthroughputcommandoutput.html)
364+
365+
</details>

clients/client-bedrock/src/Bedrock.ts

Lines changed: 115 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@ import {
88
CreateModelCustomizationJobCommandInput,
99
CreateModelCustomizationJobCommandOutput,
1010
} from "./commands/CreateModelCustomizationJobCommand";
11+
import {
12+
CreateProvisionedModelThroughputCommand,
13+
CreateProvisionedModelThroughputCommandInput,
14+
CreateProvisionedModelThroughputCommandOutput,
15+
} from "./commands/CreateProvisionedModelThroughputCommand";
1116
import {
1217
DeleteCustomModelCommand,
1318
DeleteCustomModelCommandInput,
@@ -18,6 +23,11 @@ import {
1823
DeleteModelInvocationLoggingConfigurationCommandInput,
1924
DeleteModelInvocationLoggingConfigurationCommandOutput,
2025
} from "./commands/DeleteModelInvocationLoggingConfigurationCommand";
26+
import {
27+
DeleteProvisionedModelThroughputCommand,
28+
DeleteProvisionedModelThroughputCommandInput,
29+
DeleteProvisionedModelThroughputCommandOutput,
30+
} from "./commands/DeleteProvisionedModelThroughputCommand";
2131
import {
2232
GetCustomModelCommand,
2333
GetCustomModelCommandInput,
@@ -38,6 +48,11 @@ import {
3848
GetModelInvocationLoggingConfigurationCommandInput,
3949
GetModelInvocationLoggingConfigurationCommandOutput,
4050
} from "./commands/GetModelInvocationLoggingConfigurationCommand";
51+
import {
52+
GetProvisionedModelThroughputCommand,
53+
GetProvisionedModelThroughputCommandInput,
54+
GetProvisionedModelThroughputCommandOutput,
55+
} from "./commands/GetProvisionedModelThroughputCommand";
4156
import {
4257
ListCustomModelsCommand,
4358
ListCustomModelsCommandInput,
@@ -53,6 +68,11 @@ import {
5368
ListModelCustomizationJobsCommandInput,
5469
ListModelCustomizationJobsCommandOutput,
5570
} from "./commands/ListModelCustomizationJobsCommand";
71+
import {
72+
ListProvisionedModelThroughputsCommand,
73+
ListProvisionedModelThroughputsCommandInput,
74+
ListProvisionedModelThroughputsCommandOutput,
75+
} from "./commands/ListProvisionedModelThroughputsCommand";
5676
import {
5777
ListTagsForResourceCommand,
5878
ListTagsForResourceCommandInput,
@@ -74,23 +94,33 @@ import {
7494
UntagResourceCommandInput,
7595
UntagResourceCommandOutput,
7696
} from "./commands/UntagResourceCommand";
97+
import {
98+
UpdateProvisionedModelThroughputCommand,
99+
UpdateProvisionedModelThroughputCommandInput,
100+
UpdateProvisionedModelThroughputCommandOutput,
101+
} from "./commands/UpdateProvisionedModelThroughputCommand";
77102

78103
const commands = {
79104
CreateModelCustomizationJobCommand,
105+
CreateProvisionedModelThroughputCommand,
80106
DeleteCustomModelCommand,
81107
DeleteModelInvocationLoggingConfigurationCommand,
108+
DeleteProvisionedModelThroughputCommand,
82109
GetCustomModelCommand,
83110
GetFoundationModelCommand,
84111
GetModelCustomizationJobCommand,
85112
GetModelInvocationLoggingConfigurationCommand,
113+
GetProvisionedModelThroughputCommand,
86114
ListCustomModelsCommand,
87115
ListFoundationModelsCommand,
88116
ListModelCustomizationJobsCommand,
117+
ListProvisionedModelThroughputsCommand,
89118
ListTagsForResourceCommand,
90119
PutModelInvocationLoggingConfigurationCommand,
91120
StopModelCustomizationJobCommand,
92121
TagResourceCommand,
93122
UntagResourceCommand,
123+
UpdateProvisionedModelThroughputCommand,
94124
};
95125

96126
export interface Bedrock {
@@ -111,6 +141,23 @@ export interface Bedrock {
111141
cb: (err: any, data?: CreateModelCustomizationJobCommandOutput) => void
112142
): void;
113143

144+
/**
145+
* @see {@link CreateProvisionedModelThroughputCommand}
146+
*/
147+
createProvisionedModelThroughput(
148+
args: CreateProvisionedModelThroughputCommandInput,
149+
options?: __HttpHandlerOptions
150+
): Promise<CreateProvisionedModelThroughputCommandOutput>;
151+
createProvisionedModelThroughput(
152+
args: CreateProvisionedModelThroughputCommandInput,
153+
cb: (err: any, data?: CreateProvisionedModelThroughputCommandOutput) => void
154+
): void;
155+
createProvisionedModelThroughput(
156+
args: CreateProvisionedModelThroughputCommandInput,
157+
options: __HttpHandlerOptions,
158+
cb: (err: any, data?: CreateProvisionedModelThroughputCommandOutput) => void
159+
): void;
160+
114161
/**
115162
* @see {@link DeleteCustomModelCommand}
116163
*/
@@ -145,6 +192,23 @@ export interface Bedrock {
145192
cb: (err: any, data?: DeleteModelInvocationLoggingConfigurationCommandOutput) => void
146193
): void;
147194

195+
/**
196+
* @see {@link DeleteProvisionedModelThroughputCommand}
197+
*/
198+
deleteProvisionedModelThroughput(
199+
args: DeleteProvisionedModelThroughputCommandInput,
200+
options?: __HttpHandlerOptions
201+
): Promise<DeleteProvisionedModelThroughputCommandOutput>;
202+
deleteProvisionedModelThroughput(
203+
args: DeleteProvisionedModelThroughputCommandInput,
204+
cb: (err: any, data?: DeleteProvisionedModelThroughputCommandOutput) => void
205+
): void;
206+
deleteProvisionedModelThroughput(
207+
args: DeleteProvisionedModelThroughputCommandInput,
208+
options: __HttpHandlerOptions,
209+
cb: (err: any, data?: DeleteProvisionedModelThroughputCommandOutput) => void
210+
): void;
211+
148212
/**
149213
* @see {@link GetCustomModelCommand}
150214
*/
@@ -210,6 +274,23 @@ export interface Bedrock {
210274
cb: (err: any, data?: GetModelInvocationLoggingConfigurationCommandOutput) => void
211275
): void;
212276

277+
/**
278+
* @see {@link GetProvisionedModelThroughputCommand}
279+
*/
280+
getProvisionedModelThroughput(
281+
args: GetProvisionedModelThroughputCommandInput,
282+
options?: __HttpHandlerOptions
283+
): Promise<GetProvisionedModelThroughputCommandOutput>;
284+
getProvisionedModelThroughput(
285+
args: GetProvisionedModelThroughputCommandInput,
286+
cb: (err: any, data?: GetProvisionedModelThroughputCommandOutput) => void
287+
): void;
288+
getProvisionedModelThroughput(
289+
args: GetProvisionedModelThroughputCommandInput,
290+
options: __HttpHandlerOptions,
291+
cb: (err: any, data?: GetProvisionedModelThroughputCommandOutput) => void
292+
): void;
293+
213294
/**
214295
* @see {@link ListCustomModelsCommand}
215296
*/
@@ -261,6 +342,23 @@ export interface Bedrock {
261342
cb: (err: any, data?: ListModelCustomizationJobsCommandOutput) => void
262343
): void;
263344

345+
/**
346+
* @see {@link ListProvisionedModelThroughputsCommand}
347+
*/
348+
listProvisionedModelThroughputs(
349+
args: ListProvisionedModelThroughputsCommandInput,
350+
options?: __HttpHandlerOptions
351+
): Promise<ListProvisionedModelThroughputsCommandOutput>;
352+
listProvisionedModelThroughputs(
353+
args: ListProvisionedModelThroughputsCommandInput,
354+
cb: (err: any, data?: ListProvisionedModelThroughputsCommandOutput) => void
355+
): void;
356+
listProvisionedModelThroughputs(
357+
args: ListProvisionedModelThroughputsCommandInput,
358+
options: __HttpHandlerOptions,
359+
cb: (err: any, data?: ListProvisionedModelThroughputsCommandOutput) => void
360+
): void;
361+
264362
/**
265363
* @see {@link ListTagsForResourceCommand}
266364
*/
@@ -333,6 +431,23 @@ export interface Bedrock {
333431
options: __HttpHandlerOptions,
334432
cb: (err: any, data?: UntagResourceCommandOutput) => void
335433
): void;
434+
435+
/**
436+
* @see {@link UpdateProvisionedModelThroughputCommand}
437+
*/
438+
updateProvisionedModelThroughput(
439+
args: UpdateProvisionedModelThroughputCommandInput,
440+
options?: __HttpHandlerOptions
441+
): Promise<UpdateProvisionedModelThroughputCommandOutput>;
442+
updateProvisionedModelThroughput(
443+
args: UpdateProvisionedModelThroughputCommandInput,
444+
cb: (err: any, data?: UpdateProvisionedModelThroughputCommandOutput) => void
445+
): void;
446+
updateProvisionedModelThroughput(
447+
args: UpdateProvisionedModelThroughputCommandInput,
448+
options: __HttpHandlerOptions,
449+
cb: (err: any, data?: UpdateProvisionedModelThroughputCommandOutput) => void
450+
): void;
336451
}
337452

338453
/**

clients/client-bedrock/src/BedrockClient.ts

Lines changed: 32 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,19 @@ import {
5454
CreateModelCustomizationJobCommandInput,
5555
CreateModelCustomizationJobCommandOutput,
5656
} from "./commands/CreateModelCustomizationJobCommand";
57+
import {
58+
CreateProvisionedModelThroughputCommandInput,
59+
CreateProvisionedModelThroughputCommandOutput,
60+
} from "./commands/CreateProvisionedModelThroughputCommand";
5761
import { DeleteCustomModelCommandInput, DeleteCustomModelCommandOutput } from "./commands/DeleteCustomModelCommand";
5862
import {
5963
DeleteModelInvocationLoggingConfigurationCommandInput,
6064
DeleteModelInvocationLoggingConfigurationCommandOutput,
6165
} from "./commands/DeleteModelInvocationLoggingConfigurationCommand";
66+
import {
67+
DeleteProvisionedModelThroughputCommandInput,
68+
DeleteProvisionedModelThroughputCommandOutput,
69+
} from "./commands/DeleteProvisionedModelThroughputCommand";
6270
import { GetCustomModelCommandInput, GetCustomModelCommandOutput } from "./commands/GetCustomModelCommand";
6371
import { GetFoundationModelCommandInput, GetFoundationModelCommandOutput } from "./commands/GetFoundationModelCommand";
6472
import {
@@ -69,6 +77,10 @@ import {
6977
GetModelInvocationLoggingConfigurationCommandInput,
7078
GetModelInvocationLoggingConfigurationCommandOutput,
7179
} from "./commands/GetModelInvocationLoggingConfigurationCommand";
80+
import {
81+
GetProvisionedModelThroughputCommandInput,
82+
GetProvisionedModelThroughputCommandOutput,
83+
} from "./commands/GetProvisionedModelThroughputCommand";
7284
import { ListCustomModelsCommandInput, ListCustomModelsCommandOutput } from "./commands/ListCustomModelsCommand";
7385
import {
7486
ListFoundationModelsCommandInput,
@@ -78,6 +90,10 @@ import {
7890
ListModelCustomizationJobsCommandInput,
7991
ListModelCustomizationJobsCommandOutput,
8092
} from "./commands/ListModelCustomizationJobsCommand";
93+
import {
94+
ListProvisionedModelThroughputsCommandInput,
95+
ListProvisionedModelThroughputsCommandOutput,
96+
} from "./commands/ListProvisionedModelThroughputsCommand";
8197
import {
8298
ListTagsForResourceCommandInput,
8399
ListTagsForResourceCommandOutput,
@@ -92,6 +108,10 @@ import {
92108
} from "./commands/StopModelCustomizationJobCommand";
93109
import { TagResourceCommandInput, TagResourceCommandOutput } from "./commands/TagResourceCommand";
94110
import { UntagResourceCommandInput, UntagResourceCommandOutput } from "./commands/UntagResourceCommand";
111+
import {
112+
UpdateProvisionedModelThroughputCommandInput,
113+
UpdateProvisionedModelThroughputCommandOutput,
114+
} from "./commands/UpdateProvisionedModelThroughputCommand";
95115
import {
96116
ClientInputEndpointParameters,
97117
ClientResolvedEndpointParameters,
@@ -108,40 +128,50 @@ export { __Client };
108128
*/
109129
export type ServiceInputTypes =
110130
| CreateModelCustomizationJobCommandInput
131+
| CreateProvisionedModelThroughputCommandInput
111132
| DeleteCustomModelCommandInput
112133
| DeleteModelInvocationLoggingConfigurationCommandInput
134+
| DeleteProvisionedModelThroughputCommandInput
113135
| GetCustomModelCommandInput
114136
| GetFoundationModelCommandInput
115137
| GetModelCustomizationJobCommandInput
116138
| GetModelInvocationLoggingConfigurationCommandInput
139+
| GetProvisionedModelThroughputCommandInput
117140
| ListCustomModelsCommandInput
118141
| ListFoundationModelsCommandInput
119142
| ListModelCustomizationJobsCommandInput
143+
| ListProvisionedModelThroughputsCommandInput
120144
| ListTagsForResourceCommandInput
121145
| PutModelInvocationLoggingConfigurationCommandInput
122146
| StopModelCustomizationJobCommandInput
123147
| TagResourceCommandInput
124-
| UntagResourceCommandInput;
148+
| UntagResourceCommandInput
149+
| UpdateProvisionedModelThroughputCommandInput;
125150

126151
/**
127152
* @public
128153
*/
129154
export type ServiceOutputTypes =
130155
| CreateModelCustomizationJobCommandOutput
156+
| CreateProvisionedModelThroughputCommandOutput
131157
| DeleteCustomModelCommandOutput
132158
| DeleteModelInvocationLoggingConfigurationCommandOutput
159+
| DeleteProvisionedModelThroughputCommandOutput
133160
| GetCustomModelCommandOutput
134161
| GetFoundationModelCommandOutput
135162
| GetModelCustomizationJobCommandOutput
136163
| GetModelInvocationLoggingConfigurationCommandOutput
164+
| GetProvisionedModelThroughputCommandOutput
137165
| ListCustomModelsCommandOutput
138166
| ListFoundationModelsCommandOutput
139167
| ListModelCustomizationJobsCommandOutput
168+
| ListProvisionedModelThroughputsCommandOutput
140169
| ListTagsForResourceCommandOutput
141170
| PutModelInvocationLoggingConfigurationCommandOutput
142171
| StopModelCustomizationJobCommandOutput
143172
| TagResourceCommandOutput
144-
| UntagResourceCommandOutput;
173+
| UntagResourceCommandOutput
174+
| UpdateProvisionedModelThroughputCommandOutput;
145175

146176
/**
147177
* @public

0 commit comments

Comments
 (0)