Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: fix logical mistake in welcome behavior rule
Version: 4.3.x

...

Info
titleStructure of Identifiers

The returned URI is a reference for this specific resource. This recourse will be referenced in the bot definition.

Part of URIMeaning
eddi://This URI is related to a resource with in EDDI
ai.labs.regulardictionaryType of resource
/regulardictionarystore/regulardictionariesAPI path
<UNIQUE_DICTIONARY_ID>ID of the resources
<DICTIONARY_VERSION>

Version of this resource
(each update operation will create a new version of the resource)


2.
Anchor

...

behaviorSet

...

behaviorSet
Creating Behavior Rules

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
languagejs
titleBehavior Rules
linenumberstrue
collapsetrue
{
  "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.

...