search
HomeTechnology peripheralsAIICML 2024 | The new frontier of large language model pre-training: 'Best Adaptation Packaging' reshapes document processing standards

ICML 2024 | 大语言模型预训练新前沿:「最佳适配打包」重塑文档处理标准
The AIxiv column is a column where this site publishes academic and technical content. In the past few years, the AIxiv column of this site has received more than 2,000 reports, covering top laboratories from major universities and companies around the world, effectively promoting academic exchanges and dissemination. If you have excellent work that you want to share, please feel free to contribute or contact us for reporting. Submission email: liyazhou@jiqizhixin.com; zhaoyunfeng@jiqizhixin.com

##In the training process of large language models, the way of data processing is crucial important.

#Traditional methods usually splice and split a large number of documents into training sequences equal to the context length of the model. Although this improves training efficiency, it often leads to unnecessary truncation of documents, damages data integrity, and leads to the loss of key contextual information, which in turn affects the logical coherence and factual consistency of the content learned by the model, and makes the model easier to Hallucinations.

Researchers at AWS AI Labs conducted an in-depth study of this common splicing-chunking text processing method and found that it seriously affects the model's understanding of contextual coherence and facts. The ability to be consistent. This not only affects the model's performance on downstream tasks, but also increases the risk of hallucinations.

In response to this problem, they proposed an innovative document processing strategy - Best-fit Packing (Best-fit Packing), which eliminates the problem by optimizing document combinations. Unnecessary text truncation, significantly improves model performance and reduces model artifacts. This research has been accepted into ICML 2024.

ICML 2024 | 大语言模型预训练新前沿:「最佳适配打包」重塑文档处理标准

Article title: Fewer Truncations Improve Language Modeling
Paper link: https://arxiv.org/pdf/2404.10830

Research background

In the traditional large language model training method, in order to improve efficiency , researchers typically splice together multiple input documents and then split these spliced ​​documents into fixed-length sequences.

Although this method is simple and efficient, it will cause a major problem - document truncation (document truncation), damaging data integrity (data integrity). Document truncation results in a loss of information contained in the document.

Additionally, document truncation reduces the amount of context in each sequence, potentially causing the prediction of the next word to be irrelevant to the previous one, making the model more susceptible to hallucinations ( hallucination).

The following example shows the problems caused by document truncation:

  • Figure 2 (a): In Python programming, although the original code is correct, splitting the definition and use of variables into different training sequences will introduce syntax errors, causing some variables to be undefined in subsequent training sequences, causing the model to learn errors patterns and may produce hallucinations in downstream tasks. For example, in program synthesis tasks, a model may use variables directly without defining them.
  • Figure 2(b): Truncation also damages the integrity of the information. For example, "Monday morning" in the summary cannot match any context in the training sequence, resulting in inaccurate content. This kind of incomplete information will significantly reduce the sensitivity of the model to contextual information, causing the generated content to be inconsistent with the actual situation, which is the so-called unfaithful generation.
  • Figure 2(c): Truncation also hinders knowledge acquisition during training, because the representation of knowledge in text often relies on complete sentences or paragraphs. For example, the model cannot learn the location of the ICML conference because the conference name and location are distributed in different training sequences.
ICML 2024 | 大语言模型预训练新前沿:「最佳适配打包」重塑文档处理标准

Figure 2. Example of document truncation leading to illusion or loss of knowledge. (a) The variable definition (blue part) is truncated and subsequent usage calls result in an undefined name (red part). (b) Key contextual information is truncated (blue part), making the summary less accurate than the original text (red part). (c) Due to truncation, the model does not know where ICML 2024 will be held.

Best-fit Packing

To address this problem, researchers proposed Best-fit Packing.

This method uses length-aware combinatorial optimization techniques to efficiently pack documents into training sequences, completely eliminating unnecessary truncation. This not only maintains the training efficiency of traditional methods, but also substantially improves the quality of model training by reducing data fragmentation.

#The author first splits each text into one or more sequences up to the length of the model context length L. The limitation of this step comes from the model, so it must be carried out.

Now, based on a large number of file blocks that are at most L in length, researchers hope to combine them reasonably and obtain as few training sequences as possible. This problem can be viewed as a Bin Packing problem. The assembly optimization problem is NP-hard. As shown in the algorithm below, here they adopt the heuristic strategy of Best-Fit-Decreasing (BFD).

Next, we will discuss the feasibility of BFD from the perspective of time complexity (Time Complexity) and compactness (Compactness).

ICML 2024 | 大语言模型预训练新前沿:「最佳适配打包」重塑文档处理标准

