Learning to rank explained

Learning to rank[1] or machine-learned ranking (MLR) is the application of machine learning, typically supervised, semi-supervised or reinforcement learning, in the construction of ranking models for information retrieval systems.[2] Training data may, for example, consist of lists of items with some partial order specified between items in each list. This order is typically induced by giving a numerical or ordinal score or a binary judgment (e.g. "relevant" or "not relevant") for each item. The goal of constructing the ranking model is to rank new, unseen lists in a similar way to rankings in the training data.

Applications

In information retrieval

Ranking is a central part of many information retrieval problems, such as document retrieval, collaborative filtering, sentiment analysis, and online advertising.

A possible architecture of a machine-learned search engine is shown in the accompanying figure.

Training data consists of queries and documents matching them together with the relevance degree of each match. It may be prepared manually by human assessors (or raters, as Google calls them), who check results for some queries and determine relevance of each result. It is not feasible to check the relevance of all documents, and so typically a technique called pooling is used — only the top few documents, retrieved by some existing ranking models are checked. This technique may introduce selection bias. Alternatively, training data may be derived automatically by analyzing clickthrough logs (i.e. search results which got clicks from users), query chains, or such search engines' features as Google's (since-replaced) SearchWiki. Clickthrough logs can be biased by the tendency of users to click on the top search results on the assumption that they are already well-ranked.

Training data is used by a learning algorithm to produce a ranking model which computes the relevance of documents for actual queries.

Typically, users expect a search query to complete in a short time (such as a few hundred milliseconds for web search), which makes it impossible to evaluate a complex ranking model on each document in the corpus, and so a two-phase scheme is used. First, a small number of potentially relevant documents are identified using simpler retrieval models which permit fast query evaluation, such as the vector space model, Boolean model, weighted AND, or BM25. This phase is called top-

k

document retrieval and many heuristics were proposed in the literature to accelerate it, such as using a document's static quality score and tiered indexes.[3] In the second phase, a more accurate but computationally expensive machine-learned model is used to re-rank these documents.

In other areas

Learning to rank algorithms have been applied in areas other than information retrieval:

Feature vectors

For the convenience of MLR algorithms, query-document pairs are usually represented by numerical vectors, which are called feature vectors. Such an approach is sometimes called bag of features and is analogous to the bag of words model and vector space model used in information retrieval for representation of documents.

Components of such vectors are called features, factors or ranking signals. They may be divided into three groups (features from document retrieval are shown as examples):

Some examples of features, which were used in the well-known LETOR dataset:

Selecting and designing good features is an important area in machine learning, which is called feature engineering.

Evaluation measures

There are several measures (metrics) which are commonly used to judge how well an algorithm is doing on training data and to compare the performance of different MLR algorithms. Often a learning-to-rank problem is reformulated as an optimization problem with respect to one of these metrics.

Examples of ranking quality measures:

DCG and its normalized variant NDCG are usually preferred in academic research when multiple levels of relevance are used.[6] Other metrics such as MAP, MRR and precision, are defined only for binary judgments.

Recently, there have been proposed several new evaluation metrics which claim to model user's satisfaction with search results better than the DCG metric:

Both of these metrics are based on the assumption that the user is more likely to stop looking at search results after examining a more relevant document, than after a less relevant document.

Approaches

Tie-Yan Liu of Microsoft Research Asia has analyzed existing algorithms for learning to rank problems in his book Learning to Rank for Information Retrieval. He categorized them into three groups by their input spaces, output spaces, hypothesis spaces (the core function of the model) and loss functions: the pointwise, pairwise, and listwise approach. In practice, listwise approaches often outperform pairwise approaches and pointwise approaches. This statement was further supported by a large scale experiment on the performance of different learning-to-rank methods on a large collection of benchmark data sets.

In this section, without further notice,

x

denotes an object to be evaluated, for example, a document or an image,

f(x)

denotes a single-value hypothesis,

h()

denotes a bi-variate or multi-variate function and

L()

denotes the loss function.

Pointwise approach

In this case, it is assumed that each query-document pair in the training data has a numerical or ordinal score. Then the learning-to-rank problem can be approximated by a regression problem — given a single query-document pair, predict its score. Formally speaking, the pointwise approach aims at learning a function

f(x)

predicting the real-value or ordinal score of a document

x

using the loss function

L(f;xj,yj)

.

A number of existing supervised machine learning algorithms can be readily used for this purpose. Ordinal regression and classification algorithms can also be used in pointwise approach when they are used to predict the score of a single query-document pair, and it takes a small, finite number of values.

