Hermes/tts/say command leads to doubled tts output

Hi,

I’m using rhasspy to integrate with openhab

if I try to send a command to “hermes/tts/say” topic

{"siteId":"mySatellite", "text":"any text"}

I get a doubled response from my speakers

 rhasspy responds: "any text"... "any text"

do I have to end my tts request with something to avoid doubling my answers??

or maybe I have to reconfigure something according to my server/satellite setup?

Sounds like you are running two Rhasspy instances somewhere

yes… I’m running a server client setup… but I thought it would be enough to set the right ‘siteId’
while sending the JSON but unfortunately there are doubled mqtt messages, and I think openhab sends only one - mysterious :ghost:

my sattelite’s tts is set to hermes and on serverside I have activated nanotts

That is true, but depends on your settings for both base and sat.
Can you post them?

1 Like

this is the server config

{
    "dialogue": {
        "satellite_site_ids": "SATELLITE1",
        "system": "rhasspy",
        "volume": "0"
    },
    "intent": {
        "satellite_site_ids": "SATELLITE1",
        "system": "fsticuffs"
    },
    "mqtt": {
        "enabled": "true",
        "host": "192.168.xxx.xxx",
        "password": "passwd",
        "site_id": "HQ",
        "username": "rhasspy"
    },
    "sounds": {
        "error": "",
        "recorded": "",
        "wake": ""
    },
    "speech_to_text": {
        "kaldi": {
            "language_model_type": "arpa"
        },
        "pocketsphinx": {
            "min_confidence": "0",
            "mix_weight": "0"
        },
        "satellite_site_ids": "SATELLITE1",
        "system": "kaldi"
    },
    "text_to_speech": {
        "espeak": {
            "voice": "de"
        },
        "larynx": {
            "voice": "de-thorsten",
            "volume": "0.95"
        },
        "satellite_site_ids": "SATELLITE1",
        "system": "nanotts"
    }
}

and this is my satellite config

{
    "dialogue": {
        "satellite_site_ids": "SATELLITE1",
        "system": "rhasspy"
    },
    "intent": {
        "system": "hermes"
    },
    "microphone": {
        "arecord": {
            "udp_audio_host": "127.0.0.1",
            "udp_audio_port": "12202"
        },
        "pyaudio": {
            "device": "0",
            "udp_audio_host": "127.0.0.1",
            "udp_audio_port": "12202"
        },
        "system": "pyaudio"
    },
    "mqtt": {
        "enabled": "true",
        "host": "192.168.xxx.xxx",
        "password": "passwd",
        "site_id": "SATELLITE1",
        "username": "rhasspy"
    },
    "sounds": {
        "aplay": {
            "device": "hw:CARD=Headphones,DEV=0"
        },
        "system": "aplay"
    },
    "speech_to_text": {
        "system": "hermes"
    },
    "text_to_speech": {
        "system": "hermes"
    },
    "wake": {
        "pocketsphinx": {
            "keyphrase": "okay igor",
            "threshold": 3.1622776601683794e-28,
            "udp_audio": "127.0.0.1:12202"
        },
        "porcupine": {
            "keyword_path": "hey siri_raspberry-pi.ppn",
            "sensitivity": "0,5",
            "udp_audio": "127.0.0.1:12202"
        },
        "precise": {
            "model": "marvin.pb",
            "udp_audio": "127.0.0.1:12202"
        },
        "raven": {
            "keywords": {
                "FU_Computer": {
                    "enabled": false
                },
                "FU_Igor": {
                    "enabled": false
                },
                "Ok Igor": {
                    "enabled": true
                },
                "Ok_Computer": {
                    "enabled": false
                },
                "Ok_Igor": {
                    "enabled": true
                }
            },
            "minimum_matches": "1",
            "probability_threshold": "0.55",
            "udp_audio": "127.0.0.1:12202",
            "vad_sensitivity": "2"
        },
        "snowboy": {
            "apply_frontend": true,
            "model": "hey_extreme.umdl",
            "sensitivity": "0.5",
            "udp_audio": "127.0.0.1:12202"
        },
        "system": "snowboy"
    }
}

and there are no other satellites in my network

Speech to text should be disabled on the satellite.
What happens now:

  • server: message arrives on server and satellite_site_ids is set to SATELLITE1, so the server is generating text and publishes the audio and the satellite plays it
  • satellite: TTS is set to hermes, so when the audio generated by the server arrives, it too plays the audio.
1 Like

thank you very much for clarifying this :+1:

tried this but unfortunately with no change

I also tried restarting both Server & Satellite but the doubling remains…
I have no idea why this still happens

I also looked into my openhab logs and this seems to be the problem
but I don’t understand how this occures - seems like there are multiple detections

the first Rhasspy_Time event change is from “wie spät ist es” to “wie spät”

