Handcrafting Codes← Index

AI

What LLMs Can't Refactor (Yet)

Models are extraordinary at local edits and strangely helpless at the changes that actually matter. The gap is instructive.

May 28, 2026 / 1 min read / By the author

COVER IMAGE — 16:9

Hand a model a function and it will tidy it beautifully. Hand it a system and ask where the seams should move, and it stalls — politely, confidently, and wrongly.

Local genius, global blindness

Refactoring that matters is rarely about a single function. It is about deciding which module should own a responsibility, which boundary is in the wrong place, which abstraction has quietly become a liability. Those judgments require holding intent, history, and tradeoffs at once — exactly the context a model does not have.

The lesson is not that models are weak. It is that the valuable part of the job was never the typing. It was the deciding.