AIExplainer

What is a recall at k?

A metric for evaluating systems that output a ranked (ordered) list of items.

A metric for evaluating systems that output a ranked (ordered) list of items. Recall at k identifies the fraction of relevant items in the first k items in that list out of the total number of relevant items returned. \[\text{recall at k} = \frac{\text{relevant items in first k items of the list}} {\text{total number of relevant items in the list}}\] Contrast with precision at k.

Suppose a large language model is given the following query:

And the large language model returns the list shown in the first two columns: Relevant? | --- | Yes | Yes | No | Yes | Yes | Yes | Yes | Yes | No | Yes | Eight of the movies in the preceding list are very funny, so they are "relevant items in the list." Therefore, 8 will be the denominator in all the calculations of recall at k. What about the numerator? Well, 3 of the first 4 items are relevant, so recall at 4 is:

7 of the first 8 movies are very funny, so recall at 8 is: