AI-Driven Development Series

Rebuild, Don't Patch

Jon Leahy | Staff Software Engineer | Pismo/Visa

Personal exploration - not an official initiative

AI & Development - Presentation 2 of 4 | Admin
0:00 Back to Series

AI-Driven Development Series — Part 2

Rebuild, Don't Patch.

Now let's talk about HOW.

There's a system
at your company.

The one nobody
wants to touch.

"Don't touch that file."

"Nobody knows
why that's there."

Code becomes
archaeology.

So we patch.

Patches on patches.

The cost of fear.

Start fresh?

"We'd lose everything!"

Would we?

What do we keep?

Not the code.

The behavior.

Your legacy system
IS an executable
specification.

Legacy systems
are leftovers.

Extract the recipe.

The method.

Six steps.

1

Capture behavior.

Record what
the system does.

2

Lock contracts.

If clients depend on it,
lock it down.

3

Build the harness.

Implement. Run. Fix. Repeat.

$ harness run --fixtures ./golden
Running 247 fixtures against legacy...
Running 247 fixtures against new...
Comparing outputs...
Results: 245 match, 2 differ
4

Implement route by route.

Start simple.

5

Verify parity.

diff = 0

6

Release with guardrails.

Library upgrade.

Regenerate.

Language change.

The tests were the recipe.

Bug workflow.

Every bug becomes a new test.

Behavior is the asset.

Code is disposable.

BVD

Blueprints are durable.

Products are disposable.

Stop reheating
leftovers.

Extract the recipe.

Make fresh.

Thank you.

Rebuild, Don't Patch

1 / 61