nemoguardrails.colang.v2_x.lang.colang_ast
nemoguardrails.colang.v2_x.lang.colang_ast
The data types that are used when constructing the Abstract Syntax Tree after parsing.
Module Contents
Classes
Functions
Data
API
Bases: Element
Defines the start of a new scope in a flow to keep track of all started actions/flows.
Bases: Element
Set the pattern failure catcher to catch a failing pattern and forward it to the specified label. If the label is not set the failure will be propagated to the parent flow.
Bases: Element
The definition for a flow decorator.
Explicit typing is not yet supported.
Base class for all elements in the AST.
Getter for backward compatibility with dict elements.
TODO: to remove at some point.
Return the hash for the current object.
Bases: Element
Defines the end of a scope in a flow that will stop all active actions/flows that have been started within that scope.
Bases: Element
Element that represents a flow.
The definition for a flow parameter.
Explicit typing is not yet supported.
The definition for a flow return member.
Explicit typing is not yet supported.
Bases: Element
Element to fork the current head into multiple heads.
For each label a new head.
Bases: Element
Element for navigating to a label.
If the expression is not True, just skips to the next element.
Bases: Element
The definition for an import statement.
We support both “path mode” and “package” mode.
import core import rag.advanced import “some-spec/some-sub-package”
Bases: Element
Merge heads based on uid from same flow.
Only one head will advance from this element.
Bases: Element
Set the priority of the flow in terms of action resolution.
Information about the source of an element.
Bases: Element
Element that represents a spec.
A spec can represent a flow, an action or an event. Currently, we will determine at runtime what the spec is.
A spec is either specified directly through a name and arguments, or through a variable. In both cases, additional members can be accessed, e.g., .Finished().
Bases: Element
An operation performed on a spec.
Valid operations are: send, match, start, stop, await, activate, deactivate.
Bases: enum.Enum
All internal event types.
Bases: enum.Enum
The type of a spec.
Bases: Element
Wait for a number of heads.
Once enough heads have reached this element they will be merged and only one head will advance.
Make all subtypes of Element hashable.