moved model stuff to model directory