@@ -17,7 +17,6 @@ syntax = "proto3";
1717package google.cloud.dialogflow.cx.v3 ;
1818
1919import "google/api/annotations.proto" ;
20- import "google/api/client.proto" ;
2120import "google/api/field_behavior.proto" ;
2221import "google/api/resource.proto" ;
2322import "google/cloud/dialogflow/cx/v3/audio_config.proto" ;
@@ -30,6 +29,7 @@ import "google/protobuf/duration.proto";
3029import "google/protobuf/struct.proto" ;
3130import "google/rpc/status.proto" ;
3231import "google/type/latlng.proto" ;
32+ import "google/api/client.proto" ;
3333
3434option cc_enable_arenas = true ;
3535option csharp_namespace = "Google.Cloud.Dialogflow.Cx.V3" ;
@@ -45,9 +45,8 @@ option (google.api.resource_definition) = {
4545};
4646
4747// A session represents an interaction with a user. You retrieve user input
48- // and pass it to the
49- // [DetectIntent][google.cloud.dialogflow.cx.v3.Sessions.DetectIntent] method to
50- // determine user intent and respond.
48+ // and pass it to the [DetectIntent][google.cloud.dialogflow.cx.v3.Sessions.DetectIntent] method to determine
49+ // user intent and respond.
5150service Sessions {
5251 option (google.api.default_host ) = "dialogflow.googleapis.com" ;
5352 option (google.api.oauth_scopes ) =
@@ -80,8 +79,8 @@ service Sessions {
8079 // Note: Always use agent versions for production traffic.
8180 // See [Versions and
8281 // environments](https://cloud.google.com/dialogflow/cx/docs/concept/version).
83- rpc StreamingDetectIntent (stream StreamingDetectIntentRequest )
84- returns ( stream StreamingDetectIntentResponse ) { }
82+ rpc StreamingDetectIntent (stream StreamingDetectIntentRequest ) returns ( stream StreamingDetectIntentResponse ) {
83+ }
8584
8685 // Returns preliminary intent match results, doesn't change the session
8786 // status.
@@ -96,13 +95,9 @@ service Sessions {
9695 };
9796 }
9897
99- // Fulfills a matched intent returned by
100- // [MatchIntent][google.cloud.dialogflow.cx.v3.Sessions.MatchIntent]. Must be
101- // called after
102- // [MatchIntent][google.cloud.dialogflow.cx.v3.Sessions.MatchIntent], with
103- // input from
104- // [MatchIntentResponse][google.cloud.dialogflow.cx.v3.MatchIntentResponse].
105- // Otherwise, the behavior is undefined.
98+ // Fulfills a matched intent returned by [MatchIntent][google.cloud.dialogflow.cx.v3.Sessions.MatchIntent].
99+ // Must be called after [MatchIntent][google.cloud.dialogflow.cx.v3.Sessions.MatchIntent], with input from
100+ // [MatchIntentResponse][google.cloud.dialogflow.cx.v3.MatchIntentResponse]. Otherwise, the behavior is undefined.
106101 rpc FulfillIntent (FulfillIntentRequest ) returns (FulfillIntentResponse ) {
107102 option (google.api.http ) = {
108103 post : "/v3/{match_intent_request.session=projects/*/locations/*/agents/*/sessions/*}:fulfillIntent"
@@ -162,9 +157,9 @@ message DetectIntentResponse {
162157 // The audio data bytes encoded as specified in the request.
163158 // Note: The output audio is generated based on the values of default platform
164159 // text responses found in the
165- // [`query_result.response_messages`][google.cloud.dialogflow.cx.v3.QueryResult.response_messages]
166- // field. If multiple default text responses exist, they will be concatenated
167- // when generating audio. If no default platform text responses exist, the
160+ // [`query_result.response_messages`][google.cloud.dialogflow.cx.v3.QueryResult.response_messages] field. If
161+ // multiple default text responses exist, they will be concatenated when
162+ // generating audio. If no default platform text responses exist, the
168163 // generated audio content will be empty.
169164 //
170165 // In some scenarios, multiple output audio fields may be present in the
@@ -177,29 +172,24 @@ message DetectIntentResponse {
177172}
178173
179174// The top-level message sent by the client to the
180- // [Sessions.StreamingDetectIntent][google.cloud.dialogflow.cx.v3.Sessions.StreamingDetectIntent]
181- // method.
175+ // [Sessions.StreamingDetectIntent][google.cloud.dialogflow.cx.v3.Sessions.StreamingDetectIntent] method.
182176//
183177// Multiple request messages should be sent in order:
184178//
185179// 1. The first message must contain
186180// [session][google.cloud.dialogflow.cx.v3.StreamingDetectIntentRequest.session],
187- // [query_input][google.cloud.dialogflow.cx.v3.StreamingDetectIntentRequest.query_input]
188- // plus optionally
189- // [query_params][google.cloud.dialogflow.cx.v3.StreamingDetectIntentRequest.query_params].
190- // If the client wants to receive an audio response, it should also contain
181+ // [query_input][google.cloud.dialogflow.cx.v3.StreamingDetectIntentRequest.query_input] plus optionally
182+ // [query_params][google.cloud.dialogflow.cx.v3.StreamingDetectIntentRequest.query_params]. If the client
183+ // wants to receive an audio response, it should also contain
191184// [output_audio_config][google.cloud.dialogflow.cx.v3.StreamingDetectIntentRequest.output_audio_config].
192185//
193- // 2. If
194- // [query_input][google.cloud.dialogflow.cx.v3.StreamingDetectIntentRequest.query_input]
195- // was set to
196- // [query_input.audio.config][google.cloud.dialogflow.cx.v3.AudioInput.config],
197- // all subsequent messages must contain
198- // [query_input.audio.audio][google.cloud.dialogflow.cx.v3.AudioInput.audio]
199- // to continue with Speech recognition. If you decide to rather detect an
200- // intent from text input after you already started Speech recognition,
201- // please send a message with
202- // [query_input.text][google.cloud.dialogflow.cx.v3.QueryInput.text].
186+ // 2. If [query_input][google.cloud.dialogflow.cx.v3.StreamingDetectIntentRequest.query_input] was set to
187+ // [query_input.audio.config][google.cloud.dialogflow.cx.v3.AudioInput.config], all subsequent messages
188+ // must contain [query_input.audio.audio][google.cloud.dialogflow.cx.v3.AudioInput.audio] to continue with
189+ // Speech recognition.
190+ // If you decide to rather detect an intent from text
191+ // input after you already started Speech recognition, please send a message
192+ // with [query_input.text][google.cloud.dialogflow.cx.v3.QueryInput.text].
203193//
204194// However, note that:
205195//
@@ -228,8 +218,8 @@ message StreamingDetectIntentRequest {
228218 // See [Versions and
229219 // environments](https://cloud.google.com/dialogflow/cx/docs/concept/version).
230220 string session = 1 [(google.api.resource_reference ) = {
231- type : "dialogflow.googleapis.com/Session"
232- }];
221+ type : "dialogflow.googleapis.com/Session"
222+ }];
233223
234224 // The parameters of this query.
235225 QueryParameters query_params = 2 ;
@@ -315,8 +305,8 @@ message StreamingRecognitionResult {
315305 // additional results). The client should stop sending additional audio
316306 // data, half-close the gRPC connection, and wait for any additional results
317307 // until the server closes the gRPC connection. This message is only sent if
318- // [`single_utterance`][google.cloud.dialogflow.cx.v3.InputAudioConfig.single_utterance]
319- // was set to `true`, and is not used otherwise.
308+ // [`single_utterance`][google.cloud.dialogflow.cx.v3.InputAudioConfig.single_utterance] was set to
309+ // `true`, and is not used otherwise.
320310 END_OF_SINGLE_UTTERANCE = 2 ;
321311 }
322312
@@ -352,8 +342,7 @@ message StreamingRecognitionResult {
352342 float stability = 6 ;
353343
354344 // Word-specific information for the words recognized by Speech in
355- // [transcript][google.cloud.dialogflow.cx.v3.StreamingRecognitionResult.transcript].
356- // Populated if and only if `message_type` = `TRANSCRIPT` and
345+ // [transcript][google.cloud.dialogflow.cx.v3.StreamingRecognitionResult.transcript]. Populated if and only if `message_type` = `TRANSCRIPT` and
357346 // [InputAudioConfig.enable_word_info] is set.
358347 repeated SpeechWordInfo speech_word_info = 7 ;
359348
@@ -415,22 +404,20 @@ message QueryParameters {
415404 // - Else: parameter value
416405 google.protobuf.Struct parameters = 5 ;
417406
418- // The unique identifier of the [page][google.cloud.dialogflow.cx.v3.Page] to
419- // override the [current page][QueryResult.current_page] in the session.
420- // Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
421- // ID>/pages/<page ID>`.
407+ // The unique identifier of the [page][google.cloud.dialogflow.cx.v3.Page] to override the [current
408+ // page][QueryResult.current_page] in the session. Format: `projects/<Project
409+ // ID>/locations/<Location ID>/agents/<Agent ID>/pages/<page ID>`.
422410 //
423411 // If `current_page` is specified, the previous state of the session will be
424412 // ignored by Dialogflow, including the [previous
425413 // page][QueryResult.current_page] and the [previous session
426414 // parameters][QueryResult.parameters].
427- // In most cases,
428- // [current_page][google.cloud.dialogflow.cx.v3.QueryParameters.current_page]
429- // and [parameters][google.cloud.dialogflow.cx.v3.QueryParameters.parameters]
430- // should be configured together to direct a session to a specific state.
431- string current_page = 6 [
432- (google.api.resource_reference ) = { type : "dialogflow.googleapis.com/Page" }
433- ];
415+ // In most cases, [current_page][google.cloud.dialogflow.cx.v3.QueryParameters.current_page] and
416+ // [parameters][google.cloud.dialogflow.cx.v3.QueryParameters.parameters] should be configured together to
417+ // direct a session to a specific state.
418+ string current_page = 6 [(google.api.resource_reference ) = {
419+ type : "dialogflow.googleapis.com/Page"
420+ }];
434421
435422 // Whether to disable webhook calls for this request.
436423 bool disable_webhook = 7 ;
@@ -490,25 +477,24 @@ message QueryInput {
490477message QueryResult {
491478 // The original conversational query.
492479 oneof query {
493- // If [natural language text][google.cloud.dialogflow.cx.v3.TextInput] was
494- // provided as input, this field will contain a copy of the text.
480+ // If [natural language text][google.cloud.dialogflow.cx.v3.TextInput] was provided as input, this field
481+ // will contain a copy of the text.
495482 string text = 1 ;
496483
497- // If an [intent][google.cloud.dialogflow.cx.v3.IntentInput] was provided as
498- // input, this field will contain a copy of the intent identifier. Format:
499- // `projects/<Project ID>/locations/<Location ID>/agents/<Agent
484+ // If an [intent][google.cloud.dialogflow.cx.v3.IntentInput] was provided as input, this field will
485+ // contain a copy of the intent identifier.
486+ // Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
500487 // ID>/intents/<Intent ID>`.
501488 string trigger_intent = 11 [(google.api.resource_reference ) = {
502- type : "dialogflow.googleapis.com/Intent"
503- }];
489+ type : "dialogflow.googleapis.com/Intent"
490+ }];
504491
505- // If [natural language speech
506- // audio][google.cloud.dialogflow.cx.v3.AudioInput] was provided as input,
492+ // If [natural language speech audio][google.cloud.dialogflow.cx.v3.AudioInput] was provided as input,
507493 // this field will contain the transcript for the audio.
508494 string transcript = 12 ;
509495
510- // If an [event][google.cloud.dialogflow.cx.v3.EventInput] was provided as
511- // input, this field will contain the name of the event.
496+ // If an [event][google.cloud.dialogflow.cx.v3.EventInput] was provided as input, this field will contain
497+ // the name of the event.
512498 string trigger_event = 14 ;
513499 }
514500
@@ -518,8 +504,7 @@ message QueryResult {
518504 // for a list of the currently supported language codes.
519505 string language_code = 2 ;
520506
521- // The collected [session
522- // parameters][google.cloud.dialogflow.cx.v3.SessionInfo.parameters].
507+ // The collected [session parameters][google.cloud.dialogflow.cx.v3.SessionInfo.parameters].
523508 //
524509 // Depending on your protocol or client library language, this is a
525510 // map, associative array, symbol table, dictionary, or JSON object
@@ -545,23 +530,19 @@ message QueryResult {
545530 // The list of webhook call status in the order of call sequence.
546531 repeated google.rpc.Status webhook_statuses = 13 ;
547532
548- // The list of webhook payload in
549- // [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload],
550- // in the order of call sequence. If some webhook call fails or doesn't return
533+ // The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
534+ // the order of call sequence. If some webhook call fails or doesn't return
551535 // any payload, an empty `Struct` would be used instead.
552536 repeated google.protobuf.Struct webhook_payloads = 6 ;
553537
554- // The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all
555- // fields are filled in this message, including but not limited to `name` and
556- // `display_name`.
538+ // The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all fields are filled in this message,
539+ // including but not limited to `name` and `display_name`.
557540 Page current_page = 7 ;
558541
559- // The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the
560- // conversational query. Some, not all fields are filled in this message,
561- // including but not limited to: `name` and `display_name`. This field is
562- // deprecated, please use
563- // [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match]
564- // instead.
542+ // The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the conversational query. Some, not all fields
543+ // are filled in this message, including but not limited to: `name` and
544+ // `display_name`.
545+ // This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
565546 Intent intent = 8 [deprecated = true ];
566547
567548 // The intent detection confidence. Values range from 0.0 (completely
@@ -570,9 +551,7 @@ message QueryResult {
570551 // help match the best intent within the classification threshold.
571552 // This value may change for the same end-user expression at any time due to a
572553 // model retraining or change in implementation.
573- // This field is deprecated, please use
574- // [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match]
575- // instead.
554+ // This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
576555 float intent_detection_confidence = 9 [deprecated = true ];
577556
578557 // Intent match result, could be an intent or an event.
@@ -585,15 +564,14 @@ message QueryResult {
585564
586565 // The sentiment analyss result, which depends on
587566 // [`analyze_query_text_sentiment`]
588- // [google.cloud.dialogflow.cx.v3.QueryParameters.analyze_query_text_sentiment],
589- // specified in the request.
567+ // [google.cloud.dialogflow.cx.v3.QueryParameters.analyze_query_text_sentiment], specified in the request.
590568 SentimentAnalysisResult sentiment_analysis_result = 17 ;
591569}
592570
593571// Represents the natural language text to be processed.
594572message TextInput {
595- // Required. The UTF-8 encoded natural language text to be processed. Text
596- // length must not exceed 256 characters.
573+ // Required. The UTF-8 encoded natural language text to be processed. Text length must
574+ // not exceed 256 characters.
597575 string text = 1 [(google.api.field_behavior ) = REQUIRED ];
598576}
599577
@@ -618,9 +596,8 @@ message AudioInput {
618596
619597 // The natural language speech audio to be processed.
620598 // A single request can contain up to 1 minute of speech audio data.
621- // The [transcribed
622- // text][google.cloud.dialogflow.cx.v3.QueryResult.transcript] cannot contain
623- // more than 256 bytes.
599+ // The [transcribed text][google.cloud.dialogflow.cx.v3.QueryResult.transcript] cannot contain more than 256
600+ // bytes.
624601 //
625602 // For non-streaming audio detect intent, both `config` and `audio` must be
626603 // provided.
@@ -670,10 +647,9 @@ message Match {
670647 EVENT = 6 ;
671648 }
672649
673- // The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the query.
674- // Some, not all fields are filled in this message, including but not limited
675- // to: `name` and `display_name`. Only filled for
676- // [`INTENT`][google.cloud.dialogflow.cx.v3.Match.MatchType] match type.
650+ // The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the query. Some, not all fields are filled in
651+ // this message, including but not limited to: `name` and `display_name`. Only
652+ // filled for [`INTENT`][google.cloud.dialogflow.cx.v3.Match.MatchType] match type.
677653 Intent intent = 1 ;
678654
679655 // The event that matched the query. Only filled for
@@ -747,35 +723,33 @@ message MatchIntentRequest {
747723message MatchIntentResponse {
748724 // The original conversational query.
749725 oneof query {
750- // If [natural language text][google.cloud.dialogflow.cx.v3.TextInput] was
751- // provided as input, this field will contain a copy of the text.
726+ // If [natural language text][google.cloud.dialogflow.cx.v3.TextInput] was provided as input, this field
727+ // will contain a copy of the text.
752728 string text = 1 ;
753729
754- // If an [intent][google.cloud.dialogflow.cx.v3.IntentInput] was provided as
755- // input, this field will contain a copy of the intent identifier. Format:
756- // `projects/<Project ID>/locations/<Location ID>/agents/<Agent
730+ // If an [intent][google.cloud.dialogflow.cx.v3.IntentInput] was provided as input, this field will
731+ // contain a copy of the intent identifier.
732+ // Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
757733 // ID>/intents/<Intent ID>`.
758734 string trigger_intent = 2 [(google.api.resource_reference ) = {
759- type : "dialogflow.googleapis.com/Intent"
760- }];
735+ type : "dialogflow.googleapis.com/Intent"
736+ }];
761737
762- // If [natural language speech
763- // audio][google.cloud.dialogflow.cx.v3.AudioInput] was provided as input,
738+ // If [natural language speech audio][google.cloud.dialogflow.cx.v3.AudioInput] was provided as input,
764739 // this field will contain the transcript for the audio.
765740 string transcript = 3 ;
766741
767- // If an [event][google.cloud.dialogflow.cx.v3.EventInput] was provided as
768- // input, this field will contain a copy of the event name.
742+ // If an [event][google.cloud.dialogflow.cx.v3.EventInput] was provided as input, this field will
743+ // contain a copy of the event name.
769744 string trigger_event = 6 ;
770745 }
771746
772747 // Match results, if more than one, ordered descendingly by the confidence
773748 // we have that the particular intent matches the query.
774749 repeated Match matches = 4 ;
775750
776- // The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all
777- // fields are filled in this message, including but not limited to `name` and
778- // `display_name`.
751+ // The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all fields are filled in this message,
752+ // including but not limited to `name` and `display_name`.
779753 Page current_page = 5 ;
780754}
781755
@@ -804,9 +778,9 @@ message FulfillIntentResponse {
804778 // The audio data bytes encoded as specified in the request.
805779 // Note: The output audio is generated based on the values of default platform
806780 // text responses found in the
807- // [`query_result.response_messages`][google.cloud.dialogflow.cx.v3.QueryResult.response_messages]
808- // field. If multiple default text responses exist, they will be concatenated
809- // when generating audio. If no default platform text responses exist, the
781+ // [`query_result.response_messages`][google.cloud.dialogflow.cx.v3.QueryResult.response_messages] field. If
782+ // multiple default text responses exist, they will be concatenated when
783+ // generating audio. If no default platform text responses exist, the
810784 // generated audio content will be empty.
811785 //
812786 // In some scenarios, multiple output audio fields may be present in the
0 commit comments