All are concatenated and copied verbatim into the head of the output. Nonterminals are declared by their presence on the left side of rules.
Rules define tree patterns in a fully parenthesized prefix form.
Every nonterminal denotes a tree. Each operator has a fixed arity, which is inferred from the rules in which it is used. A chain rule is a rule whose pattern is another nonterminal. If no start symbol is declared, the nonterminal defined by the first rule is used. Costs of chain rules must be constants.