Time complexity:

Sorting sum of BFD The time complexity of packaging is O(N log N), where N is the number of document blocks. In pre-training data processing, since the length of the document block is an integer and limited ([1, L]), count sort can be used to reduce the time complexity of sorting to O(N).

In the packaging phase, by using the data structure of the segment tree, each operation of finding the best-fitting container only takes logarithmic time, that is, O (log L). And because L

ICML 2024 | 大语言模型预训练新前沿:「最佳适配打包」重塑文档处理标准

Compactness:

##Compactness is another important factor in measuring the effectiveness of the packaging algorithm Indicators, it is necessary to reduce the number of training sequences as much as possible to improve the efficiency of model training without destroying the integrity of the original document.

In practical applications, by precisely controlling the filling and arrangement of sequences, best-fit packing can generate an almost equivalent number of training sequences as traditional methods, while significantly reducing Data loss due to truncation is eliminated.

ICML 2024 | 大语言模型预训练新前沿:「最佳适配打包」重塑文档处理标准

Based on experiments on natural language (RefinedWeb) and programming language (The Stack) data sets, we found that best-fit packaging significantly reduces text truncation.

It is worth noting that most documents contain less than 2048 tokens; due to the truncation caused by traditional splicing-blocking mainly occurs in this range, Best-fit packaging will not truncate any document with a length less than L, thus effectively maintaining the integrity of the vast majority of documents.

ICML 2024 | 大语言模型预训练新前沿:「最佳适配打包」重塑文档处理标准

Figure 4: When the maximum sequence length is set to 2k or 8k, under different document lengths, the number of documents and the number of truncation corresponding to each document length. After using the "Best-fit Packing" technology, the number of truncation is significantly reduced. Above: Natural language. Below: Programming languages.

##Experiments and results

Researchers reported in detail the performance comparison of language models trained using best-fit packaging and traditional methods (i.e. splicing methods) on different tasks, including: natural language processing and programming language tasks, such as reading comprehension (Reading Comprehension), Natural Language Inference (Natural Language Inference), Context Following (Context Following), Text Summarization (Summarization), World Knowledge (Commonsense and Closed-book QA) and Program Synthesis (Program Synthesis), a total of 22 subtasks.

The experiments involved model sizes ranging from 7 billion to 13 billion parameters, sequence lengths from 2,000 to 8,000 tokens, and data sets covering natural languages ​​and programming languages. These models are trained on large-scale datasets such as Falcon RefinedWeb and The Stack, and experiments are conducted using the LLaMA architecture.

ICML 2024 | 大语言模型预训练新前沿:「最佳适配打包」重塑文档处理标准

Experimental results show that using optimal adaptation packaging improves model performance in a series of tasks, especially in reading comprehension (4.7%), natural language reasoning ( The performance is significant in tasks such as 9.3%), context following (16.8%) and program synthesis (15.0%) (Due to the different scales of metrics for different tasks, the author defaults to relative improvement to describe the results.)

After statistical testing, the researchers found that all results were either statistically significantly better than the baseline (marked as s) or on par with the baseline (marked as n), and in all evaluated tasks, using No significant performance degradation was observed for any of the best-fit packings.

This improvement in consistency and monotonicity highlights that optimal adaptation packaging can not only improve the overall performance of the model, but also ensure the performance under different tasks and conditions. stability. Please refer to the text for detailed results and discussions.

ICML 2024 | 大语言模型预训练新前沿:「最佳适配打包」重塑文档处理标准

ICML 2024 | 大语言模型预训练新前沿:「最佳适配打包」重塑文档处理标准

ICML 2024 | 大语言模型预训练新前沿:「最佳适配打包」重塑文档处理标准

ICML 2024 | 大语言模型预训练新前沿:「最佳适配打包」重塑文档处理标准

##

The authors focused on the impact of best-fit packaging on illusion.

In summary generation, using the QAFactEval metric it was found that models using best-fit packaging had a significantly lower in generating hallucinations.

More significantly, in the program synthesis task, when using the best-fit packaged trained model to generate code, the "Undefined Name" The error was reduced by up to 58.3%, which shows that the model has a more complete understanding of the program structure and logic, thereby effectively reducing hallucinations.

#The authors also reveal differences in the model’s performance when dealing with different types of knowledge.

As mentioned earlier, truncation during training may affect the integrity of the information, thereby hindering the acquisition of knowledge. But the questions in most standard assessment sets focus on common knowledge, which occurs frequently in human language. So even if some knowledge is lost due to truncation, the model still has a good chance of learning this information from the document fragments.

