Multiple mqtt messages on wake word detection or intent recognized

i’m just starting to use rhasspy 2.5 pre-release .
So i have this script that prints mqtt topics on detection , but the issue is if an intent is recognized it is recognized 3 (or more) times , every sentences sent to tts gets read multiple times …

i can’t figure out what the issue is.

Can you give more information about your setup, like is it all on a single machine, client/satellite, what settings you have entered, what you use for wake word, etc.

It’s a bit hard to help with no information.

I’m using a raspberry pi 3 with a matrix voice as a mic.
The following is my setting page :

i’m using the provided in rhasspy docs (loops forever and catches mqtt topics .
The issue is present whether i’m using the porcupine wakeword or the recognize intent button on the web interface.

Also if i speak the wakeword it just keeps beeping .

I don’t see any messages in the screenshot you included above saying that it got an intent.
I think that is processing other messages sent to mqtt.

What happens if you disable Dialogue Management?

I can’t really help you with the wakeword handling. I have tried a respeaker 2-mic with snowboy and it accepts the wakeword but then the audio sent to the speech to text seems to be garbled and causes bells in the console but doesn’t hear/handle the input properly and continues until the input times out.
So I think I’m in the same boat as you there.

Hope you find a solution for your issue :pray:

This is my python script :

import json
import traceback
import paho.mqtt.client as mqtt
NoneType = type(None)

def on_connect(client, userdata, flags, rc):
“”“Called when connected to MQTT broker.”""
print(“Connected. Waiting for intents.”)

def on_disconnect(client, userdata, flags, rc):
“”“Called when disconnected from MQTT broker.”""

def on_message(client, userdata, msg):
“”“Called each time a message is received on a subscribed topic.”""
nlu_payload = json.loads(msg.payload)
site_id = nlu_payload[“siteId”]

Create MQTT client and connect to broker

client = mqtt.Client()
client.on_connect = on_connect
client.on_disconnect = on_disconnect
client.on_message = on_message

client.connect(“localhost”, 1883)

and this is what it prints when i say “Hey porcupine , ouvrir”

this issue perssist even when i disable dialogue management .

1 Like

So now everything is working fine , here’s what i did :

run on terminal

docker pull rhasspy/rhasspy:2.5.0-pre

then list docker containers

docker container ls

Found 2 rhasspy containers( i guess this was the issue, if not then the new rhasspy 2.5 image did the trick) , then stoped and removed these containers :

docker stop “container id”
docker rm “container id”

After i just normally ran docker (added network host because i’m using an external mqtt;profil fr for frensh):

docker run -d -p 12101:12101
–network host
–restart unless-stopped
-v “$HOME/.config/rhasspy/profiles:/profiles”
–device /dev/snd:/dev/snd
–user-profiles /profiles
–profile fr

Now it works fine .

I’m glad you worked it out.