Given the learned neural units, decoding for the “best” program is an intractable problem, hence we use beam search [1]}.
Because beam search is only applicable for sequences, we modify it to perform a depth-first traversal on the AST, with the non-terminal nodes that lead to branching in the AST stored in a separate stack.
