add app autoloader and minor clean ups