Skip to content
English
  • There are no suggestions because the search field is empty.

🎥 How use Variables in SmartChat

This video covers how to set up and use variables in an activity. It introduces the four variable types: Units variables (counters, shown with a pound symbol), Aggregate variables (calculated from other variables using math expressions, shown with a pencil), String variables (text values that can be inserted into prose or displayed on-screen, shown with an "A"), and String Expression variables (combine multiple string variables into one, shown with a wrench). It also shows two ways to change variable values — through learner responses in a question node, or automatically via a score node using Change or Overwrite.

Finally, it demonstrates how conditional nodes use variables to branch a story. A conditional node is added by clicking the "if" button before or after a node, and it evaluates a boolean expression made up of three parts: a first value (chosen from a dropdown of Objectives and Variables, e.g., Revenue), a comparison operator (e.g., greater than), and a second value (a number or another token, such as a table cell). The expression resolves to True or False, and the node automatically creates a new branch for each outcome. In the example shown, the condition checks whether Revenue is greater than $1000 — if true, the story goes one way, and if false (revenue at or below $1000), it goes the other way.