refactor models a bit