'json-html', emit a simplified JSON representation of the data, suitable for notably SWISH. This deals with Prolog answers and output messages. If a message originates from print_message/3, it gets several additional properties:
json-htmlformat. This format represents the answer as JSON, but the variable bindings are (structured) HTML strings rather than JSON objects.
CHR residual goals are not bound to the projection variables. We hacked a bypass to fetch these by returning them in a variable named Residuals, which must be bound to a term '$residuals'(List). Such a variable is removed from the projection and added to residual goals.