In contrast, uncommon
tail knowledge
is more susceptible to truncation because this type of information is in the training data The frequency of occurrence itself is low, and it is difficult for the model to supplement the lost knowledge from other sources.

By analyzing the results of the two test sets ARC-C and ARC-E, the researchers found that compared to ARC-E, which contains more common knowledge, using Optimal fit packaging will result in a more significant performance improvement in the model in ARC-C, which contains more tail knowledge.

This finding was further verified by counting the number of co-occurrences of each question-answer pair in Kandpal et al. (2023) preprocessed Wikipedia entity map . Statistical results show that the challenge set (ARC-C) contains more rare co-occurring pairs, which verifies the hypothesis that optimal adaptation packaging can effectively support tail knowledge learning, and also explains why traditional large language models are unable to learn long-tail knowledge. provides an explanation for the difficulties encountered.

ICML 2024 | 大语言模型预训练新前沿:「最佳适配打包」重塑文档处理标准

Summary

##This article proposes large-scale language model training Common document truncation problem.
This truncation effect affects the model's ability to learn logical coherence and factual consistency, and increases the hallucination phenomenon during the generation process. The authors proposed Best-fit Packing, which maximizes the integrity of each document by optimizing the data sorting process. This method is not only suitable for processing large-scale data sets with billions of documents, but is also on par with traditional methods in terms of data compactness.
Experimental results show that this method is extremely effective in reducing unnecessary truncation, and can significantly improve the performance of the model in various text and code tasks, while effectively reducing The illusion of closed-domain language generation. Although the experiments in this paper mainly focus on the pre-training stage, optimal adaptation packaging can also be widely used in other stages such as fine-tuning. This work contributes to the development of more efficient and reliable language models and advances the development of language model training technology.
For more study details, please see the original paper. If you are interested in a job or internship, you can contact the author of this article by email zijwan@amazon.com.

The above is the detailed content of ICML 2024 | The new frontier of large language model pre-training: 'Best Adaptation Packaging' reshapes document processing standards. For more information, please follow other related articles on the PHP Chinese website!

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
4090生成器:与A100平台相比,token生成速度仅低于18%,上交推理引擎赢得热议4090生成器:与A100平台相比,token生成速度仅低于18%,上交推理引擎赢得热议Dec 21, 2023 pm 03:25 PM

PowerInfer提高了在消费级硬件上运行AI的效率上海交大团队最新推出了超强CPU/GPULLM高速推理引擎PowerInfer。PowerInfer和llama.cpp都在相同的硬件上运行,并充分利用了RTX4090上的VRAM。这个推理引擎速度有多快?在单个NVIDIARTX4090GPU上运行LLM,PowerInfer的平均token生成速率为13.20tokens/s,峰值为29.08tokens/s,仅比顶级服务器A100GPU低18%,可适用于各种LLM。PowerInfer与

思维链CoT进化成思维图GoT,比思维树更优秀的提示工程技术诞生了思维链CoT进化成思维图GoT,比思维树更优秀的提示工程技术诞生了Sep 05, 2023 pm 05:53 PM

要让大型语言模型(LLM)充分发挥其能力,有效的prompt设计方案是必不可少的,为此甚至出现了promptengineering(提示工程)这一新兴领域。在各种prompt设计方案中,思维链(CoT)凭借其强大的推理能力吸引了许多研究者和用户的眼球,基于其改进的CoT-SC以及更进一步的思维树(ToT)也收获了大量关注。近日,苏黎世联邦理工学院、Cledar和华沙理工大学的一个研究团队提出了更进一步的想法:思维图(GoT)。让思维从链到树到图,为LLM构建推理过程的能力不断得到提升,研究者也通

复旦NLP团队发布80页大模型Agent综述,一文纵览AI智能体的现状与未来复旦NLP团队发布80页大模型Agent综述,一文纵览AI智能体的现状与未来Sep 23, 2023 am 09:01 AM

近期,复旦大学自然语言处理团队(FudanNLP)推出LLM-basedAgents综述论文,全文长达86页,共有600余篇参考文献!作者们从AIAgent的历史出发,全面梳理了基于大型语言模型的智能代理现状,包括:LLM-basedAgent的背景、构成、应用场景、以及备受关注的代理社会。同时,作者们探讨了Agent相关的前瞻开放问题,对于相关领域的未来发展趋势具有重要价值。论文链接:https://arxiv.org/pdf/2309.07864.pdfLLM-basedAgent论文列表:

