用数学语言解析大模型如何理解与生成文本
Large Language Models: A Mathematical Formulation
- 从信息论与概率角度构建文本编码与预测的数学模型
- 揭示大模型在问答、写作等任务中的算法实现机制
- 适合想深入理解大模型原理的研究者与工程师
大型语言模型通过处理和预测包含文本的序列来回答问题,并完成文档摘要、推荐、编程及解决定量问题等任务。本文通过描述文本序列到标记序列的编码方式,定义下一标记预测模型的架构,解释模型如何从数据中学习,并展示其在多种任务中的部署方法,建立了一个数学框架。该框架基于信息论、概率和优化等基础数学概念,虽数学复杂度不高,但整合多个学科思想形成复杂的算法结构,已展现出显著的实证成功。该框架为提出并解答关于模型准确性、效率与鲁棒性的问题提供了平台,并指明了改进与创新方法的方向。
原文摘要 · Abstract (English)
Large language models (LLMs) process and predict sequences containing text to answer questions, and address tasks including document summarization, providing recommendations, writing software and solving quantitative problems. We provide a mathematical framework for LLMs by describing the encoding of text sequences into sequences of tokens, defining the architecture for next-token prediction models, explaining how these models are learned from data, and demonstrating how they are deployed to address a variety of tasks. The mathematical sophistication required to understand this material is not high, and relies on straightforward ideas from information theory, probability and optimization. Nonetheless, the combination of ideas resting on these different components from the mathematical sciences yields a complex algorithmic structure; and this algorithmic structure has demonstrated remarkable empirical successes. The mathematical framework established here provides a platform from which it is possible to formulate and address questions concerning the accuracy, efficiency and robustness of the algorithms that constitute LLMs. The framework also suggests directions for development of modified and new methodologies.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。