Neptune ML inference endpoint API
Inference endpoint actions:
CreateMLEndpoint (action)
The AWS CLI name for this API is: create-ml-endpoint
.
Creates a new Neptune ML inference endpoint that lets you query one specific model that the model-training process constructed. See Managing inference endpoints using the endpoints command.
When invoking this operation in a Neptune cluster that has IAM authentication enabled, the IAM user or role making the request must have a policy attached that allows the neptune-db:CreateMLEndpoint IAM action in that cluster.
Request
-
id (in the CLI:
--id
) – a String, of type:string
(a UTF-8 encoded string).A unique identifier for the new inference endpoint. The default is an autogenerated timestamped name.
-
instanceCount (in the CLI:
--instance-count
) – an Integer, of type:integer
(a signed 32-bit integer).The minimum number of Amazon EC2 instances to deploy to an endpoint for prediction. The default is 1
-
instanceType (in the CLI:
--instance-type
) – a String, of type:string
(a UTF-8 encoded string).The type of Neptune ML instance to use for online servicing. The default is
ml.m5.xlarge
. Choosing the ML instance for an inference endpoint depends on the task type, the graph size, and your budget. -
mlModelTrainingJobId (in the CLI:
--ml-model-training-job-id
) – a String, of type:string
(a UTF-8 encoded string).The job Id of the completed model-training job that has created the model that the inference endpoint will point to. You must supply either the
mlModelTrainingJobId
or themlModelTransformJobId
. -
mlModelTransformJobId (in the CLI:
--ml-model-transform-job-id
) – a String, of type:string
(a UTF-8 encoded string).The job Id of the completed model-transform job. You must supply either the
mlModelTrainingJobId
or themlModelTransformJobId
. -
modelName (in the CLI:
--model-name
) – a String, of type:string
(a UTF-8 encoded string).Model type for training. By default the Neptune ML model is automatically based on the
modelType
used in data processing, but you can specify a different model type here. The default isrgcn
for heterogeneous graphs andkge
for knowledge graphs. The only valid value for heterogeneous graphs isrgcn
. Valid values for knowledge graphs are:kge
,transe
,distmult
, androtate
. -
neptuneIamRoleArn (in the CLI:
--neptune-iam-role-arn
) – a String, of type:string
(a UTF-8 encoded string).The ARN of an IAM role providing Neptune access to SageMaker and Amazon S3 resources. This must be listed in your DB cluster parameter group or an error will be thrown.
-
update (in the CLI:
--update
) – a Boolean, of type:boolean
(a Boolean (true or false) value).If set to
true
,update
indicates that this is an update request. The default isfalse
. You must supply either themlModelTrainingJobId
or themlModelTransformJobId
. -
volumeEncryptionKMSKey (in the CLI:
--volume-encryption-kms-key
) – a String, of type:string
(a UTF-8 encoded string).The Amazon Key Management Service (Amazon KMS) key that SageMaker uses to encrypt data on the storage volume attached to the ML compute instances that run the training job. The default is None.
Response
-
arn – a String, of type:
string
(a UTF-8 encoded string).The ARN for the new inference endpoint.
-
creationTimeInMillis – a Long, of type:
long
(a signed 64-bit integer).The endpoint creation time, in milliseconds.
-
id – a String, of type:
string
(a UTF-8 encoded string).The unique ID of the new inference endpoint.
Errors
ListMLEndpoints (action)
The AWS CLI name for this API is: list-ml-endpoints
.
Lists existing inference endpoints. See Managing inference endpoints using the endpoints command.
When invoking this operation in a Neptune cluster that has IAM authentication enabled, the IAM user or role making the request must have a policy attached that allows the neptune-db:ListMLEndpoints IAM action in that cluster.
Request
-
maxItems (in the CLI:
--max-items
) – a ListMLEndpointsInputMaxItemsInteger, of type:integer
(a signed 32-bit integer), not less than 1 or more than 1024 ?st?s.The maximum number of items to return (from 1 to 1024; the default is 10.
-
neptuneIamRoleArn (in the CLI:
--neptune-iam-role-arn
) – a String, of type:string
(a UTF-8 encoded string).The ARN of an IAM role that provides Neptune access to SageMaker and Amazon S3 resources. This must be listed in your DB cluster parameter group or an error will occur.
Response
-
ids – a String, of type:
string
(a UTF-8 encoded string).A page from the list of inference endpoint IDs.
Errors
GetMLEndpoint (action)
The AWS CLI name for this API is: get-ml-endpoint
.
Retrieves details about an inference endpoint. See Managing inference endpoints using the endpoints command.
When invoking this operation in a Neptune cluster that has IAM authentication enabled, the IAM user or role making the request must have a policy attached that allows the neptune-db:GetMLEndpointStatus IAM action in that cluster.
Request
-
id (in the CLI:
--id
) – Required: a String, of type:string
(a UTF-8 encoded string).The unique identifier of the inference endpoint.
-
neptuneIamRoleArn (in the CLI:
--neptune-iam-role-arn
) – a String, of type:string
(a UTF-8 encoded string).The ARN of an IAM role that provides Neptune access to SageMaker and Amazon S3 resources. This must be listed in your DB cluster parameter group or an error will occur.
Response
-
endpoint – A MlResourceDefinition object.
The endpoint definition.
-
endpointConfig – A MlConfigDefinition object.
The endpoint configuration
-
id – a String, of type:
string
(a UTF-8 encoded string).The unique identifier of the inference endpoint.
-
status – a String, of type:
string
(a UTF-8 encoded string).The status of the inference endpoint.
Errors
DeleteMLEndpoint (action)
The AWS CLI name for this API is: delete-ml-endpoint
.
Cancels the creation of a Neptune ML inference endpoint. See Managing inference endpoints using the endpoints command.
When invoking this operation in a Neptune cluster that has IAM authentication enabled, the IAM user or role making the request must have a policy attached that allows the neptune-db:DeleteMLEndpoint IAM action in that cluster.
Request
-
clean (in the CLI:
--clean
) – a Boolean, of type:boolean
(a Boolean (true or false) value).If this flag is set to
TRUE
, all Neptune ML S3 artifacts should be deleted when the job is stopped. The default isFALSE
. -
id (in the CLI:
--id
) – Required: a String, of type:string
(a UTF-8 encoded string).The unique identifier of the inference endpoint.
-
neptuneIamRoleArn (in the CLI:
--neptune-iam-role-arn
) – a String, of type:string
(a UTF-8 encoded string).The ARN of an IAM role providing Neptune access to SageMaker and Amazon S3 resources. This must be listed in your DB cluster parameter group or an error will be thrown.
Response
-
status – a String, of type:
string
(a UTF-8 encoded string).The status of the cancellation.