I1: completed refactuing up until Ranking and Sorting