语言模型内部知识库的爬行
Crawling the Internal Knowledge-Base of Language Models
摘要:
语言模型是在大量文本上训练的,因此它们的参数可能包含大量的事实知识。由这些模型执行的任何下游任务都隐含地建立在这些事实的基础上,因此非常希望有一种以可解释的方式表示这一知识体系的方法。然而,目前还没有这种代表机制。在这里,我们建议通过从给定的语言模型中提取事实的知识图来解决这个目标。我们描述了一个过程“爬行”的内部知识库的语言模型。具体来说,给定一个种子实体,我们围绕它扩展一个知识图。爬行过程被分解为子任务,通过专门设计的提示来实现,这些提示控制精度(即,不产生错误事实)和回忆(即,产生的事实数)。我们评估了从几十个种子实体开始爬取的图的方法,并表明它产生了高精度的图(82-92%),同时每个实体发出合理数量的事实。
英文摘要:
Language models are trained on large volumes of text, and as a result their parameters might contain a significant body of factual knowledge. Any downstream task performed by these models implicitly builds on these facts, and thus it is highly desirable to have means for representing this body of knowledge in an interpretable way. However, there is currently no mechanism for such a representation. Here, we propose to address this goal by extracting a knowledge-graph of facts from a given language model. We describe a procedure for ``crawling'' the internal knowledge-base of a language model. Specifically, given a seed entity, we expand a knowledge-graph around it. The crawling procedure is decomposed into sub-tasks, realized through specially designed prompts that control for both precision (i.e., that no wrong facts are generated) and recall (i.e., the number of facts generated). We evaluate our approach on graphs crawled starting from dozens of seed entities, and show it yields high precision graphs (82-92%), while emitting a reasonable number of facts per entity.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。