Pairwise approach

h(xu,xv)

that can tell which document is better in a given pair of documents. The classifier shall take two documents as its input and the goal is to minimize a loss function

L(h;xu,xv,yu,v)

. The loss function typically reflects the number and magnitude of inversions in the induced ranking.

In many cases, the binary classifier

h(xu,xv)

is implemented with a scoring function

f(x)

. As an example, RankNet [8] adapts a probability model and defines

h(xu,xv)

as the estimated probability of the document

xu

has higher quality than

xv

:

Pu,(f)=CDF(f(xu)-f(xv)),

where

CDF()

is a cumulative distribution function, for example, the standard logistic CDF, i.e.

CDF(x) =

1
1+\exp\left[-x\right]

.

Listwise approach

These algorithms try to directly optimize the value of one of the above evaluation measures, averaged over all queries in the training data. This is often difficult in practice because most evaluation measures are not continuous functions with respect to ranking model's parameters, and so continuous approximations or bounds on evaluation measures have to be used. For example the SoftRank algorithm.[9] LambdaMART is a pairwise algorithm which has been empirically shown to approximate listwise objective functions.[10]

List of methods

A partial list of published learning-to-rank algorithms is shown below with years of first publication of each method:

Year Name Type Notes
1989 OPRF 2 pointwise Polynomial regression (instead of machine learning, this work refers to pattern recognition, but the idea is the same)
1992 SLR 2 pointwise Staged logistic regression
1994 NMOpt 2 listwise Non-Metric Optimization
1999 MART (Multiple Additive Regression Trees) 2 pairwise
2000 Ranking SVM (RankSVM) 2 pairwise A more recent exposition is in, which describes an application to ranking using clickthrough logs.
2002 Pranking[11] 1 pointwise Ordinal regression.
2003 RankBoost 2 pairwise
2005 RankNet 2 pairwise
2006 IR-SVM 2 pairwise Ranking SVM with query-level normalization in the loss function.
2006 LambdaRank pairwise/listwise RankNet in which pairwise loss function is multiplied by the change in the IR metric caused by a swap.
2007 AdaRank 3 listwise
2007 FRank 2 pairwise Based on RankNet, uses a different loss function - fidelity loss.
2007 GBRank 2 pairwise
2007 ListNet 3 listwise
2007 McRank 1 pointwise
2007 QBRank 2 pairwise
2007 RankCosine 3 listwise
2007 RankGP[12] 3 listwise
2007 RankRLS 2 pairwise Regularized least-squares based ranking. The work is extended in to learning to rank from general preference graphs.
2007 SVMmap 3 listwise
2008 LambdaSMART/LambdaMART pairwise/listwise Winning entry in the Yahoo Learning to Rank competition in 2010, using an ensemble of LambdaMART models. Based on MART (1999)[13] “LambdaSMART”, for Lambda-submodel-MART, or LambdaMART for the case with no submodel.
2008 ListMLE 3 listwise Based on ListNet.
2008 PermuRank 3 listwise
2008 SoftRank 3 listwise
2008 Ranking Refinement[14] 2 pairwise A semi-supervised approach to learning to rank that uses Boosting.
2008 SSRankBoost[15] 2 pairwiseAn extension of RankBoost to learn with partially labeled data (semi-supervised learning to rank)
2008 SortNet[16] 2 pairwiseSortNet, an adaptive ranking algorithm which orders objects using a neural network as a comparator.
2009 MPBoost 2 pairwise Magnitude-preserving variant of RankBoost. The idea is that the more unequal are labels of a pair of documents, the harder should the algorithm try to rank them.
2009 BoltzRank 3 listwise Unlike earlier methods, BoltzRank produces a ranking model that looks during query time not just at a single document, but also at pairs of documents.
2009 BayesRank 3 listwise A method combines Plackett-Luce Model and neural network to minimize the expected Bayes risk, related to NDCG, from the decision-making aspect.
2010 NDCG Boost[17] 3 listwise A boosting approach to optimize NDCG.
2010 GBlend 2 pairwise Extends GBRank to the learning-to-blend problem of jointly solving multiple learning-to-rank problems with some shared features.
2010 IntervalRank 2 pairwise & listwise
2010 CRR 2 pointwise & pairwise Combined Regression and Ranking. Uses stochastic gradient descent to optimize a linear combination of a pointwise quadratic loss and a pairwise hinge loss from Ranking SVM.
2014 LCR 2 pairwise Applied local low-rank assumption on collaborative ranking. Received best student paper award at WWW'14.
2015FaceNetpairwiseRanks face images with the triplet metric via deep convolutional network.
2016XGBoostpairwiseSupports various ranking objectives and evaluation metrics.
2017 ES-Rank listwise Evolutionary Strategy Learning to Rank technique with 7 fitness evaluation metrics
2018 DLCM 2 listwise A multi-variate ranking function that encodes multiple items from an initial ranked list (local context) with a recurrent neural network and create result ranking accordingly.
2018PolyRank[18] pairwiseLearns simultaneously the ranking and the underlying generative model from pairwise comparisons.
2018 FATE-Net/FETA-Net [19] listwise End-to-end trainable architectures, which explicitly take all items into account to model context effects.
2019FastAP [20] listwiseOptimizes Average Precision to learn deep embeddings
2019Mulberry listwise & hybrid Learns ranking policies maximizing multiple metrics across the entire dataset
2019 DirectRanker pairwise Generalisation of the RankNet architecture
2019 GSF 2 listwise A permutation-invariant multi-variate ranking function that encodes and ranks items with groupwise scoring functions built with deep neural networks.
2020RaMBO[21] listwiseOptimizes rank-based metrics using blackbox backpropagation[22]
2020PRM [23] pairwise Transformer network encoding both the dependencies among items and the interactionsbetween the user and items
2020 SetRank 2 listwise A permutation-invariant multi-variate ranking function that encodes and ranks items with self-attention networks.
2021PiRank [24] listwise Differentiable surrogates for ranking able to exactly recover the desired metrics and scales favourably to large list sizes, significantly improving internet-scale benchmarks.
2022SAS-RanklistwiseCombining Simulated Annealing with Evolutionary Strategy for implicit and explicit learning to rank from relevance labels
2022VNS-RanklistwiseVariable Neighborhood Search in 2 Novel Methodologies in AI for Learning to Rank
2022VNA-RanklistwiseCombining Simulated Annealing with Variable Neighbourhood Search for Learning to Rank
2023GVN-RanklistwiseCombining Gradient Ascent with Variable Neighbourhood Search for Learning to Rank

