This site is no longer updated.Go to new Conversational Cloud docs

intent


The intent trigger tag declares an intent by which the dialog can enter a state.

This is a local tag: transitions by this tag can be made only from the nearest parent, sibling, or children states.

Value

A path to the intent is specified after the tag. Within the path, / is a separator between nesting levels:

  • /hi — the path consists of the / character and the intent name.
  • /hi/politely — a nested intent. There is no upper limit to the nesting depth.

Parameters

Parameter Type Description Default value
fromState String A path to a state from which a transition to the current state by this intent tag can be made.
toState String A path to a state to which a transition from the current state by this intent tag can be made.
onlyThisState Boolean • If true and the fromState parameter is present, a transition to the current state can be made strictly from the state specified in fromState, but not from its nested states.
• If true and the toState parameter is present, a transition to the state specified in toState can be made strictly from the current state, but not from its nested states.
false

How to use

state: Symptoms
    a: Have you recently found yourself with a fever, a dry cough, or a rapid tiredness?

    state: Positive
        intent: /Sick
        a: Then do not put yourself in danger! Seek medical attention immediately!

    state: Negative
        intent: /Healthy
        a: Good to hear everything is fine! Still, do not forget to wash your hands and wear face masks.

state: Callback
    intent: /Callback || fromState = "/Symptoms", onlyThisState = true
    a: Okay, I’ll call you back later!