Snips.ai Voice Assistant - from questions to ultimate guide

Hi home’s!

I would like to make this a guide for beginners to create their own Snips Voice Assistant. I spent the whole day with reading about this topic but i still did not understand the whole thing.
There’s not that much on the web… some things are outdated, thats why i created this here.

What is snips?
Snips is a local voice assistant. The brain is in the device itself, it does not need an internet connection and has a big focus on privacy. Thats the main difference to Alexa and Google Home which need a cloud server to understand/interpret your commands.

Documentations
Hass.io Addon Docs: https://www.home-assistant.io/addons/snips/
Hassbian Docs: Snips - Home Assistant
Built-in intents | Home Assistant Developer Docs
Home Assistant | Latest Platform Version | Snips Dev Center
Home · tschmidty69/hass-snips-bundle-intents Wiki · GitHub
https://forum.snips.ai/t/integrating-snips-with-home-assistant/211

My Plan
I would like have four snips in my flat
flat

I ordered 3x RaspberryPi 3 and 4x ReSpeaker 4-Mic Array

db9eedab7d5586cc30e13533ed259592bebf5e0c

What I understood

Installation
The first steps are pretty easy with hassio.

  1. Install the mosquitto broker addon
  2. Install snips.ai addon
  3. Install samba addon

Click on the snips.ai addon.
If your are a native english speaker you can leave the config as it is. I switched it to “de” for german language.
4) Plug in an USB Mic and Speaker. At the Moment I am using a gaming headset.

The “assistant.zip” is the brain of snips. The snips addon automatically installs an assistant.zip for you.

You can use it but you should create your own assistant. You can follow the tutorial here:

…to be continuted…

My first question: Whats the best setup?
Would you use the hassio main installation and install a respeaker on it?

Hassio ↔ Snips ↔ 3 Snips
Hassio(w/ Snips) ↔ 3 Snips

Second question
How does homeassistant know which light to switch when i say. “Hey snips, turn on the light in the living room”
Are the groups the room they are in?
I dont understand what happens when i tell the assistant to do it. Does it send the data to homeassistant and it does understand it immediately? What are those intent_scripts doing?

I dont understand this part:

As the Snips Platform parses this query into an intent, it will be published on MQTT, on the hermes/intent/<intentName> topic. The Snips Home Assistant component subscribes to this topic, and handles the intent according to the rules defined in configuration.yaml file, as explained below.

I will edit this here and keep on reading and getting better at this stuff here. Thanks for any help in advance

Might be useful too:

He is using a HASS installation, uses an extra raspberry for snips and wants to add another “satellite”-snips raspberry.

10 Likes

Ciao @totolino!

May I please ask (100% laziness on my part!)? As you work on your how-to/walk-through, would you please consider adding a 2-3 sentence part at the beginning that explains what the Snips Voice Assistant is, and perhaps, why it is an alternative to the traditional options, e.g., Alexa, Siri, Google Assistant. I know nothing about it and figure other readers may be as lazy/ignorant as me. :wink:

Thanks and looking forward to seeing your progress. The details you’ve posted already are wonderful!

-Matt

You are absolutely right.

Are you also working on it?

ATM I’m running home-assistant on an abandoned laptop (linux) – but I’m really interested in moving toward a lighter solution, like the raspberry pi. OH HEY just saw the details you added, thanks!!! Let me read up on it a bit before answering your question.

In the meantime, the short-term answer is that – rather than voice – I’m hoping to focus a bit more on video-based machine-learning. Examples might be things like face recognition, presence detection, and eventually, data-mining over long-term image-processing, e.g., seasonal variation in room occupancy as it relates to lighting, room temperature, and ultimately (of course!) energy usage. :money_mouth_face:

Thanks again for the quick update!

-Matt

PS But anything with the letters “AI” gets me excited. :wink:

1 Like

the plugin does not work with new assistant.zip files… update incoming… thats why it does not work for me…

1 Like

Hi @totolino

Did you ever managed to get the Respeaker to work with a Hassio running the Snips App? I just got a Respeaker and was hoping to add it to my RPI Running Hassio

Hi. No i didnt. I switched to hassbian. Sorry

Arh okay, well I am actually also considering whether I might just run Snips Headless on Hassio and then build satellites

But how did your project go? I would love to get an update, sounded like you were on your way to making a really cool setup :slight_smile:

1 Like

It’s running pretty well. By the way… while reading your text I realized that I did not install snips on my HomeAssistant Pi.

I have a mqtt Bridge between snips pi and HA pi.

Yeah maybe I should just type the whole thing in here. Please give me some time. Have a lot to do atm.

1 Like

Just playing around here.
Day one: I have the snips raspi all set with the 4 way microphone ( it answers to my "hey snips).
Bridged the two Mqtt server together.
With mosquito_sub with an “hand crafted” message I managed to turn off a switch.
Nothing more: long way to go.

1 Like

yes would be very interested in taking a look at your snips.toml, mqtt config, and configuration.yaml to see what intents and such you used.

replying to self here — i have this fully working now.

I will document the install process, with extreme detail, and share it here in the next few days. The process was quite easy once I got it ironed out.

I have a stand-alone SNIPS server running on raspi3B+ connecting to a hass.io instance, using the MQTT hass.io addon.

full instructions and documentation coming soon.

4 Likes

looking forward to this :blush:
what microphone setup do you use? And how much does it cost?

Wish i could use an echo dot completely offline with snips

Awesome. I will do it for hassbian than.

I am using this:


Actually, is quite good, but not good as the mics of Google Mini devices, IMHO.
1 Like

I use the same and have set-up snips and snapcast on a separate RPI3B+.

There is so much stuff that I’ve never played with so it has been a bit hit and miss. But I got it working via pulseaudio such that music can play through the RPI while snips is still working.
Pulse also comes with easy integration of echo cancellation, which I’ve added but haven’t tested it probably

I haven’t gotten around to adding all the mqtt, but super nice to see it all works, I have a mosquito server running on HASSIO so I would just add that. But I’d love to see some of your guys examples of intent handling both from the snips side and HASS !

This is because the next part is, that I need to setup a hifiberry amp2, hopefully I’ll get the last part this week so I can attach the driver.

My concern is whether I can get the stacking of the respeaker and hifiberry to work, I mean they both run on the i2s bus so should be possible.

Incase I get defeated, I’ll get a PS3 mic and use that one instead

Hey your how to would be really handy about now! I have been trying to get my head around all this, but without much progress.

Anyway if you get your how to done, you’d have my appreciation, and many others I suspect.

http://hackspace.io/?page_id=245

Give that a look…

1 Like

thanks I’ll do that.

Ok first question. Did you install snips via apt, docker or using sam?

  1. From what I have read sam is installed on a third computer (ie not the snips rpi and not on hassio) and then controls snips running on the pi. Am I right?