Add index attribute to entities. #78