Working spliced processed output. Need json.dumps with |safe .