generators
Creates, updates, deletes, gets or lists a generators
resource.
Overview
Name | generators |
Type | Resource |
Id | google.dialogflow.generators |
Fields
The following fields are returned by SELECT
queries:
- projects_locations_agents_generators_get
- projects_locations_agents_generators_list
Successful response
Name | Datatype | Description |
---|---|---|
name | string | The unique identifier of the generator. Must be set for the Generators.UpdateGenerator method. Generators.CreateGenerate populates the name automatically. Format: projects//locations//agents//generators/ . |
displayName | string | Required. The human-readable name of the generator, unique within the agent. The prompt contains pre-defined parameters such as $conversation, $last-user-utterance, etc. populated by Dialogflow. It can also contain custom placeholders which will be resolved during fulfillment. |
llmModelSettings | object | The LLM model settings. (id: GoogleCloudDialogflowCxV3LlmModelSettings) |
modelParameter | object | Parameters passed to the LLM to configure its behavior. (id: GoogleCloudDialogflowCxV3GeneratorModelParameter) |
placeholders | array | Optional. List of custom placeholders in the prompt text. |
promptText | object | Required. Prompt for the LLM model. (id: GoogleCloudDialogflowCxV3Phrase) |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | The unique identifier of the generator. Must be set for the Generators.UpdateGenerator method. Generators.CreateGenerate populates the name automatically. Format: projects//locations//agents//generators/ . |
displayName | string | Required. The human-readable name of the generator, unique within the agent. The prompt contains pre-defined parameters such as $conversation, $last-user-utterance, etc. populated by Dialogflow. It can also contain custom placeholders which will be resolved during fulfillment. |
llmModelSettings | object | The LLM model settings. (id: GoogleCloudDialogflowCxV3LlmModelSettings) |
modelParameter | object | Parameters passed to the LLM to configure its behavior. (id: GoogleCloudDialogflowCxV3GeneratorModelParameter) |
placeholders | array | Optional. List of custom placeholders in the prompt text. |
promptText | object | Required. Prompt for the LLM model. (id: GoogleCloudDialogflowCxV3Phrase) |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
projects_locations_agents_generators_get | select | projectsId , locationsId , agentsId , generatorsId | languageCode | Retrieves the specified generator. |
projects_locations_agents_generators_list | select | projectsId , locationsId , agentsId | languageCode , pageSize , pageToken | Returns the list of all generators in the specified agent. |
projects_locations_agents_generators_create | insert | projectsId , locationsId , agentsId | languageCode | Creates a generator in the specified agent. |
projects_locations_agents_generators_patch | update | projectsId , locationsId , agentsId , generatorsId | languageCode , updateMask | Update the specified generator. |
projects_locations_agents_generators_delete | delete | projectsId , locationsId , agentsId , generatorsId | force | Deletes the specified generators. |
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 |
---|---|---|
agentsId | string | |
generatorsId | string | |
locationsId | string | |
projectsId | string | |
force | boolean | |
languageCode | string | |
pageSize | integer (int32) | |
pageToken | string | |
updateMask | string (google-fieldmask) |
SELECT
examples
- projects_locations_agents_generators_get
- projects_locations_agents_generators_list
Retrieves the specified generator.
SELECT
name,
displayName,
llmModelSettings,
modelParameter,
placeholders,
promptText
FROM google.dialogflow.generators
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND agentsId = '{{ agentsId }}' -- required
AND generatorsId = '{{ generatorsId }}' -- required
AND languageCode = '{{ languageCode }}';
Returns the list of all generators in the specified agent.
SELECT
name,
displayName,
llmModelSettings,
modelParameter,
placeholders,
promptText
FROM google.dialogflow.generators
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND agentsId = '{{ agentsId }}' -- required
AND languageCode = '{{ languageCode }}'
AND pageSize = '{{ pageSize }}'
AND pageToken = '{{ pageToken }}';
INSERT
examples
- projects_locations_agents_generators_create
- Manifest
Creates a generator in the specified agent.
INSERT INTO google.dialogflow.generators (
data__name,
data__displayName,
data__promptText,
data__placeholders,
data__llmModelSettings,
data__modelParameter,
projectsId,
locationsId,
agentsId,
languageCode
)
SELECT
'{{ name }}',
'{{ displayName }}',
'{{ promptText }}',
'{{ placeholders }}',
'{{ llmModelSettings }}',
'{{ modelParameter }}',
'{{ projectsId }}',
'{{ locationsId }}',
'{{ agentsId }}',
'{{ languageCode }}'
RETURNING
name,
displayName,
llmModelSettings,
modelParameter,
placeholders,
promptText
;
# Description fields are for documentation purposes
- name: generators
props:
- name: projectsId
value: string
description: Required parameter for the generators resource.
- name: locationsId
value: string
description: Required parameter for the generators resource.
- name: agentsId
value: string
description: Required parameter for the generators resource.
- name: name
value: string
description: >
The unique identifier of the generator. Must be set for the Generators.UpdateGenerator method. Generators.CreateGenerate populates the name automatically. Format: `projects//locations//agents//generators/`.
- name: displayName
value: string
description: >
Required. The human-readable name of the generator, unique within the agent. The prompt contains pre-defined parameters such as $conversation, $last-user-utterance, etc. populated by Dialogflow. It can also contain custom placeholders which will be resolved during fulfillment.
- name: promptText
value: object
description: >
Required. Prompt for the LLM model.
- name: placeholders
value: array
description: >
Optional. List of custom placeholders in the prompt text.
- name: llmModelSettings
value: object
description: >
The LLM model settings.
- name: modelParameter
value: object
description: >
Parameters passed to the LLM to configure its behavior.
- name: languageCode
value: string
UPDATE
examples
- projects_locations_agents_generators_patch
Update the specified generator.
UPDATE google.dialogflow.generators
SET
data__name = '{{ name }}',
data__displayName = '{{ displayName }}',
data__promptText = '{{ promptText }}',
data__placeholders = '{{ placeholders }}',
data__llmModelSettings = '{{ llmModelSettings }}',
data__modelParameter = '{{ modelParameter }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND agentsId = '{{ agentsId }}' --required
AND generatorsId = '{{ generatorsId }}' --required
AND languageCode = '{{ languageCode}}'
AND updateMask = '{{ updateMask}}'
RETURNING
name,
displayName,
llmModelSettings,
modelParameter,
placeholders,
promptText;
DELETE
examples
- projects_locations_agents_generators_delete
Deletes the specified generators.
DELETE FROM google.dialogflow.generators
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND agentsId = '{{ agentsId }}' --required
AND generatorsId = '{{ generatorsId }}' --required
AND force = '{{ force }}';