Hook console interaction. Currently only used for <-/1 to emit
the captured output. In this cases, Stream is stdout and Term
is a list of strings, each representing a line of output. The
list can be empty. If the hook fails, maplist(writeln, Term) is
called to write the output to current_output.