add basic validation to models