当前位置:   article > 正文

【Datawhale课程笔记-简单学点大模型】引言_大模型课程

大模型课程

参考课程GITHUB地址:https://github.com/datawhalechina/so-large-lm

引言

什么是语言模型

语言模型(LM)的经典定义是一种对令牌序列(token)的概率分布。假设我们有一个令牌集的词汇表 V V V 。语言模型p为每个令牌序列 x 1 , . . . , x L x_{1},...,x_{L} x1,...,xL V V V 分配一个概率(介于0和1之间的数字):

p ( x 1 , … , x L ) p(x_1, \dots, x_L) p(x1,,xL)

概率直观地告诉我们一个标记序列有多“好(good)”。例如,如果词汇表为{ate, ball, cheese, mouse, the},语言模型可能会分配以下概率(演示):

p ( the, mouse, ate, the, lcheese ) = 0.02 , p(\text{the, mouse, ate, the, lcheese}) = 0.02, p(the, mouse, ate, the, lcheese)=0.02,

p ( the, cheese ate, the, lcheese ) = 0.02 , p(\text{the, cheese ate, the, lcheese}) = 0.02, p(the, cheese ate, the, lcheese)=0.02,

p ( mouse, the, the, cheese, ate ) = 0.02 , p(\text{mouse, the, the, cheese, ate}) = 0.02, p(mouse, the, the, cheese, ate)=0.02,

从数学上讲,语言模型是一个非常简单而又美妙的对象。但是这种简单是具有欺骗性的:赋予所有序列以(有意义的)概率的能力,该能力要求语言模型具有非凡的(但是隐含的)语言能力和世界知识。

例如,语言模型应该隐含地赋予"

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/正经夜光杯/article/detail/968531
推荐阅读
相关标签