Orca score function refactoring