add view model and generate json template