← All artifacts
library

LuxemBERT

A BERT model for Luxembourgish — a low-resource West Germanic language — trained with a simple, practical data-augmentation trick: partially translate closely-related German text into "pseudo-Luxembourgish" by swapping unambiguous function words, then mix it with real Luxembourgish. LuxemBERT outperforms a Luxembourgish-only baseline and multilingual mBERT on most evaluated task variants; the paper reports five of six wins over mBERT, with the cased model winning all six. The study also creates four annotated downstream datasets, available from the authors on request.

Cedric Lothritz, Bertrand Lebichot, Kevin Allix, Lisa Veiber, Tegawendé F. Bissyandé, Jacques Klein, Andrey Boytsov, Clément Lefebvre, Anne Goujon

Website

How it works

The data-augmentation scheme — German text is preprocessed and its function words translated into pseudo-Luxembourgish, then mixed with Luxembourgish text to pre-train LuxemBERT (paper, Figure 1)
The data-augmentation scheme — German text is preprocessed and its function words translated into pseudo-Luxembourgish, then mixed with Luxembourgish text to pre-train LuxemBERT (paper, Figure 1)

Interactive demo

Try three Luxembourgish masked-language prompts and preview the top tokens a LuxemBERT fill-mask pipeline could return.

Pick a task above to see it in action.

Interactive simulation — prompts, token rankings, and probabilities are illustrative mock outputs chosen to demonstrate masked-language modeling. No model inference runs in the browser and these values are not paper measurements.

Explore the dataset

110,000,000Model parameters (BERT Base)
6,100,000Luxembourgish sentences (pre-training)
130,000,000Words in the Luxembourgish corpus
12Transformer layers
768Hidden size
50%Luxembourgish share in the best corpus mix
120Alphabet size (cut from 1000)
529Function-word pairs for augmentation (De↔Lb)
20%German text pseudo-translated to Luxembourgish
4Downstream datasets created (available on request)
Load the model

The uncased LuxemBERT model is on the Hugging Face Hub.

from transformers import AutoTokenizer, AutoModelForMaskedLM

tok = AutoTokenizer.from_pretrained("lothritz/LuxemBERT")
model = AutoModelForMaskedLM.from_pretrained("lothritz/LuxemBERT")

Cite this artifact

@inproceedings{lothritz-etal-2022-luxembert,
  author    = {Lothritz, Cedric and Lebichot, Bertrand and Allix, Kevin and Veiber, Lisa and Bissyand\'{e}, Tegawend\'{e} F. and Klein, Jacques and Boytsov, Andrey and Lefebvre, Cl\'{e}ment and Goujon, Anne},
  title     = {{LuxemBERT}: Simple and Practical Data Augmentation in Language Model Pre-Training for Luxembourgish},
  booktitle = {Proceedings of the 13th Language Resources and Evaluation Conference (LREC)},
  year      = {2022},
  pages     = {5080--5089},
  publisher = {European Language Resources Association},
  url       = {https://aclanthology.org/2022.lrec-1.543/}
}