Note: as most supervised learning to Rank algorithms can be applied to pointwise, pairwise and listwise case, only those methods which are specifically designed with ranking in mind are shown above.

History

Norbert Fuhr introduced the general idea of MLR in 1992, describing learning approaches in information retrieval as a generalization of parameter estimation; a specific variant of this approach (using polynomial regression) had been published by him three years earlier. Bill Cooper proposed logistic regression for the same purpose in 1992 and used it with his Berkeley research group to train a successful ranking function for TREC. Manning et al.[25] suggest that these early works achieved limited results in their time due to little available training data and poor machine learning techniques.

Several conferences, such as NeurIPS, SIGIR and ICML had workshops devoted to the learning-to-rank problem since mid-2000s (decade).

Practical usage by search engines

Commercial web search engines began using machine learned ranking systems since the 2000s (decade). One of the first search engines to start using it was AltaVista (later its technology was acquired by Overture, and then Yahoo), which launched a gradient boosting-trained ranking function in April 2003.[26]

Bing's search is said to be powered by RankNet algorithm,[27] which was invented at Microsoft Research in 2005.

In November 2009 a Russian search engine Yandex announced[28] that it had significantly increased its search quality due to deployment of a new proprietary MatrixNet algorithm, a variant of gradient boosting method which uses oblivious decision trees.[29] Recently they have also sponsored a machine-learned ranking competition "Internet Mathematics 2009"[30] based on their own search engine's production data. Yahoo has announced a similar competition in 2010.[31]

As of 2008, Google's Peter Norvig denied that their search engine exclusively relies on machine-learned ranking.[32] Cuil's CEO, Tom Costello, suggests that they prefer hand-built models because they can outperform machine-learned models when measured against metrics like click-through rate or time on landing page, which is because machine-learned models "learn what people say they like, not what people actually like".[33]

In January 2017, the technology was included in the open source search engine Apache Solr.[34] It is also available in the open source OpenSearch and the source-available Elasticsearch.[35] [36] These implementations make learning to rank widely accessible for enterprise search.

Vulnerabilities

Similar to recognition applications in computer vision, recent neural network based ranking algorithms are also found to be susceptible to covert adversarial attacks, both on the candidates and the queries.[37] With small perturbations imperceptible to human beings, ranking order could be arbitrarily altered. In addition, model-agnostic transferable adversarial examples are found to be possible, which enables black-box adversarial attacks on deep ranking systems without requiring access to their underlying implementations.[38]

