Added core functionality to models.