The Dataset Viewer has been disabled on this dataset.

MS MARCO PISA Index

Description

This is an index of the MS MARCO passage (v1) dataset with PISA. It can be used for passage retrieval using lexical methods.

Usage

>>> from pyterrier_pisa import PisaIndex
>>> index = PisaIndex.from_hf('macavaney/msmarco-passage.pisa')
>>> bm25 = index.bm25()
>>> bm25.search('terrier breeds')
    qid           query    docno      score  rank
0     1  terrier breeds  1406578  22.686367     0
1     1  terrier breeds  5785957  22.611134     1
2     1  terrier breeds  7455374  22.592781     2
3     1  terrier breeds  3984886  22.242958     3
4     1  terrier breeds  3984893  22.009525     4
...

Benchmarks

TREC DL 2019

Code
from ir_measures import nDCG, RR, MAP, R
import pyterrier as pt
from pyterrier_pisa import PisaIndex
index = PisaIndex.from_hf('macavaney/msmarco-passage.pisa')
dataset = pt.get_dataset('irds:msmarco-passage/trec-dl-2019/judged')
pt.Experiment(
  [index.bm25(), index.qld(), index.dph(), index.pl2()],
  dataset.get_topics(),
  dataset.get_qrels(),
  [nDCG@10, nDCG, RR(rel=2), MAP(rel=2), R(rel=2)@1000],
  ['BM25', 'QLD', 'DPH', 'PL2'],
  round=4,
)
name nDCG@10 nDCG RR(rel=2) AP(rel=2) R(rel=2)@1000
0 BM25 0.4989 0.6023 0.6804 0.3031 0.7555
1 QLD 0.468 0.5984 0.6047 0.3037 0.7601
2 DPH 0.4975 0.5907 0.6674 0.3009 0.7436
3 PL2 0.4503 0.5681 0.6495 0.2679 0.7304

TREC DL 2020

Code
from ir_measures import nDCG, RR, MAP, R
import pyterrier as pt
from pyterrier_pisa import PisaIndex
index = PisaIndex.from_hf('macavaney/msmarco-passage.pisa')
dataset = pt.get_dataset('irds:msmarco-passage/trec-dl-2020/judged')
pt.Experiment(
  [index.bm25(), index.qld(), index.dph(), index.pl2()],
  dataset.get_topics(),
  dataset.get_qrels(),
  [nDCG@10, nDCG, RR(rel=2), MAP(rel=2), R(rel=2)@1000],
  ['BM25', 'QLD', 'DPH', 'PL2'],
  round=4,
)
name nDCG@10 nDCG RR(rel=2) AP(rel=2) R(rel=2)@1000
0 BM25 0.4793 0.5963 0.6529 0.2974 0.8048
1 QLD 0.4511 0.587 0.5812 0.2879 0.8125
2 DPH 0.4586 0.5704 0.6123 0.2779 0.798
3 PL2 0.4552 0.5609 0.5788 0.2666 0.7772

MS MARCO Dev (small)

Code
from ir_measures import RR, R
import pyterrier as pt
from pyterrier_pisa import PisaIndex
index = PisaIndex.from_hf('macavaney/msmarco-passage.pisa')
dataset = pt.get_dataset('irds:msmarco-passage/dev/small')
pt.Experiment(
  [index.bm25(), index.qld(), index.dph(), index.pl2()],
  dataset.get_topics(),
  dataset.get_qrels(),
  [RR@10, R@1000],
  ['BM25', 'QLD', 'DPH', 'PL2'],
  round=4,
)
name RR@10 R@1000
0 BM25 0.185 0.8677
1 QLD 0.1683 0.8542
2 DPH 0.1782 0.8605
3 PL2 0.1741 0.8607

Reproduction

>>> import pyterrier_pisa
>>> import pyterrier as pt
>>> idx = pyterrier_pisa.PisaIndex('msmarco-passage.pisa')
>>> idx.indexer().index(pt.get_dataset('irds:msmarco-passage').get_corpus_iter())

Metadata

{
  "type": "sparse_index",
  "format": "pisa",
  "package_hint": "pyterrier-pisa",
  "stemmer": "porter2"
}
Downloads last month
74