TRULY Custom Commands with Parameters / Variables.

Started by matt3003, Jun 03, 2016, 11:30 AM

Previous topic - Next topic

matt3003

Hi.

I'm still experimenting with your fantastic program, and one thing I would love to be able to do is create custom commands with parameters.

For example : "Research X", and braina for example opens the url "https://www.google.com/#q=X"


I know it could be seen as difficult, because of the parsing of the query (What if someone says "Research X on Google", or "Research X please", then it would open google and launch a search for "X on Google" and "X please" respectively.

But for the usage I have in mind it's not a problem : I want to be able to send parameters to programs I am developing, so the parsing / understanding of the parameters would be my problem.

I want to be able to say "Myprogram bla bla bla bla" and Braina would open my program with the parameters "bla bla bla bla" (or open a web page with the parameters bla bla bla bla - I can use a local or remote web server and php to communicate with my program if there are no other ways - braina would open the url "http:\\my_server_url\do_something?parameters=bla bla bla" and I would take it from there.

So can it be done ? (a custom commands that send everything said after the custom command "trigger word(s)" as parameters ? (to a .exe on the computer using the execute cmd or via a url)

Thank you again and thank you also for answering so fast to my other posts - it's nice to see that this forum is active and that you listen to your community regarding features ideas etc..

saurav

#1
@matt3003 Such customization will be surely available in Braina's upcoming updates.

Update: The feature is now available: https://blog.brainasoft.com/braina-1-70-advanced-strong-ai-engine/

jrsofsd

Hi

I have a feature request, one that would allow truly Custom Commands:

Please pass any speech following the custom command itself to a batch script or program.

Example

A custom command using a batch script looks like this:
 
cmd:MyScript.cmd



and could be invoked with the voice command "my script".
I'm suggesting passing any speech-to-text after "my script" to the MyScript.cmd batch script.

MyScript.cmd would access the additional parameters in the standard way via "%*":
   
@Echo On
    Echo %*
   

This batch script merely echoes the additional parameters, spoken by the user.

Similarly, passing the speech-to-text to a program would work the same way. This would make Custom Commands truly custom!

saurav

Please update to the latest version of Braina. Braina version 1.70 has this feature: https://blog.brainasoft.com/braina-1-70-advanced-strong-ai-engine/

kepinu

1. On the 1.70 release where custom commands with params was announced it said there would be a more in depth blog post. Did I miss that or is it still to come?
2. does the variable/param only support 1 word per variable?

saurav

#5
Hello Kepinu,

The blog post is currently in draft but will be published soon. The variable supports multiple words.