从零训练的德语新编码器:ModernGBERT与转换后的LLM2Vec模型对比
New Encoders for German Trained from Scratch: Comparing ModernGBERT with Converted LLM2Vec Models
AI总结:
本研究在相同约束下对比了从零训练的ModernGBERT与基于LLM2Vec转换的LLäMmleinVec德语编码器,发现前者在参数效率与延迟上占优并创下新SOTA,后者在算力受限时为有效替代方案。
摘要:
尽管decoder-only LLM兴起,编码器在高效的德语NLP和NLU场景中依然不可或缺。本研究在相同数据和训练约束下,探索获取高质量德语编码器的两条路径:1)从零训练;2)通过LLM2Vec转换解码器。我们引入两项资源:ModernGBERT(134M, 1B),采用ModernBERT风格的全透明德语编码器;以及LLäMmleinVec(120M, 1B, 7B),使用掩码下一词元预测训练的解码器到编码器转换模型,两者均将上下文扩展至8.192个词元。在SuperGLEBER上,ModernGBERT 1B创下新SOTA(平均0.808),超越GBERT Large(+4%)和参数大七倍的7B转换模型(0.787)。在监督微调后的German MTEB上,ModernGBERT 1B(0.551)逼近7B转换模型(0.557)。我们发布所有模型、检查点、数据集和完整训练记录,并引入适配编码器的QA-NIAH评估。结果表明:当参数效率和延迟至关重要时,从零训练的编码器占优;若已有预训练解码器且计算受限,转换是有效替代方案。所有代码、数据和中间检查点均以仅限研究的RAIL许可证发布。
英文摘要:
Encoders remain essential for efficient German NLP and NLU scenarios despite the rise of decoder-only LLMs. This work studies two routes to high-quality German encoders under identical data and training constraints: 1) training from scratch and 2) converting decoders via LLM2Vec. We introduce two resources: ModernGBERT (134M, 1B), fully transparent German encoders in the ModernBERT style, and LLäMmleinVec (120M, 1B, 7B), decoder-to-encoder conversions trained with masked next-token prediction, both undergoing a context extension to 8.192 tokens. Across SuperGLEBer, ModernGBERT 1B sets a new state of the art (avg 0.808), surpassing GBERT Large (+4%) and the seven-times larger converted 7B model (0.787). On German MTEB after supervised fine-tuning, ModernGBERT 1B (0.551) approaches the converted 7B model (0.557). We release all models, checkpoints, datasets, and full training records, and introduce an encoder-adapted QA-NIAH evaluation. All in all, our results provide actionable guidance: when parameter efficiency and latency matter, from-scratch encoders dominate. When a pre-trained decoder exists and compute is a limited, conversion offers an effective alternative. ModernGBERT and LLäMmleinVec, including all code, data and intermediary checkpoints are published under a research-only RAIL license.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。