cleaned up models and improved controllers