【问题标题】:Is it possible to test Google Cloud Text-to-Speech voice in Dialogflow Action Console?是否可以在 Dialogflow 操作控制台中测试 Google Cloud Text-to-Speech 语音?
【发布时间】:2019-04-07 03:37:37
【问题描述】:

我想为我的 Google Assistant Dialogflow 代理使用 WaveNet 语音,而不是标准的机器人 TTS 语音。所以我碰到了这个article

据我所知,可以在 WaveNet 语音中获得带有机器人答案的输出音频文件,但如果我能在 Dialogflow 的操作控制台或我的 Google Home 中听到这个声音,那就太好了。 是否可以在控制台中听到不同于常规 TTS 声音的声音?

【问题讨论】:

    标签: google-cloud-platform text-to-speech dialogflow-es google-assistant-sdk


    【解决方案1】:

    您可以将 SSML 与 Dialogflow 结合使用来附加您自己的 .ogg 文件。

    如果您好奇,Google 会提供 a sample use case on Github。附上代码:

    <speak>
      The key element for layered sound mixing is <sub alias="par">${'<par>'}</sub>
      (as in "parallel") which inserts a mixed sound at the current point of the TTS.
      It is similar to the <sub alias="paragraph">${'<p>'}</sub>
      element with an important difference of not displaying
      the text content in chat bubbles on surfaces with displays.
      <par>
        <media xml:id="first_thing" begin="2.5s">
          <speak>
            This media element contains a <sub alias="speak element">${'<speak>'}</sub> for TTS.
            It has an <say-as interpret-as="verbatim">xml:id</say-as> attribute so that other
            <sub alias="media">${'<media>'}</sub> elements can refer to it.
            There is also a "begin" attribute that delays the start time by 2.5 seconds.
            Millisecond units are also supported by the
            <say-as interpret-as="letters">ms</say-as> suffix.
          </speak>
        </media>
        <media xml:id="second_thing" soundLevel="-1dB" repeatCount="3">
          <audio src="https://actions.google.com/sounds/v1/cartoon/cartoon_boing.ogg">
            The sound source for this <sub alias="audio">${'<audio>'}</sub> element is missing.
            Find more sounds at https://developers.google.com/actions/tools/sound-library.
          </audio>
        </media>
        <media xml:id="last_thing" begin="first_thing.end + 1234ms">
          <speak>
            This TTS starts <say-as interpret-as="units">1234 milliseconds</say-as>
            after the end of the media element with the
            <say-as interpret-as="verbatim">xml:id</say-as> equal to "first_thing".
          </speak>
        </media>
      </par>
    </speak>
    

    【讨论】:

    • SSML 使用标准的 TTS 语音,但我想使用 WaveNet 语音
    猜你喜欢
    • 1970-01-01
    • 2020-09-24
    • 2019-04-16
    • 1970-01-01
    • 2019-09-11
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2016-03-12
    相关资源
    最近更新 更多