Do
The Do action dynamically executes another skill or action by name. This is useful when the skill to execute is determined at runtime, such as dispatching to different handlers based on a variable.
Do(
actionName: str,
(any arguments)
)
Where:
- actionName: The name of the skill or action to execute.
- (any arguments): Any additional keyword arguments are passed through to the target skill.
Example
{{set(name="handler", value="greet_user")}}
{{Do(actionName=handler, message="Hello!")}}The above code snippet dynamically calls the skill named greet_user, passing message="Hello!" as an argument. The actionName can be a variable, allowing skills to be selected at runtime based on logic or user input.
Updated 4 days ago
