organize code / change model constructor