refactoring models.