You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<pre>Generates and returns a suggestion for a conversation that does not have a resource created for it.
92
+
93
+
Args:
94
+
parent: string, Required. The parent resource to charge for the Suggestion's generation. Format: `projects//locations/`. (required)
95
+
body: object, The request body.
96
+
The object takes the form of:
97
+
98
+
{ # The request message for Conversations.GenerateStatelessSuggestion.
99
+
"conversationContext": { # Context of the conversation, including transcripts. # Optional. Context of the conversation, including transcripts.
100
+
"messageEntries": [ # Optional. List of message transcripts in the conversation.
101
+
{ # Represents a message entry of a conversation.
102
+
"createTime": "A String", # Optional. Create time of the message entry.
103
+
"languageCode": "A String", # Optional. The language of the text. See [Language Support](https://cloud.google.com/dialogflow/docs/reference/language) for a list of the currently supported language codes.
104
+
"role": "A String", # Optional. Participant role of the message.
105
+
"text": "A String", # Optional. Transcript content of the message.
106
+
},
107
+
],
108
+
},
109
+
"generator": { # LLM generator. # Uncreated generator. It should be a complete generator that includes all information about the generator.
110
+
"createTime": "A String", # Output only. Creation time of this generator.
111
+
"description": "A String", # Optional. Human readable description of the generator.
112
+
"inferenceParameter": { # The parameters of inference. # Optional. Inference parameters for this generator.
113
+
"maxOutputTokens": 42, # Optional. Maximum number of the output tokens for the generator.
114
+
"temperature": 3.14, # Optional. Controls the randomness of LLM predictions. Low temperature = less random. High temperature = more random. If unset (or 0), uses a default value of 0.
115
+
"topK": 42, # Optional. Top-k changes how the model selects tokens for output. A top-k of 1 means the selected token is the most probable among all tokens in the model's vocabulary (also called greedy decoding), while a top-k of 3 means that the next token is selected from among the 3 most probable tokens (using temperature). For each token selection step, the top K tokens with the highest probabilities are sampled. Then tokens are further filtered based on topP with the final token selected using temperature sampling. Specify a lower value for less random responses and a higher value for more random responses. Acceptable value is [1, 40], default to 40.
116
+
"topP": 3.14, # Optional. Top-p changes how the model selects tokens for output. Tokens are selected from most K (see topK parameter) probable to least until the sum of their probabilities equals the top-p value. For example, if tokens A, B, and C have a probability of 0.3, 0.2, and 0.1 and the top-p value is 0.5, then the model will select either A or B as the next token (using temperature) and doesn't consider C. The default top-p value is 0.95. Specify a lower value for less random responses and a higher value for more random responses. Acceptable value is [0.0, 1.0], default to 0.95.
117
+
},
118
+
"name": "A String", # Output only. Identifier. The resource name of the generator. Format: `projects//locations//generators/`
119
+
"summarizationContext": { # Summarization context that customer can configure. # Input of prebuilt Summarization feature.
120
+
"fewShotExamples": [ # Optional. List of few shot examples.
121
+
{ # Providing examples in the generator (i.e. building a few-shot generator) helps convey the desired format of the LLM response. NEXT_ID: 10
122
+
"conversationContext": { # Context of the conversation, including transcripts. # Optional. Conversation transcripts.
123
+
"messageEntries": [ # Optional. List of message transcripts in the conversation.
124
+
{ # Represents a message entry of a conversation.
125
+
"createTime": "A String", # Optional. Create time of the message entry.
126
+
"languageCode": "A String", # Optional. The language of the text. See [Language Support](https://cloud.google.com/dialogflow/docs/reference/language) for a list of the currently supported language codes.
127
+
"role": "A String", # Optional. Participant role of the message.
128
+
"text": "A String", # Optional. Transcript content of the message.
129
+
},
130
+
],
131
+
},
132
+
"extraInfo": { # Optional. Key is the placeholder field name in input, value is the value of the placeholder. E.g. instruction contains "@price", and ingested data has <"price", "10">
133
+
"a_key": "A String",
134
+
},
135
+
"output": { # Suggestion generated using a Generator. # Required. Example output of the model.
136
+
"summarySuggestion": { # Suggested summary of the conversation. # Optional. Suggested summary.
137
+
"summarySections": [ # Required. All the parts of generated summary.
138
+
{ # A component of the generated summary.
139
+
"section": "A String", # Required. Name of the section.
140
+
"summary": "A String", # Required. Summary text for the section.
141
+
},
142
+
],
143
+
},
144
+
},
145
+
"summarizationSectionList": { # List of summarization sections. # Summarization sections.
"definition": "A String", # Optional. Definition of the section, for example, "what the customer needs help with or has question about."
149
+
"key": "A String", # Optional. Name of the section, for example, "situation".
150
+
"type": "A String", # Optional. Type of the summarization section.
151
+
},
152
+
],
153
+
},
154
+
},
155
+
],
156
+
"outputLanguageCode": "A String", # Optional. The target language of the generated summary. The language code for conversation will be used if this field is empty. Supported 2.0 and later versions.
157
+
"summarizationSections": [ # Optional. List of sections. Note it contains both predefined section sand customer defined sections.
158
+
{ # Represents the section of summarization.
159
+
"definition": "A String", # Optional. Definition of the section, for example, "what the customer needs help with or has question about."
160
+
"key": "A String", # Optional. Name of the section, for example, "situation".
161
+
"type": "A String", # Optional. Type of the summarization section.
162
+
},
163
+
],
164
+
"version": "A String", # Optional. Version of the feature. If not set, default to latest version. Current candidates are ["1.0"].
165
+
},
166
+
"triggerEvent": "A String", # Optional. The trigger event of the generator. It defines when the generator is triggered in a conversation.
167
+
"updateTime": "A String", # Output only. Update time of this generator.
168
+
},
169
+
"generatorName": "A String", # The resource name of the existing created generator. Format: `projects//locations//generators/`
170
+
"triggerEvents": [ # Optional. A list of trigger events. Generator will be triggered only if it's trigger event is included here.
171
+
"A String",
172
+
],
173
+
}
174
+
175
+
x__xgafv: string, V1 error format.
176
+
Allowed values
177
+
1 - v1 error format
178
+
2 - v2 error format
179
+
180
+
Returns:
181
+
An object of the form:
182
+
183
+
{ # The response message for Conversations.GenerateStatelessSuggestion.
184
+
"generatorSuggestion": { # Suggestion generated using a Generator. # Required. Generated suggestion for a conversation.
185
+
"summarySuggestion": { # Suggested summary of the conversation. # Optional. Suggested summary.
186
+
"summarySections": [ # Required. All the parts of generated summary.
187
+
{ # A component of the generated summary.
188
+
"section": "A String", # Required. Name of the section.
189
+
"summary": "A String", # Required. Summary text for the section.
Copy file name to clipboardExpand all lines: docs/dyn/dialogflow_v2.projects.locations.suggestions.html
+7-1Lines changed: 7 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -159,6 +159,9 @@ <h3>Method Details</h3>
159
159
},
160
160
},
161
161
],
162
+
"generators": [ # Optional. List of various generator resource names used in the conversation profile.
163
+
"A String",
164
+
],
162
165
"groupSuggestionResponses": True or False, # If `group_suggestion_responses` is false, and there are multiple `feature_configs` in `event based suggestion` or StreamingAnalyzeContent, we will try to deliver suggestions to customers as soon as we get new suggestion. Different type of suggestions based on the same context will be in separate Pub/Sub event or `StreamingAnalyzeContentResponse`. If `group_suggestion_responses` set to true. All the suggestions to the same participant based on the same context will be grouped into a single Pub/Sub event or StreamingAnalyzeContentResponse.
163
166
},
164
167
"humanAgentSuggestionConfig": { # Detail human agent assistant config. # Configuration for agent assistance of human agent participant.
@@ -213,6 +216,9 @@ <h3>Method Details</h3>
213
216
},
214
217
},
215
218
],
219
+
"generators": [ # Optional. List of various generator resource names used in the conversation profile.
220
+
"A String",
221
+
],
216
222
"groupSuggestionResponses": True or False, # If `group_suggestion_responses` is false, and there are multiple `feature_configs` in `event based suggestion` or StreamingAnalyzeContent, we will try to deliver suggestions to customers as soon as we get new suggestion. Different type of suggestions based on the same context will be in separate Pub/Sub event or `StreamingAnalyzeContentResponse`. If `group_suggestion_responses` set to true. All the suggestions to the same participant based on the same context will be grouped into a single Pub/Sub event or StreamingAnalyzeContentResponse.
217
223
},
218
224
"messageAnalysisConfig": { # Configuration for analyses to run on each conversation message. # Configuration for message analysis.
@@ -225,7 +231,7 @@ <h3>Method Details</h3>
225
231
},
226
232
},
227
233
"humanAgentHandoffConfig": { # Defines the hand off to a live agent, typically on which external agent service provider to connect to a conversation. Currently, this feature is not general available, please contact Google to get access. # Configuration for connecting to a live agent. Currently, this feature is not general available, please contact Google to get access.
228
-
"livePersonConfig": { # Configuration specific to LivePerson(https://www.liveperson.com). # Uses LivePerson(https://www.liveperson.com).
234
+
"livePersonConfig": { # Configuration specific to [LivePerson](https://www.liveperson.com). # Uses [LivePerson](https://www.liveperson.com).
229
235
"accountNumber": "A String", # Required. Account number of the LivePerson account to connect. This is the account number you input at the login page.
230
236
},
231
237
"salesforceLiveAgentConfig": { # Configuration specific to Salesforce Live Agent. # Uses Salesforce Live Agent.
Copy file name to clipboardExpand all lines: docs/dyn/dialogflow_v2.projects.suggestions.html
+7-1Lines changed: 7 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -159,6 +159,9 @@ <h3>Method Details</h3>
159
159
},
160
160
},
161
161
],
162
+
"generators": [ # Optional. List of various generator resource names used in the conversation profile.
163
+
"A String",
164
+
],
162
165
"groupSuggestionResponses": True or False, # If `group_suggestion_responses` is false, and there are multiple `feature_configs` in `event based suggestion` or StreamingAnalyzeContent, we will try to deliver suggestions to customers as soon as we get new suggestion. Different type of suggestions based on the same context will be in separate Pub/Sub event or `StreamingAnalyzeContentResponse`. If `group_suggestion_responses` set to true. All the suggestions to the same participant based on the same context will be grouped into a single Pub/Sub event or StreamingAnalyzeContentResponse.
163
166
},
164
167
"humanAgentSuggestionConfig": { # Detail human agent assistant config. # Configuration for agent assistance of human agent participant.
@@ -213,6 +216,9 @@ <h3>Method Details</h3>
213
216
},
214
217
},
215
218
],
219
+
"generators": [ # Optional. List of various generator resource names used in the conversation profile.
220
+
"A String",
221
+
],
216
222
"groupSuggestionResponses": True or False, # If `group_suggestion_responses` is false, and there are multiple `feature_configs` in `event based suggestion` or StreamingAnalyzeContent, we will try to deliver suggestions to customers as soon as we get new suggestion. Different type of suggestions based on the same context will be in separate Pub/Sub event or `StreamingAnalyzeContentResponse`. If `group_suggestion_responses` set to true. All the suggestions to the same participant based on the same context will be grouped into a single Pub/Sub event or StreamingAnalyzeContentResponse.
217
223
},
218
224
"messageAnalysisConfig": { # Configuration for analyses to run on each conversation message. # Configuration for message analysis.
@@ -225,7 +231,7 @@ <h3>Method Details</h3>
225
231
},
226
232
},
227
233
"humanAgentHandoffConfig": { # Defines the hand off to a live agent, typically on which external agent service provider to connect to a conversation. Currently, this feature is not general available, please contact Google to get access. # Configuration for connecting to a live agent. Currently, this feature is not general available, please contact Google to get access.
228
-
"livePersonConfig": { # Configuration specific to LivePerson(https://www.liveperson.com). # Uses LivePerson(https://www.liveperson.com).
234
+
"livePersonConfig": { # Configuration specific to [LivePerson](https://www.liveperson.com). # Uses [LivePerson](https://www.liveperson.com).
229
235
"accountNumber": "A String", # Required. Account number of the LivePerson account to connect. This is the account number you input at the login page.
230
236
},
231
237
"salesforceLiveAgentConfig": { # Configuration specific to Salesforce Live Agent. # Uses Salesforce Live Agent.
Copy file name to clipboardExpand all lines: docs/dyn/dialogflow_v2beta1.projects.agent.environments.users.sessions.html
+1Lines changed: 1 addition & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -152,6 +152,7 @@ <h3>Method Details</h3>
152
152
"noBargeInDuration": "A String", # Duration that is not eligible for barge-in at the beginning of the input audio.
153
153
"totalDuration": "A String", # Total duration for the playback at the beginning of the input audio.
154
154
},
155
+
"defaultNoSpeechTimeout": "A String", # If set, use this no-speech timeout when the agent does not provide a no-speech timeout itself.
155
156
"disableNoSpeechRecognizedEvent": True or False, # Only used in Participants.AnalyzeContent and Participants.StreamingAnalyzeContent. If `false` and recognition doesn't return any result, trigger `NO_SPEECH_RECOGNIZED` event to Dialogflow agent.
156
157
"enableAutomaticPunctuation": True or False, # Enable automatic punctuation option at the speech backend.
157
158
"enableWordInfo": True or False, # If `true`, Dialogflow returns SpeechWordInfo in StreamingRecognitionResult with information about the recognized speech words, e.g. start and end time offsets. If false or unspecified, Speech doesn't return any word-level information.
0 commit comments