Manual:Verbot Editor Creating Your First Rule

From VerbotWiki

Creating Rules in VerbotŪ 4.0 is quick and easy.

Rules hold the knowledge of your VerbotŪ. A Rule is made up of Inputs and Outputs. An Input is used to match to what the user types. Once an Input finds a match the Output (or Response) is presented to the user.

To create a Rule you must first give it a name. Start by typing in the Rule Name input box. We'll use"Hello World" for this example.

Image:Ve_tut_firstrule1.png

Once you've typed "Hello World," click the "New Rule" button or simply press "Enter" to create a Primary Rule. Your screen should look like the following:

Image:Ve_tut_firstrule2.png

Adding an Input to your Rule

Now that you've created a Rule. You'll need to add an input or two to make it available for your VerbotŪ to use. An Input can be made up of single or multiple words. For the purposes of this example, we simply want the VerbotŪ to respond to a user typing in "Hello" or "Hi".

To create an Input click the "Add" button within the "Inputs Group".

Image:Ve_tut_firstrule3.png

You'll notice that "Hello World" appears in the pop-up window and is highlighted. As a convenience, the Editor assumes your Rule name will be your first input. However for this example we want the Rule to fire on the input of "Hello" or "Hi". Change the text from "Hello World" to "Hello". And click "Ok" or press the "Enter" key.

Image:Ve_tut_firstrule4.png

Now that you've added "Hello," you may want to also add the Input "Hi". To add another Input, click the "Add" button within the "Inputs Group" and repeat the process as you did with "Hello". You can add as many inputs as desired. Now that you've finished adding your inputs, it's time to create an Output (also known as a Response).

To create an Output click the "Add" button within the "Outputs Group". A pop-up box appears with two fields. The top field is used to hold the VerbotŪ Output. The lower field is used to hold extra commands (i.e. a command to run a program).

Image:Ve_tut_firstrule5.png

Enter "Hello World" within the top field and click the "Ok" button or press the "Enter" key. The Output has been added. You've now created your first Rule.

Image:Ve_tut_firstrule6.png

At this point it's a good idea to save your KnowledgeBase. Click "File" --> "Save" on the menu.

After you've saved your KnowledgeBase you can test your Rule two different ways. You can:

1. Load the Verbot Player then load your KnowledgeBase or 2. Use "Test KnowledgeBase" from the "Tools" menu.