major changes and new files, model base class implementation