Prevent google assistant response? #134

Closed
opened 2022-07-05 01:38:56 +02:00 by blacklight · 0 comments
Owner

Created by: bendikrb

Hi, thank you for building this great project!
I'm in the situation where I need to tts.google.say the response from google myself - so I can get the voice I want (in my language the only voice available in the google assistant app is 1 female one -- even though Google have 4 flavors (+ non-wavenet ones) available for their TTS API). Also this will of course give me the opportunity to perhaps alter or omit the response all-together.

I haven't played around very much with platypush yet (or studied the code), but my initial thought was something like this;

event.hook.AssistantGoogleResponse:
    if:
        type: platypush.message.event.assistant.ResponseEvent
    then:
        - action: assistant.google.pushtotalk.stop_conversation
        - action: tts.google.say
          args:
              voice: nb-NO-Wavenet-B
              gender: MALE
              text: "Google said: ${response_text}"

This .. kind of .. works, but I'll hear the first few milliseconds of the google response before it gets killed --. and it sometimes crashes in such a way that I need to restart the service to get it up and running again.

Any ideas how I could approach this problem?

*Created by: bendikrb* Hi, thank you for building this great project! I'm in the situation where I need to `tts.google.say` the response from google myself - so I can get the voice I want (in my language the only voice available in the google assistant app is 1 female one -- even though Google have 4 flavors (+ non-wavenet ones) available for their TTS API). Also this will of course give me the opportunity to perhaps alter or omit the response all-together. I haven't played around very much with platypush yet (or studied the code), but my initial thought was something like this; ```yaml event.hook.AssistantGoogleResponse: if: type: platypush.message.event.assistant.ResponseEvent then: - action: assistant.google.pushtotalk.stop_conversation - action: tts.google.say args: voice: nb-NO-Wavenet-B gender: MALE text: "Google said: ${response_text}" ``` This .. kind of .. works, but I'll hear the first few milliseconds of the google response before it gets killed --. and it sometimes crashes in such a way that I need to restart the service to get it up and running again. Any ideas how I could approach this problem?
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: platypush/platypush#134
No description provided.