stanford-oval / almond-hassio-repository Goto Github PK
View Code? Open in Web Editor NEWLicense: Apache License 2.0
License: Apache License 2.0
I spoke some with gcampax to work on integrating api calls into a home assistant implementation of node-red/almond. The direction given for the authentication step was to retrieve the bearer token from "/data/almond-server/prefs.db in the add-on container" where it should have been set up during setup/startup.
I was unable to find a method to access the file, and a search of the entire home assistant file system (ls -laR / | grep prefs.db) came up with zero hits. Per home-assistant/operating-system#634 my understanding is that the add-on files are inaccessible.
One potential option I can think of is to set the bearer token to be available in a config file (editable if the user wants to modify it), and expose that config file for read/write in the Home assistant>supervisor dashboard > almond > configuration tab (I tried attaching an image of the add-on page with the configuration tab available, hopefully it goes through). All that said, I do not have a background in add-on setup, or the integration into Almond, so while that seems like an easy method to me, there may be better options to expose the bearer token to home assistant users.
Thanks for your work on this project and add-on for home assistant. Bit of background - my personal intermediate goal is to tie together my existing setup of Rhasspy server/satellites into Almond via API calls rather than having to hardcode (in node red) every command/response manually for Rhasspy.
Almond starts up, speaks the "...how can I help you" line and then waits. When I issue the wake word, Almond crashes with the following error.
I am running the following version:
Current version: edge-7c75cfe
The home server version of Almond 2.0 (edge builds).
/opt/almond/main.js:24
process.on('unhandledRejection', (up) => { throw up; });
^
TypeError [ERR_HTTP_INVALID_HEADER_VALUE]: Invalid value "undefined" for header "Ocp-Apim-Subscription-Key"
at ClientRequest.setHeader (_http_outgoing.js:533:3)
at new ClientRequest (_http_client.js:242:14)
at Object.request (https.js:316:10)
at /opt/almond/node_modules/genie-toolkit/dist/lib/speech/speech_recognizer.js:251:29
at new Promise (<anonymous>)
at SpeechRecognizer._obtainAccessToken (/opt/almond/node_modules/genie-toolkit/dist/lib/speech/speech_recognizer.js:250:16)
at SpeechRecognizer._ensureAccessToken (/opt/almond/node_modules/genie-toolkit/dist/lib/speech/speech_recognizer.js:269:21)
at SpeechRecognizer._ensureConnection (/opt/almond/node_modules/genie-toolkit/dist/lib/speech/speech_recognizer.js:345:25)
at SpeechRecognizer.request (/opt/almond/node_modules/genie-toolkit/dist/lib/speech/speech_recognizer.js:349:14)
at SpeechHandler._onDetected (/opt/almond/node_modules/genie-toolkit/dist/lib/speech/speech_handler.js:199:49)
Emitted 'error' event on SpeechHandler instance at:
at SpeechRecognizer.<anonymous> (/opt/almond/node_modules/genie-toolkit/dist/lib/speech/speech_handler.js:76:18)
at SpeechRecognizer.emit (events.js:314:20)
at /opt/almond/node_modules/genie-toolkit/dist/lib/speech/speech_recognizer.js:353:18
at processTicksAndRejections (internal/process/task_queues.js:97:5) {
code: 'ERR_HTTP_INVALID_HEADER_VALUE'
}
On the Info tab of the Home Assistant Addon, at the top of the page, there's a blob of text that says "Visit the Almond - Edge page for more details". The 'Almond - Edge' part is a link to: http$://github.com/home-assistant/addons/blob/master/almond/edge (URI changed to avoid getting chopped).
That page doesn't exist and gives a 404 error as of 5/10/2021, around 11:41pm EDT.
Hey, trying to start the Genie pre release gives me the following log:
I've got no mic or speaker connected, running from an ha blue device.
Any tips?
If SSL is configured for the Home Assistant installation, we should pick up the same certificates and use them to enable SSL for our own endpoint, given that we no longer go through the ingress.
Hello,
I installed Amond edge version on my HA raspberry but I can't get voice commans to work.
I have audio configured like this using an USB microphone:
When I try to use the wake word and talk to it nothing happens, there's no response and also nothing in the logs.
What can I do the get the voice recognition to work?
After a few days of not using Genie, when I try to use voice commands now the client tells "certificate expired".
When opening the webui on the Homeassistant Genie Server it just says "Lost connection to the server".
When looking in the logs there is nothing related to a certificate error...
On discord there seem to be others with the same issue.
The addon works as is, though it fails to initialize pulseaudio since it assumes all HASS instances are running on a bare OS. (In my case HASS is running as an Appliance VM on a bare metal hypervisor)
** (genie-client:380): ERROR **: 13:14:47.478: pa_simple_new() failed: No such entity
genie-client exited with signal SIGTRAP
The idea would be to have a server-only version of the addon (or have a config option / startup flag - that won't start the client part of genie), in order to support HASS instances which would act only as a server.
Hello, I have problems with Almond on my Home assistant instalation. It won't respond to simple commands. Here is an example:
Also if I try to click on one of the Skills I get: 'almond.stanford.edu refused to connect.'
Any help appreciated!
LOGS:
GET / 200 1510.434 ms - 4393 172.30.32.2 - - [04/Jul/2021:10:50:45 +0000] "GET / HTTP/1.1" 200 1707 "http://homeassistant.local:8123/core_almond" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" 172.30.32.2 - - [04/Jul/2021:10:50:45 +0000] "GET /stylesheets/bootstrap.min.css HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /stylesheets/bootstrap.min.css 304 50.703 ms - - 172.30.32.2 - - [04/Jul/2021:10:50:45 +0000] "GET /stylesheets/style.css HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /stylesheets/style.css 304 52.539 ms - - 172.30.32.2 - - [04/Jul/2021:10:50:45 +0000] "GET /javascripts/validator.min.js HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /javascripts/validator.min.js 304 10.775 ms - - 172.30.32.2 - - [04/Jul/2021:10:50:45 +0000] "GET /javascripts/jstz.min.js HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /javascripts/jstz.min.js 304 11.002 ms - - 172.30.32.2 - - [04/Jul/2021:10:50:45 +0000] "GET /javascripts/shared.js HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /javascripts/shared.js 304 11.421 ms - - 172.30.32.2 - - [04/Jul/2021:10:50:54 +0000] "GET /conversation HTTP/1.1" 200 1685 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /conversation 200 372.905 ms - 4820 172.30.32.2 - - [04/Jul/2021:10:50:54 +0000] "GET /stylesheets/bootstrap.min.css HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/conversation" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /stylesheets/bootstrap.min.css 304 4.490 ms - - 172.30.32.2 - - [04/Jul/2021:10:50:54 +0000] "GET /stylesheets/style.css HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/conversation" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /stylesheets/style.css 304 5.129 ms - - 172.30.32.2 - - [04/Jul/2021:10:50:54 +0000] "GET /stylesheets/spinner.css HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/conversation" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /stylesheets/spinner.css 304 6.290 ms - - 172.30.32.2 - - [04/Jul/2021:10:50:54 +0000] "GET /stylesheets/conversation.css HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/conversation" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /stylesheets/conversation.css 304 6.030 ms - - 172.30.32.2 - - [04/Jul/2021:10:50:54 +0000] "GET /javascripts/validator.min.js HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/conversation" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /javascripts/validator.min.js 304 6.075 ms - - 172.30.32.2 - - [04/Jul/2021:10:50:54 +0000] "GET /javascripts/jstz.min.js HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/conversation" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /javascripts/jstz.min.js 304 5.289 ms - - 172.30.32.2 - - [04/Jul/2021:10:50:54 +0000] "GET /javascripts/conversation.js HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/conversation" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /javascripts/conversation.js 304 5.879 ms - - 172.30.32.2 - - [04/Jul/2021:10:50:54 +0000] "GET /javascripts/shared.js HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/conversation" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /javascripts/shared.js 304 6.597 ms - - Sun, 04 Jul 2021 10:50:54 GMT express deprecated req.host: Use req.hostname instead at routes/api.js:245:24 172.30.32.2 - - [04/Jul/2021:10:50:54 +0000] "GET /images/bubble_almond.png HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/stylesheets/conversation.css" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /images/bubble_almond.png 304 3.814 ms - - 172.30.32.2 - - [04/Jul/2021:10:50:58 +0000] "GET /images/bubble_user.png HTTP/1.1" 304 0 "http://homeassistant.local:8123/api/hassio_ingress/alSBnCUlj1OzPPdCNtl2TSy9nk6fUklZ85VS7Qnydl0/stylesheets/conversation.css" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" GET /images/bubble_user.png 304 3.265 ms - - Analyzed message into now => @org.thingpedia.builtin.thingengine.builtin.faq_reply param:question:Enum(about_almond_identity,about_almond_age,about_almond_how_are_you,about_almond_location,about_almond_comparison,about_almond_training,about_almond_partner,about_almond_junk,about_almond_preference,check_capability_home_assistant,check_capability_phone,general_help,iot_help,positive_emotion_thanks,positive_emotion_cool,abusive,revoke_consent,how_to_train,how_to_configure_skill,how_to_disable_skill,how_to_set_language,how_to_access_settings,how_to_use_wakeword,troubleshooting_home_assistant) = enum:general_help Failed to parse beam 0: Class org.thingpedia.builtin.thingengine.builtin has no action faq_reply Failed to parse beam 1: Class org.thingpedia.builtin.thingengine.builtin has no action faq_reply
Use case: I would like to only be able to access Almond internally on my network or through hassio ingress
Steps to reproduce:
Expected:
Almond works in the ingress tab or via http://homeassistant.local:9320
When attempting the local http protocol using port 9320, an NGINX error is given:
400 Bad Request
The plain HTTP request was sent to HTTPS port
I do not want to open port 9320 and only want Almond available using Hassio ingress or via my local network
Currently, the only way to access Almond is to open port 9320 in my firewall
We should remove all the bits of the documentation that are specific to the official add-on. Especially we should change the communication channels to refer to our discord and our community forum, instead of Home Assistant's.
Hello,
just installed the hassio almond edge addon and it worked right away using the chat.
The only problem that I came across is that the configured audio input and output devices are not working:
I can't find any way to debug the audio with almond/home assistant.
Running debian 10 with home assistant supervised on a amd64 machine.
To play news with SmartNews, we'll need something capable of playing MP3. GStreamer (gst-plugins-good, gst-plugins-bad-free, and whatever package includes "gst-play-1.0" and "gst-discoverer-1.0") is the best technical choice.
Not sure if something should be in that panel, but apart from a "My Rules" header there is nothing if no rules were created yet. Is that expected behaviour for the current version?
If there are no rules yet, perhaps a short text indicating so with a hint on how to create them might be helpful. Otherwise users might think something failed to render (as I did at first ๐).
EDIT: Now that I think about it, this is probably the wrong repo as the Almond GUI is most likely not specific to that HA add-on.
I just installed the Genie - Edge add-on on my Home Assistant OS OVA (version 8.1), however the container is not starting. I have the following logs:
s6-rc: info: service s6rc-oneshot-runner: starting
s6-rc: info: service s6rc-oneshot-runner successfully started
s6-rc: info: service fix-attrs: starting
s6-rc: info: service fix-attrs successfully started
s6-rc: info: service legacy-cont-init: starting
s6-rc: info: service legacy-cont-init successfully started
s6-rc: info: service legacy-services: starting
services-up: info: copying legacy longrun almond (no readiness notification)
services-up: info: copying legacy longrun nginx (no readiness notification)
s6-supervise nginx: warning: unable to spawn ./run - waiting 10 seconds
s6-supervise nginx (child): fatal: unable to exec run: Permission denied
s6-supervise almond: warning: unable to spawn ./run - waiting 10 seconds
s6-supervise almond (child): fatal: unable to exec run: Permission denied
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.