Callum Kirkwood

Blog
Projects
Photography
LinkedIn
GitHub
Twitter

Google AIY Projects

07 May 2017

Google AIY

Although I eventually managed to get my hands on a Raspberry Pi Zero (and more recently a Zero W), I never had the satisfaction of getting a free computer attached to a magazine (MagPi #40). MagPi #57 offers something even better - AIY (Artifical-Intelligence-Yourself), a free hardware kit from Google; their latest experiment in cardboard and their first in open source AI for makers and educators.

Built around a custom Voice HAT, Google’s first AIY box helps a Raspberry Pi communicate with the Google Assistant API, which essentially turns the kit into a £130 Google Home. A stereo microphone provides near & far-field coverage, similar to the Home, and the 3 inch speaker is surprisingly clear. The main draw for me, however, is the included arcade button - the box will only be listening when I want it to, unlike similar home assistants.

Google AIY Components

Source: Google Developers Blog

I had to fiddle with the microphone and speaker connections a couple of times to deal with crackling audio, but once everything was inside the box there didn’t seem to be any problems. The combination of the brilliant microphone and Google’s speech-to-text capabilities totally knock Siri out of the park - I rarely have to repeat myself and I don’t feel so obliged to speak slowly and clearly, while background noise from the TV doesn’t seem to cause any problems.

I’ve not quite tested the limits of the stock features, but it’s possible to ask questions with multiple variables, and some responses seem to store context from previous questions. For example, in some follow up questions it’s not necessary to specify a target (such as a destination), although I’m not certain which circumstances allow this shorthand.

Q: How far is it to the train station?
A: ...the closest is 0.4 miles away by car
Q: How long will it take to walk there?
A: ...it will take you 12 minutes to get there on foot

As I mentioned in my last post localisation and low cost are the key factors in my IoT projects, so this kit is pretty much ideal. While the main script essentially mimics Google Home, the real power lies in the ability to extract specific functions and create custom actions. The hardware is also nicely expandable, with room for a second speaker terminal and a solder bridge for stereo audio, as well as a number of GPIO breakouts and space for a DC barrel jack. Everything can be connected without soldering, so the components are also reusable for other projects.

Google's Voice HAT

Limitations are to be expected for such a low cost, but there’s nothing that can’t be overlooked. Aside from the speaker issues mentioned earlier, the ‘local’ voice setting used when creating your own scripts is almost unusable due to the low quality - with the community already working on their own projects, I’m sure this will be fixed soon. Some features seem to be reserved for the full Google Home, or at least a device connected to a smartphone - podcasts, for example, can be found but won’t seem to play.

The response:failure ratio seems to be around 80:20, with only around 5% of responses resulting in an error code or no response. The conversational aspects feel like a logical evolution of Google’s development of semantic search, where the introduction of card results and the knowledge graph have steadily encouraged people to search in a more natural way. Thanks to this, it’s not difficult to think of fairly advanced questions that the Assistant API is able to deal with.

As much as I love the cardboard casing, I definitely want to integrate this into something more convenient. I’ve also been toying with the idea of using arcade buttons in a coffee table for simple IoT control, so I’m pretty much settled on that direction now. While I’m at it, I figure I may as well make this a full project and design/build the table myself so that the button placement is just right. I’ll also be able to embed a pair of speakers for improved audio, and my experiments in analogue inputs should also come in handy. I’ve got a pretty good idea of where I’ll start, and I’ll be posting my progress here as it develops.

MagPi stocks are inevitably sold out already, although there are rumours of some shops holding them back as they can’t fit in the shelves… Google have also set up a mailing list to announce the next release. This is just the first in what seems to be a suite of AIY kits, and I’m assuming that future kits will dig further into the AI aspect - I can’t wait to see what’s up next!