created Evaluator class and moved functions into it