The factual knowledge acquired during pre-training and stored in the parameters of Language Models (LMs) can be useful in downstream tasks (e.g., question answering or textual inference). However, some facts can be incorrectly induced or become obsolete over time. We present KnowledgeEditor, a method which can be used to edit this knowledge and, thus, fix 'bugs' or unexpected predictions without the need for expensive re-training or fine-tuning. Besides being computationally efficient, KnowledgeEditordoes not require any modifications in LM pre-training (e.g., the use of meta-learning). In our approach, we train a hyper-network with constrained optimization to modify a fact without affecting the rest of the knowledge; the trained hyper-network is then used to predict the weight update at test time. We show KnowledgeEditor's efficacy with two popular architectures and knowledge-intensive tasks: i) a BERT model fine-tuned for fact-checking, and ii) a sequence-to-sequence BART model for question answering. With our method, changing a prediction on the specific wording of a query tends to result in a consistent change in predictions also for its paraphrases. We show that this can be further encouraged by exploiting (e.g., automatically-generated) paraphrases during training. Interestingly, our hyper-network can be regarded as a 'probe' revealing which components need to be changed to manipulate factual knowledge; our analysis shows that the updates tend to be concentrated on a small subset of components. Source code available at https://github.com/nicola-decao/KnowledgeEditor
Locate-then-edit for Multi-hop Factual Recall under Knowledge Editing
Peking University(北京大学);Provable Responsible AI and Data Analytics (PRADA) Lab(可验证负责任人工智能与数据分析(PRADA)实验室);King Abdullah University of Science and Technology(阿卜杜拉国王科技大学);South China University of Technology(华南理工大学)
School of Computer Science and Technology, Beijing Institute of Technology(北京理工大学计算机科学与技术学院);School of Computer Science and Engineering, Beihang University(北京航空航天大学计算机科学与工程学院)
Editing Factual Knowledge and Explanatory Ability of Medical Large Language Models
University of Science and Technology of China(中国科学技术大学);City University of Hong Kong(香港城市大学);Jarvis Research Center(贾维斯研究中心);Tencent YouTu Lab(腾讯优图实验室);Peking University(北京大学)
Assessing Knowledge Editing in Language Models via Relation Perspective
University of Chinese Academy of Sciences(中国科学院大学);Institute of Automation, CAS(中国科学院自动化研究所);Kunming University of Science and Technology(昆明理工大学);Beijing Institute of Technology(北京理工大学)
REACT: Representation Extraction And Controllable Tuning to Overcome Overfitting in LLM Knowledge Editing
NLPR, MAIS, Institute of Automation, Chinese Academy of Sciences(中国科学院自动化研究所国家信息处理实验室、人工智能研究所);Cuiying Honors College, Lanzhou University(兰州大学萃英荣誉学院);Department of Mathematics, The Chinese University of Hong Kong(香港中文大学数学系);Tencent(腾讯)
KEditVis: A Visual Analytics System for Knowledge Editing of Large Language Models
Zhejiang University(浙江大学);State Key Lab of CAD&CG, Zhejiang University(浙江大学CAD&CG国家重点实验室);Hong Kong University of Science and Technology(香港科技大学);School of Software Engineering, South China University of Technology(华南理工大学软件学院);School of Software Technology, Zhejiang University(浙江大学软件学院)
Reasoning Factual Knowledge in Structured Data with Large Language Models
Hong Kong Polytechnic University(香港理工大学);University Technology Sydney(悉尼科技大学);The Hong Kong University of Science and Technology (Guangzhou)(香港科技大学(广州));Soochow University(苏州大学);The Education University of Hong Kong(香港教育大学)
Unveiling Factual Recall Behaviors of Large Language Models through Knowledge Neurons
Institute of Automation, Chinese Academy of Sciences(中国科学院自动化研究所);University of Chinese Academy of Sciences(中国科学院大学);Beijing Wenge Technology Co., Ltd(北京文格科技有限公司)
Related Knowledge Perturbation Matters: Rethinking Multiple Pieces of Knowledge Editing in Same-Subject
Institute of Computing Technology, Chinese Academy of Sciences(中国科学院计算技术研究所);University of Chinese Academy of Sciences(中国科学院大学);People’s Public Security University of China(中国人民公安大学)
Orthogonal Representation Editing: Decoupling Semantic Entanglement in Batch Knowledge Editing of LLMs
School of Computer Science and Technology, Tianjin University(天津大学计算机科学与技术学院);Kexin Technology(可心科技);University of Chinese Academy of Sciences(中国科学院大学);Tencent Hunyuan(腾讯混元);College of Computer Science, Chongqing University(重庆大学计算机学院)
MILA - Quebec AI Institute(MILA - 魁北克人工智能研究所);Microsoft(微软公司);UNC Chapel Hill(北卡罗来纳大学教堂山分校);North Carolina State University(北卡罗来纳州立大学);Massachusetts Institute of Technology(麻省理工学院);Google DeepMind(谷歌DeepMind)
Cracking Factual Knowledge: A Comprehensive Analysis of Degenerate Knowledge Neurons in Large Language Models
Institute of Automation, Chinese Academy of Sciences(中国科学院自动化研究所);Unisound(云知声);The Laboratory of Cognition and Decision Intelligence for Complex Systems(复杂系统认知与决策智能实验室)
Commonsense Knowledge Editing Based on Free-Text in LLMs
Institute of Automation, Chinese Academy of Sciences(中国科学院自动化研究所);School of Artificial Intelligence, University of Chinese Academy of Sciences(中国科学院大学人工智能学院);Beijing Academy of Artificial Intelligence(北京智源人工智能研究院)
Knowledgeable In-Context Tuning: Exploring and Exploiting Factual Knowledge for In-Context Learning
School of Data Science and Engineering, East China Normal University(华东师范大学数据科学与工程学院);Alibaba Group(阿里巴巴集团);School of Statistics, East China Normal University(华东师范大学统计学院)
Is Factuality Enhancement a Free Lunch For LLMs? Better Factuality Can Lead to Worse Context-Faithfulness
Institute of Computing Technology, CAS(中国科学院计算技术研究所);University of Chinese Academy of Sciences(中国科学院大学);University of California, Merced(加州大学默塞德分校);University of Science and Technology of China(中国科学技术大学)
RGAR: Recurrence Generation-augmented Retrieval for Factual-aware Medical Question Answering
King’s College London(伦敦国王学院);School of Electronic Information and Electrical Engineering, Shanghai Jiao Tong University(上海交通大学电子信息与电气工程学院);School of Electrical and Computer Engineering, Carnegie Mellon University(卡内基梅隆大学电气与计算机工程学院)
Large Language Models, scientific knowledge and factuality: A framework to streamline human expert evaluation
National Biomarker Centre, CRUK-MI, Univ. of Manchester(英国曼彻斯特大学CRUK-MI国家生物标志物中心);Idiap Research Institute(Idiap研究所);Inflamalps SA(因弗马尔普斯公司);Department of Computer Science, Univ. of Manchester(英国曼彻斯特大学计算机科学系)
Unveiling the Pitfalls of Knowledge Editing for Large Language Models
College of Computer Science and Technology, Zhejiang University(浙江大学计算机科学与技术学院);ZJU-Ant Group Joint Research Center for Knowledge Graphs, Zhejiang University(浙江大学-蚂蚁集团知识图谱联合研究中心);ZJU-Hangzhou Global Scientific and Technological Innovation Center, Zhejiang University(浙江大学杭州国际科技创新中心);Tencent(腾讯)
Latent Knowledge Scalpel: Precise and Massive Knowledge Editing for Large Language Models
Institute of Information Engineering, Chinese Academy of Sciences(中国科学院信息工程研究所);School of Cyber Security, University of Chinese Academy of Sciences(中国科学院大学网络安全学院);Tsinghua University(清华大学);University of Electronic Science and Technology of China(电子科技大学)
Can LLMs Refuse Questions They Do Not Know? Measuring Knowledge-Aware Refusal in Factual Tasks
Department of Computer Science, City University of Hong Kong(香港城市大学计算机科学系);Harbin Institute of Technology(哈尔滨工业大学);College of Computing and Data Science, Nanyang Technological University(南洋理工大学计算机与数据科学学院);School of Computer Science and Engineering, Central South University(中南大学计算机科学与工程学院)
Visual-Oriented Fine-Grained Knowledge Editing for MultiModal Large Language Models
Hefei University of Technology(合肥工业大学);University of Science and Technology of China(中国科学技术大学);Hefei Comprehensive National Science Center(合肥综合性国家科学中心)