add basic validation for models