OpenELM: An Efficient Language Model Family with Open Training and Inference Framework

📄 arXiv: 2404.14619v2 📥 PDF

作者: Sachin Mehta, Mohammad Hossein Sekhavat, Qingqing Cao, Maxwell Horton, Yanzi Jin, Chenfan Sun, Iman Mirzadeh, Mahyar Najibi, Dmitry Belenko, Peter Zatloukal, Mohammad Rastegari

分类: cs.CL, cs.AI, cs.LG

发布日期: 2024-04-22 (更新: 2024-05-02)

备注: Minor corrections

🔗 代码/项目: GITHUB | HUGGINGFACE


💡 一句话要点

提出OpenELM以提升大语言模型的可复现性与透明性

🎯 匹配领域: 支柱九:具身大模型 (Embodied Foundation Models)

关键词: 开放语言模型 可复现性 透明性 分层缩放 自然语言处理 模型训练 公开数据集

📋 核心要点

  1. 现有大语言模型的可复现性和透明性不足,限制了研究的深入和结果的可信度。
  2. OpenELM通过分层缩放策略优化参数分配,提升模型准确性,并提供完整的训练框架和数据集。
  3. 在实验中,OpenELM在相同参数预算下实现了2.36%的准确性提升,并减少了预训练所需的标记数量。

📝 摘要(中文)

大语言模型的可复现性和透明性对于推动开放研究至关重要,有助于确保结果的可信性,并使得对数据和模型偏见及潜在风险的调查成为可能。为此,我们发布了OpenELM,一个最先进的开放语言模型。OpenELM采用分层缩放策略,在每层有效分配参数,从而提高准确性。例如,在大约十亿参数的预算下,OpenELM相比OLMo在准确性上提升了2.36%,同时所需的预训练标记减少了2倍。与以往仅提供模型权重和推理代码的做法不同,我们的发布包括完整的训练和评估框架,涵盖公开数据集的训练日志、多个检查点和预训练配置,旨在增强开放研究社区的能力。

🔬 方法详解

问题定义:本论文旨在解决大语言模型在可复现性和透明性方面的不足,现有方法通常仅提供模型权重和推理代码,缺乏完整的训练框架和公开数据集的支持。

核心思路:OpenELM的核心思路是采用分层缩放策略,以更高效的方式在每层中分配参数,从而提升模型的准确性和训练效率。这样的设计使得模型在保持较小参数量的同时,依然能够实现较高的性能。

技术框架:OpenELM的整体架构包括多个模块,主要包括数据预处理、模型训练、评估和推理。模型训练阶段使用公开数据集,并记录训练日志和多个检查点,以便于后续的评估和复现。

关键创新:OpenELM的主要创新在于其分层缩放策略和完整的训练框架,区别于以往仅提供模型权重的做法,增强了模型的可复现性和透明性。

关键设计:在参数设置上,OpenELM在约十亿参数预算内进行优化,采用特定的损失函数和网络结构设计,以实现更高的准确性和更低的预训练标记需求。具体的训练配置和日志也被公开,便于研究者复现和验证。

🖼️ 关键图片

fig_0
fig_1
fig_2

📊 实验亮点

在实验中,OpenELM在约十亿参数预算下实现了2.36%的准确性提升,相比于OLMo模型,且所需的预训练标记数量减少了2倍。这一结果表明,OpenELM在效率和效果上均具有显著优势,能够为开放研究提供有力支持。

🎯 应用场景

OpenELM的研究成果具有广泛的应用潜力,尤其是在自然语言处理、对话系统和文本生成等领域。通过提供开放的训练框架和模型,研究者可以更方便地进行模型的改进和应用,推动相关技术的发展。此外,OpenELM的透明性和可复现性将促进学术界和工业界的合作与创新。

📄 摘要(原文)

The reproducibility and transparency of large language models are crucial for advancing open research, ensuring the trustworthiness of results, and enabling investigations into data and model biases, as well as potential risks. To this end, we release OpenELM, a state-of-the-art open language model. OpenELM uses a layer-wise scaling strategy to efficiently allocate parameters within each layer of the transformer model, leading to enhanced accuracy. For example, with a parameter budget of approximately one billion parameters, OpenELM exhibits a 2.36% improvement in accuracy compared to OLMo while requiring $2\times$ fewer pre-training tokens. Diverging from prior practices that only provide model weights and inference code, and pre-train on private datasets, our release includes the complete framework for training and evaluation of the language model on publicly available datasets, including training logs, multiple checkpoints, and pre-training configurations. We also release code to convert models to MLX library for inference and fine-tuning on Apple devices. This comprehensive release aims to empower and strengthen the open research community, paving the way for future open research endeavors. Our source code along with pre-trained model weights and training recipes is available at \url{https://github.com/apple/corenet}. Additionally, \model models can be found on HuggingFace at: \url{https://huggingface.co/apple/OpenELM}.