Skip to Content

fallback "skill_occurences" count is not increasing

Hi
I have a scenario when i have to count the skill_occurrence for the fallback skill,

even after triggering for lot of times, it is showing "skill_occurences": 1,

does the skill_occurences count will increase for Fallback?

please let me know
Thanks

Kishore

fallback.jpg (32.5 kB)
Add a comment
10|10000 characters needed characters exceeded

  • Hi Daniel,

    Thanks a lot for your reply,

    Yes, I am kind of doing the same thing but with out using the "if else" helper, in the memory section of fallback skill, I created a variable fallbackCount

    First I am checking the condition of my fallback action that fallbackCount exits and on every time the skill is triggered I am checking the condition fallbackCount < 4 and when the skill is triggered I am assigning fallbackCount = "{{plus memory.fallbackCount 1}}" and if the count is more than 3 I am doing something else.

    Thanks

    Kishore

Assigned Tags

Related questions

4 Answers

  • Best Answer
    Posted on Jul 30, 2020 at 01:31 PM

    Hi Shiva,

    I think this use case is not possible with how the skill occurrence counter works. From what I understand from your bot the flow seems to be like this

    User sends text
    Fallback skill is triggered -> skill occurrence counter set to 1
    Goto continuechat is executed -> skill occurrence counter is reset and starts with 1
    Reply to the user

    User sends the next text
    Fallback skill is triggered -> as the last executed skill beforehand was continuechat the skill occurrence counter is reset and starts again at 1
    and so on.

    However, to achieve your goal you could instead use the scripting syntax which is documented over here https://help.sap.com/viewer/a4522a393d2b4643812b7caadfe90c18/latest/en-US/b4f08a9a66434327a405b6934880445c.html and try to create a memory variable and adding 1 on each occasion you enter the fallback skill.

    Hint: remember to initialize the counter memory attribute with 0 upfront.

    Hope this helps.

    Best,

    Stephan

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Jul 30, 2020 at 09:11 AM

    It works for me.

    Are you triggering another skill, and therefore resetting this value?

    How are you checking its value?


    skill.png (20.8 kB)
    Add a comment
    10|10000 characters needed characters exceeded

    • Hi Daniel Wroblewski
      If the fallback is independent the count is increasing
      but i have a scenario where i am redirecting to continuechat and starting theskill and that skill is connected all the other skills in my bot, The fall back skill is connected only to the continuechat skill, and I want to set a limit to the fallback such that is the fallback skill_occurences is less than 5 I want to redirect to continuechat skill, if 5 or more i want to do some thing else, But the skill_occurences count is not increasing.

      Do i need to remove the link in order to work is the fall back should be independent or any restrictions on it?

      Please let me know
      Thanks
      Kishore

      connections.jpg (18.7 kB)
  • Posted on Jul 30, 2020 at 09:34 AM

    Hi Shiva,

    could you provide some more information on your conversation flow with regards to the skills that are triggered and executed after each user input?

    Generally, the skill occurrence counter is increased each time when the exact same skill is consecutively executed. If another skill is executed in between, the counter is reset to one.

    Best regards,
    Stephan

    Add a comment
    10|10000 characters needed characters exceeded

    • Hi Stephan Bender

      on fallback i am redirecting to continuechat and starting the skill and that skill is connected all the other skills in my bot
      The fall back skill is connected only to the continuechat skill, and I want to set a limit to the fallback such that is the fallback skill_occurences is less than 5 I want to redirect to continuechat skill, if 5 or more i want to do some thing else, But the skill_occurences count is not increasing.
      Do i need to remove the link in order to work is the fall back should be independent or any restrictions on it?

      Please let me know
      Thanks
      Kishore

      connections.jpg (18.7 kB)
  • Posted on Aug 02, 2020 at 07:36 AM

    Why not have your own memory variable to manage what you want to count. Set it to 0, and then add 1 each time the skill is triggered.

    You can decide to have "skill1" a memory variable and then when the skill is triggered set the memory with this:

    "{{#if memory.skill1}}{{add memory.skill1 1}}{{else}}1{{/if}}"   
    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.