Add json option to haiku.py