Skip to main content

jobs

Creates, updates, deletes, gets or lists a jobs resource.

Overview

Namejobs
TypeResource
Idaws.braket.jobs

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
algorithm_specificationobjectDefines the Amazon Braket hybrid job to be created. Specifies the container image the job uses and the paths to the Python scripts used for entry and training.
associationsarrayThe list of Amazon Braket resources associated with the hybrid job.
billable_durationintegerThe billable time for which the Amazon Braket hybrid job used to complete.
checkpoint_configobjectContains information about the output locations for hybrid job checkpoint data.
created_atstring (date-time)The time at which the Amazon Braket hybrid job was created.
device_configobjectConfigures the primary device used to create and run an Amazon Braket hybrid job.
ended_atstring (date-time)The time at which the Amazon Braket hybrid job ended.
eventsarrayDetails about the time and type of events occurred related to the Amazon Braket hybrid job.
failure_reasonstringA description of the reason why an Amazon Braket hybrid job failed, if it failed.
hyper_parametersobjectAlgorithm-specific parameters used by an Amazon Braket hybrid job that influence the quality of the traiing job. The values are set with a map of JSON key:value pairs, where the key is the name of the hyperparameter and the value is the value of th hyperparameter.
input_data_configarrayA list of parameters that specify the name and type of input data and where it is located.
instance_configobjectConfigures the resource instances to use while running the Amazon Braket hybrid job on Amazon Braket.
job_arnstringThe ARN of the Amazon Braket hybrid job. (pattern: <code>arn:aws[a-z-]:braket:[a-z0-9-]+:[0-9]{12}:job/.</code>)
job_namestringThe name of the Amazon Braket hybrid job. (pattern: <code>[a-zA-Z0-9](-*[a-zA-Z0-9]){0,50}</code>)
output_data_configobjectSpecifies the path to the S3 location where you want to store hybrid job artifacts and the encryption key used to store them.
queue_infoobjectQueue information for the requested hybrid job. Only returned if QueueInfo is specified in the additionalAttributeNames" field in the GetJob API request.
role_arnstringThe Amazon Resource Name (ARN) of an IAM role that Amazon Braket can assume to perform tasks on behalf of a user. It can access user resources, run an Amazon Braket job container on behalf of user, and output results and other hybrid job details to the s3 buckets of a user. (pattern: <code>arn:aws[a-z-]*:iam::\d{12}:role/?[a-zA-Z_0-9+=,.@-_/]+</code>)
started_atstring (date-time)The time at which the Amazon Braket hybrid job was started.
statusstringThe status of the Amazon Braket hybrid job. (QUEUED, RUNNING, COMPLETED, FAILED, CANCELLING, CANCELLED)
stopping_conditionobjectSpecifies limits for how long an Amazon Braket hybrid job can run.
tagsobjectThe tags associated with this hybrid job.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_jobselectjob_arn, regionadditionalAttributeNamesRetrieves the specified Amazon Braket hybrid job.
search_jobsselectregionSearches for Amazon Braket hybrid jobs that match the specified filter values.
create_jobinsertregion, clientToken, algorithmSpecification, outputDataConfig, jobName, roleArn, instanceConfig, deviceConfigCreates an Amazon Braket hybrid job.
cancel_jobexecjob_arn, regionCancels an Amazon Braket hybrid job.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
job_arnstringThe ARN of the Amazon Braket hybrid job to cancel.
regionstringAWS region (default: us-east-1)
additionalAttributeNamesarrayA list of attributes to return additional information for. Only the QueueInfo additional attribute name is currently supported.

SELECT examples

Retrieves the specified Amazon Braket hybrid job.

SELECT
algorithm_specification,
associations,
billable_duration,
checkpoint_config,
created_at,
device_config,
ended_at,
events,
failure_reason,
hyper_parameters,
input_data_config,
instance_config,
job_arn,
job_name,
output_data_config,
queue_info,
role_arn,
started_at,
status,
stopping_condition,
tags
FROM aws.braket.jobs
WHERE job_arn = '{{ job_arn }}' -- required
AND region = '{{ region }}' -- required
AND additionalAttributeNames = '{{ additionalAttributeNames }}'
;

INSERT examples

Creates an Amazon Braket hybrid job.

INSERT INTO aws.braket.jobs (
clientToken,
algorithmSpecification,
inputDataConfig,
outputDataConfig,
checkpointConfig,
jobName,
roleArn,
stoppingCondition,
instanceConfig,
hyperParameters,
deviceConfig,
tags,
associations,
region
)
SELECT
'{{ clientToken }}' /* required */,
'{{ algorithmSpecification }}' /* required */,
'{{ inputDataConfig }}',
'{{ outputDataConfig }}' /* required */,
'{{ checkpointConfig }}',
'{{ jobName }}' /* required */,
'{{ roleArn }}' /* required */,
'{{ stoppingCondition }}',
'{{ instanceConfig }}' /* required */,
'{{ hyperParameters }}',
'{{ deviceConfig }}' /* required */,
'{{ tags }}',
'{{ associations }}',
'{{ region }}'
RETURNING
job_arn
;

Lifecycle Methods

Cancels an Amazon Braket hybrid job.

EXEC aws.braket.jobs.cancel_job
@job_arn='{{ job_arn }}' --required,
@region='{{ region }}' --required
;