Skip to content
>GLB_
Go back

improve-codebase-architecture: review that knows your domain

Generic architecture review produces generic output. “Consider extracting this into a service.” “This class has too many responsibilities.” These observations are technically defensible and practically useless — they ignore the domain, the history of the decisions, and the constraints that produced the current shape.

improve-codebase-architecture runs a different kind of review. It reads the domain model before reading the code.

What it reads

Before analysing structure, the skill builds context from:

Only after that does it look at structural issues.

What the review targets

Usage

/improve-codebase-architecture

No arguments required. Run from the project root. If ADRs exist (typically in docs/adr/ or docs/decisions/), the skill finds and reads them. If they don’t, it derives decisions from naming and structure.

The difference from generic refactor

A generic refactor suggestion works from code structure alone. It sees a large class and recommends splitting it. It sees duplication and recommends extraction. These are pattern matches against code shape.

Domain-informed review sees a large class and asks whether it’s large because it was built wrong or because the domain concept it represents is genuinely large. It sees duplication and asks whether the two duplicated sections represent the same concept or two concepts that currently look identical but will diverge.

The outputs are different. One produces smaller classes. The other produces a codebase that’s easier to reason about in domain terms — which is the property that actually reduces maintenance cost.

When it’s most useful


Share this post:

Related Posts


Previous Post
grill-me: stress-testing a plan before touching the codebase
Next Post
Building a data quality dashboard on top of Tuva's DQI mart