Relative cost matrix Indexed · one change · comparable

Layered C# = 100%. Everything else is a percentage of that.

Figures describe one product-rule change — a new persisted setting, two endpoints, one enforcement check — under the three in-process postures. They are relative, not billed tokenizer dumps. Triplets always read Layered · Modular · Operation-local.

Direction

Token cost · lower is cheaper

60%

Modular reading + implementation vs Layered. Operation-local sits at 86% because the file is dense on purpose.

Developer involvement · lower is cheaper

38%

Files opened to understand Operation-local vs Layered. Modular navigation is 56%.

Correct output · higher is better · estimated

90%

First-pass completeness when a playbook names the file. Layered fan-out scores about 40%. These three figures are estimates, not counts.

Pillar 1 — Token cost lower is cheaper

Reading + implementation

Layered100%
Modular60%
Operation-local86%

The headline comparison. Modular is cheapest once the agent already knows the modules. Operation-local spends more tokens inside one file on purpose.

Reading only

Layered100%
Modular66%
Operation-local98%

Operation files are verbose: examples, unions, mapping, persistence. You open fewer files; each file is larger.

Implementation only

Layered100%
Modular49%
Operation-local65%

Layered extras are duplicated types. Operation-local extras are a copied template plus comments.

Pillar 2 — Developer involvement lower is cheaper · Layered · Modular · Operation-local

Files opened

100% · 56% · 38%

Search tax before the first confident edit. Maps collapse this.

Files touched

100% · 55% · 45%

Review surface and merge-conflict surface for the same rule.

New types created

100% · 36% · 18%

Layered needs a vertical slice of types the other postures never invent.

Forgotten wiring points

High · Medium · One root

Mediator conventions hide registration; Operation-local maps the route in one file.

Pillar 3 — Correct output higher is better

First-pass completeness estimated

Layered40%
Modular75%
Operation-local90%

Share of required layers included in the first patch, estimated from hop count and whether an edit ritual is written down. Not a counted sample.

Compile-time outcome coverage

LayeredNone
ModularPartial
Operation-localClosed

Whether the compiler can answer “did we handle every business status?” before the agent pushes. Layered uses exceptions. Modular uses a shared enum. Operation-local uses a closed union. These are labels, not percentages, because the coverage was not counted.

Real data path in default tests

Mocked handler tests0%
HTTP tests on a real host100%

A green mock will not catch a query the database cannot translate. Correctness of output includes the persistence path.

Runtime is not the reason — but it does not get worse Layered · Modular · Operation-local

Time to first successful read · lower is cheaper

100% · 33% · 31%

Shorter DI graphs and fewer projects start faster. About a 67–69% reduction vs Layered.

Typical request latency · lower is cheaper

100% · 92% · 85%

Geometric mean of representative operations. Architecture is a few percent on top of the database.

Working set after traffic · lower is cheaper

100% · 93% · 93%

Memory is not a product difference. Do not split services to save it.

How to read the tradeoff

  • If the agent already knows the codebase, Modular usually wins the token budget (60% of Layered).
  • If the agent is cold, Operation-local wins files touched (45%) and first-pass completeness (estimated 90%) because the map and template remove search.
  • Layered loses token cost, review surface, and correctness proxies together. The extra work is fan-out, not documentation.
  • Do not optimise “fewer characters in the file you edit” if those characters are the closed outcome set. Irrelevant hops are the waste.

How these numbers were produced

One change — a daily withdrawal limit — applied once to three demo payment APIs in a single session. Tokens were estimated at roughly four characters each because no tokenizer was available. A SQLite DateTimeOffset translation bug was found while doing the Modular app and then reused in the other two, so Modular paid a debug cost the others did not. A token-measurement harness is still out of scope in the reference repository. The sourced percentages (files opened, files touched, tokens, latency, memory) trace to that session. First-pass completeness is an estimate from hop count, not a counted sample.