refactored scoring controller