Skip to main content

data_labeling_jobs

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

Overview

Namedata_labeling_jobs
TypeResource
Idgoogle.aiplatform.data_labeling_jobs

Fields

NameDatatypeDescription
namestringOutput only. Resource name of the DataLabelingJob.
activeLearningConfigobjectParameters that configure the active learning pipeline. Active learning will label the data incrementally by several iterations. For every iteration, it will select a batch of data based on the sampling strategy.
annotationLabelsobjectLabels to assign to annotations generated by this DataLabelingJob. Label keys and values can be no longer than 64 characters (Unicode codepoints), can only contain lowercase letters, numeric characters, underscores and dashes. International characters are allowed. See https://goo.gl/xmQnxf for more information and examples of labels. System reserved label keys are prefixed with "aiplatform.googleapis.com/" and are immutable.
createTimestringOutput only. Timestamp when this DataLabelingJob was created.
currentSpendobjectRepresents an amount of money with its currency type.
datasetsarrayRequired. Dataset resource names. Right now we only support labeling from a single Dataset. Format: projects/{project}/locations/{location}/datasets/{dataset}
displayNamestringRequired. The user-defined name of the DataLabelingJob. The name can be up to 128 characters long and can consist of any UTF-8 characters. Display name of a DataLabelingJob.
encryptionSpecobjectRepresents a customer-managed encryption key spec that can be applied to a top-level resource.
errorobjectThe Status type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by gRPC. Each Status message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the API Design Guide.
inputsanyRequired. Input config parameters for the DataLabelingJob.
inputsSchemaUristringRequired. Points to a YAML file stored on Google Cloud Storage describing the config for a specific type of DataLabelingJob. The schema files that can be used here are found in the https://storage.googleapis.com/google-cloud-aiplatform bucket in the /schema/datalabelingjob/inputs/ folder.
instructionUristringRequired. The Google Cloud Storage location of the instruction pdf. This pdf is shared with labelers, and provides detailed description on how to label DataItems in Datasets.
labelerCountintegerRequired. Number of labelers to work on each DataItem.
labelingProgressintegerOutput only. Current labeling job progress percentage scaled in interval [0, 100], indicating the percentage of DataItems that has been finished.
labelsobjectThe labels with user-defined metadata to organize your DataLabelingJobs. Label keys and values can be no longer than 64 characters (Unicode codepoints), can only contain lowercase letters, numeric characters, underscores and dashes. International characters are allowed. See https://goo.gl/xmQnxf for more information and examples of labels. System reserved label keys are prefixed with "aiplatform.googleapis.com/" and are immutable. Following system labels exist for each DataLabelingJob: * "aiplatform.googleapis.com/schema": output only, its value is the inputs_schema's title.
specialistPoolsarrayThe SpecialistPools' resource names associated with this job.
statestringOutput only. The detailed state of the job.
updateTimestringOutput only. Timestamp when this DataLabelingJob was updated most recently.

Methods

NameAccessible byRequired ParamsDescription
getSELECTdataLabelingJobsId, locationsId, projectsIdGets a DataLabelingJob.
listSELECTlocationsId, projectsIdLists DataLabelingJobs in a Location.
createINSERTlocationsId, projectsIdCreates a DataLabelingJob.
deleteDELETEdataLabelingJobsId, locationsId, projectsIdDeletes a DataLabelingJob.
cancelEXECdataLabelingJobsId, locationsId, projectsIdCancels a DataLabelingJob. Success of cancellation is not guaranteed.

SELECT examples

Lists DataLabelingJobs in a Location.

SELECT
name,
activeLearningConfig,
annotationLabels,
createTime,
currentSpend,
datasets,
displayName,
encryptionSpec,
error,
inputs,
inputsSchemaUri,
instructionUri,
labelerCount,
labelingProgress,
labels,
specialistPools,
state,
updateTime
FROM google.aiplatform.data_labeling_jobs
WHERE locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';

INSERT example

Use the following StackQL query and manifest file to create a new data_labeling_jobs resource.

/*+ create */
INSERT INTO google.aiplatform.data_labeling_jobs (
locationsId,
projectsId,
datasets,
labelerCount,
instructionUri,
activeLearningConfig,
inputsSchemaUri,
inputs,
encryptionSpec,
annotationLabels,
displayName,
labels,
specialistPools
)
SELECT
'{{ locationsId }}',
'{{ projectsId }}',
'{{ datasets }}',
'{{ labelerCount }}',
'{{ instructionUri }}',
'{{ activeLearningConfig }}',
'{{ inputsSchemaUri }}',
'{{ inputs }}',
'{{ encryptionSpec }}',
'{{ annotationLabels }}',
'{{ displayName }}',
'{{ labels }}',
'{{ specialistPools }}'
;

DELETE example

Deletes the specified data_labeling_jobs resource.

/*+ delete */
DELETE FROM google.aiplatform.data_labeling_jobs
WHERE dataLabelingJobsId = '{{ dataLabelingJobsId }}'
AND locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';