Refactor Entity Structure