Conversely, the robustness of such ranking systems can be improved via adversarial defenses such as the Madry defense.[39]

See also

External links

Competitions and public datasets

Notes and References

  1. . Slides from Tie-Yan Liu's talk at WWW 2009 conference are available online
  2. [Mehryar Mohri]
  3. . Section 7.1
  4. Yuanhua Lv, Taesup Moon, Pranam Kolari, Zhaohui Zheng, Xuanhui Wang, and Yi Chang, Learning to Model Relatedness for News Recommendation, in International Conference on World Wide Web (WWW), 2011.
  5. M. . Richardson . Prakash, A. . Brill, E. . Beyond PageRank: Machine Learning for Static Ranking . Proceedings of the 15th International World Wide Web Conference . 707–715 . 2006 . 2009-11-18 . 2009-08-15 . https://web.archive.org/web/20090815173829/http://research.microsoft.com/en-us/um/people/mattri/papers/www2006/staticrank.pdf . live .
  6. Web site: Archived copy . 2009-12-14 . 2011-01-04 . https://web.archive.org/web/20110104111500/http://www.stanford.edu/class/cs276/handouts/lecture15-learning-ranking.ppt . live .
  7. (in Russian)
  8. Burges . Chris J. C. . Shaked . Tal . Renshaw . Erin . Lazier . Ari . Deeds . Matt . Hamilton . Nicole . Hullender . Greg . Learning to Rank using Gradient Descent . 1 August 2005 . 31 March 2021 . 26 February 2021 . https://web.archive.org/web/20210226045904/https://www.microsoft.com/en-us/research/publication/learning-to-rank-using-gradient-descent/ . live .
  9. Taylor, M.J., Guiver, J., Robertson, S.E., & Minka, T.P. (2008). SoftRank: optimizing non-smooth rank metrics. Web Search and Data Mining.
  10. Burges . Chris J. C. . 2010-06-23 . From RankNet to LambdaRank to LambdaMART: An Overview . en-US.
  11. 10.1.1.20.378 . Pranking . 2001 . 641–647 .
  12. 10.1.1.90.220 . RankGP .
  13. C. Burges. (2010). From RankNet to LambdaRank to LambdaMART: An Overview .
  14. Rong Jin, Hamed Valizadegan, Hang Li, Ranking Refinement and Its Application for Information Retrieval, in International Conference on World Wide Web (WWW), 2008.
  15. Massih-Reza Amini, Vinh Truong, Cyril Goutte, A Boosting Algorithm for Learning Bipartite Ranking Functions with Partially Labeled Data, International ACM SIGIR conference, 2008. The code is available for research purposes.
  16. Leonardo Rigutini, Tiziano Papini, Marco Maggini, Franco Scarselli, "SortNet: learning to rank by a neural-based sorting algorithm", SIGIR 2008 workshop: Learning to Rank for Information Retrieval, 2008
  17. Hamed Valizadegan, Rong Jin, Ruofei Zhang, Jianchang Mao, Learning to Rank by Optimizing NDCG Measure, in Proceeding of Neural Information Processing Systems (NIPS), 2010.
  18. Davidov. Ori. Ailon. Nir. Oliveira. Ivo F. D.. 2018. A New and Flexible Approach to the Analysis of Paired Comparison Data. Journal of Machine Learning Research. 19. 60. 1–29. 1533-7928. 2019-09-17. 2019-10-03. https://web.archive.org/web/20191003090745/http://www.jmlr.org/papers/v19/17-179.html. live.
  19. Pfannschmidt . Karlson . Gupta . Pritha . Hüllermeier . Eyke . 2018 . Deep Architectures for Learning Context-dependent Ranking Functions . stat.ML . 1803.05796.
  20. Fatih Cakir, Kun He, Xide Xia, Brian Kulis, Stan Sclaroff, Deep Metric Learning to Rank, In Proc. IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2019.
  21. Rolínek . Michal . Musil . Vít . Paulus . Anselm . Vlastelica . Marin . Michaelis . Claudio . Martius . Georg . 2020-03-18 . Optimizing Rank-based Metrics with Blackbox Differentiation . cs.LG . 1912.03500 .
  22. Vlastelica . Marin . Paulus . Anselm . Musil . Vít . Martius . Georg . Rolínek . Michal . 2019-12-04 . Differentiation of Blackbox Combinatorial Solvers . 1912.02175 . en .
  23. Book: Liu. Weiwen. Liu. Qing. Tang. Ruiming. Chen. Junyang. He. Xiuqiang. Heng. Pheng Ann. Proceedings of the 29th ACM International Conference on Information & Knowledge Management . Personalized Re-ranking with Item Relationships for E-commerce . 2020-10-19. https://doi.org/10.1145/3340531.3412332. CIKM '20. Virtual Event, Ireland. Association for Computing Machinery. 925–934. 10.1145/3340531.3412332. 978-1-4503-6859-9. 224281012. 2021-04-26. 2021-10-17. https://web.archive.org/web/20211017153218/https://dl.acm.org/doi/10.1145/3340531.3412332. live.
  24. Swezey. Robin. Grover. Aditya. Charron. Bruno. Ermon. Stefano. 2021-11-27. PiRank: Scalable Learning To Rank via Differentiable Sorting. 2012.06731. Advances in Neural Information Processing Systems . 34 . NeurIPS '21. Virtual Event, Ireland.
  25. . Sections 7.4 and 15.5
  26. Jan O. Pedersen. The MLR Story
  27. Web site: Bing Search Blog: User Needs, Features and the Science behind Bing . 2009-11-19 . 2009-11-25 . https://web.archive.org/web/20091125205204/http://www.bing.com/community/blogs/search/archive/2009/06/01/user-needs-features-and-the-science-behind-bing.aspx?PageIndex=4 . live .
  28. http://webmaster.ya.ru/replies.xml?item_no=5707&ncrnd=5118 Yandex corporate blog entry about new ranking model "Snezhinsk"
  29. The algorithm wasn't disclosed, but a few details were made public in http://download.yandex.ru/company/experience/GDD/Zadnie_algoritmy_Karpovich.pdf and http://download.yandex.ru/company/experience/searchconf/Searchconf_Algoritm_MatrixNet_Gulin.pdf .
  30. Web site: Yandex's Internet Mathematics 2009 competition page . 2009-11-11 . https://web.archive.org/web/20150317144535/http://imat2009.yandex.ru/academic/mathematic/2009/en/ . 2015-03-17 . dead .
  31. Web site: Yahoo Learning to Rank Challenge . 2010-02-26 . https://web.archive.org/web/20100301011649/http://learningtorankchallenge.yahoo.com/ . 2010-03-01 . dead .
  32. Web site: Are Machine-Learned Models Prone to Catastrophic Errors? . https://archive.today/20120701122042/http://anand.typepad.com/datawocky/2008/05/are-human-experts-less-prone-to-catastrophic-errors-than-machine-learned-models.html . 2012-07-01 . 2008-05-24 . Rajaraman . Anand . Anand Rajaraman . 2009-11-11 . live.
  33. Web site: Cuil Blog: So how is Bing doing? . https://archive.today/20090627213358/http://www.cuil.com/info/blog/2009/06/26/so-how-is-bing-doing . 2009-06-27 . 2009-06-26 . Costello . Tom.
  34. News: How Bloomberg Integrated Learning-to-Rank into Apache Solr Tech at Bloomberg. 2017-01-23. Tech at Bloomberg. 2017-02-28. en-US. 2017-03-01. https://web.archive.org/web/20170301092711/https://www.techatbloomberg.com/blog/bloomberg-integrated-learning-rank-apache-solr/. live.
  35. Web site: Learning to Rank for Amazon OpenSearch Service - Amazon OpenSearch Service . 2023-09-22 . docs.aws.amazon.com.
  36. Web site: Elasticsearch Learning to Rank: the documentation — Elasticsearch Learning to Rank documentation . 2023-09-22 . elasticsearch-learning-to-rank.readthedocs.io.
  37. Zhou . Mo . Niu . Zhenxing . Wang . Le . Zhang . Qilin . Hua . Gang . Adversarial Ranking Attack and Defense . 2020 . cs.CV . 2002.11293v2 .
  38. Li . Jie . Ji . Rongrong . Liu . Hong . Hong . Xiaopeng . Gao . Yue . Tian . Qi . Universal Perturbation Attack Against Image Retrieval . International Conference on Computer Vision (ICCV 2019) . 2019 . 4899–4908 . 1812.00552 . 2020-07-04 . 2020-07-06 . https://web.archive.org/web/20200706051031/https://openaccess.thecvf.com/content_ICCV_2019/html/Li_Universal_Perturbation_Attack_Against_Image_Retrieval_ICCV_2019_paper.html . live .
  39. Madry . Aleksander . Makelov . Aleksandar . Schmidt . Ludwig . Tsipras . Dimitris . Vladu . Adrian . Towards Deep Learning Models Resistant to Adversarial Attacks . 2017-06-19 . stat.ML . 1706.06083v4 .