Skip to content

Commit

Permalink
feat(v3beta1): added audio_export_settings (#311)
Browse files Browse the repository at this point in the history
* feat: add audio export settings to security settings
docs: update the doc on diagnostic info

PiperOrigin-RevId: 446763565

Source-Link: googleapis/googleapis@2d07d51

Source-Link: googleapis/googleapis-gen@7cf0655
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiN2NmMDY1NWVjMGI3MWE1OTYzMDgxZmU4YzVkYTkwOGZjYzg0MGUzZSJ9

* 🦉 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 May 5, 2022
1 parent cab5e10 commit 20667d4
Show file tree
Hide file tree
Showing 2 changed files with 92 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,27 @@ class SecuritySettings(proto.Message):
purge_data_types (Sequence[google.cloud.dialogflowcx_v3beta1.types.SecuritySettings.PurgeDataType]):
List of types of data to remove when
retention settings triggers purge.
audio_export_settings (google.cloud.dialogflowcx_v3beta1.types.SecuritySettings.AudioExportSettings):
Controls audio export settings for post-conversation
analytics when ingesting audio to conversations via
[Participants.AnalyzeContent][] or
[Participants.StreamingAnalyzeContent][].
If
[retention_strategy][google.cloud.dialogflow.cx.v3beta1.SecuritySettings.retention_strategy]
is set to REMOVE_AFTER_CONVERSATION or
[audio_export_settings.gcs_bucket][] is empty, audio export
is disabled.
If audio export is enabled, audio is recorded and saved to
[audio_export_settings.gcs_bucket][], subject to retention
policy of [audio_export_settings.gcs_bucket][].
This setting won't effect audio input for implicit sessions
via
[Sessions.DetectIntent][google.cloud.dialogflow.cx.v3beta1.Sessions.DetectIntent]
or
[Sessions.StreamingDetectIntent][google.cloud.dialogflow.cx.v3beta1.Sessions.StreamingDetectIntent].
insights_export_settings (google.cloud.dialogflowcx_v3beta1.types.SecuritySettings.InsightsExportSettings):
Controls conversation exporting settings to Insights after
conversation is completed.
Expand Down Expand Up @@ -282,6 +303,51 @@ class PurgeDataType(proto.Enum):
PURGE_DATA_TYPE_UNSPECIFIED = 0
DIALOGFLOW_HISTORY = 1

class AudioExportSettings(proto.Message):
r"""Settings for exporting audio.
Attributes:
gcs_bucket (str):
Cloud Storage bucket to export audio record to. You need to
grant
``service-<Conversation Project Number>@gcp-sa-dialogflow.iam.gserviceaccount.com``
the ``Storage Object Admin`` role in this bucket.
audio_export_pattern (str):
Filename pattern for exported audio.
enable_audio_redaction (bool):
Enable audio redaction if it is true.
audio_format (google.cloud.dialogflowcx_v3beta1.types.SecuritySettings.AudioExportSettings.AudioFormat):
File format for exported audio file.
Currently only in telephony recordings.
"""

class AudioFormat(proto.Enum):
r"""File format for exported audio file. Currently only in
telephony recordings.
"""
AUDIO_FORMAT_UNSPECIFIED = 0
MULAW = 1
MP3 = 2
OGG = 3

gcs_bucket = proto.Field(
proto.STRING,
number=1,
)
audio_export_pattern = proto.Field(
proto.STRING,
number=2,
)
enable_audio_redaction = proto.Field(
proto.BOOL,
number=3,
)
audio_format = proto.Field(
proto.ENUM,
number=4,
enum="SecuritySettings.AudioExportSettings.AudioFormat",
)

class InsightsExportSettings(proto.Message):
r"""Settings for exporting conversations to
`Insights <https://cloud.google.com/contact-center/insights/docs>`__.
Expand Down Expand Up @@ -334,6 +400,11 @@ class InsightsExportSettings(proto.Message):
number=8,
enum=PurgeDataType,
)
audio_export_settings = proto.Field(
proto.MESSAGE,
number=12,
message=AudioExportSettings,
)
insights_export_settings = proto.Field(
proto.MESSAGE,
number=13,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -802,10 +802,27 @@ class QueryResult(proto.Message):
Intent match result, could be an intent or an
event.
diagnostic_info (google.protobuf.struct_pb2.Struct):
The free-form diagnostic info. For example,
this field could contain webhook call latency.
The string keys of the Struct's fields map can
change without notice.
The free-form diagnostic info. For example, this field could
contain webhook call latency. The fields of this data can
change without notice, so you should not write code that
depends on its structure.
One of the fields is called "Alternative Matched Intents",
which may aid with debugging. The following describes these
intent results:
- The list is empty if no intent was matched to end-user
input.
- Only intents that are referenced in the currently active
flow are included.
- The matched intent is included.
- Other intents that could have matched end-user input, but
did not match because they are referenced by intent
routes that are out of
`scope <https://cloud.google.com/dialogflow/cx/docs/concept/handler#scope>`__,
are included.
- Other intents referenced by intent routes in scope that
matched end-user input, but had a lower confidence score.
sentiment_analysis_result (google.cloud.dialogflowcx_v3beta1.types.SentimentAnalysisResult):
The sentiment analyss result, which depends on
[``analyze_query_text_sentiment``]
Expand Down

0 comments on commit 20667d4

Please sign in to comment.