punctuation-restoration-iwslt-eval
Adversarial Transfer Learning for Punctuation Restoration — Jiangyan Yi et al. (2020) (arXiv:2004.00248, 2020)
What this evaluates
Evaluates a model's ability to restore punctuation marks (commas, periods, question marks) in English text. It specifically probes robustness on both manually transcribed transcripts and ASR-generated transcripts, ignoring non-punctuation tokens during evaluation.
Datasets
- IWSLT2011 — total ?; splits: train (-1), dev (-1), test_Ref (-1), test_ASR (-1)
Metrics
F1-score (primary) — range: percent
- Standard F1 score calculated as 2 * (Precision * Recall) / (Precision + Recall). Precision and Recall are computed exclusively on punctuation tokens (COMMA, PERIOD, QUESTION), completely ignoring non-punctuation tokens (O).
Precision — range: percent
- Ratio of correctly predicted punctuation tokens to all predicted punctuation tokens. Computed only on COMMA, PERIOD, and QUESTION labels.
Recall — range: percent
- Ratio of correctly predicted punctuation tokens to all actual punctuation tokens. Computed only on COMMA, PERIOD, and QUESTION labels.
Input / output format
Input: A sequence of English words/tokens from TED Talk transcripts.
Output: A sequence of token-level labels: O, COMMA, PERIOD, or QUESTION.
Scoring recipe
def compute_metrics(predictions, gold):
# Filter out non-punctuation tokens (O) as per protocol
pred_punct = [p for p, g in zip(predictions, gold) if g != 'O']
gold_punct = [g for g in gold if g != 'O']
tp = sum(1 for p, g in zip(pred_punct, gold_punct) if p == g)
fp = sum(1 for p, g in zip(pred_punct, gold_punct) if p != g)
fn = sum(1 for p, g in zip(pred_punct, gold_punct) if p != g)
precision = tp / (tp + fp) if (tp + fp) > 0 else 0.0
recall = tp / (tp + fn) if (tp + fn) > 0 else 0.0
f1 = 2 * precision * recall / (precision + recall) if (precision + recall) > 0 else 0.0
return precision, recall, f1
Common pitfalls
- Including non-punctuation tokens (label 'O') in the precision/recall/F1 calculation, which artificially inflates scores.
- Failing to distinguish between the two test sets (Ref. for manual transcripts vs. ASR for speech recognition outputs), leading to misreported results.
- Misinterpreting the label mapping: exclamation marks and semicolons are grouped under PERIOD, not treated as separate classes.
Evidence (verbatim from paper)
All models are evaluated in terms of precision (P), recall (R), F1-score (F1) in our experiments. We focus on the performance of the punctuation marks. So the correctly predicted non-punctuation marks O are ignored. We only evaluate the performance of COMMA, PERIOD and QUESTION on two test sets: Ref. and ASR, respectively.
Citation
@misc{yi2020adversarial,
title={Adversarial Transfer Learning for Punctuation Restoration},
author={Jiangyan Yi et al. (2020)},
year={2020},
note={arXiv:2004.00248}
}
1---2name: punctuation-restoration-iwslt-eval3description: Evaluates a model's ability to restore punctuation marks (commas, periods, question marks) in English text. It specifically probes robustness on both manually transcribed transcripts and ASR-generated transcripts, ignoring non-punctuation tokens during evaluation. Use when the user wants to benchmark on IWSLT2011, or asks about evaluating this task. Reports F1-score.4---56# punctuation-restoration-iwslt-eval78> Adversarial Transfer Learning for Punctuation Restoration — Jiangyan Yi et al. (2020) (arXiv:2004.00248, 2020)910## What this evaluates1112Evaluates a model's ability to restore punctuation marks (commas, periods, question marks) in English text. It specifically probes robustness on both manually transcribed transcripts and ASR-generated transcripts, ignoring non-punctuation tokens during evaluation.1314## Datasets1516- **IWSLT2011** — total ?; splits: train (-1), dev (-1), test_Ref (-1), test_ASR (-1)1718## Metrics1920- `F1-score` **(primary)** — range: percent21 - Standard F1 score calculated as 2 * (Precision * Recall) / (Precision + Recall). Precision and Recall are computed exclusively on punctuation tokens (COMMA, PERIOD, QUESTION), completely ignoring non-punctuation tokens (O).22- `Precision` — range: percent23 - Ratio of correctly predicted punctuation tokens to all predicted punctuation tokens. Computed only on COMMA, PERIOD, and QUESTION labels.24- `Recall` — range: percent25 - Ratio of correctly predicted punctuation tokens to all actual punctuation tokens. Computed only on COMMA, PERIOD, and QUESTION labels.2627## Input / output format2829**Input**: A sequence of English words/tokens from TED Talk transcripts.3031**Output**: A sequence of token-level labels: O, COMMA, PERIOD, or QUESTION.3233## Scoring recipe3435```python36def compute_metrics(predictions, gold):37 # Filter out non-punctuation tokens (O) as per protocol38 pred_punct = [p for p, g in zip(predictions, gold) if g != 'O']39 gold_punct = [g for g in gold if g != 'O']40 41 tp = sum(1 for p, g in zip(pred_punct, gold_punct) if p == g)42 fp = sum(1 for p, g in zip(pred_punct, gold_punct) if p != g)43 fn = sum(1 for p, g in zip(pred_punct, gold_punct) if p != g)44 45 precision = tp / (tp + fp) if (tp + fp) > 0 else 0.046 recall = tp / (tp + fn) if (tp + fn) > 0 else 0.047 f1 = 2 * precision * recall / (precision + recall) if (precision + recall) > 0 else 0.048 return precision, recall, f149```5051## Common pitfalls5253- Including non-punctuation tokens (label 'O') in the precision/recall/F1 calculation, which artificially inflates scores.54- Failing to distinguish between the two test sets (Ref. for manual transcripts vs. ASR for speech recognition outputs), leading to misreported results.55- Misinterpreting the label mapping: exclamation marks and semicolons are grouped under PERIOD, not treated as separate classes.5657## Evidence (verbatim from paper)5859> All models are evaluated in terms of precision (P), recall (R), F1-score (F1) in our experiments. We focus on the performance of the punctuation marks. So the correctly predicted non-punctuation marks O are ignored. We only evaluate the performance of COMMA, PERIOD and QUESTION on two test sets: Ref. and ASR, respectively.6061## Citation6263```bibtex64@misc{yi2020adversarial,65 title={Adversarial Transfer Learning for Punctuation Restoration},66 author={Jiangyan Yi et al. (2020)},67 year={2020},68 note={arXiv:2004.00248}69}70```7172- arXiv: 2004.00248