From 531d3b869ecec68fb5a97c61d0d873f365cd81df Mon Sep 17 00:00:00 2001 From: pm3310 Date: Sat, 13 Jan 2024 18:18:36 +0000 Subject: [PATCH] Add docs for foundation model deploy --- README.md | 40 ++++++++++++++++++++++++++++++++++++++++ docs/index.md | 40 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 80 insertions(+) diff --git a/README.md b/README.md index f8abaf7..1b7c272 100644 --- a/README.md +++ b/README.md @@ -927,3 +927,43 @@ Example of `xgboost_config.json`: { "framework_version": "0.23-1" } + + +### Cloud Foundation Model Deploy + +#### Name + +Command for deployment of Foundation models on SageMaker without code + +#### Synopsis +```sh +sagify cloud foundation-model-deploy --model-id MODEL_ID --model-version MODEL_VERSION --num-instances NUMBER_OF_EC2_INSTANCES --ec2-type EC2_TYPE --aws-profile AWS_PROFILE --aws-region AWS_REGION [--aws-tags TAGS] [--iam-role-arn IAM_ROLE] [--external-id EXTERNAL_ID] [--endpoint-name ENDPOINT_NAME] +``` + +#### Description + +This command deploys a Foundation model without code. + +#### Required Flags + +`--model-id MODEL_ID`: Model id of the Foundation model. For more, see the list of Foundation models https://sagemaker.readthedocs.io/en/stable/doc_utils/pretrainedmodels.html. + +`--model-version MODEL_VERSION`: Model verion of the Foundation model (default: 1.* which fetches the latest of this major version) + +`--num-instances NUMBER_OF_EC2_INSTANCES` or `n NUMBER_OF_EC2_INSTANCES`: Number of ec2 instances + +`--ec2-type EC2_TYPE` or `e EC2_TYPE`: ec2 type. Refer to https://aws.amazon.com/sagemaker/pricing/instance-types/ + +`--aws-profile AWS_PROFILE`: The AWS profile to use for the lightning deploy command + +`--aws-region AWS_REGION`: The AWS region to use for the lightning deploy command + +#### Optional Flags + +`--aws-tags TAGS` or `-a TAGS`: Tags for labeling a training job of the form `tag1=value1;tag2=value2`. For more, see https://docs.aws.amazon.com/sagemaker/latest/dg/API_Tag.html. + +`--iam-role-arn IAM_ROLE` or `-r IAM_ROLE`: AWS IAM role to use for deploying with *SageMaker* + +`--external-id EXTERNAL_ID` or `-x EXTERNAL_ID`: Optional external id used when using an IAM role + +`--endpoint-name ENDPOINT_NAME`: Optional name for the SageMaker endpoint diff --git a/docs/index.md b/docs/index.md index 0accf2b..efcdb81 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1634,3 +1634,43 @@ Example of `xgboost_config.json`: "framework_version": "0.23-1" } ``` + + +### Cloud Foundation Model Deploy + +#### Name + +Command for deployment of Foundation models on SageMaker without code + +#### Synopsis +```sh +sagify cloud foundation-model-deploy --model-id MODEL_ID --model-version MODEL_VERSION --num-instances NUMBER_OF_EC2_INSTANCES --ec2-type EC2_TYPE --aws-profile AWS_PROFILE --aws-region AWS_REGION [--aws-tags TAGS] [--iam-role-arn IAM_ROLE] [--external-id EXTERNAL_ID] [--endpoint-name ENDPOINT_NAME] +``` + +#### Description + +This command deploys a Foundation model without code. + +#### Required Flags + +`--model-id MODEL_ID`: Model id of the Foundation model. For more, see the list of Foundation models https://sagemaker.readthedocs.io/en/stable/doc_utils/pretrainedmodels.html. + +`--model-version MODEL_VERSION`: Model verion of the Foundation model (default: 1.* which fetches the latest of this major version) + +`--num-instances NUMBER_OF_EC2_INSTANCES` or `n NUMBER_OF_EC2_INSTANCES`: Number of ec2 instances + +`--ec2-type EC2_TYPE` or `e EC2_TYPE`: ec2 type. Refer to https://aws.amazon.com/sagemaker/pricing/instance-types/ + +`--aws-profile AWS_PROFILE`: The AWS profile to use for the lightning deploy command + +`--aws-region AWS_REGION`: The AWS region to use for the lightning deploy command + +#### Optional Flags + +`--aws-tags TAGS` or `-a TAGS`: Tags for labeling a training job of the form `tag1=value1;tag2=value2`. For more, see https://docs.aws.amazon.com/sagemaker/latest/dg/API_Tag.html. + +`--iam-role-arn IAM_ROLE` or `-r IAM_ROLE`: AWS IAM role to use for deploying with *SageMaker* + +`--external-id EXTERNAL_ID` or `-x EXTERNAL_ID`: Optional external id used when using an IAM role + +`--endpoint-name ENDPOINT_NAME`: Optional name for the SageMaker endpoint