From 6a21cbf0dced1fa4fb8a4865525fa8771d64f1cd Mon Sep 17 00:00:00 2001 From: Google APIs Date: Wed, 24 Jan 2018 12:10:03 -0800 Subject: [PATCH] Synchronize new proto changes. --- google/cloud/dialogflow/v2beta1/agent.proto | 44 ++++++++++++++++++- google/cloud/dialogflow/v2beta1/context.proto | 5 +-- .../dialogflow/v2beta1/entity_type.proto | 2 +- google/cloud/dialogflow/v2beta1/intent.proto | 6 ++- google/cloud/dialogflow/v2beta1/session.proto | 22 ++++++++-- .../v2beta1/session_entity_type.proto | 2 +- google/cloud/dialogflow/v2beta1/webhook.proto | 2 +- 7 files changed, 71 insertions(+), 12 deletions(-) diff --git a/google/cloud/dialogflow/v2beta1/agent.proto b/google/cloud/dialogflow/v2beta1/agent.proto index 6fe5b036aa..1ba7b5195c 100644 --- a/google/cloud/dialogflow/v2beta1/agent.proto +++ b/google/cloud/dialogflow/v2beta1/agent.proto @@ -1,4 +1,4 @@ -// Copyright 2017 Google Inc. +// Copyright 2018 Google Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -229,6 +229,7 @@ message ExportAgentRequest { // Warning: Exporting agents to a URI is not implemented yet. // This feature is coming soon. + // // Optional. The Google Cloud Storage URI to export the agent to. // Note: The URI must start with // "gs://". If left unspecified, the serialized agent is returned inline. @@ -245,6 +246,19 @@ message ExportAgentResponse { string agent_uri = 1; // The exported agent. + // + // Example for how to export an agent to a zip file via a command line: + // + // curl \ + // 'https://dialogflow.googleapis.com/v2beta1/projects//agent:export'\ + // -X POST \ + // -H 'Authorization: Bearer '$(gcloud auth print-access-token) \ + // -H 'Accept: application/json' \ + // -H 'Content-Type: application/json' \ + // --compressed \ + // --data-binary '{}' \ + // | grep agentContent | sed -e 's/.*"agentContent": "\([^"]*\)".*/\1/' \ + // | base64 --decode > bytes agent_content = 2; } } @@ -260,11 +274,25 @@ message ImportAgentRequest { oneof agent { // Warning: Importing agents from a URI is not implemented yet. // This feature is coming soon. + // // The URI to a Google Cloud Storage file containing the agent to import. // Note: The URI must start with "gs://". string agent_uri = 2; // The agent to import. + // + // Example for how to import an agent via the command line: + // + // curl \ + // 'https://dialogflow.googleapis.com/v2beta1/projects//agent:import\ + // -X POST \ + // -H 'Authorization: Bearer '$(gcloud auth print-access-token) \ + // -H 'Accept: application/json' \ + // -H 'Content-Type: application/json' \ + // --compressed \ + // --data-binary "{ + // 'agentContent': '$(cat | base64 -w 0)' + // }" bytes agent_content = 3; } } @@ -280,11 +308,25 @@ message RestoreAgentRequest { oneof agent { // Warning: Restoring agents from a URI is not implemented yet. // This feature is coming soon. + // // The URI to a Google Cloud Storage file containing the agent to restore. // Note: The URI must start with "gs://". string agent_uri = 2; // The agent to restore. + // + // Example for how to restore an agent via the command line: + // + // curl \ + // 'https://dialogflow.googleapis.com/v2beta1/projects//agent:restore\ + // -X POST \ + // -H 'Authorization: Bearer '$(gcloud auth print-access-token) \ + // -H 'Accept: application/json' \ + // -H 'Content-Type: application/json' \ + // --compressed \ + // --data-binary "{ + // 'agentContent': '$(cat | base64 -w 0)' + // }" \ bytes agent_content = 3; } } diff --git a/google/cloud/dialogflow/v2beta1/context.proto b/google/cloud/dialogflow/v2beta1/context.proto index 1ec9530d74..1e8751154a 100644 --- a/google/cloud/dialogflow/v2beta1/context.proto +++ b/google/cloud/dialogflow/v2beta1/context.proto @@ -1,4 +1,4 @@ -// Copyright 2017 Google Inc. +// Copyright 2018 Google Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -150,8 +150,7 @@ message CreateContextRequest { // The request message for // [Contexts.UpdateContext][google.cloud.dialogflow.v2beta1.Contexts.UpdateContext]. message UpdateContextRequest { - // Required. The context to update. Format: - // `projects//agent/sessions//contexts/`. + // Required. The context to update. Context context = 1; // Optional. The mask to control which fields get updated. diff --git a/google/cloud/dialogflow/v2beta1/entity_type.proto b/google/cloud/dialogflow/v2beta1/entity_type.proto index 3e605144b6..c3c17bb3e7 100644 --- a/google/cloud/dialogflow/v2beta1/entity_type.proto +++ b/google/cloud/dialogflow/v2beta1/entity_type.proto @@ -1,4 +1,4 @@ -// Copyright 2017 Google Inc. +// Copyright 2018 Google Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. diff --git a/google/cloud/dialogflow/v2beta1/intent.proto b/google/cloud/dialogflow/v2beta1/intent.proto index 004f9a51e3..41b0668c8c 100644 --- a/google/cloud/dialogflow/v2beta1/intent.proto +++ b/google/cloud/dialogflow/v2beta1/intent.proto @@ -1,4 +1,4 @@ -// Copyright 2017 Google Inc. +// Copyright 2018 Google Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -209,6 +209,10 @@ message Intent { message Image { // Optional. The public URI to an image file. string image_uri = 1; + + // Optional. A text description of the image to be used for accessibility, + // e.g., screen readers. + string accessibility_text = 2; } // The quick replies response message. diff --git a/google/cloud/dialogflow/v2beta1/session.proto b/google/cloud/dialogflow/v2beta1/session.proto index b1705ff299..bd785c98db 100644 --- a/google/cloud/dialogflow/v2beta1/session.proto +++ b/google/cloud/dialogflow/v2beta1/session.proto @@ -1,4 +1,4 @@ -// Copyright 2017 Google Inc. +// Copyright 2018 Google Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -163,11 +163,15 @@ message QueryResult { // for a list of the currently supported language codes. string language_code = 15; - // The confidence estimate between 0.0 and 1.0. A higher number + // The Speech recognition confidence between 0.0 and 1.0. A higher number // indicates an estimated greater likelihood that the recognized words are // correct. The default of 0.0 is a sentinel value indicating that confidence - // was not set. This field is populated if natural speech audio was provided - // as input. + // was not set. + // + // You should not rely on this field as it isn't guaranteed to be accurate, or + // even set. In particular this field isn't set in Webhook calls and for + // StreamingDetectIntent since the streaming endpoint has separate confidence + // estimates per portion of the audio in StreamingRecognitionResult. float speech_recognition_confidence = 2; // The action name from the matched intent. @@ -349,11 +353,21 @@ message StreamingRecognitionResult { // Populated if and only if `event_type` = `RECOGNITION_EVENT_TRANSCRIPT`. string transcript = 2; + // The default of 0.0 is a sentinel value indicating `confidence` was not set. // If `false`, the `StreamingRecognitionResult` represents an // interim result that may change. If `true`, the recognizer will not return // any further hypotheses about this piece of the audio. May only be populated // for `event_type` = `RECOGNITION_EVENT_TRANSCRIPT`. bool is_final = 3; + + // The Speech confidence between 0.0 and 1.0 for the current portion of audio. + // A higher number indicates an estimated greater likelihood that the + // recognized words are correct. The default of 0.0 is a sentinel value + // indicating that confidence was not set. + // + // This field is typically only provided if `is_final` is true and you should + // not rely on it being accurate or even set. + float confidence = 4; } // Instructs the speech recognizer how to process the audio content. diff --git a/google/cloud/dialogflow/v2beta1/session_entity_type.proto b/google/cloud/dialogflow/v2beta1/session_entity_type.proto index a0815ad630..18a53085bc 100644 --- a/google/cloud/dialogflow/v2beta1/session_entity_type.proto +++ b/google/cloud/dialogflow/v2beta1/session_entity_type.proto @@ -1,4 +1,4 @@ -// Copyright 2017 Google Inc. +// Copyright 2018 Google Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. diff --git a/google/cloud/dialogflow/v2beta1/webhook.proto b/google/cloud/dialogflow/v2beta1/webhook.proto index 1c28f2e379..d4db3b8c10 100644 --- a/google/cloud/dialogflow/v2beta1/webhook.proto +++ b/google/cloud/dialogflow/v2beta1/webhook.proto @@ -1,4 +1,4 @@ -// Copyright 2017 Google Inc. +// Copyright 2018 Google Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License.