大模型也有小偷?为保护你的参数,上交大给大模型制作「人类可读指纹」大模型也有小偷?为保护你的参数,上交大给大模型制作「人类可读指纹」Feb 02, 2024 pm 09:33 PM

将不同的基模型象征为不同品种的狗,其中相同的「狗形指纹」表明它们源自同一个基模型。大模型的预训练需要耗费大量的计算资源和数据,因此预训练模型的参数成为各大机构重点保护的核心竞争力和资产。然而,与传统软件知识产权保护不同,对预训练模型参数盗用的判断存在以下两个新问题:1)预训练模型的参数,尤其是千亿级别模型的参数,通常不会开源。预训练模型的输出和参数会受到后续处理步骤(如SFT、RLHF、continuepretraining等)的影响,这使得判断一个模型是否基于另一个现有模型微调得来变得困难。无

FATE 2.0发布:实现异构联邦学习系统互联FATE 2.0发布:实现异构联邦学习系统互联Jan 16, 2024 am 11:48 AM

FATE2.0全面升级,推动隐私计算联邦学习规模化应用FATE开源平台宣布发布FATE2.0版本,作为全球领先的联邦学习工业级开源框架。此次更新实现了联邦异构系统之间的互联互通,持续增强了隐私计算平台的互联互通能力。这一进展进一步推动了联邦学习与隐私计算规模化应用的发展。FATE2.0以全面互通为设计理念,采用开源方式对应用层、调度、通信、异构计算(算法)四个层面进行改造,实现了系统与系统、系统与算法、算法与算法之间异构互通的能力。FATE2.0的设计兼容了北京金融科技产业联盟的《金融业隐私计算

吞吐量提升5倍,联合设计后端系统和前端语言的LLM接口来了吞吐量提升5倍,联合设计后端系统和前端语言的LLM接口来了Mar 01, 2024 pm 10:55 PM

大型语言模型(LLM)被广泛应用于需要多个链式生成调用、高级提示技术、控制流以及与外部环境交互的复杂任务。尽管如此,目前用于编程和执行这些应用程序的高效系统却存在明显的不足之处。研究人员最近提出了一种新的结构化生成语言(StructuredGenerationLanguage),称为SGLang,旨在改进与LLM的交互性。通过整合后端运行时系统和前端语言的设计,SGLang使得LLM的性能更高、更易控制。这项研究也获得了机器学习领域的知名学者、CMU助理教授陈天奇的转发。总的来说,SGLang的

220亿晶体管,IBM机器学习专用处理器NorthPole,能效25倍提升220亿晶体管,IBM机器学习专用处理器NorthPole,能效25倍提升Oct 23, 2023 pm 03:13 PM

IBM再度发力。随着AI系统的飞速发展,其能源需求也在不断增加。训练新系统需要大量的数据集和处理器时间,因此能耗极高。在某些情况下,执行一些训练好的系统,智能手机就能轻松胜任。但是,执行的次数太多,能耗也会增加。幸运的是,有很多方法可以降低后者的能耗。IBM和英特尔已经试验过模仿实际神经元行为设计的处理器。IBM还测试了在相变存储器中执行神经网络计算,以避免重复访问RAM。现在,IBM又推出了另一种方法。该公司的新型NorthPole处理器综合了上述方法的一些理念,并将其与一种非常精简的计算运行

何恺明和谢赛宁团队成功跟随解构扩散模型探索,最终创造出备受赞誉的去噪自编码器何恺明和谢赛宁团队成功跟随解构扩散模型探索,最终创造出备受赞誉的去噪自编码器Jan 29, 2024 pm 02:15 PM

去噪扩散模型(DDM)是目前广泛应用于图像生成的一种方法。最近,XinleiChen、ZhuangLiu、谢赛宁和何恺明四人团队对DDM进行了解构研究。通过逐步剥离其组件,他们发现DDM的生成能力逐渐下降,但表征学习能力仍然保持一定水平。这说明DDM中的某些组件对于表征学习的作用可能并不重要。针对当前计算机视觉等领域的生成模型,去噪被认为是一种核心方法。这类方法通常被称为去噪扩散模型(DDM),通过学习一个去噪自动编码器(DAE),能够通过扩散过程有效地消除多个层级的噪声。这些方法实现了出色的图

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Tools

mPDF

mPDF

mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),

ZendStudio 13.5.1 Mac

ZendStudio 13.5.1 Mac

Powerful PHP integrated development environment

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Safe Exam Browser

Safe Exam Browser

Safe Exam Browser is a secure browser environment for taking online exams securely. This software turns any computer into a secure workstation. It controls access to any utility and prevents students from using unauthorized resources.