add new format for writing json from models