Caching for PyTerrier

pyterrier-caching provides several PyTerrier components for caching intermediate results.

You can install pyterrier-caching with pip:

Install pyterrier-caching
$ pip install pyterrier-caching

The right component (ScorerCache, IndexerCache, or RetrieverCache) will depend on your use case. More information can be found in the subsequent pages:

For more information about caching in PyTerrier, see our WOWS 2025 paper:

Citation

MacAvaney and Macdonald. On Precomputation and Caching in Information Retrieval Experiments with Pipeline Architectures. arXiv 2025. [link]
@article{DBLP:journals/corr/abs-2504-09984,
  author       = {Sean MacAvaney and
                  Craig Macdonald},
  title        = {On Precomputation and Caching in Information Retrieval Experiments
                  with Pipeline Architectures},
  journal      = {CoRR},
  volume       = {abs/2504.09984},
  year         = {2025},
  url          = {https://doi.org/10.48550/arXiv.2504.09984},
  doi          = {10.48550/ARXIV.2504.09984},
  eprinttype    = {arXiv},
  eprint       = {2504.09984},
  timestamp    = {Wed, 21 May 2025 20:31:33 +0200},
  biburl       = {https://dblp.org/rec/journals/corr/abs-2504-09984.bib},
  bibsource    = {dblp computer science bibliography, https://dblp.org}
}