Evaluates document-to-document information retrieval systems for regulatory compliance, testing their ability to match long, noisy legislative texts to related legal documents. It probes how well models handle extended query lengths, domain-specific vocabulary, and temporal constraints in legal transposition tasks. Use when the user wants to benchmark on EU2UK, UK2EU, or asks about evaluating this task. Reports R@100.
Scanned 9/11/2026
Install to Claude Code
npx -y skills add qhjqhj00/research-skills-pool --skill doc2doc-ir-eval --agent claude-codeInstalls into .claude/skills of the current project.
Are you the author of Doc2doc Ir Eval?
Add the live security badge to your README — it updates automatically with every re-scan.
[](https://www.skillsdirectory.com/skills/qhjqhj00-doc2doc-ir-eval)More formats (shields.io, HTML) on the badges page.
---
name: doc2doc-ir-eval
description: Evaluates document-to-document information retrieval systems for regulatory compliance, testing their ability to match long, noisy legislative texts to related legal documents. It probes how well models handle extended query lengths, domain-specific vocabulary, and temporal constraints in legal transposition tasks. Use when the user wants to benchmark on EU2UK, UK2EU, or asks about evaluating this task. Reports R@100.
metadata:
skill_kind: dataset_eval
source_arxiv: 2101.10726
bibtex_key: chalkidis2021regulatory
confidence: high
---
# doc2doc-ir-eval
> Regulatory Compliance through Doc2Doc Information Retrieval: A case study in EU/UK legislation where text similarity has limitations — Chalkidis et al. (2021) (arXiv:2101.10726, 2021)
## What this evaluates
Evaluates document-to-document information retrieval systems for regulatory compliance, testing their ability to match long, noisy legislative texts to related legal documents. It probes how well models handle extended query lengths, domain-specific vocabulary, and temporal constraints in legal transposition tasks.
## Datasets
- **EU2UK** — total ?; splits: train (-1), val (-1), test (-1)
- **UK2EU** — total ?; splits: train (-1), val (-1), test (-1)
## Metrics
- `R@100` **(primary)** — range: [0, 1]
- Recall@k measures the fraction of relevant documents retrieved within the top-k ranked results. For pre-fetching, k is fixed at 100.
- `R@20` — range: [0, 1]
- Recall@20 measures the fraction of relevant documents retrieved within the top-20 ranked results, used for re-ranking evaluation.
- `nDCG@20` — range: [0, 1]
- Normalized Discounted Cumulative Gain at rank 20, which evaluates the quality of the ranked list by discounting the relevance score of each document by its position.
- `R-Precision` — range: [0, 1]
- Recall at rank R, where R equals the total number of relevant documents for the query. It measures how many relevant documents appear in the top-R positions.
## Input / output format
**Input**: Full-text of legislative acts (queries and candidate documents), pre-processed by removing stop-words, punctuation, digits, and low-IDF terms, reducing average length by ~55%.
**Output**: A ranked list of candidate documents for each query.
## Scoring recipe
```python
def compute_recall_at_k(predictions, gold_set, k):
retrieved = set(predictions[:k])
relevant = len(retrieved & gold_set)
return relevant / len(gold_set) if gold_set else 0.0
# For nDCG@k and R-Precision, apply standard IR formulas over the top-k ranked predictions against the gold set.
```
## Common pitfalls
- Using traditional BM25 hyperparameters (k1=1.2, b=0.75) instead of tuning for long queries, which significantly degrades performance.
- Using only the legislative title as a query instead of the full text, which drops R@100 by 5–20%.
- Ignoring temporal context, which is critical for correctly matching transposed legislation.
## Evidence (verbatim from paper)
> Pre-fetching aims to bring all the relevant documents in the top-k, thus we report R@k. We observe that for k > 100 the best pre fetchers have not significant gains in performance in development data, thus we select k = 100 , as a reasonable threshold. For re-ranking we report R@20, nDCG@20 and R-Precision (RP) following the literature (Manning et al., 2009). We report the average and standard deviation across three runs considering the best set of hyper-parameters on development data for neural re-rankers.
## Citation
```bibtex
@misc{chalkidis2021regulatory,
title={Regulatory Compliance through Doc2Doc Information Retrieval: A case study in EU/UK legislation where text similarity has limitations},
author={Chalkidis et al. (2021)},
year={2021},
note={arXiv:2101.10726}
}
```
- arXiv: 2101.10726
Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.
No comments yet. Be the first to comment!