Home » Blog » Local Voice Assistance with Wake Word in Home Assistant! Bye Bye Google Home and Alexa!

Local Voice Assistance with Wake Word in Home Assistant! Bye Bye Google Home and Alexa!

Okay Junkie, Turn off Office Back! Okay Junkie, Turn on Office back! Okay Junkie, Office Scene Green! Okay Junkie, Office Scene Cosy! Yes! Home Assistant now supports local voice assistance with Wake Words! You can even create your own wake word! And, with this ESP32-S3-Box-3, it’s even fancier! Let’s ditch Google Home and Alexa and say hello to Home Assistant to control your devices locally using speech!


โญโญโญ NOTE: โญโญโญ

This article accompanies a YouTube video. I wrote it for people who would rather read than watch a video. To keep doing this, I want to ask you to check out the video, leave a comment under the video, give the video a thumbs up, and subscribe to my YouTube channel. This means that the video is offered more often to new visitors so that they also stay informed of the latest Home Assistant tutorials.

Thank you for your support!

Ed

Click here to watch the video

Home Assistant did it! In the last month of the Year of Voice, the wake word implementation is finished, so now you can control your devices seamlessly using voice assistance locally in Home Assistant! And, if you use this ESP32-S3-Box-3, you can set it up in minutes on your Home Assistant instance! And I will show you how in this video!

Prerequisites

First of all, you need to use Home Assistant Cloud or set up a local Assist pipeline. If you make use of Nabu Casa, you can start with this tutorial right away. If you want to use a local Assist pipeline, then please follow this video first where I explain how you can set this up easily in Home Assistant. I use the ESP32-S3-Box-3 for this tutorial, but this also works with the ESP32-S3-Box or the ESP-32-S3-Box-Lite. You will find a link to purchase the ESP32-S3-Box-3 in the video description. However, obtaining one may be challenging right now due to high demand.

In the next steps, we will set up a Wake Word in Home Assistant and make sure that our ESP-S3-Box-3 will recognize the Wake Word and trigger the devices in Home Assistant. I already have the ESPHome add-on installed in Home Assistant, but I’m not certain whether you need to have it installed before following this tutorial. If you want to be safe, you can do so by going to Settings -> Add-Ons and searching for ESPHome in the Add-On Store. I don’t think it’s needed, but let me know in the comments if you had to install ESPHome first before setting up this device.

Enabling wake word in Home Assistant

Now, let’s enable the wake word!

  • Go to Settings > Add-Ons.
  • Click Add-On Store.
  • Search for Openwakeword.
  • Click Openwakeword.
  • Click Install.
  • After installation is finished, turn on Watchdog and Auto update, and click start.
  • After the add-on is started, go to Settings-> Devices and Services.
  • If everything goes well, you will see an OpenWakeWord Wyoming Protocol integration.
  • Click Configure.
  • Click Submit.
  • Click Finish.

Now we are going to connect the wakeword integration to our Voice Assistant.

  • Go to Settings > Voice Assistants.
  • Click Add Assistant.
  • Give your voice assistant a name. In my case, I call it Nabu, but you can give it any name that you want.
  • Select the Language of your choice in the Speech-to-text section. In my case, I choose American English. Please note that you can only choose from a lot of languages if you use Nabu Casa. If you use a local assist pipeline, you will probably only see one language that you can choose from.
  • Do the same for the Text To Speech section.
  • Finally, select the Wake word engine. In our case that will be openwakeword.
  • Then, select the wakeword of your choice. In my case, I choose Ok Nabu. At the end of the video, I will show you how you can create and use a custom wake word.
  • Click Create.

Our Wakeword integration is now installed. In the next step, we are going to install the S3 box. Make sure you haven’t installed the ESP-3 box before in ESPHome. If you did that before, first remove the existing ESP3 Box from your ESP Home integration. You can do so by entering the integration, clicking on the three dots next to the existing ESP, and clicking delete.

Installing the ESP32-S3-Box-3 for Wake Word detection and speech recognition

  • Go to The esphome projects website. You’ll find the link in the description of this video.
  • Select Voice Assistant.
  • Select the ESP32-S3-Box.
  • Select your variant of the S3-Box. In my case it’s the S3-Box-3.
  • Click connect
  • Now connect your USB cable to the S3-Box. In my case I had to connect the USB cable to the S3-Box itself for my PC to recognize it. When I connected the USB cable to the docking station of the S3-Box-3, the device was not recognized. This only happened during the installation. After that, connecting the USB cable through the docking station worked just fine.
  • Select the device that shows up in the popup and click Connect.
  • The device will now connect.
  • After that, it will be erased and flashed with the new firmware.
  • When the installation is completed, click ‘Next’.
  • Now select your Wi-Fi network and enter the Wi-Fi password for your network.
  • Click Connect.
