Automated framework for calculating NDCG