noteslearnings

When does abstraction reduce complexity?

Simple Made Easy resonated with me, but left questions about tests and abstraction. I want to look beyond code that looks alike to why it must change together.

The distinction between easy and simple in Simple Made Easy resonated with me. AI has made features easier to build, but that does not necessarily make the results easier to understand and change. Seeing simplicity as a lack of entanglement gave a name to discomfort I had felt at work.

In particular, it brought back experiences where premature abstraction added complexity. Similar code was grouped together, then growing differences in requirements led to more options and branches. Yet leaving duplication indefinitely is not an answer either. When does bringing things together help?

For now, I want to ask whether things change for the same reason, rather than whether they look alike. If the reasons differ, I would keep them independently understandable. If changing the same rule in several places leads to inconsistency, there is a reason to bring it together. More than the appearance of separate files or classes, what matters to me is whether changing one place requires understanding the circumstances of another.

I also agreed with the criticism of developing as though guardrails make it fine to keep crashing into them. Tests catching errors do not justify changing code without understanding where it is going. AI repeatedly failing tests and fixing them seemed to overlap with that criticism.

Questions remained, though. Could writing tests first help make the intended behavior concrete? Could AI use feedback from failure to make a better next attempt? I still want to think more about whether reaching passing tests is the same as understanding structure and reducing entanglement.

I also noticed how often queues had appeared in my earlier studies. On the frontend, they could separate requests for uploads or autosaves from the time they execute. But someone still has to own cancellation, retries, and ordering. Whether adding an abstraction or a queue, I want to ask what the new structure separates and what coordination it requires in return.

Lecture: Simple Made Easy, Rich Hickey