/AWS1/IF_SGM=>CREATEAIWORKLOADCONFIG()¶
About CreateAIWorkloadConfig¶
Creates a reusable AI workload configuration that defines datasets, data sources, and benchmark tool settings for consistent performance testing of generative AI inference deployments on Amazon SageMaker AI.
Method Signature¶
METHODS /AWS1/IF_SGM~CREATEAIWORKLOADCONFIG
IMPORTING
!IV_AIWORKLOADCONFIGNAME TYPE /AWS1/SGMAIENTITYNAME OPTIONAL
!IO_DATASETCONFIG TYPE REF TO /AWS1/CL_SGMAIDATASETCONFIG OPTIONAL
!IO_AIWORKLOADCONFIGS TYPE REF TO /AWS1/CL_SGMAIWORKLOADCONFIGS OPTIONAL
!IT_TAGS TYPE /AWS1/CL_SGMTAG=>TT_TAGLIST OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_sgmcreateaiwkldcfgrsp
RAISING
/AWS1/CX_SGMRESOURCEINUSE
/AWS1/CX_SGMRESOURCELIMITEXCD
/AWS1/CX_SGMCLIENTEXC
/AWS1/CX_SGMSERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
iv_aiworkloadconfigname TYPE /AWS1/SGMAIENTITYNAME /AWS1/SGMAIENTITYNAME¶
The name of the AI workload configuration. The name must be unique within your Amazon Web Services account in the current Amazon Web Services Region.
Optional arguments:¶
io_datasetconfig TYPE REF TO /AWS1/CL_SGMAIDATASETCONFIG /AWS1/CL_SGMAIDATASETCONFIG¶
The dataset configuration for the workload. Specify input data channels with their data sources for benchmark workloads.
io_aiworkloadconfigs TYPE REF TO /AWS1/CL_SGMAIWORKLOADCONFIGS /AWS1/CL_SGMAIWORKLOADCONFIGS¶
The benchmark tool configuration and workload specification. Provide the specification as an inline YAML or JSON string.
it_tags TYPE /AWS1/CL_SGMTAG=>TT_TAGLIST TT_TAGLIST¶
The metadata that you apply to Amazon Web Services resources to help you categorize and organize them. Each tag consists of a key and a value, both of which you define. For more information, see Tagging Amazon Web Services Resources in the Amazon Web Services General Reference.
RETURNING¶
oo_output TYPE REF TO /aws1/cl_sgmcreateaiwkldcfgrsp /AWS1/CL_SGMCREATEAIWKLDCFGRSP¶
Examples¶
Syntax Example¶
This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.
DATA(lo_result) = lo_client->createaiworkloadconfig(
io_aiworkloadconfigs = new /aws1/cl_sgmaiworkloadconfigs( new /aws1/cl_sgmworkloadspec( |string| ) )
io_datasetconfig = new /aws1/cl_sgmaidatasetconfig(
it_inputdataconfig = VALUE /aws1/cl_sgmaiwkldinputdatacfg=>tt_aiwkldinputdataconfiglist(
(
new /aws1/cl_sgmaiwkldinputdatacfg(
io_datasource = new /aws1/cl_sgmaiwklddatasource( new /aws1/cl_sgmaiwklds3datasource( |string| ) )
iv_channelname = |string|
)
)
)
)
it_tags = VALUE /aws1/cl_sgmtag=>tt_taglist(
(
new /aws1/cl_sgmtag(
iv_key = |string|
iv_value = |string|
)
)
)
iv_aiworkloadconfigname = |string|
).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lv_aiworkloadconfigarn = lo_result->get_aiworkloadconfigarn( ).
ENDIF.