Add model validation.