Author Topic: More control in handling alternates  (Read 2076 times)

0 Members and 2 Guests are viewing this topic.

Telorast

  • $upporter
  • Jr. Member
  • *****
  • Posts: 28
  • Karma: 0
    • View Profile
More control in handling alternates
« on: March 31, 2014, 06:06:55 PM »
In the options you have some options for alternative interpretations. One of them is "Don't execute if there are alternate commands". I think it would be a lot more useful if you could set a limit for how many alternates there can be before preventing execution. Often correct guesses can have a few alternatives but rarely 5 or 6, at least in my configuration. At the same time there are sometimes false positives with high confidence despite 8 alternates...

Kalle

  • $upporter
  • Hero Member
  • *****
  • Posts: 2320
  • Karma: 47
    • View Profile
Re: More control in handling alternates
« Reply #1 on: March 31, 2014, 06:21:36 PM »
Hi Telorast, maybe this command will help you.

http://voxcommando.com/forum/index.php?topic=1225.msg10418#msg10418

You can modify it if don't like that VC read the alternates aloud.
***********  get excited and make things  **********

Telorast

  • $upporter
  • Jr. Member
  • *****
  • Posts: 28
  • Karma: 0
    • View Profile
Re: More control in handling alternates
« Reply #2 on: April 01, 2014, 08:33:21 PM »
Ok so how do I execute a command I know the name of?

I assume you want me to use the Don't execute if there are alternates and generate an alternate event and execute the commands in there instead?

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7714
  • Karma: 116
    • View Profile
    • VoxCommando
Re: More control in handling alternates
« Reply #3 on: April 01, 2014, 11:41:45 PM »
You can't execute a command by name.

I'm not opposed to adding this option in a future release although I'm not convinced it will be that useful to most users.  I thought I had responded to your request but my response seems to have gone missing.  Maybe I replied to an email instead of posting...

Anyway this might work for you for now.  Based on Kalle's suggestion.

In options:
- set vc to not execute if there are alternates
- set vc to generate alternates events

Add this command to your tree.  It will be triggered if there are 2 or 3 alternates, and will then select the most likely (option 1)
Code: [Select]
<?xml version="1.0" encoding="utf-16"?>
<!--VoxCommando 1.9.1.9-->
<command id="169" name="do option 1 if less than 4 alternates" enabled="true" alwaysOn="False" confirm="False" requiredConfidence="0" loop="False" loopDelay="0" loopMax="0" description="">
  <action>
    <cmdType>VC.TellVox</cmdType>
    <params>
      <param>option 1</param>
    </params>
    <cmdRepeat>1</cmdRepeat>
  </action>
  <event>VC.Alternates.2</event>
  <event>VC.Alternates.3</event>
</command>

Telorast

  • $upporter
  • Jr. Member
  • *****
  • Posts: 28
  • Karma: 0
    • View Profile
Re: More control in handling alternates
« Reply #4 on: April 02, 2014, 12:56:56 PM »
That seems to work well. Now I just have to figure out if it's worth using and how many alternates to break at.

jitterjames

  • Administrator
  • Hero Member
  • *****
  • Posts: 7714
  • Karma: 116
    • View Profile
    • VoxCommando
Re: More control in handling alternates
« Reply #5 on: April 02, 2014, 01:04:56 PM »
In my experience, the number of alternates has more to do with your command structure and which command you are using than it does with the accuracy or quality of the recognition.  If you say "play artist john" you will often get 8 alternates (depending on your library) and most of them will be equally correct because of subset matching.  If you use dictation you are also likely to get 8 alternates most of the time.  Does that mean that you should not execute the most likely one?  It is really up to you.  Unfortunately the relative confidence values seem to be somewhat arbitrary and part of the "black box" that is the MS speech api.