Our new X account is live! Follow @wizwand_team for updates
WorkDL logo mark

AnyEdit: Edit Any Knowledge Encoded in Language Models

About

Large language models (LLMs) often produce incorrect or outdated information, necessitating efficient and precise knowledge updates. Current model editing methods, however, struggle with long-form knowledge in diverse formats, such as poetry, code snippets, and mathematical derivations. These limitations arise from their reliance on editing a single token's hidden state, a limitation we term "efficacy barrier". To solve this, we propose AnyEdit, a new autoregressive editing paradigm. It decomposes long-form knowledge into sequential chunks and iteratively edits the key token in each chunk, ensuring consistent and accurate outputs. Theoretically, we ground AnyEdit in the Chain Rule of Mutual Information, showing its ability to update any knowledge within LLMs. Empirically, it outperforms strong baselines by 21.5% on benchmarks including UnKEBench, AKEW, and our new EditEverything dataset for long-form diverse-formatted knowledge. Additionally, AnyEdit serves as a plug-and-play framework, enabling current editing methods to update knowledge with arbitrary length and format, significantly advancing the scope and practicality of LLM knowledge editing.

Houcheng Jiang, Junfeng Fang, Ningyu Zhang, Guojun Ma, Mingyang Wan, Xiang Wang, Xiangnan He, Tat-seng Chua• 2025

Related benchmarks

TaskDatasetResultRank
Image EditingImgEdit-Bench
Overall Score2.45
132
Image EditingGEdit-Bench English
G_O (Overall Quality)3.21
73
Image EditingKRIS-Bench
Factual Knowledge Score39.26
65
Instruction-based Image EditingImgEdit Bench 1.0 (test)
Add Score3.18
37
Knowledge EditingUnKEBench Original questions
BERTScore99.86
18
Knowledge EditingUnKEBench Paraphrased questions (Para.)
Bert Score96.6
18
Medical Knowledge EditingMedMCQA edit
Efficacy36.6
18
Medical Knowledge EditingMedExQA edit
Efficacy39.1
18
Question AnsweringAKEW
Precision38.24
16
Unstructured Knowledge EditingAKEW Com.
ROUGE-L Precision23.68
16
Showing 10 of 24 rows

Other info

Code

Follow for update