Aktualizacja Diamond i zbudujemy wam własną aplikację dla systemu Android lub iOS
Self, AIML, and scripting

sample of using the new response cretion

w passionguru wysłany Nov 24 2016, 4:46


I want to see the sample of the "previous", "condition", "keywords" etc

A quick help is highly appreciated.


by admin posted Nov 24 2016, 9:27
There is a good example script of previous and keywords here,


This is a "response list" file that you can import from your bot's "Training & Chat Logs" page.
You can also create the same responses directly from the "Training & Chat Logs" page by clicking "Add new response", and clicking the "show" checkboxes for keywords and previous.

Conditions are a little more complicated as they involve code. Normally you would use a "condition" with a "think". A condition is a block of Self code that will evaluate to true or false, and the response is only used if it evaluates to true.

For example, consider this "response list",

greeting: Are you a new or existing client?

Welcome to our service.
require previous: Are you a new or existing client?
think: speaker.status = "new";

Welcome back.
require previous: Are you a new or existing client?
think: speaker.status = "existing";

How can I help?
condition: speaker.status == "existing"

Sorry, you need to register first.
condition: speaker.status == "new"

Updated: Nov 24 2016, 10:23
Thumbs up: 0, thumbs down: 0, stars: 0.0
Views: 2505, today: 1, week: 3, month: 14

Identyfikator: 14747086
Wysłany: Nov 24 2016, 4:46
Aktualizacja: Nov 24 2016, 9:18
Odpowiedzi: 1
Widok: 2219, dziś: 1, tydzień: 2, miesiąc: 12
0 0 0.0/5