This paper presents Mecellem models, a framework for developing specialized language models for the Turkish legal domain through domain adaptation strategies. We make two contributions: (1)Encoder Model Pre-trained from Scratch: ModernBERT-based bidirectional encoders pre-trained on a Turkish-dominant corpus of 112.7 billion tokens. We implement a checkpoint selection strategy that evaluates downstream retrieval performance throughout training, revealing that optimal checkpoints achieve best retrieval scores before pre-training loss reaches its minimum. Our encoder models achieve top-3 rankings on the Turkish retrieval leaderboard, with smaller models (155M parameters) achieving comparable performance to larger reference models (307M-567M parameters). Our approach achieves 92.36% production efficiency compared to state-of-the-art models (embeddinggemma-300m: 100.00%, BAAI/bge-m3: 99.54%, newmindai/bge-m3-stsb: 94.38%), ranking fourth overall despite requiring less computational resources. SOTA models rely on multi-stage, computationally intensive training pipelines, making our single-stage pre-training followed by efficient post-training approach a cost-effective alternative; (2)Decoder Model with Continual Pre-training (CPT): Qwen3-1.7B and Qwen3-4B models adapted to Turkish legal domain through controlled curriculum learning. Four-phase CPT with optimal sample ratios enables gradual transition from general language knowledge to specialized legal terminology and long-context reasoning. This approach achieves 36.2% perplexity reduction on Turkish legal text, demonstrating domain adaptation gains.


翻译:本文提出了Mecellem模型框架,该框架通过领域适应策略开发面向土耳其法律领域的专用语言模型。我们做出了两项贡献:(1)从头预训练的编码器模型:基于ModernBERT的双向编码器在包含1127亿词符的土耳其语主导语料库上进行预训练。我们实施了检查点选择策略,在训练全程评估下游检索性能,发现最优检查点在预训练损失达到最小值之前即可获得最佳检索分数。我们的编码器模型在土耳其语检索排行榜上位列前三,其中较小模型(1.55亿参数)取得了与更大参考模型(3.07亿-5.67亿参数)相当的性能。相较于最先进模型(embeddinggemma-300m: 100.00%,BAAI/bge-m3: 99.54%,newmindai/bge-m3-stsb: 94.38%),我们的方法实现了92.36%的生产效率,尽管所需计算资源更少,仍位列总排名第四。当前SOTA模型依赖多阶段、计算密集的训练流程,而我们采用单阶段预训练结合高效后训练的方法,提供了一种经济高效的替代方案;(2)采用持续预训练(CPT)的解码器模型:通过受控课程学习将Qwen3-1.7B和Qwen3-4B模型适配至土耳其法律领域。四阶段CPT配合最优样本比例,实现了从通用语言知识到专业法律术语及长上下文推理的渐进过渡。该方法在土耳其法律文本上实现了36.2%的困惑度降低,证明了领域适应的有效性。

0
下载
关闭预览

相关内容

在搭建网络模型时,需要随机初始化参数,然后开始训练网络,不断调整直到网络的损失越来越小。在训练的过程中,一开始初始化的参数会不断变化。当参数训练到比较好的时候就可以将训练模型的参数保存下来,以便训练好的模型可以在下次执行类似任务时获得较好的结果。
Llama-3-SynE:实现有效且高效的大语言模型持续预训练
专知会员服务
36+阅读 · 2024年7月30日
预训练语言模型fine-tuning近期进展概述
专知会员服务
40+阅读 · 2021年4月9日
专知会员服务
34+阅读 · 2020年11月25日
绝对干货!NLP预训练模型:从transformer到albert
新智元
13+阅读 · 2019年11月10日
自然语言处理中的语言模型预训练方法
PaperWeekly
14+阅读 · 2018年10月21日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
14+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
5+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
4+阅读 · 2014年12月31日
Arxiv
0+阅读 · 2月16日
VIP会员
相关VIP内容
Llama-3-SynE:实现有效且高效的大语言模型持续预训练
专知会员服务
36+阅读 · 2024年7月30日
预训练语言模型fine-tuning近期进展概述
专知会员服务
40+阅读 · 2021年4月9日
专知会员服务
34+阅读 · 2020年11月25日
相关基金
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
14+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
5+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
4+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员