JarbasHiveMind / HiveMind-cli

OpenVoiceOS Remote CLI
Apache License 2.0
7 stars 7 forks source link

Cli interface answers first question then goes silent/ freezes #9

Closed Guillaume-slize closed 1 year ago

Guillaume-slize commented 3 years ago

I am trying to set-up a small Hivemind network using a raspberry 4B and a mac (macOs Catalina 10.15.7) via Wi-Fi and ssh.

I managed to connect to the hive thanks to @JarbasAl help but now the interface is bugging/lagging. Raspberry output:

(.venv) pi@raspberrypi:~ $ python3 HiveMind-core/examples/mycroft_master.py 
2021-07-28 21:30:01.739 - OVOS - jarbas_hive_mind:secure_listen:201 - INFO - HiveMind Listening: wss://0.0.0.0:5678
2021-07-28 21:31:21.094 - OVOS - jarbas_hive_mind.nodes.master:onConnect:45 - INFO - Client connecting: tcp4:192.168.1.7:56923
2021-07-28 21:31:21.109 - OVOS - jarbas_hive_mind.nodes.master:onOpen:87 - INFO - WebSocket connection open.
2021-07-28 21:31:21.115 - OVOS - jarbas_hive_mind.nodes.master:register_client:250 - INFO - registering client: tcp4:192.168.1.7:56923
2021-07-28 21:31:25.146 - OVOS - jarbas_hive_mind.nodes.master:handle_incoming_mycroft:395 - INFO - Forwarding message to mycroft bus from client: tcp4:192.168.1.7:56923
2021-07-28 21:31:26.074 - OVOS - jarbas_hive_mind.nodes.master:handle_incoming_mycroft:395 - INFO - Forwarding message to mycroft bus from client: tcp4:192.168.1.7:56923
2021-07-28 21:31:51.153 - OVOS - jarbas_hive_mind.nodes.master:handle_incoming_mycroft:395 - INFO - Forwarding message to mycroft bus from client: tcp4:192.168.1.7:56923

Mac Output:

(py36) MacBook-Pro:11_guillaume.scripts $ HiveMind-cli --access_key=RESISTENCEisFUTILE --crypto_key=resistanceISfutile --name=JarbasCliTerminal --host=wss://192.168.1.42
2
2021-07-28 15:31:20.916 - OVOS - jarbas_hive_mind:secure_connect:68 - INFO - Connecting securely to wss://192.168.1.42:5678
2021-07-28 15:31:21.159 - OVOS - jarbas_hive_mind.nodes.terminal:onConnect:20 - INFO - HiveMind connected: tcp4:192.168.1.42:5678
2021-07-28 15:31:21.161 - OVOS - jarbas_hive_mind.nodes.terminal:onOpen:25 - INFO - HiveMind websocket connection open. 
Input:hello world
Input:Mycroft: Hi to you too
Mycroft: Sorry, I didn't catch that.
Input:who is benjamin franklin
Input:Mycroft: Benjamin Franklin is an American polymath and one of the Founding Fathers of the United States.
what is the wind?

It seems that mycroft use the answer of the first question as an input ("Hi to you too") and when it gives an elaborate answer (such as B.Franklin biography) it seems to freeze and does not recognise or ask for another input (e.g. "What is the wind").

Also when I reboot the hive and stop and rerun the cli interface, the cli does answers the first question but stops there.

Not sure where to look for answers/explanations, as there is nothing significant in the skills log.

ChanceNCounter commented 3 years ago

I am compelled to assume things aren't going to work well on post-Catalina Mac until I make my entire life about it for a week or two.

Full disclosure: I was literally born into the Mac industry. Hence, the degree of my current rage at Apple is in proportion to the years lost. If it were legal, I would fly direct to Silicon Valley and break pieces of Tim Cook he didn't know he had.

So it might be a while.

Guillaume-slize commented 3 years ago

Haha, no worries, I will try on a linux machine then :) .

Guillaume-slize commented 3 years ago

Tried it out on raspberry, it works well :) . The printing of "input" and "mycroft" is sometimes out of sync

(.venv) pi@raspberrypi:~ $ HiveMind-cli --access_key=RESISTENCEisFUTILE --crypto_key=resistanceISfutile --name=JarbasCliTerminal --host=wss://0.0.0.0 
2021-07-30 21:01:48.222 - OVOS - jarbas_hive_mind:secure_connect:68 - INFO - Connecting securely to wss://0.0.0.0:5678
2021-07-30 21:01:48.298 - OVOS - jarbas_hive_mind.nodes.terminal:onConnect:20 - INFO - HiveMind connected: tcp4:0.0.0.0:5678
2021-07-30 21:01:48.303 - OVOS - jarbas_hive_mind.nodes.terminal:onOpen:25 - INFO - HiveMind websocket connection open. 
Input:Hello world
Mycroft: Hello
Input:What is the wind
Mycroft: Currently, wind speed is at 0 meters per second from the north
Mycroft: Not much wind
Input:who is abraham lincoln
Input:Mycroft: Abraham Lincoln is an American lawyer and statesman who served as the 16th president of the United States.
what is the weather
Mycroft: It's currently scattered clouds and 20 degrees celsius.
Mycroft: Today's forecast is for a high of 20 and a low of 13.
Input:gibberish
Input:Mycroft: Please rephrase your request.
what do you mean?
Input:Mycroft: The definition of the word "you" is: second‐person singular and plural personal pronouns, refers to the person or people being addressed
ChanceNCounter commented 3 years ago

Yep. Sorry about that prompt delay. We know it's annoying, but it's a very low priority compared with connecting the Mycroft side to device control, an undertaking which itself has been mostly-stalled in favor of @OpenVoiceOS efforts. OVOS components ultimately feed directly into HiveMind, but the reverse is not (currently) true, and the projects are of equal importance to our team.

Apart from protocol design, HiveMind's most immediate concern is nailing down the voice sat's audio-related behavior, especially on Linux. This repo's important, but at this stage, its most important purpose is just to exist =P both to verify that a new Hive is working, and to help narrow down problems.