Skip to content

Commit

Permalink
feat: [dialogflow] added dialogflow_assist_answer (#4364)
Browse files Browse the repository at this point in the history
* feat: added dialogflow_assist_answer
feat: added session_ttl
feat: added human_agent_side_config
feat: added suggestion_input
feat: added suggest_dialogflow_assists_response
feat: added suggest_entity_extraction_response

PiperOrigin-RevId: 542021587

Source-Link: googleapis/googleapis@f40416d

Source-Link: googleapis/googleapis-gen@04ca491
Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWRpYWxvZ2Zsb3cvLk93bEJvdC55YW1sIiwiaCI6IjA0Y2E0OTFkZWM4ZjM1MTczZWU1OTlkN2VkMDc5MzZiNDA4NmU5NmQifQ==

* feat: added dialogflow_assist_answer
feat: added session_ttl
feat: added human_agent_side_config
feat: added suggestion_input
feat: added suggest_dialogflow_assists_response
feat: added suggest_entity_extraction_response

PiperOrigin-RevId: 542024928

Source-Link: googleapis/googleapis@06f7999

Source-Link: googleapis/googleapis-gen@0f124f3
Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLWRpYWxvZ2Zsb3cvLk93bEJvdC55YW1sIiwiaCI6IjBmMTI0ZjNjMzdiNWE2MDQ5OTA2YTk1MTRjZDk5NGRhZjA3M2RjMDEifQ==

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

---------

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
  • Loading branch information
gcf-owl-bot[bot] and gcf-owl-bot[bot] authored Jun 28, 2023
1 parent eca0623 commit 2339f4d
Show file tree
Hide file tree
Showing 31 changed files with 2,927 additions and 94 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -208,8 +208,8 @@ message AnswerFeedback {

// Indicates whether the answer/item was clicked by the human agent
// or not. Default to false.
// For knowledge search, the answer record is considered to be clicked if the
// answer was copied or any URI was clicked.
// For knowledge search and knowledge assist, the answer record is considered
// to be clicked if the answer was copied or any URI was clicked.
bool clicked = 3;

// Time when the answer/item was clicked.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -434,7 +434,7 @@ message SuggestConversationSummaryRequest {
// suggestion. By default 500 and at most 1000.
int32 context_size = 4;

// Parameters for a human assist query.
// Parameters for a human assist query. Only used for POC/demo purpose.
AssistQueryParameters assist_query_params = 5;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import "google/api/resource.proto";
import "google/cloud/dialogflow/v2/audio_config.proto";
import "google/cloud/dialogflow/v2/participant.proto";
import "google/longrunning/operations.proto";
import "google/protobuf/duration.proto";
import "google/protobuf/empty.proto";
import "google/protobuf/field_mask.proto";
import "google/protobuf/timestamp.proto";
Expand Down Expand Up @@ -381,6 +382,13 @@ message AutomatedAgentConfig {
type: "dialogflow.googleapis.com/Agent"
}
];

// Optional. Sets Dialogflow CX session life time.
// By default, a Dialogflow CX session remains active and its data is stored
// for 30 minutes after the last request is sent for the session. This value
// should be no longer than 1 day.
google.protobuf.Duration session_ttl = 3
[(google.api.field_behavior) = OPTIONAL];
}

