Version: 4.3.x
...
Info | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||
The returned URI is a reference for this specific resource. This recourse will be referenced in the bot definition.
|
2. Anchor
...
behaviorSet
behaviorSet |
...
behaviorSet
Creating Behavior Rules
behaviorSet |
See also Behavior Rules
Next, create a behavior rule resource to configure the decision making
a. Make a POST to /behaviorstore/behaviorsets
With an json in the body like this:
Code Block | ||||||||
---|---|---|---|---|---|---|---|---|
| ||||||||
{ "behaviorGroups": [ { "name": "Smalltalk", "behaviorRules": [ { "name": "Welcome", "actions": [ "welcome" ], "children": [ { "type": "negation", "children": [ { "type": "occurrence", "values": { "maxTimesOccurred": 10, "behaviorRuleName": "Welcome" } } ] } ] }, { "name": "Greeting", "actions": [ "greet" ], "children": [ { "type": "inputmatcher", "values": { "expressions": "greeting(*)", "occurrence": "currentStep" } } ] }, { "name": "Goodbye", "actions": [ "say_goodbye", "CONVERSATION_END" ], "children": [ { "type": "inputmatcher", "values": { "expressions": "goodbye(*)" } } ] }, { "name": "Thank", "actions": [ "thank" ], "children": [ { "type": "inputmatcher", "values": { "expressions": "thank(*)" } } ] }, { "name": "how are you", "actions": [ "how_are_you" ], "children": [ { "type": "inputmatcher", "values": { "expressions": "how_are_you" } } ] } ] } ] } |
...
b. You should again get a return code of 201 with an URI in the location header referencing the newly created package
format eddi://ai.labs.package/packagestore/packages/<UNIQUE_PACKAGE_ID>?version=<PACKAGE_VERSION>
e.g. eddi://ai.labs.package/packagestore/packages/5a2ae60f17312624f8b8a445?version=1
5. Creating a Bot
Make a POST to /botstore/bots
...
b. You should again get a return code of 201 with an URI in the location header referencing the newly created bot
format eddi://ai.labs.bot/botstore/bots/<UNIQUE_BOT_ID>?version=<BOT_VERSION>
e.g. eddi://ai.labs.bot/botstore/bots/5a2ae68a17312624f8b8a446?version=1
6. Launching the Bot
Finally, we are ready to let the bot fly. From here on, you have the possibility to let an UI do it for you or you do it step by step.
...