Moved entities to models