首页> 外国专利> METHOD AND APPARATUS FOR TRAINING LANGUAGE MODEL, ELECTRONIC DEVICE, READABLE STORAGE MEDIUM AND COMPUTER PROGRAM PRODUCT

METHOD AND APPARATUS FOR TRAINING LANGUAGE MODEL, ELECTRONIC DEVICE, READABLE STORAGE MEDIUM AND COMPUTER PROGRAM PRODUCT

机译:用于培训语言模型,电子设备,可读存储介质和计算机程序产品的方法和装置

摘要

A method and apparatus for training a language model, an electronic device, a readable storage medium and a computer program product, which relate to the field of natural language processing technologies in artificial intelligence, are disclosed. The method may include pre-training the language model using preset text language materials in a corpus; replacing at least one word in a sample text language material with a word mask respectively to obtain a sample text language material including at least one word mask; inputting the sample text language material including the at least one word mask into the language model, and outputting a context vector of each of the at least one word mask via the language model; determining a word vector corresponding to each word mask based on the context vector of the word mask and a word vector parameter matrix; and training the language model based on the word vector corresponding to each word mask. Introduction of semantic information representation with greater granularity enhances the capacity of the language model to learn word meaning information and may effectively avoid an information leakage risk possibly caused by character-based full word coverage.
机译:公开了一种用于训练语言模型,电子设备,可读存储介质和计算机程序产品的方法和装置,其涉及人工智能中的自然语言处理技术领域。该方法可以包括使用语料库中的预设文本语言材料进行预培训语言模型;用单词掩码替换至少一个单词,分别使用单词掩码获取示例文本语言材料,包括至少一个单词掩码;将包括至少一个单词掩码的示例文本语言材料输入到语言模型中,并通过语言模型输出每个至少一个单词掩码的上下文向量;基于单词掩码的上下文向量和单词向量参数矩阵确定与每个单词掩码对应的单词矢量;并基于对应于每个单词掩码的单词载体训练语言模型。用更大的粒度引入语义信息表示增强了语言模型的能力,以了解文字意义信息,可以有效地避免可能由基于角色的全文覆盖率引起的信息泄漏风险。

著录项

相似文献

  • 专利
  • 外文文献
  • 中文文献
获取专利

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号