BM25, abréviation de Best Matching 25, est un système avancé de recherche d'informations model that ranks documents based on their relevance to a given search query. It is widely used in moteurs de recherche and recommendation systems due to its effectiveness in handling varying document lengths and the frequency of term occurrences.
L'algorithme BM25 fait partie d'une famille de modèles probabilistes which estimate the likelihood of a document being relevant to a user’s query. It calculates a score for each document based on several factors including:
- Fréquence du terme (TF) : The number of times a search term appears in a document. Higher term frequency generally leads to a higher score de pertinence.
- Longueur du document : BM25 normalizes term frequency by considering the length of the document. This helps to prevent longer documents from being unfairly favored simply because they contain more words.
- Fréquence de Document Inverse (IDF) : A measure of how common or rare a term is across the entire corpus of documents. Rare terms have a higher weight in the scoring, as they are more informative for distinguishing relevant documents.
BM25 intègre également parameters pour affiner le processus de notation, comme :
- b: Un paramètre qui ajuste l'impact de la normalisation de la longueur du document.
- k1 : A parameter that controls the saturation of term frequency; higher values mean that additional occurrences of the term will have a diminishing effect on the score.
Overall, BM25 is highly regarded for its performance in various applications, including search engines, text mining, and tâches de traitement du langage naturel. It helps ensure that users receive the most relevant results based on their queries.