and the second event changes from “wie spät” to “wie spät”

this gives me headache but looks like my detected phrases are not unique or something like that…

==> /var/log/openhab/events.log <==
2021-07-31 19:39:26.013 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'Rhasspy_Time' changed from {"input": "wie spät ist es", "intent": {"intentName": "GetTime", "confidenceScore": 1.0}, "siteId": "SATELLITE1", "id": null, "slots": [], "sessionId": "SATELLITE1-snowboy-1132c4cd-8098-4700-89ed-62833d64fd45", "customData": "snowboy", "asrTokens": [[{"value": "wie", "confidence": 1.0, "rangeStart": 0, "rangeEnd": 3, "time": null}, {"value": "spät", "confidence": 1.0, "rangeStart": 4, "rangeEnd": 8, "time": null}, {"value": "ist", "confidence": 1.0, "rangeStart": 9, "rangeEnd": 12, "time": null}, {"value": "es", "confidence": 1.0, "rangeStart": 13, "rangeEnd": 15, "time": null}]], "asrConfidence": 0.800022, "rawInput": "wie spät ist es", "wakewordId": "snowboy", "lang": null} to {"input": "wie spät", "intent": {"intentName": "GetTime", "confidenceScore": 0.5}, "siteId": "SATELLITE1", "id": null, "slots": [], "sessionId": "SATELLITE1-snowboy-2985a957-f3ea-4e5a-8057-ffab378d60fb", "customData": "snowboy", "asrTokens": [[{"value": "wie", "confidence": 1.0, "rangeStart": 0, "rangeEnd": 3, "time": null}, {"value": "spät", "confidence": 1.0, "rangeStart": 4, "rangeEnd": 8, "time": null}]], "asrConfidence": 0.429419, "rawInput": "wie spät ist", "wakewordId": "snowboy", "lang": null}
2021-07-31 19:39:26.014 [INFO ] [openhab.event.ItemCommandEvent      ] - Item 'Rhasspy_Answer' received command {"sessionId":"NULL", "siteId":"SATELLITE1","text":"es ist 19 uhr und 39 minuten"}
2021-07-31 19:39:26.016 [INFO ] [penhab.event.ItemStatePredictedEvent] - Item 'Rhasspy_Answer' predicted to become {"sessionId":"NULL", "siteId":"SATELLITE1","text":"es ist 19 uhr und 39 minuten"}
2021-07-31 19:39:26.018 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'Rhasspy_Answer' changed from {"sessionId":"NULL", "siteId":"SATELLITE1","text":"es ist 19 uhr und 31 minuten"} to {"sessionId":"NULL", "siteId":"SATELLITE1","text":"es ist 19 uhr und 39 minuten"}

==> /var/log/openhab/events.log <==
2021-07-31 19:39:27.835 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'Rhasspy_Time' changed from {"input": "wie spät", "intent": {"intentName": "GetTime", "confidenceScore": 0.5}, "siteId": "SATELLITE1", "id": null, "slots": [], "sessionId": "SATELLITE1-snowboy-2985a957-f3ea-4e5a-8057-ffab378d60fb", "customData": "snowboy", "asrTokens": [[{"value": "wie", "confidence": 1.0, "rangeStart": 0, "rangeEnd": 3, "time": null}, {"value": "spät", "confidence": 1.0, "rangeStart": 4, "rangeEnd": 8, "time": null}]], "asrConfidence": 0.429419, "rawInput": "wie spät ist", "wakewordId": "snowboy", "lang": null} to {"input": "wie spät", "intent": {"intentName": "GetTime", "confidenceScore": 0.5}, "siteId": "SATELLITE1", "id": null, "slots": [], "sessionId": "SATELLITE1-snowboy-24e23bd4-fe0a-477d-a38a-99828e0b1b28", "customData": "snowboy", "asrTokens": [[{"value": "wie", "confidence": 1.0, "rangeStart": 0, "rangeEnd": 3, "time": null}, {"value": "spät", "confidence": 1.0, "rangeStart": 4, "rangeEnd": 8, "time": null}]], "asrConfidence": 0.429419, "rawInput": "wie spät ist", "wakewordId": "snowboy", "lang": null}
2021-07-31 19:39:27.836 [INFO ] [openhab.event.ItemCommandEvent      ] - Item 'Rhasspy_Answer' received command {"sessionId":"NULL", "siteId":"SATELLITE1","text":"es ist 19 uhr und 39 minuten"}
2021-07-31 19:39:27.844 [INFO ] [penhab.event.ItemStatePredictedEvent] - Item 'Rhasspy_Answer' predicted to become {"sessionId":"NULL", "siteId":"SATELLITE1","text":"es ist 19 uhr und 39 minuten"}

I have to think about that and review my phrases which activate the [GetTime] thanks a lot so far

cheers
Dan

Np, good luck with the debugging!