Connect the S3-Box to Home Assistant

In the next step, we are going to connect the S3-Box to Home Assistant.

  • Click Add to Home Assistant.
  • You will be presented with the my homeassistant page. Make sure that the URL you see here is correct and points to your Home Assistant instance! If this URL is not correct, then edit the URL so that it points to your local Home Assistant instance. This would normally be http://homeassistant.local:8123. In my case, it’s a different address because I use multiple Home Assistant instances.
  • Click Open Link.
  • A dialog box will ask you to set up ESPHome.
  • Click OK in that dialog box.
  • Select your Discovered S3-Box.
  • Click Submit.
  • Click Finish.
  • You can also configure the S3-Box using the other two options that are shown, but it’s not needed once you have followed the instructions that I’ve just shown.
  • Click on the devices link in the ESPHome integration.
  • If everything goes well, the ESP32-S3-Box is now present in the list of devices.
  • When you open the device, you can set some options like the LCD backlight and you can mute the microphone as well.

Now, Let’s test the Wake Word. It should work now.

  • Okay Nabu, Office Back Off.
  • Okay Nabu, Office Back On.
  • Okay Nabu, Office Back 10 percent.
  • Okay Nabu, Office Back 100 percent.
I need your help!

You will be doing me a huge favor if you subscribe to my channel if you haven’t already. And, you will help me a lot if you also give this video a thumbs up and leave a comment. This way, YouTube will present this video to new people, making the channel grow! In the video description, you will also find information about how you can sponsor me so that I can continue to make these tutorials for you.

Thank you!

Creating a custom Wake Word in Home Assistant

Great! This is working. Let’s take it one step further by creating a custom wake word! I’d like to create a wakeword: “Okay Junkie” to control my devices in my house.

  • Go to the model training site. You will find the link in the description below.
  • Enter a target word. It might be that you have to spell the word phonetically so that is pronounced just the way you want it.
  • Click Show Code.
  • Click on the play button at the top left corner of the code field.
  • If you get a warning, just ignore that warning and click on Run anyway.
  • After the process has finished, you can check the pronunciation by clicking on the play button below the code field. If you feel the pronunciation is okay, go to the Runtime menu and click “Run all”.
  • This process will take about an hour, so you can make yourself some coffee or buy me a coffee to ensure that I can continue creating these tutorials for you. See the links in the description of the video for that.
  • After the training process is finished, two files are downloaded to your downloads folder.
Copy the file to the share folder
  • Now you need to copy one of these two files to your Home Assistant server. To be able to do that, you have to have Samba installed in Home Assistant. If you want to know how to do that, you can follow this video where I explain how you can do this. The link to this video is in the description below the video.
  • When you’ve installed Samba, you can access your Home Assistant server with your file explorer.
  • Go to the share folder on your Home Assistant server.
  • Create a new folder “openwakeword”.
  • Now copy the tflite file to that openwakeword folder.
  • Go back to Home Assistant and click on Settings->Voice Assistants.
  • You can either change the existing Nabu assistant that we’ve just created, or add a new assistant.
  • I choose to add a new assistant, so we click on Add Assistant.
  • Give your Assistant a name. In my case, it’s junkie.
  • Again, select the languages for your Speech-to-text and text-to-speech settings.
  • Select Openwakeword in the Wake Word section and select your new wakeword in the Wake Word field. In my case, that is Okay Junkie.
  • Click Create.
Listen to the Wake Word

Now, we have to make sure that our S3-box listens to the new wake word.

  • Go to Settings > Devices and Services.
  • Click the ESPHome integration.
  • Click the device link of your S3 Box.
  • Select your new Wakeword in the Assist pipeline.

And that’s it! Your ESP32-S3-Box will now respond to your new wakeword!

  • Okay Junkie, Office Back Off.
  • Okay Junkie, Office Back On.
  • Okay Junkie, Office Back 50 percent.
  • Okay Junkie, Office Back 100 percent.

So, this is how you set up a wake word in Home Assistant! Thank you for tuning in! If my videos save you time and frustration, consider supporting me through sponsorship just like these awesome people do. You can find links to Patreon, Ko-Fi, and details on becoming a channel member in the video description.

Also, don’t forget to show your support by giving this video a thumbs-up and subscribing to my channel. Stay tuned for my next videoโ€”I’ll see you there!

Bye Bye!

Where to buy the ESP32-S3-Box:

  • ESP32-S3-Box-3:
    AliExpress: https://www.aliexpress.com/item/1005005920207976.html
    Amazon.com: https://amzn.to/3Tr3pdt

Links referred to in this video:



Back to all articles