Lets start off with a simple example:
@greeting intent(learn: @sentences.greeting) dialog main do say "To the optimist, the glass is half-full." type 3 say "To the pessimist, the glass is half-empty." type 2 say "To the engineer, the glass is twice as big as it needs to be." pause 10 ask "Did you laugh?", expecting: ["Yes", "No"] if answer == "Yes" do say "You must be an engineer!" else say "You're not an engineer are you?" end end
Hopefully you already get the gist of what this bot will do. Don’t worry if you don’t. In the following paragraphs the language used will be explained in more detail.