Large Language Model Editing via Gradient Tracing and ROME

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing large language models become outdated with new information, requiring editing without labeled data, and existing methods struggle with editing arbitrary propositions without subject labels.

Innovation Solution

A language model editing framework using Gradient Tracing to locate factual knowledge and Rank-One Model Editing (ROME) to edit transformer neural networks, enabling editing of arbitrary propositions without subject labels.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Loss of information

If large language models are trained with new data to update knowledge, then the model becomes current with new information, but the model loses previously learned factual knowledge and requires extensive retraining

Engineering Contradiction:
Improvefactual knowledge retentionVSAvoidretraining time
Core Design Contradiction:
Loss of informationVSLoss of time

Solution Approach 1:

The patent extracts and modifies only the specific neural network components responsible for outdated factual knowledge rather than retraining the entire model. By identifying and isolating the relevant weights and parameters associated with specific facts, the system can update individual knowledge points without affecting other learned information, thus avoiding the need for extensive retraining while preserving both new and existing factual knowledge.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

The patent applies local quality by making different parts of the neural network have different functions - specific regions are designated for storing and updating particular factual knowledge. This allows targeted editing of specific facts by modifying only the local weights and parameters associated with those facts, while leaving the rest of the model intact. This localized approach enables efficient knowledge updates without global retraining.

Inventive Principle:
Principle #3Local quality

2Adaptability or versatility

If existing editing methods are used to update large language models, then the model can be edited with labeled data, but the methods cannot edit arbitrary propositions without subject labels

Engineering Contradiction:
Improveediting capability for arbitrary propositionsVSAvoidediting framework complexity
Core Design Contradiction:
Adaptability or versatilityVSDevice complexity

Solution Approach 1:

The patent implements a universal editing framework that can handle multiple types of propositions and knowledge updates through a single unified approach. The system uses generalizable components including a proposition parser, knowledge graph builder, and neural network editor that work together to edit any factual proposition regardless of subject type. This multi-functional design enables the system to edit arbitrary propositions without requiring subject-specific customization while maintaining manageable complexity through modular architecture.

Inventive Principle:
Principle #6Universality (Multi-functionality)

3Loss of information

If the entire large language model is retrained to update knowledge, then all factual knowledge can be updated, but the computational resources and time required become prohibitive

Engineering Contradiction:
Improvefactual knowledge accuracyVSAvoidcomputational energy consumption
Core Design Contradiction:
Loss of informationVSUse of energy by moving object

Solution Approach 1:

The patent extracts only the specific neural network weights and parameters related to the factual knowledge that needs updating, rather than processing the entire model. By identifying and isolating the relevant components through knowledge graph mapping and gradient-based attribution, the system updates only the necessary parameters, dramatically reducing computational energy consumption while maintaining factual knowledge accuracy.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

The patent applies partial action by performing incomplete but sufficient updates - instead of retraining the entire model to ensure all knowledge is current, the system updates only the specific facts that are outdated or incorrect. This partial approach achieves the necessary factual knowledge accuracy for the target propositions without the excessive computational cost of full model retraining.

Inventive Principle:
Principle #16Partial or excessive action

Data Source

PatentUS12530541B2Systems and methods for editing a large language model
Publication Date: 2026.01.20 SALESFORCE INC
  • US12530541B2 patent drawing
  • US12530541B2 patent drawing
  • US12530541B2 patent drawing

AI summary

Systems and methods for editing a large language model are provided. The large language model generates a sequence of tokens, a first probability of a pre-edit output based on the sequence of tokens, and a second probability of a target output based on the sequence of tokens. A loss function is provided based on the first probability and the second probability. A plurality of gradients of the large language model with respect to the loss function is computed. An edit location of the large language model is determined based on the plurality of gradients. The large language model is edited by editing weights at the edit location of the large language model, such that the updated large language model generates the target output for an input including the sequence of words.