@lenardangeloolajay/len-toolkit 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +209 -0
- package/bin/cli.js +244 -0
- package/package.json +35 -0
- package/src/installer.js +236 -0
- package/templates/configs/.editorconfig +12 -0
- package/templates/configs/sample.gitignore +8 -0
- package/templates/docs/FEATURE.md +40 -0
- package/templates/docs/HANDOFF.md +39 -0
- package/templates/docs/IMPLEMENTATION_PLAN.md +47 -0
- package/templates/docs/SPEC_INDEX.md +12 -0
- package/templates/docs/VERIFICATION.md +14 -0
- package/templates/docs/product/ARCHITECTURE.md +22 -0
- package/templates/docs/product/CONSTRAINTS.md +22 -0
- package/templates/docs/product/DATA_MODEL.md +22 -0
- package/templates/docs/product/OVERVIEW.md +22 -0
- package/templates/examples/flutter-handoff/EXERCISES.md +16 -0
- package/templates/examples/flutter-handoff/HANDOFF.md +32 -0
- package/templates/examples/flutter-handoff/docs/SPEC_INDEX.md +19 -0
- package/templates/examples/flutter-handoff/docs/evidence/FEAT-001-verification.md +14 -0
- package/templates/examples/flutter-handoff/docs/features/FEAT-001-local-note.md +40 -0
- package/templates/examples/flutter-handoff/docs/plans/FEAT-001-implementation.md +43 -0
- package/templates/examples/flutter-handoff/docs/product/ARCHITECTURE.md +24 -0
- package/templates/examples/flutter-handoff/docs/product/CONSTRAINTS.md +13 -0
- package/templates/examples/flutter-handoff/docs/product/DATA_MODEL.md +20 -0
- package/templates/examples/flutter-handoff/docs/product/OVERVIEW.md +26 -0
- package/templates/rules/.cursorrules +7 -0
- package/templates/rules/AGENTS.md +61 -0
- package/templates/rules/GEMINI.md +7 -0
- package/templates/skills/a-philosophy-of-software-design/SKILL.md +11 -0
- package/templates/skills/a-philosophy-of-software-design/a-philosophy-of-software-design.md +370 -0
- package/templates/skills/a-philosophy-of-software-design/a-philosophy-of-software-design.mini.md +46 -0
- package/templates/skills/a-philosophy-of-software-design/a-philosophy-of-software-design.nano.md +35 -0
- package/templates/skills/clean-architecture/SKILL.md +11 -0
- package/templates/skills/clean-architecture/clean-architecture.md +515 -0
- package/templates/skills/clean-architecture/clean-architecture.mini.md +49 -0
- package/templates/skills/clean-architecture/clean-architecture.nano.md +36 -0
- package/templates/skills/clean-code/SKILL.md +11 -0
- package/templates/skills/clean-code/clean-code.md +297 -0
- package/templates/skills/clean-code/clean-code.mini.md +47 -0
- package/templates/skills/clean-code/clean-code.nano.md +32 -0
- package/templates/skills/code-complete/SKILL.md +11 -0
- package/templates/skills/code-complete/code-complete.md +354 -0
- package/templates/skills/code-complete/code-complete.mini.md +56 -0
- package/templates/skills/code-complete/code-complete.nano.md +41 -0
- package/templates/skills/council/SKILL.md +37 -0
- package/templates/skills/designing-data-intensive-applications/SKILL.md +11 -0
- package/templates/skills/designing-data-intensive-applications/designing-data-intensive-applications.md +393 -0
- package/templates/skills/designing-data-intensive-applications/designing-data-intensive-applications.mini.md +55 -0
- package/templates/skills/designing-data-intensive-applications/designing-data-intensive-applications.nano.md +34 -0
- package/templates/skills/domain-driven-design/SKILL.md +11 -0
- package/templates/skills/domain-driven-design/domain-driven-design.md +979 -0
- package/templates/skills/domain-driven-design/domain-driven-design.mini.md +48 -0
- package/templates/skills/domain-driven-design/domain-driven-design.nano.md +39 -0
- package/templates/skills/domain-driven-design-distilled/SKILL.md +11 -0
- package/templates/skills/domain-driven-design-distilled/domain-driven-design-distilled.md +317 -0
- package/templates/skills/domain-driven-design-distilled/domain-driven-design-distilled.mini.md +56 -0
- package/templates/skills/domain-driven-design-distilled/domain-driven-design-distilled.nano.md +41 -0
- package/templates/skills/implementation-plan/SKILL.md +42 -0
- package/templates/skills/implementing-domain-driven-design/SKILL.md +11 -0
- package/templates/skills/implementing-domain-driven-design/implementing-domain-driven-design.md +337 -0
- package/templates/skills/implementing-domain-driven-design/implementing-domain-driven-design.mini.md +57 -0
- package/templates/skills/implementing-domain-driven-design/implementing-domain-driven-design.nano.md +37 -0
- package/templates/skills/patterns-of-enterprise-application-architecture/SKILL.md +11 -0
- package/templates/skills/patterns-of-enterprise-application-architecture/patterns-of-enterprise-application-architecture.md +404 -0
- package/templates/skills/patterns-of-enterprise-application-architecture/patterns-of-enterprise-application-architecture.mini.md +54 -0
- package/templates/skills/patterns-of-enterprise-application-architecture/patterns-of-enterprise-application-architecture.nano.md +35 -0
- package/templates/skills/ponytail/SKILL.md +124 -0
- package/templates/skills/ponytail-audit/SKILL.md +45 -0
- package/templates/skills/ponytail-debt/SKILL.md +48 -0
- package/templates/skills/ponytail-gain/SKILL.md +17 -0
- package/templates/skills/ponytail-help/SKILL.md +42 -0
- package/templates/skills/ponytail-review/SKILL.md +61 -0
- package/templates/skills/refactoring/SKILL.md +11 -0
- package/templates/skills/refactoring/refactoring.md +433 -0
- package/templates/skills/refactoring/refactoring.mini.md +49 -0
- package/templates/skills/refactoring/refactoring.nano.md +37 -0
- package/templates/skills/refactoring-guru/SKILL.md +11 -0
- package/templates/skills/refactoring-guru/refactoring-guru.md +765 -0
- package/templates/skills/refactoring-guru/refactoring-guru.mini.md +64 -0
- package/templates/skills/refactoring-guru/refactoring-guru.nano.md +41 -0
- package/templates/skills/release-it/SKILL.md +11 -0
- package/templates/skills/release-it/release-it.md +382 -0
- package/templates/skills/release-it/release-it.mini.md +48 -0
- package/templates/skills/release-it/release-it.nano.md +38 -0
- package/templates/skills/security-audit/AI-AND-LLM.md +83 -0
- package/templates/skills/security-audit/ATTACK-CLASSES.md +130 -0
- package/templates/skills/security-audit/CLIENT-SIDE.md +83 -0
- package/templates/skills/security-audit/CLOUD-AND-DEPLOYMENT.md +86 -0
- package/templates/skills/security-audit/DATA-ISOLATION-AND-LIFECYCLE.md +84 -0
- package/templates/skills/security-audit/DESKTOP-MOBILE-AND-LOCAL-IPC.md +89 -0
- package/templates/skills/security-audit/HUNTING.md +251 -0
- package/templates/skills/security-audit/MEMORY-SAFETY-AND-BINARY.md +101 -0
- package/templates/skills/security-audit/PROTOCOLS-RPC-AND-MESSAGING.md +81 -0
- package/templates/skills/security-audit/RECONNAISSANCE.md +156 -0
- package/templates/skills/security-audit/RESOURCE-EXHAUSTION-AND-AVAILABILITY.md +78 -0
- package/templates/skills/security-audit/SKILL.md +192 -0
- package/templates/skills/security-audit/SUPPLY-CHAIN-AND-RELEASE.md +73 -0
- package/templates/skills/security-audit/VALIDATION-AND-REPORTING.md +186 -0
- package/templates/skills/security-audit/WEB-PROTOCOL-AND-AUTH.md +105 -0
- package/templates/skills/security-audit/report-schema.json +461 -0
- package/templates/skills/security-audit/validate-coverage-ledger.cjs +872 -0
- package/templates/skills/security-audit/validate-coverage-ledger.test.cjs +740 -0
- package/templates/skills/security-audit/validate-findings.cjs +773 -0
- package/templates/skills/security-audit/validate-findings.test.cjs +652 -0
- package/templates/skills/spec/SKILL.md +55 -0
- package/templates/skills/the-pragmatic-programmer/SKILL.md +11 -0
- package/templates/skills/the-pragmatic-programmer/the-pragmatic-programmer.md +359 -0
- package/templates/skills/the-pragmatic-programmer/the-pragmatic-programmer.mini.md +65 -0
- package/templates/skills/the-pragmatic-programmer/the-pragmatic-programmer.nano.md +44 -0
- package/templates/skills/working-effectively-with-legacy-code/SKILL.md +11 -0
- package/templates/skills/working-effectively-with-legacy-code/working-effectively-with-legacy-code.md +371 -0
- package/templates/skills/working-effectively-with-legacy-code/working-effectively-with-legacy-code.mini.md +50 -0
- package/templates/skills/working-effectively-with-legacy-code/working-effectively-with-legacy-code.nano.md +35 -0
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
# OBEY Domain-Driven Design by Eric Evans
|
|
2
|
+
|
|
3
|
+
## When to use
|
|
4
|
+
|
|
5
|
+
Use when business complexity, model language, lifecycle rules, or cross-team/system boundaries shape the design more than generic technical organization.
|
|
6
|
+
|
|
7
|
+
## Primary bias to correct
|
|
8
|
+
|
|
9
|
+
Keep domain behavior, code, tests, documents, and team language aligned inside explicit Bounded Contexts. Do not let persistence, UI, frameworks, integration formats, or DDD vocabulary replace an implementation-driving model.
|
|
10
|
+
|
|
11
|
+
## Decision rules
|
|
12
|
+
|
|
13
|
+
- Use a model only when it organizes domain knowledge, clarifies communication, and can be expressed in implementation; iterate through code, expert conversation, scenarios, and refactoring toward deeper insight.
|
|
14
|
+
- Maintain one Ubiquitous Language per Bounded Context across names, tests, documents, diagrams, planning, and feature discussion; keep explanatory models separate from the implementation model.
|
|
15
|
+
- Put business logic in the domain layer. Keep UI, application coordination, infrastructure, persistence, messaging, and framework constraints outside the model or behind adapters.
|
|
16
|
+
- Use tactical patterns for model meaning: Entities for stable identity, Value Objects for immutable descriptive value, Services for important operations with no natural object home, and Modules for conceptual cohesion.
|
|
17
|
+
- Manage lifecycle through Aggregates, Factories, and Repositories: expose only Aggregate roots, enforce invariants inside the boundary, hide complex creation and persistence, and prevent partially formed objects from escaping.
|
|
18
|
+
- Design domain objects for the model first and persistence second; preserve identity, Aggregate boundaries, Value Object semantics, and domain query criteria instead of exposing database structure.
|
|
19
|
+
- Refactor toward deeper domain insight, not only mechanical cleanliness. Make constraints, policies, processes, calculations, allocations, and generation rules explicit when they carry domain meaning.
|
|
20
|
+
- Design for model users: name operations by domain purpose, separate side-effect-free functions from state-changing commands, make assertions explicit, and shape boundaries around conceptual contours.
|
|
21
|
+
- Define every Bounded Context explicitly. Do not assume a term has the same meaning elsewhere; use context maps, tests, and active communication to protect model integrity.
|
|
22
|
+
- Choose context relationships deliberately: Shared Kernel, Customer/Supplier, Conformist, Anticorruption Layer, Separate Ways, Open Host Service, Published Language, or incremental legacy replacement.
|
|
23
|
+
- Distill and protect the Core Domain by strategic value. Keep generic subdomains, infrastructure, reusable mechanisms, and supporting details from consuming core-domain attention.
|
|
24
|
+
- Add large-scale structure only when individual objects no longer make a large model understandable; keep structures domain-specific, evolvable, and valid only inside compatible contexts.
|
|
25
|
+
- Use analysis patterns, design patterns, specifications, industry formalisms, and prior art only when they clarify the current model and preserve domain language.
|
|
26
|
+
- Test the model in the Ubiquitous Language: prioritize domain tests for invariants, allowed and forbidden transitions, valid construction, specifications, application orchestration, and boundary translation before generic infrastructure checks.
|
|
27
|
+
- Make major strategic moves with people who understand both the implementation and the domain; architecture and framework guidance must serve application teams and domain goals.
|
|
28
|
+
|
|
29
|
+
## Trigger rules
|
|
30
|
+
|
|
31
|
+
- When terminology is awkward, ambiguous, inconsistent, or repeatedly translated, refine the Ubiquitous Language and rename code before adding more behavior.
|
|
32
|
+
- When controllers, services, scripts, SQL, jobs, or serializers carry business decisions, move rules into domain objects, domain services, specifications, or explicit domain concepts.
|
|
33
|
+
- When UI, persistence, messaging, APIs, or frameworks start shaping domain concepts, isolate them with layers, adapters, translation, or an Anticorruption Layer.
|
|
34
|
+
- When a change crosses unrelated modules, many objects, or multiple roots, reassess Module cohesion, Aggregate ownership, consistency timing, and context boundaries.
|
|
35
|
+
- When clients know creation, lifecycle, persistence, identity generation, or internal mutation details, repair Factories, Repositories, roots, and encapsulation.
|
|
36
|
+
- When new behavior is hard to explain, test, or extend, search for a deeper model, missing implicit concept, or breakthrough refactoring instead of adding procedural branches.
|
|
37
|
+
- When integrating with another model, choose the relationship, translation strategy, published language or protocol, and boundary tests before writing boundary code.
|
|
38
|
+
- When changing invariants, lifecycle transitions, specifications, orchestration, or context translation, add domain-language tests that prove valid behavior and block invalid states.
|
|
39
|
+
- When generic mechanisms, reusable frameworks, or supporting subdomains obscure distinctive value, distill the Core Domain or separate the mechanism.
|
|
40
|
+
|
|
41
|
+
## Final checklist
|
|
42
|
+
|
|
43
|
+
- Is domain behavior explicit in the model rather than hidden in delivery, persistence, or integration code?
|
|
44
|
+
- Do code, tests, documents, and conversations use one language inside each Bounded Context?
|
|
45
|
+
- Do tactical patterns protect identity, value semantics, lifecycle, invariants, and responsibility instead of adding ceremony?
|
|
46
|
+
- Does every cross-context integration have an explicit relationship, translation strategy, and boundary test?
|
|
47
|
+
- Do tests read like executable examples of the model and cover invalid transitions or construction?
|
|
48
|
+
- Is the Core Domain visible and protected from supporting complexity, generic mechanisms, infrastructure, and frameworks?
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# OBEY Domain-Driven Design by Eric Evans
|
|
2
|
+
|
|
3
|
+
## When to use
|
|
4
|
+
|
|
5
|
+
Use as always-on DDD guidance when domain language, invariants, lifecycle, or integration boundaries affect implementation choices.
|
|
6
|
+
|
|
7
|
+
## Primary bias to correct
|
|
8
|
+
|
|
9
|
+
Generic plumbing and DDD terminology are not a domain model.
|
|
10
|
+
|
|
11
|
+
## Decision rules
|
|
12
|
+
|
|
13
|
+
- Keep model, code, tests, documents, and team language aligned inside each Bounded Context.
|
|
14
|
+
- Make business behavior explicit in model code, not hidden in controllers, persistence, jobs, scripts, or framework glue.
|
|
15
|
+
- Refine Ubiquitous Language when terms are fuzzy, and use only models that solve the problem and can be implemented.
|
|
16
|
+
- Use tactical patterns for domain meaning: Entities for identity, Value Objects for value, Services for homeless operations, and Modules for conceptual cohesion.
|
|
17
|
+
- Treat Aggregates as consistency and lifecycle boundaries; expose roots only and protect invariants inside the boundary.
|
|
18
|
+
- Hide complex creation and persistence behind Factories and Repositories; design for the model first and storage second.
|
|
19
|
+
- Define context boundaries and relationships explicitly before sharing terms, data, or behavior across systems.
|
|
20
|
+
- Protect the Core Domain from generic subdomains, reusable mechanisms, infrastructure, framework pressure, and foreign models.
|
|
21
|
+
- Refactor toward deeper insight: make important constraints, policies, processes, and calculations explicit domain concepts.
|
|
22
|
+
- Test invariants, invalid construction, lifecycle transitions, and boundary translations in the Ubiquitous Language.
|
|
23
|
+
|
|
24
|
+
## Trigger rules
|
|
25
|
+
|
|
26
|
+
- Fuzzy or inconsistent terms trigger language refinement and code renaming.
|
|
27
|
+
- Procedural business rules in orchestration, SQL, jobs, or serializers trigger moving behavior into the model.
|
|
28
|
+
- Sprawling transactions or cross-module changes trigger Aggregate and context-boundary review.
|
|
29
|
+
- Foreign model, schema, API, or legacy pressure triggers translation or an explicit Conformist choice.
|
|
30
|
+
- Supporting mechanisms obscuring distinctive value trigger Core Domain distillation.
|
|
31
|
+
|
|
32
|
+
## Final checklist
|
|
33
|
+
|
|
34
|
+
- Domain behavior in the model?
|
|
35
|
+
- One language per context?
|
|
36
|
+
- Invariants protected by roots and values?
|
|
37
|
+
- Integration relationship explicit?
|
|
38
|
+
- Domain tests cover invalid states and translations?
|
|
39
|
+
- Core Domain still visible?
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: domain-driven-design-distilled
|
|
3
|
+
description: Apply Vaughn Vernon-inspired lightweight DDD rules when using bounded contexts, subdomains, context maps, and tactical modeling without excess ceremony.
|
|
4
|
+
license: MIT
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Domain-Driven Design Distilled Skill
|
|
8
|
+
|
|
9
|
+
Use this skill when a task needs practical DDD guidance for subdomains, bounded contexts, context mapping, aggregates, domain events, or tactical modeling with restrained ceremony.
|
|
10
|
+
|
|
11
|
+
Before making design or code decisions, read and apply [domain-driven-design-distilled.mini.md](domain-driven-design-distilled.mini.md). Use [domain-driven-design-distilled.md](domain-driven-design-distilled.md) only as a deeper reference when the mini rules are not enough for the current DDD tradeoff.
|
|
@@ -0,0 +1,317 @@
|
|
|
1
|
+
# OBEY Domain-Driven Design Distilled by Vaughn Vernon
|
|
2
|
+
|
|
3
|
+
## Purpose
|
|
4
|
+
|
|
5
|
+
This repository follows **Domain-Driven Design Distilled**:
|
|
6
|
+
use the smallest effective set of DDD practices to model the business meaning clearly and deliver results quickly.
|
|
7
|
+
|
|
8
|
+
All code generation, edits, and reviews must optimize for:
|
|
9
|
+
- clear business language
|
|
10
|
+
- explicit bounded contexts
|
|
11
|
+
- focus on core domain complexity
|
|
12
|
+
- selective use of tactical DDD patterns
|
|
13
|
+
- practical implementation over ceremony
|
|
14
|
+
- collaboration between model and software design
|
|
15
|
+
|
|
16
|
+
This file is a binding engineering policy: `MUST` is binding, `SHOULD` is a strong default, and `MUST NOT` is forbidden.
|
|
17
|
+
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
## Primary Directive
|
|
21
|
+
|
|
22
|
+
Use DDD where it clarifies complex business software.
|
|
23
|
+
Do not turn DDD into ritual.
|
|
24
|
+
|
|
25
|
+
When uncertain:
|
|
26
|
+
1. identify the business capability or subdomain
|
|
27
|
+
2. decide whether it is core, supporting, or generic
|
|
28
|
+
3. define the bounded context
|
|
29
|
+
4. use the local ubiquitous language
|
|
30
|
+
5. apply only the tactical patterns that actually earn their cost
|
|
31
|
+
|
|
32
|
+
Reject both extremes:
|
|
33
|
+
- no modeling when the domain is complex
|
|
34
|
+
- full-blown DDD ceremony when the problem is simple
|
|
35
|
+
|
|
36
|
+
---
|
|
37
|
+
|
|
38
|
+
## Adoption Fit and Modeling Investment
|
|
39
|
+
|
|
40
|
+
1. Use DDD when domain complexity, language ambiguity, business differentiation, or integration risk justify the modeling effort.
|
|
41
|
+
2. Do not apply full tactical DDD to simple CRUD, generic subdomains, or problems whose complexity is mainly technical.
|
|
42
|
+
3. Let business drivers decide where modeling effort goes.
|
|
43
|
+
4. Reassess the model when the core business concern drifts, terms stop matching code, or supporting complexity hides the core.
|
|
44
|
+
5. Use scenarios and acceptance tests to validate that the model expresses real business behavior.
|
|
45
|
+
|
|
46
|
+
---
|
|
47
|
+
|
|
48
|
+
## Strategic Rules
|
|
49
|
+
|
|
50
|
+
### Start with Subdomains
|
|
51
|
+
Classify major areas as:
|
|
52
|
+
- core domain
|
|
53
|
+
- supporting subdomain
|
|
54
|
+
- generic subdomain
|
|
55
|
+
|
|
56
|
+
Rules (MUST unless marked SHOULD or MUST NOT):
|
|
57
|
+
1. Invest the most design effort in the core domain.
|
|
58
|
+
2. Keep supporting and generic subdomains simpler unless complexity proves otherwise.
|
|
59
|
+
3. Do not waste the best modeling effort on commodity concerns.
|
|
60
|
+
|
|
61
|
+
### Define Bounded Contexts Early
|
|
62
|
+
1. Every meaningful model lives inside a bounded context.
|
|
63
|
+
2. A bounded context owns its language, rules, and model semantics.
|
|
64
|
+
3. The same term may mean different things in different contexts.
|
|
65
|
+
4. Code structure must reflect context boundaries.
|
|
66
|
+
|
|
67
|
+
### Use Context Mapping
|
|
68
|
+
1. Make context relationships explicit.
|
|
69
|
+
2. Translate where meanings differ.
|
|
70
|
+
3. Own integration contracts deliberately.
|
|
71
|
+
4. Protect the local model from foreign language.
|
|
72
|
+
|
|
73
|
+
Anti-patterns (MUST NOT):
|
|
74
|
+
- one model reused across billing, identity, catalog, fulfillment, and support
|
|
75
|
+
- shared domain classes with subtly different meanings
|
|
76
|
+
- context boundaries documented but ignored in code
|
|
77
|
+
|
|
78
|
+
---
|
|
79
|
+
|
|
80
|
+
## Context Relationship Rules
|
|
81
|
+
|
|
82
|
+
Choose context relationships deliberately:
|
|
83
|
+
|
|
84
|
+
- USE Partnership only when teams can coordinate closely and share planning burden.
|
|
85
|
+
- USE Shared Kernel only for a small stable overlap with joint ownership and tests.
|
|
86
|
+
- USE Customer/Supplier when the upstream team can plan for downstream needs.
|
|
87
|
+
- USE Conformist when adopting the upstream model is cheaper and safer than translation.
|
|
88
|
+
- USE Anticorruption Layer when a foreign model would corrupt the local language.
|
|
89
|
+
- USE Open Host Service when many clients need a stable protocol into one context.
|
|
90
|
+
- USE Published Language when multiple systems need a documented interchange model.
|
|
91
|
+
- USE Separate Ways when integration cost is higher than shared capability value.
|
|
92
|
+
- TREAT Big Ball of Mud as a context to contain and translate around, not as a model to spread.
|
|
93
|
+
|
|
94
|
+
Anti-patterns (MUST NOT):
|
|
95
|
+
- claiming independent modeling while conforming silently
|
|
96
|
+
- using Shared Kernel without governance
|
|
97
|
+
- calling integration an anticorruption layer when no translation exists
|
|
98
|
+
|
|
99
|
+
---
|
|
100
|
+
|
|
101
|
+
## Integration Style Rules
|
|
102
|
+
|
|
103
|
+
1. Use RPC only when request/response coupling, latency, versioning, and failure semantics are acceptable.
|
|
104
|
+
2. Use REST resources as application-facing representations, not as leaked aggregate internals.
|
|
105
|
+
3. Use messaging when asynchronous coordination fits the business process and consumers can handle lag, duplicates, and ordering limits.
|
|
106
|
+
4. Decide whether domain events should carry enough information for consumers or require query-back.
|
|
107
|
+
5. Keep integration contracts separate from internal models.
|
|
108
|
+
6. Test translations at context boundaries.
|
|
109
|
+
|
|
110
|
+
---
|
|
111
|
+
|
|
112
|
+
## Ubiquitous Language Rules
|
|
113
|
+
|
|
114
|
+
1. Use domain terms from the current bounded context in code, tests, commands, events, and conversations.
|
|
115
|
+
2. One concept gets one term.
|
|
116
|
+
3. One term must not carry multiple meanings inside one context.
|
|
117
|
+
4. Rename code when understanding improves.
|
|
118
|
+
5. Prefer domain names over technical placeholders.
|
|
119
|
+
|
|
120
|
+
Avoid:
|
|
121
|
+
- technical placeholders that conceal a business concept
|
|
122
|
+
- names imported from another bounded context without translation
|
|
123
|
+
- generic helper or utility names that end up carrying domain decisions
|
|
124
|
+
|
|
125
|
+
---
|
|
126
|
+
|
|
127
|
+
## Tactical Pattern Rules
|
|
128
|
+
|
|
129
|
+
### Entities
|
|
130
|
+
Use entities when identity and lifecycle matter.
|
|
131
|
+
|
|
132
|
+
Rules (MUST unless marked SHOULD or MUST NOT):
|
|
133
|
+
1. Entities must have explicit identity.
|
|
134
|
+
2. Entities must protect meaningful state transitions.
|
|
135
|
+
3. Do not expose unrestricted state changes by default.
|
|
136
|
+
|
|
137
|
+
### Value Objects
|
|
138
|
+
Use value objects aggressively when a primitive hides meaning.
|
|
139
|
+
|
|
140
|
+
Rules (MUST unless marked SHOULD or MUST NOT):
|
|
141
|
+
1. Value objects are immutable by default.
|
|
142
|
+
2. They validate themselves.
|
|
143
|
+
3. They make code read in domain language.
|
|
144
|
+
|
|
145
|
+
### Aggregates
|
|
146
|
+
Use aggregates only where invariants require a consistency boundary.
|
|
147
|
+
|
|
148
|
+
Rules (MUST unless marked SHOULD or MUST NOT):
|
|
149
|
+
1. Keep aggregates small.
|
|
150
|
+
2. Protect invariants through the aggregate root.
|
|
151
|
+
3. Reference other aggregates by identity.
|
|
152
|
+
4. Avoid loading large object graphs.
|
|
153
|
+
|
|
154
|
+
### Domain Events
|
|
155
|
+
Use domain events for meaningful facts.
|
|
156
|
+
|
|
157
|
+
Rules (MUST unless marked SHOULD or MUST NOT):
|
|
158
|
+
1. Name events in the past tense.
|
|
159
|
+
2. Use events when they clarify collaboration or integration.
|
|
160
|
+
3. Do not publish trivial noise for every field change.
|
|
161
|
+
|
|
162
|
+
## Aggregate Minimalism Rules
|
|
163
|
+
|
|
164
|
+
1. Do not create large aggregates to make navigation convenient.
|
|
165
|
+
2. Default to smaller boundaries.
|
|
166
|
+
3. Default to eventual consistency across aggregates.
|
|
167
|
+
4. Use IDs for references across aggregate boundaries.
|
|
168
|
+
5. One transaction should usually change one aggregate.
|
|
169
|
+
|
|
170
|
+
Anti-patterns (MUST NOT):
|
|
171
|
+
- aggregate designed around a screen
|
|
172
|
+
- one request loading and mutating a whole graph
|
|
173
|
+
- aggregate roots exposing mutable children directly
|
|
174
|
+
|
|
175
|
+
---
|
|
176
|
+
|
|
177
|
+
## Application Service Rules
|
|
178
|
+
|
|
179
|
+
1. Application services coordinate use cases.
|
|
180
|
+
2. They load aggregates, call domain behavior, save results, and trigger integration work.
|
|
181
|
+
3. They must not become the real domain model.
|
|
182
|
+
4. They should stay thin enough that the model still carries meaning.
|
|
183
|
+
|
|
184
|
+
Anti-patterns (MUST NOT):
|
|
185
|
+
- all business decisions in application services
|
|
186
|
+
- controllers duplicating application orchestration
|
|
187
|
+
- application services shaped only by transport
|
|
188
|
+
|
|
189
|
+
---
|
|
190
|
+
|
|
191
|
+
## Architecture and Infrastructure Rules
|
|
192
|
+
|
|
193
|
+
1. Infrastructure is a detail.
|
|
194
|
+
2. Keep frameworks, persistence mechanics, REST resources, transport formats, and other technology concerns out of the domain model.
|
|
195
|
+
3. Persist aggregates without letting persistence define the model.
|
|
196
|
+
4. Translate transport and integration data at the boundary.
|
|
197
|
+
|
|
198
|
+
Anti-patterns (MUST NOT):
|
|
199
|
+
- persistence-first modeling
|
|
200
|
+
- reusing transport objects as domain objects
|
|
201
|
+
- domain methods depending on framework types
|
|
202
|
+
|
|
203
|
+
---
|
|
204
|
+
|
|
205
|
+
## Collaboration Rules
|
|
206
|
+
|
|
207
|
+
1. Keep names close to real business terms.
|
|
208
|
+
2. Prefer code that teaches the model to a reader.
|
|
209
|
+
3. Make domain assumptions explicit in names, tests, and events.
|
|
210
|
+
4. Where a concept is fuzzy, do not hide the ambiguity behind technical abstractions.
|
|
211
|
+
|
|
212
|
+
Anti-patterns (MUST NOT):
|
|
213
|
+
- generic code that could belong to any business
|
|
214
|
+
- unexplained status codes and flags with domain meaning
|
|
215
|
+
- enums and booleans where a richer concept is needed
|
|
216
|
+
|
|
217
|
+
---
|
|
218
|
+
|
|
219
|
+
## Practicality Rules
|
|
220
|
+
|
|
221
|
+
1. Use the least expensive pattern that honestly models the problem.
|
|
222
|
+
2. Simple domains may use simple services and data structures.
|
|
223
|
+
3. Once invariants, lifecycle, and language complexity rise, strengthen the model.
|
|
224
|
+
4. Prefer incremental improvement over massive design overhauls.
|
|
225
|
+
|
|
226
|
+
Anti-patterns (MUST NOT):
|
|
227
|
+
- dismissing DDD because not every module needs it
|
|
228
|
+
- over-modeling a generic subsystem
|
|
229
|
+
- introducing aggregates and events before knowing why
|
|
230
|
+
|
|
231
|
+
---
|
|
232
|
+
|
|
233
|
+
## Accelerated Modeling and Project Rules
|
|
234
|
+
|
|
235
|
+
1. Use event storming or similar collaborative modeling when workflow, events, commands, policies, or team language are unclear.
|
|
236
|
+
2. Timebox modeling work so it improves implementation instead of becoming detached analysis.
|
|
237
|
+
3. Use modeling spikes to reduce uncertainty before committing to a model shape.
|
|
238
|
+
4. Track modeling debt when code and language are known to be imperfect but intentionally deferred.
|
|
239
|
+
5. Involve domain experts in scenario walkthroughs, terminology decisions, and acceptance criteria.
|
|
240
|
+
6. Estimate DDD work by modeling uncertainty, integration risk, and implementation cost, not only by feature count.
|
|
241
|
+
7. Treat team skill and access to domain experts as constraints on how much DDD ceremony the project can sustain.
|
|
242
|
+
|
|
243
|
+
---
|
|
244
|
+
|
|
245
|
+
## Code Generation Rules
|
|
246
|
+
|
|
247
|
+
When generating code, use this default order:
|
|
248
|
+
1. identify the subdomain
|
|
249
|
+
2. identify the bounded context
|
|
250
|
+
3. write names in the local ubiquitous language
|
|
251
|
+
4. decide whether a concept is entity, value object, aggregate, service, repository, or event
|
|
252
|
+
5. choose the smallest tactical pattern that fits
|
|
253
|
+
6. isolate infrastructure at boundaries
|
|
254
|
+
7. keep context translation explicit
|
|
255
|
+
|
|
256
|
+
Default avoidance:
|
|
257
|
+
- giant shared domain packages
|
|
258
|
+
- service-centric fake DDD
|
|
259
|
+
- technical names replacing domain language
|
|
260
|
+
- full tactical DDD in trivial modules
|
|
261
|
+
|
|
262
|
+
---
|
|
263
|
+
|
|
264
|
+
## Review Rules
|
|
265
|
+
|
|
266
|
+
When reviewing code, actively look for:
|
|
267
|
+
- missing subdomain classification
|
|
268
|
+
- missing bounded context ownership
|
|
269
|
+
- context bleeding
|
|
270
|
+
- no context translation where meanings differ
|
|
271
|
+
- primitive obsession
|
|
272
|
+
- anemic entities
|
|
273
|
+
- no value objects where concepts repeat
|
|
274
|
+
- aggregates too large
|
|
275
|
+
- services containing all behavior
|
|
276
|
+
- excessive ceremony in simple modules
|
|
277
|
+
- no modeling at all in complex modules
|
|
278
|
+
|
|
279
|
+
---
|
|
280
|
+
|
|
281
|
+
## Testing Rules
|
|
282
|
+
|
|
283
|
+
1. Domain tests must read in the ubiquitous language.
|
|
284
|
+
2. Test value objects for validation and behavior.
|
|
285
|
+
3. Test entities and aggregates for valid and invalid transitions.
|
|
286
|
+
4. Test application services for orchestration, not for all domain rules.
|
|
287
|
+
5. Test context translation where external or foreign models exist.
|
|
288
|
+
|
|
289
|
+
---
|
|
290
|
+
|
|
291
|
+
## Review Checklist
|
|
292
|
+
|
|
293
|
+
Before finalizing any change, verify:
|
|
294
|
+
- Is the subdomain/core importance understood?
|
|
295
|
+
- Is the bounded context explicit?
|
|
296
|
+
- Is the ubiquitous language visible in the code?
|
|
297
|
+
- Did we use only the tactical patterns that genuinely help?
|
|
298
|
+
- Are aggregates small and focused on invariants?
|
|
299
|
+
- Are value objects used where they clarify meaning?
|
|
300
|
+
- Are application services coordinating rather than owning all domain logic?
|
|
301
|
+
- Did we keep infrastructure out of the model?
|
|
302
|
+
- Did we avoid DDD theater and over-modeling?
|
|
303
|
+
|
|
304
|
+
If any answer is no, revise before shipping.
|
|
305
|
+
|
|
306
|
+
---
|
|
307
|
+
|
|
308
|
+
## Final Instruction
|
|
309
|
+
|
|
310
|
+
When uncertain, choose the option that:
|
|
311
|
+
1. sharpens the business language
|
|
312
|
+
2. clarifies the bounded context
|
|
313
|
+
3. models real complexity honestly
|
|
314
|
+
4. avoids unnecessary ceremony
|
|
315
|
+
5. keeps the design practical enough to deliver
|
|
316
|
+
|
|
317
|
+
Use DDD selectively, but seriously.
|
package/templates/skills/domain-driven-design-distilled/domain-driven-design-distilled.mini.md
ADDED
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
# OBEY Domain-Driven Design Distilled by Vaughn Vernon
|
|
2
|
+
|
|
3
|
+
## When to use
|
|
4
|
+
|
|
5
|
+
Use when business software has enough domain complexity, language ambiguity, strategic differentiation, or integration risk that modeling changes implementation decisions, but the project still needs the smallest effective DDD practice rather than ceremony.
|
|
6
|
+
|
|
7
|
+
## Primary bias to correct
|
|
8
|
+
|
|
9
|
+
Use DDD selectively, but seriously. Start from business capability, subdomain importance, bounded context, and local language before tactical patterns, frameworks, persistence, APIs, or class shapes.
|
|
10
|
+
|
|
11
|
+
## Decision rules
|
|
12
|
+
|
|
13
|
+
- Before designing code, identify the business capability, classify the subdomain as Core, Supporting, or Generic, define the Bounded Context, use its Ubiquitous Language, and choose only tactical patterns that earn their cost.
|
|
14
|
+
- Put the most modeling effort into the Core Domain. Keep Supporting and Generic Subdomains simpler unless their own complexity proves otherwise.
|
|
15
|
+
- Do not apply full tactical DDD to simple CRUD, generic subsystems, or mainly technical problems; strengthen the model only when invariants, lifecycle, language complexity, or integration risk justify it.
|
|
16
|
+
- Give every meaningful model one explicit Bounded Context. The context owns its language, rules, semantics, code structure, tests, and integration contracts.
|
|
17
|
+
- Treat the same word in different contexts as potentially different concepts. Translate at context boundaries instead of sharing domain classes or leaking foreign language into the local model.
|
|
18
|
+
- Choose context relationships deliberately: Partnership, Shared Kernel, Customer/Supplier, Conformist, Anticorruption Layer, Open Host Service, Published Language, Separate Ways, or Big Ball of Mud containment all imply different ownership and translation duties.
|
|
19
|
+
- Select integration style from business coupling and failure semantics: RPC requires acceptable request/response coupling; REST resources must not expose Aggregate internals; messaging must tolerate lag, duplicates, and ordering limits.
|
|
20
|
+
- Keep integration contracts separate from internal models and test translations wherever meanings cross a boundary.
|
|
21
|
+
- Use local domain terms in code, tests, Commands, Domain Events, APIs, and conversations. One concept gets one term, one term does not carry multiple meanings inside a context, and code is renamed when understanding improves.
|
|
22
|
+
- Use Entities when identity and lifecycle matter; make identity explicit and protect meaningful state transitions rather than exposing unrestricted setters.
|
|
23
|
+
- Use immutable, self-validating Value Objects when primitives hide domain meaning.
|
|
24
|
+
- Use Aggregates only as invariant and transactional consistency boundaries. Keep them small, modify through the root, reference other Aggregates by identity, avoid large object graphs, and usually change one Aggregate per transaction.
|
|
25
|
+
- Use Domain Events for meaningful past-tense business facts that clarify collaboration or integration; do not publish noisy field-change events.
|
|
26
|
+
- Application Services coordinate use cases by loading Aggregates, invoking domain behavior, saving results, and triggering integration work. They must not become the real domain model.
|
|
27
|
+
- Keep frameworks, persistence mechanics, transport formats, REST representations, and infrastructure types out of the domain model. Translate external data at the boundary and persist Aggregates without letting storage define the model.
|
|
28
|
+
- Prefer code that teaches the model: make domain assumptions explicit in names, tests, and events; expose richer concepts instead of hiding meaning behind flags, status codes, booleans, enums, helpers, or utilities.
|
|
29
|
+
- Use Event Storming, scenarios, acceptance tests, modeling spikes, and domain-expert walkthroughs when workflow, terminology, policies, or acceptance criteria are unclear. Timebox modeling and track modeling debt instead of drifting into detached analysis.
|
|
30
|
+
- Estimate and plan DDD work from modeling uncertainty, integration risk, implementation cost, team skill, and access to domain experts, not only from feature count.
|
|
31
|
+
|
|
32
|
+
## Trigger rules
|
|
33
|
+
|
|
34
|
+
- When language is fuzzy, generic, overloaded, or imported from another context, pause coding and sharpen the local Ubiquitous Language.
|
|
35
|
+
- When the core concern drifts, terms stop matching code, or supporting complexity hides the core, reassess subdomains, boundaries, and modeling investment.
|
|
36
|
+
- When one model spreads across billing, identity, catalog, fulfillment, support, permissions, or other separate concerns, split or translate instead of reusing shared domain classes.
|
|
37
|
+
- When an upstream model, schema, UI, framework, API payload, transport object, or database shape starts defining the domain model, restore boundary translation.
|
|
38
|
+
- When using Shared Kernel, require small stable overlap, joint ownership, and tests; without governance, choose another relationship.
|
|
39
|
+
- When calling something an Anticorruption Layer, verify that real translation exists.
|
|
40
|
+
- When a request wants to load and mutate a large graph or several Aggregate roots, revisit the invariant boundary and ask whether eventual consistency is acceptable.
|
|
41
|
+
- When controllers, helpers, services, or transport-shaped application services contain business decisions, move behavior into the domain model or name the missing concept.
|
|
42
|
+
- When a Domain Event is command-like, vague, trivial, or emitted for every field change, redesign it as a specific business fact or remove it.
|
|
43
|
+
- When a concept is represented as a primitive, flag, status code, enum, or boolean but carries domain rules, promote it to a richer concept or Value Object.
|
|
44
|
+
- When delivery pressure tempts the team to skip design, use a short modeling spike, scenario, or acceptance test and record known modeling debt.
|
|
45
|
+
|
|
46
|
+
## Final checklist
|
|
47
|
+
|
|
48
|
+
- Correct subdomain and Core Domain investment?
|
|
49
|
+
- Explicit Bounded Context and relationship to neighboring contexts?
|
|
50
|
+
- Ubiquitous Language visible in code, tests, Commands, Events, APIs, and conversations?
|
|
51
|
+
- Translation tested where external or foreign meanings cross boundaries?
|
|
52
|
+
- Tactical patterns used only where they clarify meaning or protect invariants?
|
|
53
|
+
- Aggregates small, root-protected, identity-referenced, and not graph-shaped?
|
|
54
|
+
- Application Services coordinating rather than owning business logic?
|
|
55
|
+
- Infrastructure, persistence, REST, and transport details kept out of the domain model?
|
|
56
|
+
- Modeling discoveries, acceptance tests, expert input, and modeling debt captured before shipping?
|
package/templates/skills/domain-driven-design-distilled/domain-driven-design-distilled.nano.md
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
# OBEY Domain-Driven Design Distilled by Vaughn Vernon
|
|
2
|
+
|
|
3
|
+
## When to use
|
|
4
|
+
|
|
5
|
+
Use as compact DDD guidance when business language, context ownership, invariants, or integration meaning can affect the code.
|
|
6
|
+
|
|
7
|
+
## Primary bias to correct
|
|
8
|
+
|
|
9
|
+
DDD is selective modeling for real business complexity, not decorative layers, framework shape, or blanket tactical ceremony.
|
|
10
|
+
|
|
11
|
+
## Decision rules
|
|
12
|
+
|
|
13
|
+
- Start from business capability, subdomain type, Bounded Context, and local Ubiquitous Language before tactical patterns.
|
|
14
|
+
- Invest most design effort in the Core Domain; keep Supporting, Generic, CRUD, and mainly technical areas simpler.
|
|
15
|
+
- Put every meaningful model inside one explicit Bounded Context that owns its language, rules, semantics, code, tests, and integration contracts.
|
|
16
|
+
- Translate between contexts when meanings differ; never share domain classes or terms whose meanings diverge.
|
|
17
|
+
- Choose context relationships and integration mechanisms deliberately, including Conformist or Anticorruption Layer when foreign meaning is involved.
|
|
18
|
+
- Keep integration contracts separate from internal models, and do not expose Aggregate internals through REST or transport payloads.
|
|
19
|
+
- Use Entities for identity, Value Objects for validated meaning, Aggregates for small invariant boundaries, and Domain Events for meaningful past-tense facts.
|
|
20
|
+
- Modify one Aggregate per transaction by default; reference other Aggregates by identity and use eventual consistency when the business allows it.
|
|
21
|
+
- Keep business decisions in the domain model; Application Services coordinate use cases.
|
|
22
|
+
- Keep frameworks, persistence, transport, and external schemas out of the domain model.
|
|
23
|
+
- Use scenarios, acceptance tests, Event Storming, spikes, and domain-expert walkthroughs to learn quickly without hiding modeling debt.
|
|
24
|
+
|
|
25
|
+
## Trigger rules
|
|
26
|
+
|
|
27
|
+
- When language is fuzzy or overloaded, sharpen terms before coding.
|
|
28
|
+
- When one model absorbs unrelated concerns, redraw the subdomain or context boundary.
|
|
29
|
+
- When foreign models, schemas, APIs, or frameworks drive domain shape, add boundary translation.
|
|
30
|
+
- When a transaction wants many roots or a large graph, revisit Aggregate boundaries and consistency timing.
|
|
31
|
+
- When services, controllers, setters, flags, or primitives carry business decisions, expose the missing domain concept.
|
|
32
|
+
- When events are vague, command-like, or noisy field changes, redesign them as specific business facts.
|
|
33
|
+
|
|
34
|
+
## Final checklist
|
|
35
|
+
|
|
36
|
+
- Clear subdomain?
|
|
37
|
+
- Clear context?
|
|
38
|
+
- Clear language?
|
|
39
|
+
- Clear translation?
|
|
40
|
+
- Clear invariant boundary?
|
|
41
|
+
- Clear modeling debt?
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: implementation-plan
|
|
3
|
+
description: >
|
|
4
|
+
Create, execute, or resume a phased plan from Len's approved feature spec.
|
|
5
|
+
Use for implementation planning, phase execution, or plan status.
|
|
6
|
+
Requires approval before execution, then continues through verified phase
|
|
7
|
+
commits until completion or a real blocker.
|
|
8
|
+
license: MIT
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
# Implementation planning and execution
|
|
12
|
+
|
|
13
|
+
Read project `AGENTS.md` and the current handoff for authority, commits, recovery, and evidence policy.
|
|
14
|
+
For planning, read the approved product baseline, architecture, and feature spec before choosing tasks.
|
|
15
|
+
An approved spec alone does not approve a new plan.
|
|
16
|
+
|
|
17
|
+
## Create a plan
|
|
18
|
+
|
|
19
|
+
Use `.agents/templates/docs/IMPLEMENTATION_PLAN.md`, installed by `len-toolkit start`.
|
|
20
|
+
In the toolkit source checkout, the same source template is `templates/docs/IMPLEMENTATION_PLAN.md`.
|
|
21
|
+
Write the active feature plan under `docs/plans/FEAT-NNN-implementation.md` unless an existing convention applies.
|
|
22
|
+
Keep a root `IMPLEMENTATION_PLAN.md` pointer when useful; do not maintain a second task checklist there.
|
|
23
|
+
Link tasks and verification to stable requirement IDs.
|
|
24
|
+
Choose the number of phases by testable outcomes, with one phase sufficient for small work.
|
|
25
|
+
Inspect actual branch, existing edits, scripts, and environment before filling commands; unresolved placeholders cannot pass a readiness gate.
|
|
26
|
+
Present the feature spec and plan to Len for chat approval and record exact approved revisions in the current handoff.
|
|
27
|
+
|
|
28
|
+
## Execute or resume
|
|
29
|
+
|
|
30
|
+
Reread the approved files and reconcile plan state with actual Git status and evidence.
|
|
31
|
+
Do not treat a checked box as proof that a command ran or a commit succeeded.
|
|
32
|
+
Implement only the approved phase, verify with its required commands or scenarios, and review the diff for correctness and Ponytail simplicity.
|
|
33
|
+
Update evidence, task progress, and handoff; stage only the reviewed phase paths and verify the staged diff.
|
|
34
|
+
Complete the checkpoint only when Git confirms the phase commit succeeded.
|
|
35
|
+
Proceed automatically through the remaining approved phases without requesting routine sign-off.
|
|
36
|
+
If execution is interrupted, preserve edits uncommitted and record the exact next step.
|
|
37
|
+
|
|
38
|
+
## Failure report
|
|
39
|
+
|
|
40
|
+
Follow the shared three-attempt limit, counting attempted corrections followed by a check for the same problem.
|
|
41
|
+
Report the failed requirement or gate, actual error, each attempt and result, outstanding edits, dependent work blocked, and the smallest decision or access needed.
|
|
42
|
+
Do not reset counts between sessions or substitute a different architecture to force progress.
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: implementing-domain-driven-design
|
|
3
|
+
description: Apply Vaughn Vernon-inspired implementation DDD rules when building aggregates, domain events, repositories, application services, or context integrations.
|
|
4
|
+
license: MIT
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Implementing Domain-Driven Design Skill
|
|
8
|
+
|
|
9
|
+
Use this skill when a task involves implementing DDD in code: aggregate boundaries, invariants, repositories, domain events, application services, modules, factories, or bounded-context integration.
|
|
10
|
+
|
|
11
|
+
Before making design or code decisions, read and apply [implementing-domain-driven-design.mini.md](implementing-domain-driven-design.mini.md). Use [implementing-domain-driven-design.md](implementing-domain-driven-design.md) only as a deeper reference when the mini rules are not enough for the current implementation tradeoff.
|