Recursive Self-Editing
Recursive Self-Editing: LLMs Program Their Own Weight Edits for Self-ImprovementA language model improves itself by inspecting its own weights and writing Python programs to construct low-rank weight edits without gradient descent.

The SELFWRITE model inspects its own weights and activations to write Python programs that construct low-rank weight edits for itself. The best edits are merged into the model's weights, resulting in a successor that is better at solving math problems and writing subsequent edits.
- Model inspects its own weights
- Writes Python program to edit weights
- Merges best edits into its weights
- Successor model writes better edits
- Model inspects its own weights
- Writes Python program to edit weights
- Merges best edits into its weights
- Successor model writes better edits
Why it is a road to recursion
Allowing models to directly program their own weight updates bypasses the need for gradient descent and opens a new avenue for recursive self-improvement.
Evidence
Five generations of SELFWRITE on Qwen3.8-27B raised gate accuracy from 73.95% to 76.45%.
Related loops
More self-modifying agents →
- Coding agent edits its own code
- Scored child agents enter the archive
- Archived agents make later self modifications
- repeat

- Claude Code writes its own code changes
- Changes become next Claude Code versions
- Release becomes harness for next development round
- repeat

- Model diagnoses its own failure
- Model computes weight edits
- Model applies edits to itself
- Model answers new questions better
- repeat