datasets
Creates, updates, deletes, gets or lists a datasets
resource.
Overview
Name | datasets |
Type | Resource |
Id | google.contactcenterinsights.datasets |
Fields
The following fields are returned by SELECT
queries:
- get
- list
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Immutable. Identifier. Resource name of the dataset. Format: projects/{project}/locations/{location}/datasets/{dataset} |
createTime | string (google-datetime) | Output only. Dataset create time. |
description | string | Dataset description. |
displayName | string | Display name for the dataaset |
ttl | string (google-duration) | Optional. Option TTL for the dataset. |
type | string | Dataset usage type. |
updateTime | string (google-datetime) | Output only. Dataset update time. |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Immutable. Identifier. Resource name of the dataset. Format: projects/{project}/locations/{location}/datasets/{dataset} |
createTime | string (google-datetime) | Output only. Dataset create time. |
description | string | Dataset description. |
displayName | string | Display name for the dataaset |
ttl | string (google-duration) | Optional. Option TTL for the dataset. |
type | string | Dataset usage type. |
updateTime | string (google-datetime) | Output only. Dataset update time. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | projectsId , locationsId , datasetsId | Gets a dataset. | |
list | select | projectsId , locationsId | pageSize , pageToken , filter | List datasets matching the input. |
create | insert | projectsId , locationsId | datasetId | Creates a dataset. |
patch | update | projectsId , locationsId , datasetsId | updateMask | Updates a dataset. |
delete | delete | projectsId , locationsId , datasetsId | Delete a dataset. | |
bulk_delete_feedback_labels | delete | projectsId , locationsId , datasetsId | Delete feedback labels in bulk using a filter. | |
bulk_upload_feedback_labels | exec | projectsId , locationsId , datasetsId | Upload feedback labels from an external source in bulk. Currently supports labeling Quality AI example conversations. | |
bulk_download_feedback_labels | exec | projectsId , locationsId , datasetsId | Download feedback labels in bulk from an external source. Currently supports exporting Quality AI example conversations with transcripts and question bodies. | |
export | exec | projectsId , locationsId , datasetsId | Export insights data to a destination defined in the request body. |
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.
Name | Datatype | Description |
---|---|---|
datasetsId | string | |
locationsId | string | |
projectsId | string | |
datasetId | string | |
filter | string | |
pageSize | integer (int32) | |
pageToken | string | |
updateMask | string (google-fieldmask) |
SELECT
examples
- get
- list
Gets a dataset.
SELECT
name,
createTime,
description,
displayName,
ttl,
type,
updateTime
FROM google.contactcenterinsights.datasets
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND datasetsId = '{{ datasetsId }}' -- required;
List datasets matching the input.
SELECT
name,
createTime,
description,
displayName,
ttl,
type,
updateTime
FROM google.contactcenterinsights.datasets
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND pageSize = '{{ pageSize }}'
AND pageToken = '{{ pageToken }}'
AND filter = '{{ filter }}';
INSERT
examples
- create
- Manifest
Creates a dataset.
INSERT INTO google.contactcenterinsights.datasets (
data__name,
data__displayName,
data__description,
data__type,
data__ttl,
projectsId,
locationsId,
datasetId
)
SELECT
'{{ name }}',
'{{ displayName }}',
'{{ description }}',
'{{ type }}',
'{{ ttl }}',
'{{ projectsId }}',
'{{ locationsId }}',
'{{ datasetId }}'
RETURNING
name,
createTime,
description,
displayName,
ttl,
type,
updateTime
;
# Description fields are for documentation purposes
- name: datasets
props:
- name: projectsId
value: string
description: Required parameter for the datasets resource.
- name: locationsId
value: string
description: Required parameter for the datasets resource.
- name: name
value: string
description: >
Immutable. Identifier. Resource name of the dataset. Format: projects/{project}/locations/{location}/datasets/{dataset}
- name: displayName
value: string
description: >
Display name for the dataaset
- name: description
value: string
description: >
Dataset description.
- name: type
value: string
description: >
Dataset usage type.
valid_values: ['TYPE_UNSPECIFIED', 'EVAL', 'LIVE']
- name: ttl
value: string
description: >
Optional. Option TTL for the dataset.
- name: datasetId
value: string
UPDATE
examples
- patch
Updates a dataset.
UPDATE google.contactcenterinsights.datasets
SET
data__name = '{{ name }}',
data__displayName = '{{ displayName }}',
data__description = '{{ description }}',
data__type = '{{ type }}',
data__ttl = '{{ ttl }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND datasetsId = '{{ datasetsId }}' --required
AND updateMask = '{{ updateMask}}'
RETURNING
name,
createTime,
description,
displayName,
ttl,
type,
updateTime;
DELETE
examples
- delete
- bulk_delete_feedback_labels
Delete a dataset.
DELETE FROM google.contactcenterinsights.datasets
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND datasetsId = '{{ datasetsId }}' --required;
Delete feedback labels in bulk using a filter.
DELETE FROM google.contactcenterinsights.datasets
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND datasetsId = '{{ datasetsId }}' --required;
Lifecycle Methods
- bulk_upload_feedback_labels
- bulk_download_feedback_labels
- export
Upload feedback labels from an external source in bulk. Currently supports labeling Quality AI example conversations.
EXEC google.contactcenterinsights.datasets.bulk_upload_feedback_labels
@projectsId='{{ projectsId }}' --required,
@locationsId='{{ locationsId }}' --required,
@datasetsId='{{ datasetsId }}' --required
@@json=
'{
"gcsSource": "{{ gcsSource }}",
"sheetsSource": "{{ sheetsSource }}",
"validateOnly": {{ validateOnly }}
}';
Download feedback labels in bulk from an external source. Currently supports exporting Quality AI example conversations with transcripts and question bodies.
EXEC google.contactcenterinsights.datasets.bulk_download_feedback_labels
@projectsId='{{ projectsId }}' --required,
@locationsId='{{ locationsId }}' --required,
@datasetsId='{{ datasetsId }}' --required
@@json=
'{
"gcsDestination": "{{ gcsDestination }}",
"sheetsDestination": "{{ sheetsDestination }}",
"parent": "{{ parent }}",
"filter": "{{ filter }}",
"maxDownloadCount": {{ maxDownloadCount }},
"feedbackLabelType": "{{ feedbackLabelType }}",
"conversationFilter": "{{ conversationFilter }}",
"templateQaScorecardId": "{{ templateQaScorecardId }}"
}';
Export insights data to a destination defined in the request body.
EXEC google.contactcenterinsights.datasets.export
@projectsId='{{ projectsId }}' --required,
@locationsId='{{ locationsId }}' --required,
@datasetsId='{{ datasetsId }}' --required
@@json=
'{
"bigQueryDestination": "{{ bigQueryDestination }}",
"parent": "{{ parent }}",
"filter": "{{ filter }}",
"kmsKey": "{{ kmsKey }}",
"writeDisposition": "{{ writeDisposition }}",
"exportSchemaVersion": "{{ exportSchemaVersion }}"
}';