Scalpel and Brush: Pruning and Targeted Weight Editing of a Small Language Model by a Single LLM Agent
On the map: LLM agents and tool use → Multimodal and embodied agents also fits: Tool learning and function calling
Abstract (arXiv)
It has recently been shown that an LLM can itself edit the weights of a language model, yet it remains unclear which part of such a result is due to the agent and which part is reproduced by a random edit of the same shape, by an instruction in the prompt, or by a standard procedure without an LLM. We unify repair and pruning as sparse weight edits to optimize a metric we specify, using BLEU as an example: three tasks -- targeted weight repair ("brush"), structured MLP neuron pruning ("scalpel", zeroing pruned weights), and layer removal with repair - are assigned to a DeepSeek Harness agent powered by DeepSeek-V4.1-Flash, with up to 50 dev evaluations. We study Qwen2.5-Math-1.5B-Instruct in three independent runs per task, with final evaluation on two hidden splits. On ordinary differential equations, changing at most 0.0084% of weights raised test BLEU by 24-32% on second-order equations and by a factor of 1.8-2.5 on equations with polynomial right-hand sides. An independent substitution check showed that higher BLEU reflects notation alignment rather than improved correctness. Masks that remove 12.5-15% of MLP neurons shrink the model by 9.4-11.2% with mean BLEU loss of at most 0.01 on both hidden splits, whereas standard pruning with equal shares per layer failed the constraint at all tested shares. On seven-class GoEmotions classification, edits raise macro-F1 from 0.100 to 0.396-0.451 on test and from 0.175 to 0.455-0.476 on holdout. A ridge-based classifier written into agent-selected weight rows yields macro-F1 of 0.424 and 0.464. Pruning search with the same evaluation limit removes 15.9% of neurons versus 14-21.4% for agent runs passing the hidden check. Standard procedures without an LLM reproduce much of the performance once given the location and form of intervention found by the agent; a comparison of agentic and non-agentic search remains open.
Key facts. No citing papers in the map yet (data through 24 Nov 2026). Placed in Multimodal and embodied agents, one of 16 directions in LLM agents and tool use. Builds on 25 of its 33 references that are in the map. Submitted 24 Nov 2026, announced 26 Nov 2026.
Builds on
25 of 33 references.
Closest ancestors · 1
Same direction, newest first
Other references · 24
- 2022Locating and Editing Factual Associations in GPTcited by 2,951
- 2015Learning both Weights and Connections for Efficient Neural Networkscited by 2,080
- 2023Representation Engineering: A Top-Down Approach to AI Transparencycited by 1,530
- 2023Steering Llama 2 via Contrastive Activation Additioncited by 1,270
- 2024The AI Scientist: Towards Fully Automated Open-Ended Scientific Discoverycited by 1,249
- 2024Qwen2.5-Math Technical Report: Toward Mathematical Expert Model via Self-Improvementcited by 1,155
- 2023Steering Language Models With Activation Engineeringcited by 1,128
- 2022Mass-Editing Memory in a Transformercited by 1,110
- 2023A Simple and Effective Pruning Approach for Large Language Modelscited by 878
- 2018SNIP: Single-shot Network Pruning based on Connection Sensitivitycited by 832
- 2023LLM-Pruner: On the Structural Pruning of Large Language Modelscited by 686
- 2017Learning Sparse Neural Networks through L0 Regularizationcited by 614
12 more
- 2020GoEmotions: A Dataset of Fine-Grained Emotionscited by 517
- 2024ShortGPT: Layers in Large Language Models are More Redundant Than You Expectcited by 433
- 2023MLAgentBench: Evaluating Language Agents on Machine Learning Experimentationcited by 426
- 2024SliceGPT: Compress Large Language Models by Deleting Rows and Columnscited by 422
- 2020Movement Pruning: Adaptive Sparsity by Fine-Tuningcited by 417
- 2024The Unreasonable Ineffectiveness of the Deeper Layerscited by 254
- 2024SLEB: Streamlining LLMs through Redundancy Verification and Elimination of Transformer Blockscited by 106
- 2026Compiling Activation Steering into Weights via Null-Space Constraints for Stealthy Backdoorscited by 9
- 2025Structured Pruning for Diverse Best-of-N Reasoning Optimizationcited by 6
- 2025Detecting and Pruning Prominent but Detrimental Neurons in Large Language Modelscited by 4
- 2026LLMs can Compress LLMs: Adaptive Pruning by Agentscited by 3
- 2026Reinforcement Learning for Neural Model Editingcited by 1
Built on by
Not cited yet.
Similar, not cited
Close in wording, no citation either way
- 2026Weight Space Programming for Vision Language Model Repair
- 2026Where Does a Weight-Editing Agent Help? Blind Diagnosis and Repair of Deployment Faults in Vision Models
- 2025Improved Methods for Model Pruning and Knowledge Distillation
- 2022Aligned Weight Regularizers for Pruning Pretrained Neural Networks
- 2026Exploring the Limits of Pruning: Task-Specific Neurons, Model Collapse, and Recovery in Task-Specific Large Language Models
- 2026Can LLMs Debug Robots by Editing Their Weights?
- 2026Neurosymbolic LoRA: Why and When to Tune Weights vs. Rewrite Prompts
- 2024Dissecting Language Models: Machine Unlearning via Selective Pruning