Revert "Moved the scoring function"

This reverts commit af3df2c1edc5da9589bdeb8383c93a1206664be0.