gwlans-eval
GWLAN: General Word-Level AutocompletioN for Computer-Aided Translation — Huayang Li et al. (2021) (arXiv:2105.14913, 2021)
What this evaluates
Predicts target words in computer-aided translation based on source sentences, translation context (prefix, suffix, zero, bidirectional), and human-typed characters. It probes the model's ability to handle discontinuous context and weak positional information in real-world CAT scenarios.
Datasets
- GWLAN Benchmark — total ?; splits: train (1250000), val (-1), test (-1)
Metrics
accuracy (primary) — range: percent
- Exact match accuracy: the percentage of instances where the predicted target word exactly matches the gold target word. Scores are averaged across four translation context types (prefix, suffix, zero-context, and bidirectional context).
Input / output format
Input: Source sentence, translation context type (prefix, suffix, zero, or bidirectional), and human-typed character sequence.
Output: A single predicted target word.
Scoring recipe
def compute_accuracy(predictions, golds):
correct = sum(1 for p, g in zip(predictions, golds) if p == g)
return (correct / len(golds)) * 100
# Final reported score is the average of accuracy computed separately for each of the four context types.
Common pitfalls
- The evaluation averages accuracy across four distinct context types (prefix, suffix, zero, bidirectional); reporting only one context's score misrepresents overall performance.
- Trivial instances (e.g., predicting 'the' given 'th') are filtered out using length rules (>4 chars English, >2 chars Chinese) and context length constraints; ignoring these rules inflates scores on easy cases.
Evidence (verbatim from paper)
Table 1: The main results of different systems on Chinese-English and German-English datasets. The results in this table are the averaged accuracy on four translation contexts (i.e., prefix, suffix, zero-context, and bi-context).
Citation
@misc{li2021gwlans,
title={GWLAN: General Word-Level AutocompletioN for Computer-Aided Translation},
author={Huayang Li et al. (2021)},
year={2021},
note={arXiv:2105.14913}
}
1---2name: gwlans-eval3description: Predicts target words in computer-aided translation based on source sentences, translation context (prefix, suffix, zero, bidirectional), and human-typed characters. It probes the model's ability to handle discontinuous context and weak positional information in real-world CAT scenarios. Use when the user wants to benchmark on GWLAN Benchmark, or asks about evaluating this task. Reports accuracy.4---56# gwlans-eval78> GWLAN: General Word-Level AutocompletioN for Computer-Aided Translation — Huayang Li et al. (2021) (arXiv:2105.14913, 2021)910## What this evaluates1112Predicts target words in computer-aided translation based on source sentences, translation context (prefix, suffix, zero, bidirectional), and human-typed characters. It probes the model's ability to handle discontinuous context and weak positional information in real-world CAT scenarios.1314## Datasets1516- **GWLAN Benchmark** — total ?; splits: train (1250000), val (-1), test (-1)1718## Metrics1920- `accuracy` **(primary)** — range: percent21 - Exact match accuracy: the percentage of instances where the predicted target word exactly matches the gold target word. Scores are averaged across four translation context types (prefix, suffix, zero-context, and bidirectional context).2223## Input / output format2425**Input**: Source sentence, translation context type (prefix, suffix, zero, or bidirectional), and human-typed character sequence.2627**Output**: A single predicted target word.2829## Scoring recipe3031```python32def compute_accuracy(predictions, golds):33 correct = sum(1 for p, g in zip(predictions, golds) if p == g)34 return (correct / len(golds)) * 10035# Final reported score is the average of accuracy computed separately for each of the four context types.36```3738## Common pitfalls3940- The evaluation averages accuracy across four distinct context types (prefix, suffix, zero, bidirectional); reporting only one context's score misrepresents overall performance.41- Trivial instances (e.g., predicting 'the' given 'th') are filtered out using length rules (>4 chars English, >2 chars Chinese) and context length constraints; ignoring these rules inflates scores on easy cases.4243## Evidence (verbatim from paper)4445> Table 1: The main results of different systems on Chinese-English and German-English datasets. The results in this table are the averaged accuracy on four translation contexts (i.e., prefix, suffix, zero-context, and bi-context).4647## Citation4849```bibtex50@misc{li2021gwlans,51 title={GWLAN: General Word-Level AutocompletioN for Computer-Aided Translation},52 author={Huayang Li et al. (2021)},53 year={2021},54 note={arXiv:2105.14913}55}56```5758- arXiv: 2105.14913