Skip to main content

annotation_spec_sets

Creates, updates, deletes, gets or lists an annotation_spec_sets resource.

Overview

Nameannotation_spec_sets
TypeResource
Idgoogle.datalabeling.annotation_spec_sets

Fields

The following fields are returned by SELECT queries:

Successful response

NameDatatypeDescription
namestringOutput only. The AnnotationSpecSet resource name in the following format: "projects/{project_id}/annotationSpecSets/{annotation_spec_set_id}"
annotationSpecsarrayRequired. The array of AnnotationSpecs that you define when you create the AnnotationSpecSet. These are the possible labels for the labeling task.
blockingResourcesarrayOutput only. The names of any related resources that are blocking changes to the annotation spec set.
descriptionstringOptional. User-provided description of the annotation specification set. The description can be up to 10,000 characters long.
displayNamestringRequired. The display name for AnnotationSpecSet that you define when you create it. Maximum of 64 characters.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
projects_annotation_spec_sets_getselectprojectsId, annotationSpecSetsIdGets an annotation spec set by resource name.
projects_annotation_spec_sets_listselectprojectsIdfilter, pageSize, pageTokenLists annotation spec sets for a project. Pagination is supported.
projects_annotation_spec_sets_createinsertprojectsIdCreates an annotation spec set by providing a set of labels.
projects_annotation_spec_sets_deletedeleteprojectsId, annotationSpecSetsIdDeletes an annotation spec set by resource name.

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
annotationSpecSetsIdstring
projectsIdstring
filterstring
pageSizeinteger (int32)
pageTokenstring

SELECT examples

Gets an annotation spec set by resource name.

SELECT
name,
annotationSpecs,
blockingResources,
description,
displayName
FROM google.datalabeling.annotation_spec_sets
WHERE projectsId = '{{ projectsId }}' -- required
AND annotationSpecSetsId = '{{ annotationSpecSetsId }}' -- required;

INSERT examples

Creates an annotation spec set by providing a set of labels.

INSERT INTO google.datalabeling.annotation_spec_sets (
data__annotationSpecSet,
projectsId
)
SELECT
'{{ annotationSpecSet }}',
'{{ projectsId }}'
RETURNING
name,
annotationSpecs,
blockingResources,
description,
displayName
;

DELETE examples

Deletes an annotation spec set by resource name.

DELETE FROM google.datalabeling.annotation_spec_sets
WHERE projectsId = '{{ projectsId }}' --required
AND annotationSpecSetsId = '{{ annotationSpecSetsId }}' --required;