updated model to deal with new json format