
Building a voice assistant to control music - wheresvic1
https://smalldata.tech/blog/2017/11/15/building-a-voice-assistant-to-control-music
======
gm-conspiracy
Is there a way to do this without an internet connection and without Chrome?

~~~
wheresvic1
Actually there is - there is a very nice library called pocket sphinx that
does offline speech recognition.

However it's not quite so easy to use - there's a python package that
interfaces with it but you would need to know how to grab your own audio
sample from the mic and pass it to the library.

I actually managed to get a sample app running using it but I found that the
error rate was around 50% and I needed to repeat myself quite a few times.

~~~
CaptSpify
That mirrors my experience with it. I eventually gave it up because it was
more infuriating than it was helpful.

Not to diminish all the hard work that the Sphinx group has done, but it's
only at alpha quality ATM. I think it has potential, but I don't know how fast
the development is moving.

~~~
tabeth
Doesn't it suck only because it hasn't been well trained on a variety of
voices?

~~~
jjwiseman
Pocketsphinx is pretty far behind the state of the art in speech recognition
algorithms. It also doesn't have a very large acoustic model.

You can greatly improve the recognition by using a restricted language model,
however.

------
eurticket
What if the lyrics trigger the music controls?

~~~
wheresvic1
Excellent question - in general they don't! The voice recognition is smart
enough that it can discern between music and speech (maybe there is to much
melody?)

------
uniacid
Cool I was looking to do something similar with my Pi with the Google Voice
kit essentially to be able to control your Spotify, this makes me want to take
another look at it for general use without a Pi or Python :)

------
1stcity3rdcoast
Funny, I'm reading this in the gym not 2 minutes after thinking to myself it
would be great to be able to change songs with weights in my hands. Talk about
timing!

