BART-base fine-tuned for English -> ASL gloss (ASLG-PC12)
facebook/bart-base fine-tuned on the training split of the ASLG-PC12 English-ASL gloss parallel
corpus. Input is a lowercased English sentence; output is an upper-case ASL gloss sequence in the
corpus's conventions (X- pronouns, DESC- modifiers).
This model is one of the systems in a small project comparing grammar-constrained decoding (xgrammar) with unconstrained decoding for gloss generation. Code, grammars and evaluation scripts: https://github.com/TheRealGioviok/nlpproj
Training
| Base model | facebook/bart-base |
| Data | training split of the Kaggle redistribution of ASLG-PC12 (87,710 pairs, no official split; deduplicated and re-split 80/10/10 with seed 42 in the project) |
| Epochs | 3 |
| Effective batch size | 32 |
| Learning rate | 3e-5 |
| Max length | 128 tokens (source and target) |
| Steps | 6,084 |
Weights are stored in fp16 (the evaluation in the project also ran in fp16).
Results (1,000-sentence test sample, greedy decoding)
| Decoding | BLEU | chrF | Exact match | Sequence validity |
|---|---|---|---|---|
| Unconstrained | 76.7 | 93.3 | 44.5% | 48.6% |
| Constrained (grammar v3) | 73.2 | 85.9 | 42.8% | 100% |
| Constrained + copy rule (v3) | 74.1 | 86.3 | 44.5% | 100% |
"Sequence validity" is the share of outputs whose every token is in the closed gloss vocabulary.
Usage
from transformers import AutoTokenizer, AutoModelForSeq2SeqLM
repo = "425GMM/bart-base-aslg-gloss"
tok = AutoTokenizer.from_pretrained(repo)
model = AutoModelForSeq2SeqLM.from_pretrained(repo)
src = "we should behave outside european waters in just the same way as we do at home ."
ids = tok(src, return_tensors="pt")
out = model.generate(**ids, max_new_tokens=128)
print(tok.decode(out[0], skip_special_tokens=True))
Source sentences in ASLG-PC12 are lowercased with spaces before punctuation; feed the model text in the same form.
Limitations
ASLG-PC12 glosses are rule-generated from Europarl text, not produced by signers. The model learns those rules; it is not a general English-to-ASL translator and scores do not transfer to human-annotated gloss corpora.