AutoVoice Easily manage replacements for an AutoVoice profile

Discussion in 'Guides / Examples / Ideas Forum' started by joaomgcd, Feb 18, 2015.

  1. joaomgcd

    joaomgcd Administrator Staff Member

    Joined:
    Feb 3, 2015
    Messages:
    9,479
    Likes Received:
    806
    If you create a profile in Tasker with an "AutoVoice Recognized" event condition, you can setup replacements under advanced. For example, if you want to react to the command "look at the sun" by AutoVoice keeps recognizing "look at the son", you can set a replacement like "son=sun" and AutoVoice will replace "son" with "sun", thus making your profile work.

    You can also have multiple replacements like "1=one,2=two,3=three" etc. It can get quite hard to manage these if you have lots of replacements, so here's a tip to make managing them easier:
    • create a task called "Setup replacements"
    • in the task add an "Array Clear" action on a variable called %REPLACEMENTS
    • add an "Array Push" action to the %REPLACEMENTS and add your first replacement
    • Add "Array Push" actions for all the replacements you want to have
    • In the AutoVoice condition use %REPLACEMENTS() in the replacements field

    This makes adding or removing an item to replace as easy as adding or removing an action in the "Setup replacements" task. :)
     
    amplatfus and L.Drake like this.
  2. L.Drake

    L.Drake Member

    Joined:
    Feb 12, 2015
    Messages:
    61
    Likes Received:
    1
    Works like a Charme :)
     

Share This Page