refactored code. broke up files with multiple classes into separate files and fixed cyclic imports
added template for cost values.