demo finalized & outputs in JSON