Refactor entity from reify to deftype