Skip to content

Commit

Permalink
feat(client-lookoutvision): This release introduces support for the a…
Browse files Browse the repository at this point in the history
…utomatic scaling of inference units used by Amazon Lookout for Vision models.
  • Loading branch information
awstools committed Jul 26, 2022
1 parent 8424fee commit 65ad083
Show file tree
Hide file tree
Showing 5 changed files with 49 additions and 3 deletions.
3 changes: 2 additions & 1 deletion clients/client-lookoutvision/src/LookoutVision.ts
Original file line number Diff line number Diff line change
Expand Up @@ -620,7 +620,8 @@ export class LookoutVision extends LookoutVisionClient {
}

/**
* <p>Lists the Amazon Lookout for Vision projects in your AWS account.</p>
* <p>Lists the Amazon Lookout for Vision projects in your AWS account that are in the AWS Region in
* which you call <code>ListProjects</code>.</p>
* <p>The <code>ListProjects</code> operation is eventually consistent.
* Recent calls to <code>CreateProject</code> and <code>DeleteProject</code> might
* take a while to appear in the response from <code>ListProjects</code>.</p>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ export interface ListProjectsCommandInput extends ListProjectsRequest {}
export interface ListProjectsCommandOutput extends ListProjectsResponse, __MetadataBearer {}

/**
* <p>Lists the Amazon Lookout for Vision projects in your AWS account.</p>
* <p>Lists the Amazon Lookout for Vision projects in your AWS account that are in the AWS Region in
* which you call <code>ListProjects</code>.</p>
* <p>The <code>ListProjects</code> operation is eventually consistent.
* Recent calls to <code>CreateProject</code> and <code>DeleteProject</code> might
* take a while to appear in the response from <code>ListProjects</code>.</p>
Expand Down
19 changes: 19 additions & 0 deletions clients/client-lookoutvision/src/models/models_0.ts
Original file line number Diff line number Diff line change
Expand Up @@ -846,6 +846,19 @@ export interface ModelDescription {
* during training.</p>
*/
KmsKeyId?: string;

/**
* <p>The minimum number of inference units used by the model. For more information,
* see <a>StartModel</a>
* </p>
*/
MinInferenceUnits?: number;

/**
* <p>The maximum number of inference units Amazon Lookout for Vision uses to auto-scale the model.
* For more information, see <a>StartModel</a>.</p>
*/
MaxInferenceUnits?: number;
}

export interface DescribeModelResponse {
Expand Down Expand Up @@ -1533,6 +1546,12 @@ export interface StartModelRequest {
* </p>
*/
ClientToken?: string;

/**
* <p>The maximum number of inference units to use for auto-scaling the model. If you don't
* specify a value, Amazon Lookout for Vision doesn't auto-scale the model.</p>
*/
MaxInferenceUnits?: number;
}

export enum ModelHostingStatus {
Expand Down
3 changes: 3 additions & 0 deletions clients/client-lookoutvision/src/protocols/Aws_restJson1.ts
Original file line number Diff line number Diff line change
Expand Up @@ -707,6 +707,7 @@ export const serializeAws_restJson1StartModelCommand = async (
}
let body: any;
body = JSON.stringify({
...(input.MaxInferenceUnits != null && { MaxInferenceUnits: input.MaxInferenceUnits }),
...(input.MinInferenceUnits != null && { MinInferenceUnits: input.MinInferenceUnits }),
});
return new __HttpRequest({
Expand Down Expand Up @@ -2627,6 +2628,8 @@ const deserializeAws_restJson1ModelDescription = (output: any, context: __SerdeC
? deserializeAws_restJson1OutputS3Object(output.EvaluationResult, context)
: undefined,
KmsKeyId: __expectString(output.KmsKeyId),
MaxInferenceUnits: __expectInt32(output.MaxInferenceUnits),
MinInferenceUnits: __expectInt32(output.MinInferenceUnits),
ModelArn: __expectString(output.ModelArn),
ModelVersion: __expectString(output.ModelVersion),
OutputConfig:
Expand Down
24 changes: 23 additions & 1 deletion codegen/sdk-codegen/aws-models/lookoutvision.json
Original file line number Diff line number Diff line change
Expand Up @@ -1468,6 +1468,7 @@
"smithy.api#paginated": {
"inputToken": "NextToken",
"outputToken": "NextToken",
"items": "DatasetEntries",
"pageSize": "MaxResults"
}
}
Expand Down Expand Up @@ -1594,6 +1595,7 @@
"smithy.api#paginated": {
"inputToken": "NextToken",
"outputToken": "NextToken",
"items": "ModelPackagingJobs",
"pageSize": "MaxResults"
}
}
Expand Down Expand Up @@ -1680,6 +1682,7 @@
"smithy.api#paginated": {
"inputToken": "NextToken",
"outputToken": "NextToken",
"items": "Models",
"pageSize": "MaxResults"
}
}
Expand Down Expand Up @@ -1757,7 +1760,7 @@
}
],
"traits": {
"smithy.api#documentation": "<p>Lists the Amazon Lookout for Vision projects in your AWS account.</p>\n <p>The <code>ListProjects</code> operation is eventually consistent. \n Recent calls to <code>CreateProject</code> and <code>DeleteProject</code> might\n take a while to appear in the response from <code>ListProjects</code>.</p>\n <p>This operation requires permissions to perform the\n <code>lookoutvision:ListProjects</code> operation.</p>",
"smithy.api#documentation": "<p>Lists the Amazon Lookout for Vision projects in your AWS account that are in the AWS Region in \n which you call <code>ListProjects</code>.</p>\n <p>The <code>ListProjects</code> operation is eventually consistent. \n Recent calls to <code>CreateProject</code> and <code>DeleteProject</code> might\n take a while to appear in the response from <code>ListProjects</code>.</p>\n <p>This operation requires permissions to perform the\n <code>lookoutvision:ListProjects</code> operation.</p>",
"smithy.api#http": {
"method": "GET",
"uri": "/2020-11-20/projects",
Expand All @@ -1766,6 +1769,7 @@
"smithy.api#paginated": {
"inputToken": "NextToken",
"outputToken": "NextToken",
"items": "Projects",
"pageSize": "MaxResults"
}
}
Expand Down Expand Up @@ -2031,6 +2035,18 @@
"traits": {
"smithy.api#documentation": "<p>The identifer for the AWS Key Management Service (AWS KMS) key that was used to encrypt the model\n during training.</p>"
}
},
"MinInferenceUnits": {
"target": "com.amazonaws.lookoutvision#InferenceUnits",
"traits": {
"smithy.api#documentation": "<p>The minimum number of inference units used by the model. For more information,\n see <a>StartModel</a>\n </p>"
}
},
"MaxInferenceUnits": {
"target": "com.amazonaws.lookoutvision#InferenceUnits",
"traits": {
"smithy.api#documentation": "<p>The maximum number of inference units Amazon Lookout for Vision uses to auto-scale the model.\n For more information, see <a>StartModel</a>.</p>"
}
}
},
"traits": {
Expand Down Expand Up @@ -2927,6 +2943,12 @@
"smithy.api#httpHeader": "X-Amzn-Client-Token",
"smithy.api#idempotencyToken": {}
}
},
"MaxInferenceUnits": {
"target": "com.amazonaws.lookoutvision#InferenceUnits",
"traits": {
"smithy.api#documentation": "<p>The maximum number of inference units to use for auto-scaling the model. If you don't\n specify a value, Amazon Lookout for Vision doesn't auto-scale the model.</p>"
}
}
}
},
Expand Down

0 comments on commit 65ad083

Please sign in to comment.