Struct google_api_proto::google::cloud::dialogflow::v2::StreamingAnalyzeContentResponse
source · pub struct StreamingAnalyzeContentResponse {
pub recognition_result: Option<StreamingRecognitionResult>,
pub reply_text: String,
pub reply_audio: Option<OutputAudio>,
pub automated_agent_reply: Option<AutomatedAgentReply>,
pub message: Option<Message>,
pub human_agent_suggestion_results: Vec<SuggestionResult>,
pub end_user_suggestion_results: Vec<SuggestionResult>,
pub dtmf_parameters: Option<DtmfParameters>,
pub debugging_info: Option<CloudConversationDebuggingInfo>,
}
Expand description
The top-level message returned from the StreamingAnalyzeContent
method.
Multiple response messages can be returned in order:
-
If the input was set to streaming audio, the first one or more messages contain
recognition_result
. Eachrecognition_result
represents a more complete transcript of what the user said. The lastrecognition_result
hasis_final
set totrue
. -
In virtual agent stage: if
enable_partial_automated_agent_reply
is true, the following N (currently 1 <= N <= 4) messages containautomated_agent_reply
and optionallyreply_audio
returned by the virtual agent. The first (N-1)automated_agent_reply
s will haveautomated_agent_reply_type
set toPARTIAL
. The lastautomated_agent_reply
hasautomated_agent_reply_type
set toFINAL
. Ifenable_partial_automated_agent_reply
is not enabled, response stream only contains the final reply.In human assist stage: the following N (N >= 1) messages contain
human_agent_suggestion_results
,end_user_suggestion_results
ormessage
.
Fields§
§recognition_result: Option<StreamingRecognitionResult>
The result of speech recognition.
reply_text: String
The output text content. This field is set if an automated agent responded with a text for the user.
reply_audio: Option<OutputAudio>
The audio data bytes encoded as specified in the request. This field is set if:
- The
reply_audio_config
field is specified in the request. - The automated agent, which this output comes from, responded with audio.
In such case, the
reply_audio.config
field contains settings used to synthesize the speech.
In some scenarios, multiple output audio fields may be present in the response structure. In these cases, only the top-most-level audio output has content.
automated_agent_reply: Option<AutomatedAgentReply>
Only set if a Dialogflow automated agent has responded. Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] and [AutomatedAgentReply.detect_intent_response.output_audio_config][] are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead.
message: Option<Message>
Message analyzed by CCAI.
human_agent_suggestion_results: Vec<SuggestionResult>
The suggestions for most recent human agent. The order is the same as [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config].
end_user_suggestion_results: Vec<SuggestionResult>
The suggestions for end user. The order is the same as [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config].
dtmf_parameters: Option<DtmfParameters>
Indicates the parameters of DTMF.
debugging_info: Option<CloudConversationDebuggingInfo>
Debugging info that would get populated when
StreamingAnalyzeContentRequest.enable_debugging_info
is set to true.
Trait Implementations§
source§impl Clone for StreamingAnalyzeContentResponse
impl Clone for StreamingAnalyzeContentResponse
source§fn clone(&self) -> StreamingAnalyzeContentResponse
fn clone(&self) -> StreamingAnalyzeContentResponse
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Message for StreamingAnalyzeContentResponse
impl Message for StreamingAnalyzeContentResponse
source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
source§fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
source§fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
. Read moresource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
.source§impl PartialEq for StreamingAnalyzeContentResponse
impl PartialEq for StreamingAnalyzeContentResponse
source§fn eq(&self, other: &StreamingAnalyzeContentResponse) -> bool
fn eq(&self, other: &StreamingAnalyzeContentResponse) -> bool
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for StreamingAnalyzeContentResponse
Auto Trait Implementations§
impl !Freeze for StreamingAnalyzeContentResponse
impl RefUnwindSafe for StreamingAnalyzeContentResponse
impl Send for StreamingAnalyzeContentResponse
impl Sync for StreamingAnalyzeContentResponse
impl Unpin for StreamingAnalyzeContentResponse
impl UnwindSafe for StreamingAnalyzeContentResponse
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request