ozil
ozil

Reputation: 669

how to create a serverless endpoint in sagemaker?

I followed the aws documentation ( https://docs.aws.amazon.com/sagemaker/latest/dg/serverless-endpoints-create.html#serverless-endpoints-create-config) to create a model and to use that model, i coded for a serverless endpoint config (sample code below) ,I have all the required values but this throws an error below and i'm not sure why

parameter validation failed unknown parameter inProductVariants [ 0 ]: "ServerlessConfig", must be one of : VairantName, ModelName, InitialInstanceCount , Instancetype...

response = client.create_endpoint_config(
   EndpointConfigName="abc",
   ProductionVariants=[
        {
            "ModelName": "foo",
            "VariantName": "variant-1",
            "ServerlessConfig": {
                "MemorySizeInMB": 1024,
                "MaxConcurrency": 2
            }
        } 
    ]
)

Upvotes: 2

Views: 527

Answers (1)

Marcin
Marcin

Reputation: 238199

You are probably using old boto3 version. ServerlessConfig is a very new configuration option. You need to upgrade to the latest version (1.21.1) if possible.

Upvotes: 1

Related Questions