Author Topic: VoiceAttack and the Windows Speech Engine - Help (several kinds)  (Read 4085 times)

Gary

  • Administrator
  • Hero Member
  • *****
  • Posts: 1731
VoiceAttack and the Windows Speech Engine - Help (several kinds)
« on: December 14, 2017, 08:37:50 pm »
VoiceAttack uses the Windows speech engine for its speech recognition functionality.  On a properly-configured system, the speech engine will usually work with little or no fuss.  Sometimes that's just not the case.  Out of the box, Windows will (usually) come with a built-in speech engine.  If your installation is English, Spanish, German, French, Japanese or Chinese, you will get a built-in speech engine in your language.  If your locale is not one of those listed, I *think* you will get an English speech engine (not sure what's going on nowadays… my installations always occur in Texas, so, English it is ;) ).  Your system may or may not be configured with all that is necessary to get that speech engine to light up right away, even if you have a brand new installation.  I will get messages from time to time, each with its own unique set of circumstances along with a user that has their own unique set of skills (that may be you - you've probably been sent here by me via email -welcome!).  Since it seemed like each issue was unique, it always felt like a stretch to try to make a help guide, however, as interest in VoiceAttack has grown, some form of help in a central place is becoming necessary.  This post is going to try to help out with the most common issues and questions when dealing with VoiceAttack's speech recognition functionality, based on different experiences I've had over the years.  Below are a few situations, a whole lot of rambling, and then some things to try (including new speech engines!)  ;)


"VoiceAttack does not listen to what I am saying at all"

EDIT - Before you go digging through all this, please try something out first. Go into Options>Speech Recognition and try checking the box labeled, 'Disable Acoustic Echo Cancellation'. Restart VoiceAttack if necessary. I'm finding that it's quite common for other software to interfere with this configuration of the speech engine. If that does not fix your issue, please read on ;)

When working properly, VoiceAttack will display a moving bar at the bottom of its main screen when you talk into your microphone.  In your case, that bar does not display anything no matter how loud you yell.  There are a few pieces involved in getting speech into VoiceAttack.  It usually looks like this (from a high level): Microphone -> Cable -> Sound Card/USB port -> Audio Driver -> Windows Audio -> Speech Engine -> VoiceAttack.  Anything in that route that is out of sorts can make things not work right or not at all.  You've probably got oodles of years of computer experience and the PC you built yourself was wrought with many hours of toil and painstakingly fawned-over details, but, sometimes we fiddle with hardware or settings we either didn't know we changed or have forgotten about.  Also, other software will make changes to your system and you won't even know it happened (bleh).  In addition, this is could possibly be the first time you've messed with or even considered speech recognition on Windows, so it's easy for the settings regarding speech recognition to go unnoticed.  I've compiled a checklist below for you to look over, and hopefully figure out how to get your system back in shape.  Good luck, captain!

1) The basics, as indicated mostly in the VA help document (It's kind of the bleeding obvious, but it's got to be here… my apologies for wasting your time!):

- Make sure your mic is plugged in (all the way) and any volume or power controls on the mic are turned on and up (I also need to indicate here that the mic should be in working order and does not have a short in it or in its cable o_O).
   
- Make sure the volume of your microphone is adequate and that it is not muted in Windows.
  Additional places to look regarding volume:
  Go into Control Panel & run the 'Sound' app.
  Select the recording tab.  Select your input device (it will have a green checkmark next to it). 
  Go to the levels tab.  Make sure the volume is adequate (mine is up all the way).  If there is a balance button,
  click it.  Make sure that the microphone channels are at adequate levels (mine are both up all the way).

- Confirm that the box labeled, 'Disable Speech Recognition' is NOT checked on the Options>System/Advanced tab.

2) If the basics did not help, you'll want to check out this other thread on this forum regarding to setting up audio input, as it's helped a LOT (this should probably be #1): http://voiceattack.com/SMF/index.php?topic=63.0

3) Recently (relatively), it's been found that certain third-party software may find itself getting between your sound card and the speech engine.  The idea behind this software is to, 'enhance' the recorded audio, but what the software creators have failed to do is make sure that their software doesn't trash your speech recognition experience on your Windows installation.  The main culprits (as of late) are SonicStudio by Asus and Nahimic by MSI.  These will come pre-installed on higher-end computers made by these manufacturers, as well as be part of a motherboard and/or sound card software installation.  If you have one of these apps running, and your mic level is not moving, there's a high probability that the software is getting in the way.  You'll want to refer to the documentation provided by the manufacturer on how to configure or close these apps.  This happens quite a bit, unfortunately.  It's very frustrating to pin down, as most users do not even know this is running, and it only blocks the speech engine in very specific configurations.  VoiceAttack makes an attempt at startup to alert the user that it has detected this software running by adding an entry to the log (just FYI).  One thing that works in some cases that you can try is going to the Options>Recognition tab and then try checking the box labeled, 'Disable Acoustic Echo Cancellation'.  This may get you up and running, but I'd still take a look at the settings of the third-party software just to see what's going on (noise gates and other, 'enhancements' may still be affecting input into the speech engine).