// Defines the Human Agent Assist to connect to a conversation.
Expand Down Expand Up @@ -479,7 +487,7 @@ message HumanAgentAssistantConfig {
// Supported feature: DIALOGFLOW_ASSIST.
message DialogflowQuerySource {
// Required. The name of a Dialogflow virtual agent used for end user side
// intent detection and suggestion. Format: `projects/<Project Number/
// intent detection and suggestion. Format: `projects/<Project
// ID>/locations/<Location ID>/agent`. When multiple agents are allowed in
// the same Dialogflow project.
string agent = 1 [
Expand Down Expand Up @@ -540,7 +548,8 @@ message HumanAgentAssistantConfig {
// If this field is not set, it defaults to 0.0, which means that all
// suggestions are returned.
//
// Supported features: ARTICLE_SUGGESTION, FAQ, SMART_REPLY, SMART_COMPOSE.
// Supported features: ARTICLE_SUGGESTION, FAQ, SMART_REPLY, SMART_COMPOSE,
// KNOWLEDGE_SEARCH, KNOWLEDGE_ASSIST, ENTITY_EXTRACTION.
float confidence_threshold = 5;

// Determines how recent conversation context is filtered when generating
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ message Document {
//
// If a reload fails with internal errors, the system will try to reload the
// document on the next day.
// If a reload fails with non-retriable errors (e.g. PERMISION_DENIED), the
// If a reload fails with non-retriable errors (e.g. PERMISSION_DENIED), the
// system will not try to reload the document anymore. You need to manually
// reload the document successfully by calling `ReloadDocument` and clear the
// errors.
Expand Down Expand Up @@ -500,13 +500,13 @@ message ImportDocumentsRequest {
// Dialogflow supports up to 350 documents in each request. If you try to
// import more, Dialogflow will return an error.
oneof source {
// The Google Cloud Storage location for the documents.
// Optional. The Google Cloud Storage location for the documents.
// The path can include a wildcard.
//
// These URIs may have the forms
// `gs://<bucket-name>/<object-name>`.
// `gs://<bucket-name>/<object-path>/*.<extension>`.
GcsSources gcs_source = 2;
GcsSources gcs_source = 2 [(google.api.field_behavior) = OPTIONAL];
}

// Required. Document template used for importing all the documents.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,10 @@ message AgentAssistantRecord {

// Output only. The FAQ answer.
FaqAnswer faq_answer = 6 [(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. The Dialogflow assist answer.
DialogflowAssistAnswer dialogflow_assist_answer = 7
[(google.api.field_behavior) = OUTPUT_ONLY];
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,7 @@ message BatchCreateMessagesRequest {
}
];

// Required. A maximum of 1000 Messages can be created in a batch.
// Required. A maximum of 300 messages can be created in a batch.
// [CreateMessageRequest.message.send_time][] is required. All created
// messages will have identical
// [Message.create_time][google.cloud.dialogflow.v2beta1.Message.create_time].
Expand Down Expand Up @@ -494,7 +494,7 @@ message SuggestConversationSummaryRequest {
// suggestion. By default 500 and at most 1000.
int32 context_size = 4;

// Parameters for a human assist query.
// Parameters for a human assist query. Only used for POC/demo purpose.
AssistQueryParameters assist_query_params = 5;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import "google/api/resource.proto";
import "google/cloud/dialogflow/v2beta1/audio_config.proto";
import "google/cloud/dialogflow/v2beta1/participant.proto";
import "google/longrunning/operations.proto";
import "google/protobuf/duration.proto";
import "google/protobuf/empty.proto";
import "google/protobuf/field_mask.proto";
import "google/protobuf/timestamp.proto";
Expand Down Expand Up @@ -294,6 +295,13 @@ message AutomatedAgentConfig {
type: "dialogflow.googleapis.com/Agent"
}
];

// Optional. Sets Dialogflow CX session life time.
// By default, a Dialogflow CX session remains active and its data is stored
// for 30 minutes after the last request is sent for the session. This value
// should be no longer than 1 day.
google.protobuf.Duration session_ttl = 3
[(google.api.field_behavior) = OPTIONAL];
}

// Defines the Human Agent Assistant to connect to a conversation.
Expand Down Expand Up @@ -392,8 +400,22 @@ message HumanAgentAssistantConfig {
//
// Supported feature: DIALOGFLOW_ASSIST.
message DialogflowQuerySource {
// The configuration used for human agent side Dialogflow assist
// suggestion.
message HumanAgentSideConfig {
// Optional. The name of a dialogflow virtual agent used for intent
// detection and suggestion triggered by human agent.
// Format: `projects/<Project ID>/locations/<Location ID>/agent`.
string agent = 1 [
(google.api.field_behavior) = OPTIONAL,
(google.api.resource_reference) = {
type: "dialogflow.googleapis.com/Agent"
}
];
}

// Required. The name of a dialogflow virtual agent used for end user side
// intent detection and suggestion. Format: `projects/<Project Number /
// intent detection and suggestion. Format: `projects/<Project
// ID>/locations/<Location ID>/agent`. When multiple agents are allowed in
// the same Dialogflow project.
string agent = 1 [
Expand All @@ -402,6 +424,9 @@ message HumanAgentAssistantConfig {
type: "dialogflow.googleapis.com/Agent"
}
];

// The Dialogflow assist configuration for human agent.
HumanAgentSideConfig human_agent_side_config = 3;
}

// Settings that determine how to filter recent conversation context when
Expand Down Expand Up @@ -454,7 +479,8 @@ message HumanAgentAssistantConfig {
// If this field is not set, it is default to 0.0, which means that all
// suggestions are returned.
//
// Supported features: ARTICLE_SUGGESTION, FAQ, SMART_REPLY, SMART_COMPOSE.
// Supported features: ARTICLE_SUGGESTION, FAQ, SMART_REPLY, SMART_COMPOSE,
// KNOWLEDGE_SEARCH, KNOWLEDGE_ASSIST, ENTITY_EXTRACTION.
float confidence_threshold = 5;

// Determines how recent conversation context is filtered when generating
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -508,13 +508,13 @@ message ImportDocumentsRequest {
// Dialogflow supports up to 350 documents in each request. If you try to
// import more, Dialogflow will return an error.
oneof source {
// The Google Cloud Storage location for the documents.
// Optional. The Google Cloud Storage location for the documents.
// The path can include a wildcard.
//
// These URIs may have the forms
// `gs://<bucket-name>/<object-name>`.
// `gs://<bucket-name>/<object-path>/*.<extension>`.
GcsSources gcs_source = 2;
GcsSources gcs_source = 2 [(google.api.field_behavior) = OPTIONAL];
}

// Required. Document template used for importing all the documents.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -168,9 +168,9 @@ message Environment {

// Output only. The unique identifier of this agent environment.
// Supported formats:
// - `projects/<Project Number / ID>/agent/environments/<Environment ID>`
// - `projects/<Project Number / ID>/locations/<Location
// ID>/agent/environments/<Environment ID>`
// - `projects/<Project ID>/agent/environments/<Environment ID>`
// - `projects/<Project ID>/locations/<Location
// ID>/agent/environments/<Environment ID>`
string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];

// Optional. The developer-provided description for this environment.
Expand All @@ -181,7 +181,7 @@ message Environment {
// Supported formats:
// - `projects/<Project ID>/agent/versions/<Version ID>`
// - `projects/<Project ID>/locations/<Location ID>/agent/versions/<Version
// ID>`
// ID>`
string agent_version = 3 [
(google.api.field_behavior) = OPTIONAL,
(google.api.resource_reference) = {
Expand Down Expand Up @@ -235,8 +235,8 @@ message TextToSpeechSettings {
message ListEnvironmentsRequest {
// Required. The agent to list all environments from.
// Format:
// - `projects/<Project Number / ID>/agent`
// - `projects/<Project Number / ID>/locations/<Location ID>/agent`
// - `projects/<Project ID>/agent`
// - `projects/<Project ID>/locations/<Location ID>/agent`
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
Expand Down Expand Up @@ -269,8 +269,8 @@ message ListEnvironmentsResponse {
message GetEnvironmentRequest {
// Required. The name of the environment.
// Supported formats:
// - `projects/<Project Number / ID>/agent/environments/<Environment ID>`
// - `projects/<Project Number / ID>/locations/<Location
// - `projects/<Project ID>/agent/environments/<Environment ID>`
// - `projects/<Project ID>/locations/<Location
// ID>/agent/environments/<Environment ID>`
string name = 1 [
(google.api.field_behavior) = REQUIRED,
Expand All @@ -285,8 +285,8 @@ message GetEnvironmentRequest {
message CreateEnvironmentRequest {
// Required. The agent to create an environment for.
// Supported formats:
// - `projects/<Project Number / ID>/agent`
// - `projects/<Project Number / ID>/locations/<Location ID>/agent`
// - `projects/<Project ID>/agent`
// - `projects/<Project ID>/locations/<Location ID>/agent`
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
Expand Down Expand Up @@ -324,8 +324,8 @@ message UpdateEnvironmentRequest {
message DeleteEnvironmentRequest {
// Required. The name of the environment to delete.
// / Format:
// - `projects/<Project Number / ID>/agent/environments/<Environment ID>`
// - `projects/<Project Number / ID>/locations/<Location
// - `projects/<Project ID>/agent/environments/<Environment ID>`
// - `projects/<Project ID>/locations/<Location
// ID>/agent/environments/<Environment ID>`
string name = 1 [
(google.api.field_behavior) = REQUIRED,
Expand All @@ -340,8 +340,8 @@ message DeleteEnvironmentRequest {
message GetEnvironmentHistoryRequest {
// Required. The name of the environment to retrieve history for.
// Supported formats:
// - `projects/<Project Number / ID>/agent/environments/<Environment ID>`
// - `projects/<Project Number / ID>/locations/<Location
// - `projects/<Project ID>/agent/environments/<Environment ID>`
// - `projects/<Project ID>/locations/<Location
// ID>/agent/environments/<Environment ID>`
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
Expand Down Expand Up @@ -375,8 +375,8 @@ message EnvironmentHistory {

// Output only. The name of the environment this history is for.
// Supported formats:
// - `projects/<Project Number / ID>/agent/environments/<Environment ID>`
// - `projects/<Project Number / ID>/locations/<Location
// - `projects/<Project ID>/agent/environments/<Environment ID>`
// - `projects/<Project ID>/locations/<Location
// ID>/agent/environments/<Environment ID>`
string parent = 1 [(google.api.field_behavior) = OUTPUT_ONLY];

Expand Down
Loading

0 comments on commit 2339f4d

Please sign in to comment.