Moved models to lib directory