Less probability, still worth checking if what's above didn’t help:

4)  It could very well be that your speech profile is totally borked.  You'll want to look at this thread to see how to get another speech profile set up (ignore the title):  http://voiceattack.com/SMF/index.php?topic=64.0

5) One thing I always suggest is running a system file scan (which is something that you should do from time to time anyway):  https://support.microsoft.com/en-us/help/929833/use-the-system-file-checker-tool-to-repair-missing-or-corrupted-system

6) Reinstalling VoiceAttack *may* be an option.   It could be something just as simple as reinstalling to fix a messed up installation.  Kind of rare, but it's possible.  Your profiles and registration/settings will remain intact, so have no fear.


"VoiceAttack is listening, but what it hears is complete gibberish compared to what I said"

The bar at the bottom of the main screen is moving, but things are just not working.  Commands are not executing, and you are getting a constant, 'Unrecognized - blah blah blah' .  There are a number of things that can be going on, so the intent here is to try to help you come up with a better understanding of what may be happening, and hopefully improve your VoiceAttack experience.   

1) First, and foremost, if you are using a built-in speech engine (that is, the speech engine that came with Windows and not a speech engine you explicitly installed (more on that later)), I cannot emphasize more about the importance of training your speech engine.  In fact, running through the training two or three times will help the speech engine learn a bit better.  The difference between a trained speech engine and an untrained, trainable speech engine is like night and day.  There's lots of documentation here there and everywhere about that (including the help document), so, I won't go into that here.   Just know that if you've just now installed VoiceAttack for the first time and are wondering why there is almost no accuracy, this is the place to start.

2) Make sure that if you are trying out spoken phrases WITHOUT any commands in your profile, the speech engine is left rather, 'dumb'.  So, if you turn on VoiceAttack for the very first time and say something like, 'My name is Michael' and VoiceAttack responds with, 'Unrecognized - 'pie frame in my quill', it's doing EXACTLY what it's designed to do - ignore and play dumb on things that it's not explicitly told to focus on.  So, if you add a command to your profile with the spoken phrase of, 'my name is michael', VoiceAttack *should* (given everything is set up right) recognize that as a spoken phrase and execute the command.

3) How is your speaking style?  Are you speaking clearly?  Are you using the right language/speech engine?  My German teacher in high school said in class that my German accent was so good that I could pull off being a German citizen (many years ago o_O).  However, I think that if I used a German speech engine I would still expect the results to be poor.  I know a lot of folks want to use a speech engine in different languages other than their native language (for immersion or other reasons) and truly believe that they have a firm and fluent grasp of the language they are trying to speak.  However, the bottom line is that if humans are asking you to repeat what you are saying, a speech engine is going to do so much, much more ;)  Long story longer, you'll want to stick to your native language if you can for best results.  Now, that said, if VoiceAttack is still not understanding you and you ARE using a speech engine that matches your native language, you are still not out of options.  There could be some things going on with your system that can be fixed or adjusted, or it could be that the you/your voice and the speech engine are just.not.going.to.jive (even so, there's still hope… unless you're Scottish lol (well, maybe)).  Other stuff to try:

- Make sure your mic volume is not too, 'hot' and distorting your speech.   Seems obvious, but is often overlooked.

- Make sure you do not have a third-party app that, 'enhances' your voice (Logitech's Screaming Bee software comes to mind… somehow the speech engine doesn't like it when you sound like a chipmunk lol).

- See the next section way below about line noise.  It's possible that you've got a bit of line noise going on (also see the part about trying out a different headset).

- Make sure you are not running with a webcam (or other mic) on that's up loud enough or is close enough that it makes you think you are using your headset's mic.  This happens quite a lot actually (I am guilty of this, too!).

- Make sure your mic is not too close to your mouth.  Breathing, 'lip pops', etc. can cause problems.

- Check to make sure your audio drivers are up to date.  This is sometimes an issue.
   
- Are you using the right profile?  Sometimes those get switched and you didn't know it happened.

- It could be that your speech profile is just borked up, even if it's a new installation of Windows (ignore the title… or don't): http://voiceattack.com/SMF/index.php?topic=64.0

- Webcams, desktop mics, clip-on mics and integrated mics (the ones built into laptops, for example), may work to some degree with VoiceAttack, but you will find that a quality, *USB* headset (preferably with some type of noise cancellation built in) will produce the best results by far.  Just throwing that out there ;) 


