A more advanced version is not a better version.
The same app, in 28 versions. Code quality climbs almost the whole way. Agent-friendliness doesn't: it peaks in family 6 and drops in family 7, where the code gains separate databases and boundaries the agent has to cross.
Scroll sideways to compare all branches. The tables below contain the same data.
7D: highest Rubycritic, 94.55, but 19/25 for agents
6G: best agent score, 24/25
Explore by family
Scroll horizontally in the tables to compare all columns.
Families 1 & 2: controller architecture
Branch
Rule
LOC
Rubycritic
Agent
1A-fat-controller
If it touches the model, it goes in the controller.
1,310
79.48
10 /25
1B-extract-concerns
Extract the file, keep the class.
1,377
84.95
15 /25
2A-multi-controllers
One class per responsibility, not one class per entity.
1,355
83.02
17 /25
2B-rest-actions-only
If the action doesn't fit the 7 verbs, the resource model is wrong.
1,390
84.71
19 /25
Family 3: domain structure
Branch
Rule
LOC
Rubycritic
Agent
3A-namespaced-controllers
The prefix becomes the folder.
1,390
84.71
14 /25
3B-nested-namespaces
If the prefix survived the namespace, the namespace isn't deep enough.
1,390
84.71
15 /25
3C-context-views
Domain in the path, resource in the name.
1,390
84.71
16 /25
3D-context-mailers
Declare the path; don't let Rails guess it from the class name.
1,390
84.71
17 /25
3E-singular-resources
Express every route as a resource declaration.
1,389
84.41
16 /25
3F-resource-discipline
Fix the name, not the route.
1,397
83.92
20 /25
3G-domain-naming
Name the operation, not the page.
1,417
83.22
21 /25
Family 4: entry point separation
Family 5: model authority
Branch
Rule
LOC
Rubycritic
Agent
5A-fat-models
If two controllers compute the same thing, the model should compute it once.
1,640
91.51
17 /25
5B-model-callbacks
If every creation path should trigger the effect, the model owns the event.
1,638
91.23
18 /25
5C-unified-vocabulary
The model's name should match the controller's namespace.
1,641
91.18
21 /25
5D-model-authority
Ask the model that owns the data; don't reach through its associations.
1,646
91.21
23 /25
Family 6: domain naming
Branch
Rule
LOC
Rubycritic
Agent
6A-member-object
When a concept outgrows its infrastructure home, give it a class and a name.
1,696
91.36
19 /25
6B-token-secret
When pure functions share a file with persistence logic, they need their own home.
1,712
91.46
22 /25
6C-task-status
If the code speaks a word in multiple places, give it one canonical home.
1,717
91.45
19 /25
6D-query-objects
When a computation outgrows its host model, give it its own object.
1,735
91.58
21 /25
6E-declared-authority
If it's your data, it's your responsibility to answer questions about it.
1,717
91.72
22 /25
6F-contextual-names
If the namespace already says it, the name drops the prefix.
1,717
91.72
19 /25
6G-named-orchestrations
Multi-model coordination gets its own name.
1,799
92.08
24 /25
Family 7: bounded contexts & isolation
Branch
Rule
LOC
Rubycritic
Agent
7A-domain-boundaries
No model references another domain's classes.
1,785
93.80
19 /25
7B-process-managers
When intermediate state accumulates across lifecycle phases, give the orchestration its own object.
1,793
93.67
19 /25
7C-domain-databases
Each bounded context owns its own database.
1,818
93.81
17 /25
7D-shared-kernel
The host app keeps only what both interfaces share. Everything else moves to an engine.
1,832
94.55
19 /25