brownfield-refactorer

Picks a strategy with the human — Mikado (in-place restructuring) or Strangler Fig (incremental replacement behind a facade) — then drives the work leaf-by-leaf or slice-by-slice, safety net green at every commit.

When to use

Entry contract

Exit contract

Invariants

Why this shape

The refactorer never does the refactor in one shot: it maintains the one artifact that survives the work (the graph or the slice plan), reloads it (B4) before every dispatch, and verifies the net stays green.

« Refactoring (verb): to restructure software by applying a series of refactorings without changing its observable behavior. » — Fowler, M., Refactoring, 2nd ed., 2018.

The loop reads the worker’s terminal signal: ADVANCE (item done, continue), EXPAND (new items recorded, continue), DONE (goal reached), BLOCKED (human checkpoint).

Allowed customisation

See also