You've made it all the way down here without success, and you are thinking,
"But, Google/Cortana understands me perfectly"

 I understand Cortana and Google's speech recognition work great (especially for context-sensitive dictation), but those are entirely different stacks that are designed to work in rough conditions and would be GREAT to incorporate into VA, but, since they are server-based, the recognition lag/latency is inconsistent and much too often way too lengthy.  That makes it relatively unreliable for this type of application.  Plus, Google's offering is not free, unfortunately :( 

---Which leads to the next solution (and possibly your best bet): 

ALTERNATIVE SPEECH ENGINES FOR VOICEATTACK.  VoiceAttack can load up and use Speech Platform 11 speech engines in a variety of different languages AND… they don't even need to be trained.  There are some small drawbacks to using these engines, but it might just end up being even better for you than the built-in speech engine (just ask iceblast.  Hi, iceblast!).  Trying out the different variations of each language may be helpful, too.  The files are pretty small, so, it's easy to give it a go.

Here is a link to get you started:  http://www.voiceattack.com/alternate

*** I bet you're wondering why I didn't just get this out in the first place and skip all the blah blah blah blah.  The reason is that I would save switching to another speech engine as kind of a last resort, especially if you have a built-in speech engine that is already in your native language.  A speech engine trained to your voice, when everything is right, is really hard to beat, and worth the effort to get it going.


"I'm not saying anything but VoiceAttack keeps hearing things"

The bar is moving.  Sometimes a lot.  Sometimes commands are just executed out of the blue - 'Recognized - Fire Weapons' or are showing up in my log as unrecognized - 'Unrecognized  - Get Out'.  Normally, if you are using a headset and your mic volume is set right, the bar at the bottom of VA's main screen shouldn't even show up at all if you are not saying anything.  If this is the case, it's always some form of noise that is affecting the speech engine.  That could be ambient noise or (more likely) line noise.

Ambient noise is usually easy to correct.  Just put the kids to bed and/or turn off the tv/fan/popcorn popper/vacuum/etc.  Sometimes it's smaller, unnoticeable things, such as the mic being too close to your mouth.  Using a desktop mic (or, really any mic other than a headset) will be great at picking up just about every single sound in the surrounding counties, so I usually try to dissuade folks from using them if you are in a potentially noisy place.  If your mic level is too high, this will affect how much is picked up as well.  It's always good to play around with the volume to get it just right (watch out for any of the mic boosting settings… make sure it's not making your audio too, 'hot' and really amplifying your environment).

If your environment is really nice and quiet (hopefully), you've got line noise.  Line noise is a little trickier and more subtle, but I get far more messages about line noise than ambient noise.  As with any electronic equipment, there's a good chance you'll experience some level of line noise while using it.  I know that talking to friends on Discord/Teamspeak/Skype/etc or the recording of your voice all seem clear, however, you’ve got something going on in your audio channel that the speech engine is interpreting as human speech.  VoiceAttack’s voice commands (‘when I say’ commands) are executed solely by events triggered by the speech engine.  That is, VoiceAttack ONLY reacts to these events and never just spuriously starts, 'hearing stuff' and/or executing macros.  There is most likely line noise generated by the environment (other electronic devices, including your monitor, cell phone, cordless phone, microwave) or by the hardware you are using (mic, cable, sound card, motherboard, other installed cards, etc.). 

A lot of times, just trying (borrowing) another headset has solved this issue (even if the headset you have is new, and especially if you plug your headset into a sound card (non-USB)).  For this type of test, I whole-heartedly recommend a USB headset plugged straight into the pc (that is, no hub, no extension cable, not through your monitor's USB connection, etc.).  Of course, make sure your audio input is set right if you do try out another headset:  http://voiceattack.com/SMF/index.php?topic=63.0

There's also other stuff to try:

- Again with the third-party apps… as stated above, they are there to, 'enhance' your audio.  There's a good possibility that yours is borking things up.  Try disabling it/them to see if it helps.

- You may want to look at updating your audio drivers (rare, but has been known to cause problems).

- If your mic is too, 'hot', things will not work as expected (I know I keep repeating this, but it's definitely a culprit for all kinds of things).

- If you just can't get rid of your line noise, you can always set your confidence levels higher and/or your command weight lower in (Options > Recognition) to try counter the spurious command executions.  It's a band-aid for sure, but it could help some.  See the help documentation for more info on minimum confidence levels and command weight.

- Another possibility is that it's some type of paranormal activity.  Especially if it's saying, 'GET OUT'.  Might want to call in the Ghostbusters (or move… lol)  ;)



I hope some of this helps a bit.  Sorry so wordy, but I get messages regarding these types of issues rather frequently so I know that extra help is definitely needed.  Also, the hope is you now have a better understanding of some of the things that can go wrong and know what to look for while you are using VoiceAttack.

« Last Edit: March 10, 2018, 12:21:02 am by Gary »