moved models to library (common) so they can be tested and used by the client