Set Boolean Slot from an Intent

In my form, I will be asking a yes (affirm) or no (deny) question. I want to store this value in a slot, as it’s naturally yes/no, or true/false.

In short, in my form (lets call it form1), if I see the intent affirm, I want to set the value of a boolean slot to true, else, if intent deny, set the value for that same slot to false.

Let’s assume I have a single slot form. The core of my question is that I don’t quite understand how to leverage the fact that rasa init gives us affirm/deny, and given the model does well to predict this intent, it seems as if we should easily set a slot value based on this predicted intent in a given pattern/story/form.

The use-case is that I want to capture a value to a slot (true/false) in one form, and then use a rule to determine which form to activate based on the data captured (T/F/?)

@Btibert3 ,

Does this example help? It shows a slot that is set by a Form, using the affirm and deny intents.

Yes! I was thinking too small; I didn’t even imagine we could list multiple.

I appreciate it!

Actually, to follow up up on this, I ran this through rasa interactive and it’s not behaving the way I would have expected.

forms:
  form_covid_start:
    to_campus:
    - intent: affirm
      type: from_intent
      value: true
    - intent: deny
      type: from_intent
      value: false

Slots:

slots:
  to_campus:
    type: bool
    influence_conversation: true

Everything works when I run it through interactive short of the slot value assignment.

I know it’s hard to debug remotely, but is there something that I might be missing across the configuration files? Simply, a general pattern that I may not have accounted for?

And for S&G’s, I threw the bot into a GH repo and spun up a Rasa X server. After training in Rasa X (it didn’t recognize the lone model file /models), I saw this:

This behaved exactly the way I would have expected, so this leads me to question the rasa interactive CLI?