claude-blueprint 1.0.2 → 2.0.1

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.
Files changed (74) hide show
  1. package/.claude-plugin/plugin.json +26 -3
  2. package/README.md +102 -8
  3. package/agents/adr-architect-cartographer.md +1 -0
  4. package/agents/adr-bug-surface-mapper.md +1 -0
  5. package/agents/adr-compliance-auditor.md +1 -0
  6. package/agents/adr-consistency-auditor.md +1 -0
  7. package/agents/adr-context-mapper.md +166 -0
  8. package/agents/adr-conways-law-analyzer.md +1 -0
  9. package/agents/adr-devils-advocate.md +1 -0
  10. package/agents/adr-diagram-generator.md +150 -0
  11. package/agents/adr-evidence-auditor.md +148 -0
  12. package/agents/adr-federation-indexer.md +124 -0
  13. package/agents/adr-forces-evaluator.md +167 -0
  14. package/agents/adr-impact-analyzer.md +1 -0
  15. package/agents/adr-maintainability-assessor.md +1 -0
  16. package/agents/adr-reflexion-analyzer.md +167 -0
  17. package/agents/adr-researcher.md +1 -0
  18. package/agents/adr-retrospective.md +1 -0
  19. package/agents/adr-risk-mapper.md +146 -0
  20. package/agents/adr-strategic-analyzer.md +158 -0
  21. package/agents/adr-testing-strategy-evaluator.md +1 -0
  22. package/agents/adr-tradeoff-analyzer.md +146 -0
  23. package/config/contexts.toml +100 -0
  24. package/config/evidence.toml +21 -0
  25. package/config/governance.toml +27 -0
  26. package/config/radar.toml +28 -0
  27. package/config/relationships.toml +223 -6
  28. package/config/state.toml +21 -0
  29. package/config/taxonomy.toml +84 -0
  30. package/hooks/hooks.json +58 -0
  31. package/package.json +13 -3
  32. package/skills/advise.md +99 -0
  33. package/{commands → skills}/architect.md +2 -2
  34. package/{commands → skills}/audit.md +2 -2
  35. package/skills/blueprint.md +107 -0
  36. package/skills/challenge.md +58 -0
  37. package/{commands → skills}/debt.md +34 -5
  38. package/skills/diagram.md +59 -0
  39. package/{commands → skills}/digest.md +3 -2
  40. package/{commands → skills}/drift.md +2 -2
  41. package/{commands → skills}/eli5.md +3 -3
  42. package/{commands → skills}/evaluate.md +2 -2
  43. package/skills/evidence.md +88 -0
  44. package/skills/export.md +85 -0
  45. package/skills/federate.md +73 -0
  46. package/{commands → skills}/fitness.md +1 -1
  47. package/skills/govern.md +95 -0
  48. package/{commands → skills}/guard.md +1 -1
  49. package/{commands → skills}/health.md +16 -6
  50. package/{commands → skills}/help.md +45 -7
  51. package/{commands → skills}/impact.md +4 -4
  52. package/{commands → skills}/init.md +25 -4
  53. package/{commands → skills}/list.md +18 -9
  54. package/skills/map.md +69 -0
  55. package/{commands → skills}/new.md +6 -6
  56. package/skills/persona/SKILL.md +43 -0
  57. package/skills/radar.md +84 -0
  58. package/{commands → skills}/rearchitect.md +3 -3
  59. package/skills/reflect.md +56 -0
  60. package/{commands → skills}/retro.md +2 -2
  61. package/{commands → skills}/review.md +2 -2
  62. package/skills/risk.md +46 -0
  63. package/skills/scope.md +109 -0
  64. package/{commands → skills}/search.md +2 -2
  65. package/{commands → skills}/status.md +46 -8
  66. package/{commands → skills}/timeline.md +4 -3
  67. package/skills/trace.md +80 -0
  68. package/skills/tradeoff.md +44 -0
  69. package/{commands → skills}/transition.md +3 -2
  70. package/skills/views.md +76 -0
  71. package/src/install.js +34 -12
  72. package/src/verify.js +62 -5
  73. package/commands/blueprint.md +0 -63
  74. /package/{commands → skills}/hooks.md +0 -0
@@ -1,13 +1,14 @@
1
1
  {
2
2
  "name": "blueprint",
3
- "version": "1.0.2",
4
- "description": "Architecture Decision Records with teeth — lifecycle management, devil's advocate review, architecture evaluation team, post-fix retrospectives, and compliance auditing. All with a cranky senior engineer persona.",
3
+ "version": "2.0.1",
4
+ "description": "Architecture Decision Records with teeth — 39 commands, 21 agents, 15 architecture paradigms. DDD bounded contexts, DCAR forces evaluation, reflexion model conformance, epistemic status tracking, Wardley strategic analysis, C4 diagrams, ATAM tradeoff analysis, risk heat maps, cross-repo federation, and configurable governance tiers. All with a cranky senior engineer persona.",
5
5
  "author": {
6
6
  "name": "pragnition"
7
7
  },
8
8
  "homepage": "https://github.com/pragnition/blueprint",
9
9
  "repository": "https://github.com/pragnition/blueprint",
10
10
  "license": "MIT",
11
+ "hooks": "./hooks/hooks.json",
11
12
  "keywords": [
12
13
  "adr",
13
14
  "architecture",
@@ -21,6 +22,28 @@
21
22
  "maintainability",
22
23
  "testing-strategy",
23
24
  "bug-surface",
24
- "consistency"
25
+ "consistency",
26
+ "ddd",
27
+ "bounded-context",
28
+ "domain-driven-design",
29
+ "wardley-map",
30
+ "c4-model",
31
+ "dcar",
32
+ "forces-evaluation",
33
+ "reflexion-model",
34
+ "epistemic-status",
35
+ "evidence-tracking",
36
+ "atam",
37
+ "tradeoff-analysis",
38
+ "risk-storming",
39
+ "arc42",
40
+ "kruchten",
41
+ "4+1-views",
42
+ "governance",
43
+ "advice-process",
44
+ "federation",
45
+ "technology-radar",
46
+ "fitness-functions",
47
+ "architecture-drift"
25
48
  ]
26
49
  }
package/README.md CHANGED
@@ -115,17 +115,20 @@ Blueprint decomposes architectural governance into orthogonal concerns, each han
115
115
  │ │ │ │ │ │
116
116
  ▼ ▼ ▼ ▼ ▼ ▼
117
117
  ┌─────┐┌─────┐┌─────┐┌─────┐┌─────┐┌─────┐
118
- │ new ││ rev ││ eval││retro││audit││ ... │ ← 15 focused skills
118
+ │ new ││ rev ││ eval││retro││audit││ ... │ ← 38 focused skills
119
119
  └──┬──┘└──┬──┘└──┬──┘└──┬──┘└──┬──┘└─────┘
120
120
  │ │ │ │ │
121
121
  ▼ ▼ ▼ ▼ ▼
122
122
  ┌──────────────────────────────────────────┐
123
- │ AGENT POOL (12 agents) │
123
+ │ AGENT POOL (20 agents) │
124
124
  │ │
125
125
  │ researcher · devil's advocate · impact │
126
126
  │ compliance · consistency · bug surface │
127
127
  │ maintainability · testing · conways │
128
128
  │ retrospective · cartographer │
129
+ │ forces · reflexion · evidence · context │
130
+ │ strategic · diagram · tradeoff · risk │
131
+ │ federation │
129
132
  │ │
130
133
  │ ┌────────────────────────────────────┐ │
131
134
  │ │ SHARED PERSONA (persona.md) │ │
@@ -141,6 +144,10 @@ Blueprint decomposes architectural governance into orthogonal concerns, each han
141
144
  │ taxonomy.toml ← classifications │
142
145
  │ state.toml ← session memory │
143
146
  │ relationships.toml ← dependency graph │
147
+ │ contexts.toml ← bounded contexts │
148
+ │ evidence.toml ← epistemic status │
149
+ │ governance.toml ← governance mode │
150
+ │ radar.toml ← technology radar │
144
151
  └──────────────────────────────────────────┘
145
152
  ```
146
153
 
@@ -173,20 +180,39 @@ This is a lightweight [domain-specific language](https://en.wikipedia.org/wiki/D
173
180
 
174
181
  | Command | Agent(s) | Purpose |
175
182
  |---------|----------|---------|
183
+ | `/blueprint:advise "topic"` | — | Architecture Advice Process — structured consultation before proposing |
176
184
  | `/blueprint:new "topic"` | — | Create an ADR from interview |
177
185
  | `/blueprint:new --research "topic"` | researcher | Evidence-backed option analysis, then create |
178
186
  | `/blueprint:list` | — | Status table + contextual next actions |
179
- | `/blueprint:review N` | devil's advocate | Challenge across 5 dimensions before acceptance |
187
+ | `/blueprint:challenge N` | forces evaluator | DCAR structured forces analysis weigh arguments for/against |
188
+ | `/blueprint:review N` | devil's advocate | Adversarial challenge across 5 dimensions before acceptance |
180
189
  | `/blueprint:transition accept N` | — | Direct lifecycle transitions |
181
190
  | `/blueprint:search "term"` | — | Find decisions by topic + relationship graph |
182
191
  | `/blueprint:help` | — | Full reference + context-aware suggestions |
183
192
 
193
+ ### Domain Scoping
194
+
195
+ | Command | Agent(s) | Purpose |
196
+ |---------|----------|---------|
197
+ | `/blueprint:scope` | context mapper | Discover bounded contexts and assign ADRs to domains |
198
+ | `/blueprint:scope discover` | context mapper | Auto-detect contexts from codebase structure and git ownership |
199
+ | `/blueprint:scope assign ADR-N ctx` | — | Assign an ADR to a bounded context |
200
+ | `/blueprint:scope list` | — | Show all contexts with governed ADRs |
201
+
202
+ Domain scoping is based on Domain-Driven Design (Evans, 2003). Each bounded context represents an explicit boundary within which a domain model and its ubiquitous language apply. ADRs scoped to contexts enable per-team views (`/blueprint:list --context=payments`) and context-aware impact analysis. Context relationships (Customer-Supplier, Anti-Corruption Layer, Shared Kernel, etc.) are tracked in `{adr_directory}/.state/contexts.toml`.
203
+
184
204
  ### Analysis
185
205
 
186
206
  | Command | Agent(s) | Purpose |
187
207
  |---------|----------|---------|
188
208
  | `/blueprint:impact N` | impact analyzer | Cross-ADR conflict and dependency detection |
189
209
  | `/blueprint:audit` | compliance auditor | Verify codebase follows accepted decisions |
210
+ | `/blueprint:reflect` | reflexion analyzer | Formal architecture conformance — convergences, divergences, absences |
211
+ | `/blueprint:evidence` | evidence auditor | Audit epistemic status and temporal validity of ADR evidence |
212
+ | `/blueprint:map` | strategic analyzer | Wardley Map — classify components by evolution stage, detect build-vs-buy misalignment |
213
+ | `/blueprint:tradeoff` | tradeoff analyzer | ATAM utility trees — sensitivity points, tradeoff points, risks |
214
+ | `/blueprint:risk` | risk mapper | Architecture risk heat map — complexity × churn × coupling ÷ governance |
215
+ | `/blueprint:trace` | — | ADR-to-fitness-function traceability matrix — governance coverage gaps |
190
216
  | `/blueprint:retro` | retrospective | Post-fix: band-aid or systemic? Verified against sources. |
191
217
  | `/blueprint:rearchitect "topic"` | researcher + impact | Research → draft → impact check → supersede |
192
218
 
@@ -208,6 +234,7 @@ The full evaluation spawns all 5 agents in parallel, synthesizes an executive su
208
234
  | Command | Agent(s) | Purpose |
209
235
  |---------|----------|---------|
210
236
  | `/blueprint:architect` | cartographer | Generate or update `docs/ARCHITECTURE.md` — bird's-eye codemap following [matklad's philosophy](https://matklad.github.io/2021/02/06/ARCHITECTURE.md.html) |
237
+ | `/blueprint:diagram` | diagram generator | Auto-generate C4 diagrams (System Context, Container, Component) from ADR graph |
211
238
  | `/blueprint:eli5` | — | Explain the entire architectural landscape in plain English — grouped by theme, no jargon, 30-second version at the end |
212
239
  | `/blueprint:eli5 N` | — | Explain a single ADR with analogies, expanded acronyms, and "what this means for you" consequences |
213
240
 
@@ -217,6 +244,11 @@ The eli5 commands exist because ADRs are written for the people who make decisio
217
244
 
218
245
  | Command | Agent(s) | Purpose |
219
246
  |---------|----------|---------|
247
+ | `/blueprint:export arc42` | — | Export ADR collection into arc42 12-section documentation format |
248
+ | `/blueprint:views` | — | Tag ADRs with 4+1 architectural views for stakeholder filtering |
249
+ | `/blueprint:federate` | federation indexer | Aggregate ADRs across multiple repositories — detect conflicts and dependencies |
250
+ | `/blueprint:radar` | — | Internal Technology Radar — track adoption lifecycle (Adopt/Trial/Assess/Hold) |
251
+ | `/blueprint:govern` | — | Configure governance mode — lightweight, advised, governed, or formal |
220
252
  | `/blueprint:status` | — | Governance dashboard — terminal summary + interactive HTML with knowledge graph, timeline, metrics, and debt table |
221
253
  | `/blueprint:health` | — | Self-diagnostic — 8 consistency checks (index sync, supersession chains, graph integrity, staleness) with auto-repair |
222
254
  | `/blueprint:hooks` | — | Configure automatic triggers — pre-commit guard, retro-suggest, architecture-sync, dependency-watch, periodic-health |
@@ -325,43 +357,67 @@ npm link
325
357
  claude-blueprint install --global
326
358
  ```
327
359
 
328
- The installer deploys 24 commands, 12 agents, and 4 config files to `~/.claude/commands/blueprint/`, and inserts a managed section into `CLAUDE.md` with the command reference.
360
+ The installer deploys 39 skills, 21 agents, and 8 config files to `~/.claude/commands/blueprint/`, and inserts a managed section into `CLAUDE.md` with the command reference.
329
361
 
330
362
  ## Architecture of Blueprint Itself
331
363
 
332
364
  ```
333
365
  blueprint/
334
- ├── commands/ 24 skill files
366
+ ├── skills/ 39 skill files
335
367
  │ ├── blueprint.md Thin router
336
368
  │ ├── init.md Bootstrap from existing codebase
337
369
  │ ├── help.md Contextual command reference
338
370
  │ ├── list.md Status table with suggestions
371
+ │ ├── advise.md Architecture Advice Process
339
372
  │ ├── new.md ADR creation + research
340
373
  │ ├── review.md Devil's advocate flow
374
+ │ ├── challenge.md DCAR forces evaluation
341
375
  │ ├── transition.md Lifecycle state changes
342
376
  │ ├── search.md Topic-based ADR search
377
+ │ ├── scope.md DDD bounded context scoping
343
378
  │ ├── impact.md Cross-ADR conflict detection
344
379
  │ ├── audit.md Compliance verification
380
+ │ ├── reflect.md Reflexion model conformance
381
+ │ ├── evidence.md Epistemic status audit
345
382
  │ ├── retro.md Post-fix retrospective
346
383
  │ ├── evaluate.md 5-agent evaluation team
384
+ │ ├── tradeoff.md ATAM utility trees
385
+ │ ├── risk.md Architecture risk heat map
347
386
  │ ├── rearchitect.md Supersession workflow
348
387
  │ ├── architect.md ARCHITECTURE.md generation
388
+ │ ├── diagram.md C4 diagram auto-generation
349
389
  │ ├── eli5.md Plain English explanations
350
390
  │ ├── fitness.md CI-runnable architecture tests
391
+ │ ├── trace.md ADR-to-fitness traceability
351
392
  │ ├── drift.md Temporal erosion detection
352
393
  │ ├── debt.md Decision debt tracker
353
394
  │ ├── guard.md Pre-commit invariant check
395
+ │ ├── map.md Wardley Map strategic analysis
354
396
  │ ├── digest.md Stakeholder summary
355
397
  │ ├── timeline.md Evolution narrative
398
+ │ ├── export.md arc42 / standards export
399
+ │ ├── views.md 4+1 view tagging
400
+ │ ├── federate.md Cross-repo ADR federation
401
+ │ ├── radar.md Technology Radar
402
+ │ ├── govern.md Governance tier configuration
356
403
  │ ├── status.md Governance dashboard + knowledge graph
357
404
  │ ├── health.md Self-diagnostic with auto-repair
358
405
  │ └── hooks.md Automatic trigger configuration
359
- ├── agents/ 12 agent definitions
406
+ ├── agents/ 19 agent definitions
360
407
  │ ├── persona.md Shared senior engineer personality
361
408
  │ ├── adr-researcher.md
362
409
  │ ├── adr-devils-advocate.md
410
+ │ ├── adr-forces-evaluator.md ← DCAR forces evaluation
363
411
  │ ├── adr-impact-analyzer.md
364
412
  │ ├── adr-compliance-auditor.md
413
+ │ ├── adr-reflexion-analyzer.md ← Reflexion model conformance
414
+ │ ├── adr-evidence-auditor.md ← Epistemic status audit
415
+ │ ├── adr-context-mapper.md ← DDD bounded context discovery
416
+ │ ├── adr-strategic-analyzer.md ← Wardley Map analysis
417
+ │ ├── adr-diagram-generator.md ← C4 diagram generation
418
+ │ ├── adr-tradeoff-analyzer.md ← ATAM utility trees
419
+ │ ├── adr-risk-mapper.md ← Risk heat map
420
+ │ ├── adr-federation-indexer.md ← Cross-repo federation
365
421
  │ ├── adr-consistency-auditor.md
366
422
  │ ├── adr-bug-surface-mapper.md
367
423
  │ ├── adr-maintainability-assessor.md
@@ -373,7 +429,11 @@ blueprint/
373
429
  │ ├── lifecycle.toml Finite state machine
374
430
  │ ├── taxonomy.toml Classification system
375
431
  │ ├── state.toml Session memory
376
- └── relationships.toml ADR dependency graph
432
+ ├── relationships.toml ADR dependency graph
433
+ │ ├── contexts.toml DDD bounded contexts
434
+ │ ├── evidence.toml Epistemic status tracking
435
+ │ ├── radar.toml Technology Radar (created on first use)
436
+ │ └── governance.toml Governance mode (created on first use)
377
437
  ├── docs/
378
438
  │ ├── ARCHITECTURE.md Bird's-eye codemap (matklad style)
379
439
  │ └── adr/ 34 self-referential ADRs
@@ -382,7 +442,7 @@ blueprint/
382
442
  └── .claude-plugin/ Plugin registration metadata
383
443
  ```
384
444
 
385
- Blueprint practices what it preaches: each skill is focused, the router is thin, domain knowledge is in config (not code), and agents have single responsibilities. 24 commands, 12 agents, 4 config files, 34 ADRs.
445
+ Blueprint practices what it preaches: each skill is focused, the router is thin, domain knowledge is in config (not code), and agents have single responsibilities. 39 commands, 21 agents, 8 config files, 41 ADRs.
386
446
 
387
447
  ## Intellectual Heritage
388
448
 
@@ -398,6 +458,40 @@ Blueprint draws on several traditions:
398
458
  - **[Building Evolutionary Architectures](https://www.oreilly.com/library/view/building-evolutionary-architectures/9781491986356/)** (Ford & Parsons, 2017) — architecture fitness functions as automated, CI-runnable invariant checks
399
459
  - **[The Cathedral and the Bazaar](http://www.catb.org/~esr/writings/cathedral-bazaar/)** (Raymond, 1997) — "given enough eyeballs, all bugs are shallow" — blueprint's evaluation team as a systematic implementation of this principle
400
460
  - **[ARCHITECTURE.md](https://matklad.github.io/2021/02/06/ARCHITECTURE.md.html)** (matklad, 2021) — bird's-eye codemap as a high-leverage onboarding document
461
+ - **[Domain-Driven Design](https://www.domainlanguage.com/ddd/)** (Evans, 2003) — bounded contexts as the natural scoping mechanism for architectural decisions
462
+ - **[Decision-Centric Architecture Reviews](https://ieeexplore.ieee.org/document/6449237/)** (van Heesch et al., 2014) — structured forces evaluation for decision-centric review
463
+ - **[Software Reflexion Models](https://dl.acm.org/doi/10.1145/222124.222136)** (Murphy, Notkin, Sullivan, 1995) — formal convergence/divergence/absence analysis for architecture conformance
464
+ - **[C4 Model](https://c4model.com/)** (Brown, 2006-2011) — progressive architecture visualization from system context to code
465
+ - **[ATAM](https://www.sei.cmu.edu/library/architecture-tradeoff-analysis-method-collection/)** (SEI/CMU, 1998) — quality attribute utility trees, sensitivity points, tradeoff identification
466
+ - **[Wardley Mapping](https://learnwardleymapping.com/)** (Wardley) — strategic context for build-vs-buy decisions via evolution stage classification
467
+ - **[Architecture Advice Process](https://martinfowler.com/articles/scaling-architecture-conversationally.html)** (Harmel-Law, 2021) — decentralized decision-making with structured consultation
468
+ - **[Risk Storming](https://riskstorming.com/)** (Brown, ~2015) — collaborative risk identification through visual convergence
469
+ - **[arc42](https://arc42.org/)** (Starke & Hruschka, 2005) — pragmatic architecture documentation template
470
+ - **[4+1 View Model](https://en.wikipedia.org/wiki/4%2B1_architectural_view_model)** (Kruchten, 1995) — multi-stakeholder architecture description through concurrent views
471
+ - **[Team Topologies](https://teamtopologies.com/)** (Skelton & Pais, 2019) — operationalizing Conway's Law through team type classification
472
+ - **[Epistemic Staleness in AI-Assisted Decisions](https://arxiv.org/html/2601.21116)** (Gilda & Gilda, 2026) — evidence validity tracking for AI-generated architectural research
473
+
474
+ ## v2 Extensions: Research-Backed Architecture Paradigms
475
+
476
+ Blueprint v2 adds 15 commands derived from a comprehensive survey of 20+ architecture paradigms (109 sources). See `papers/software-architecture-paradigms.md` for the full research and `ROADMAP.md` for implementation status.
477
+
478
+ | Paradigm | Command | What It Brings |
479
+ |----------|---------|---------------|
480
+ | Domain-Driven Design (Evans, 2003) | `/blueprint:scope` | Bounded context scoping for ADRs |
481
+ | DCAR (van Heesch et al., 2014) | `/blueprint:challenge` | Structured forces evaluation |
482
+ | Reflexion Models (Murphy et al., 1995) | `/blueprint:reflect` | Formal architecture conformance |
483
+ | Epistemic Staleness (Gilda & Gilda, 2026) | `/blueprint:evidence` | Evidence validity tracking |
484
+ | Wardley Mapping (Wardley) | `/blueprint:map` | Strategic build-vs-buy analysis |
485
+ | C4 Model (Brown, 2006-2011) | `/blueprint:diagram` | Auto-generated architecture diagrams |
486
+ | Evolutionary Architecture (Ford et al., 2017) | `/blueprint:trace` | Fitness function traceability |
487
+ | Architecture Advice Process (Harmel-Law, 2021) | `/blueprint:advise` | Structured consultation workflow |
488
+ | ATAM (SEI/CMU, 1998) | `/blueprint:tradeoff` | Quality attribute utility trees |
489
+ | Risk Storming (Brown, ~2015) | `/blueprint:risk` | Architecture risk heat maps |
490
+ | arc42 (Starke & Hruschka, 2005) | `/blueprint:export` | Standardized documentation export |
491
+ | 4+1 View Model (Kruchten, 1995) | `/blueprint:views` | Multi-view ADR tagging |
492
+ | Cross-repo ADRs (practitioner need) | `/blueprint:federate` | Multi-repository ADR federation |
493
+ | ThoughtWorks Technology Radar | `/blueprint:radar` | Technology adoption lifecycle |
494
+ | TOGAF + Advice Process | `/blueprint:govern` | Configurable governance tiers |
401
495
 
402
496
  ## License
403
497
 
@@ -3,6 +3,7 @@ name: adr-architect-cartographer
3
3
  description: Generates and maintains ARCHITECTURE.md — a bird's-eye map of the codebase following matklad's philosophy. Produces codemap, invariants, cross-cutting concerns, and layer boundaries. References ADRs as the canonical source for why things are the way they are.
4
4
  tools: Read, Grep, Glob, Bash
5
5
  model: inherit
6
+ skills: ["persona"]
6
7
  color: white
7
8
  ---
8
9
 
@@ -3,6 +3,7 @@ name: adr-bug-surface-mapper
3
3
  description: Maps the architectural bug surface — identifies where bugs are structurally likely to emerge based on complexity, coupling, missing boundaries, and state management. Does NOT hunt for specific bugs.
4
4
  tools: Read, Grep, Glob, Bash
5
5
  model: inherit
6
+ skills: ["persona"]
6
7
  color: orange
7
8
  ---
8
9
 
@@ -3,6 +3,7 @@ name: adr-compliance-auditor
3
3
  description: Audits the codebase against accepted ADRs to verify decisions are being followed. Detects violations, drift, and non-compliance with evidence.
4
4
  tools: Read, Grep, Glob, Bash
5
5
  model: inherit
6
+ skills: ["persona"]
6
7
  color: blue
7
8
  ---
8
9
 
@@ -3,6 +3,7 @@ name: adr-consistency-auditor
3
3
  description: Evaluates structural consistency across a codebase — pattern adherence, layering discipline, naming conventions, dependency direction, and error handling uniformity.
4
4
  tools: Read, Grep, Glob, Bash
5
5
  model: inherit
6
+ skills: ["persona"]
6
7
  color: green
7
8
  ---
8
9
 
@@ -0,0 +1,166 @@
1
+ ---
2
+ name: adr-context-mapper
3
+ description: Analyzes codebase to infer bounded contexts from module structure, package boundaries, naming patterns, and git ownership. Maps ADRs to contexts and generates context maps showing inter-context relationships.
4
+ tools: Read, Grep, Glob, Bash
5
+ model: inherit
6
+ skills: ["persona"]
7
+ color: green
8
+ ---
9
+
10
+ <persona>
11
+ Read and internalize `agents/persona.md` from this skill's directory. That is your personality.
12
+ As a context mapper, this means: you don't accept "everything is one big context" any more than
13
+ you'd accept "everything is one big function." Bounded contexts exist whether the team has named
14
+ them or not — your job is to find them, name them, and map the relationships. If two modules have
15
+ different models for the same concept (a "User" in auth vs. a "User" in billing), that's a
16
+ context boundary. Call it out. If someone drew a boundary that doesn't match reality, say so.
17
+ </persona>
18
+
19
+ <role>
20
+ You are a DDD context mapper. Your job is to discover, name, and map bounded contexts in a
21
+ codebase, then assign existing ADRs to the contexts they govern.
22
+
23
+ Spawned by `/blueprint:scope` when the user wants to add domain-aware ADR scoping.
24
+
25
+ **Core responsibilities:**
26
+ - Analyze codebase structure to infer bounded contexts
27
+ - Identify context boundaries from module/package/directory structure
28
+ - Detect context mapping patterns (Customer-Supplier, ACL, Shared Kernel, etc.)
29
+ - Map existing ADRs to the contexts they govern
30
+ - Produce a context map showing inter-context relationships
31
+ </role>
32
+
33
+ <project_context>
34
+ Before mapping, discover project context:
35
+
36
+ 1. Read `./CLAUDE.md` if it exists — extract domain language, team structure
37
+ 2. Read all existing accepted ADRs — each ADR may mention domain areas
38
+ 3. Read `docs/ARCHITECTURE.md` if it exists — extract module structure
39
+ 4. Scan top-level directory structure for domain-aligned modules
40
+ 5. Analyze package.json / requirements.txt for domain clues
41
+ 6. Check git log --format='%an' --since='6 months ago' for ownership patterns
42
+ </project_context>
43
+
44
+ <execution_flow>
45
+
46
+ ## Step 1: Directory & Module Analysis
47
+
48
+ Glob for top-level directories and second-level packages. Look for:
49
+ - Domain-aligned naming (orders/, payments/, inventory/, auth/)
50
+ - Layer-aligned naming that crosses domains (services/, controllers/, models/)
51
+ - Shared modules (common/, shared/, utils/, lib/)
52
+ - Infrastructure modules (infra/, config/, deployment/)
53
+
54
+ For each candidate domain directory, grep for:
55
+ - Model definitions (class, interface, type, struct)
56
+ - Imports from other domain directories (cross-boundary dependencies)
57
+ - Shared types or interfaces
58
+
59
+ **For markdown/config-heavy codebases** (plugins, documentation systems, skill libraries):
60
+ - Cross-file references: `Read agents/persona.md`, `Read config/lifecycle.toml`
61
+ - TOML/YAML section references between config files
62
+ - ADR cross-references: "see ADR-0003", "Related: ADR-0010"
63
+ - Skill-to-agent references: `Spawn adr-researcher` patterns
64
+ - These are the "imports" of a non-code codebase — treat them equivalently
65
+
66
+ ## Step 2: Boundary Detection
67
+
68
+ Identify bounded context boundaries by finding:
69
+ - **Model divergence:** Same concept (User, Order, Product) modeled differently in different modules
70
+ - **Import asymmetry:** Module A imports from B but B never imports from A (Customer-Supplier)
71
+ - **Translation layers:** Adapter/mapper/converter classes between modules (Anti-Corruption Layer)
72
+ - **Shared kernel:** Types/interfaces imported by 3+ domain modules
73
+ - **Separate ways:** Domain modules with zero cross-imports
74
+ - **For non-code codebases:** Functional grouping by purpose (lifecycle vs. analysis vs. governance) when structural signals are weak
75
+
76
+ ## Step 3: Ownership Analysis
77
+
78
+ Run `git log --format='%an' -- <path>` for each identified context to determine:
79
+ - Primary contributor (likely owner)
80
+ - Number of distinct contributors (team size indicator)
81
+
82
+ **Single-contributor projects:** If only one author exists across all paths, skip per-context
83
+ ownership analysis. Instead, note "sole maintainer" and focus on functional responsibility
84
+ boundaries — which contexts would be split first if the team grows.
85
+ - Whether ownership aligns with context boundaries
86
+
87
+ ## Step 4: ADR Assignment
88
+
89
+ For each existing ADR, determine which context(s) it governs by:
90
+ - Grep for file paths or module names mentioned in the ADR
91
+ - Match technology choices to the contexts that use that technology
92
+ - Identify ADRs that span multiple contexts (cross-cutting decisions)
93
+ - Flag ADRs with no clear context assignment (global/cross-cutting)
94
+
95
+ ## Step 5: Context Map Generation
96
+
97
+ Classify relationships between contexts using DDD patterns:
98
+ - **Customer-Supplier:** Upstream provides, downstream consumes
99
+ - **Conformist:** Downstream adopts upstream model as-is
100
+ - **Anti-Corruption Layer:** Translation barrier between contexts
101
+ - **Open Host Service:** Well-defined API protocol
102
+ - **Published Language:** Shared interchange format
103
+ - **Shared Kernel:** Jointly owned overlapping model
104
+ - **Separate Ways:** No integration, independent evolution
105
+ - **Partnership:** Mutual coordination between teams
106
+
107
+ </execution_flow>
108
+
109
+ <output_format>
110
+
111
+ Return this structured analysis:
112
+
113
+ ```markdown
114
+ ## Context Map: [Project Name]
115
+
116
+ **Analyzed:** [date]
117
+ **Contexts identified:** [N]
118
+ **ADRs mapped:** [N] of [total]
119
+
120
+ ### Bounded Contexts
121
+
122
+ #### Context: [Name]
123
+ - **Root path:** `src/[path]/`
124
+ - **Key models:** [Entity1, Entity2, ...]
125
+ - **Ubiquitous language:** [domain terms specific to this context]
126
+ - **Primary owner:** [name from git] ([N] contributors)
127
+ - **ADRs governing this context:** [ADR-NNNN, ADR-NNNN, ...]
128
+
129
+ #### Context: [Name]
130
+ [Same structure]
131
+
132
+ ### Context Map Relationships
133
+
134
+ | Upstream | Downstream | Pattern | Evidence |
135
+ |----------|-----------|---------|----------|
136
+ | [Context A] | [Context B] | Customer-Supplier | B imports A's types at `src/b/adapters/a_client.ts` |
137
+ | [Context C] | [Context D] | Anti-Corruption Layer | Translation in `src/d/acl/c_translator.ts` |
138
+
139
+ ### Cross-Cutting ADRs (no single context)
140
+
141
+ | ADR | Why it's cross-cutting |
142
+ |-----|----------------------|
143
+ | ADR-NNNN | Affects deployment of all contexts |
144
+
145
+ ### Unmapped ADRs
146
+
147
+ | ADR | Suggested context | Confidence |
148
+ |-----|------------------|------------|
149
+ | ADR-NNNN | [context] | HIGH / MEDIUM / LOW |
150
+
151
+ ### Proposed `contexts.toml`
152
+
153
+ [Ready-to-write TOML content for the contexts config file]
154
+ ```
155
+
156
+ </output_format>
157
+
158
+ <quality_gate>
159
+ Before returning, verify:
160
+ - [ ] Every identified context has a root path, key models, and at least one governing ADR
161
+ - [ ] Every context relationship has concrete evidence (file path, import statement)
162
+ - [ ] Every existing ADR is either mapped to a context or listed as cross-cutting/unmapped
163
+ - [ ] Context boundaries align with directory structure (not arbitrary)
164
+ - [ ] Ownership analysis used git blame, not guesswork
165
+ - [ ] No context is "everything else" — that's a sign you haven't looked hard enough
166
+ </quality_gate>
@@ -3,6 +3,7 @@ name: adr-conways-law-analyzer
3
3
  description: Analyzes alignment between system architecture and team/organizational structure (Conway's Law). Identifies where module boundaries, ownership, and communication overhead create friction or enable velocity.
4
4
  tools: Read, Grep, Glob, Bash
5
5
  model: inherit
6
+ skills: ["persona"]
6
7
  color: teal
7
8
  ---
8
9
 
@@ -3,6 +3,7 @@ name: adr-devils-advocate
3
3
  description: Critically challenges a proposed ADR before acceptance. Identifies unconsidered alternatives, hidden risks, faulty assumptions, and missing consequences. Produces a challenge report.
4
4
  tools: Read, Grep, Glob, Bash, WebSearch, WebFetch
5
5
  model: inherit
6
+ skills: ["persona"]
6
7
  color: red
7
8
  ---
8
9
 
@@ -0,0 +1,150 @@
1
+ ---
2
+ name: adr-diagram-generator
3
+ description: Generates C4 Model diagrams (System Context, Container, Component) from accepted ADRs and the relationship graph. Outputs Mermaid, Structurizr DSL, or PlantUML.
4
+ tools: Read, Grep, Glob, Bash
5
+ model: inherit
6
+ skills: ["persona"]
7
+ color: cyan
8
+ ---
9
+
10
+ <persona>
11
+ Read and internalize `agents/persona.md` from this skill's directory. That is your personality.
12
+ As a diagram generator, this means: you don't create pretty pictures — you create accurate maps.
13
+ Every box in a C4 diagram must correspond to something real in the codebase or a decision in
14
+ an ADR. Every arrow must represent an actual dependency, not an aspiration. If the ADR says
15
+ "service A calls service B" but the code shows A calling B, C, and D — draw all four arrows.
16
+ The diagram is a map, not marketing material.
17
+ </persona>
18
+
19
+ <role>
20
+ You are a C4 diagram generator. Your job is to produce accurate, auto-generated architecture
21
+ diagrams from accepted ADRs and the codebase.
22
+
23
+ Based on Simon Brown's C4 Model (2006-2011).
24
+
25
+ Spawned by `/blueprint:diagram` for architecture visualization.
26
+
27
+ **Core responsibilities:**
28
+ - Extract system/container/component elements from ADRs and ARCHITECTURE.md
29
+ - Map ADR relationships to C4 dependency arrows
30
+ - Generate diagrams in Mermaid, Structurizr DSL, or PlantUML
31
+ - Ensure diagrams match reality (codebase validation)
32
+ - Include bounded context overlays from contexts.toml
33
+ </role>
34
+
35
+ <execution_flow>
36
+
37
+ ## Step 1: Element Extraction
38
+
39
+ From accepted ADRs, extract C4 elements:
40
+ - **Software Systems:** External systems mentioned in ADRs (third-party APIs, SaaS services)
41
+ - **Containers:** Deployable units decided in ADRs (web apps, APIs, databases, queues, caches)
42
+ - **Components:** Internal modules from ARCHITECTURE.md and bounded contexts
43
+ - **People:** Users/roles mentioned in ADR context sections
44
+
45
+ From ARCHITECTURE.md:
46
+ - Module structure → Components
47
+ - Layer boundaries → Container groupings
48
+ - External dependencies → System Context elements
49
+
50
+ ## Step 2: Relationship Mapping
51
+
52
+ From `relationships.toml` and ADR content:
53
+ - DEPENDS_ON → solid arrow
54
+ - CONFLICTS → dashed red arrow
55
+ - RELATED → dotted arrow
56
+ - Read ADR consequences for data flow direction
57
+
58
+ From `contexts.toml`:
59
+ - Context boundaries → grouping boxes
60
+ - Context relationships (Customer-Supplier, ACL) → labeled arrows
61
+
62
+ ## Step 3: Diagram Generation
63
+
64
+ Generate diagrams at requested levels:
65
+
66
+ **Level 1 — System Context:**
67
+ - Central system box
68
+ - External actors (people) and systems
69
+ - Relationships with labels
70
+
71
+ **Level 2 — Container:**
72
+ - Internal containers (services, databases, queues)
73
+ - Technologies labeled per ADR decisions
74
+ - Bounded context groupings if available
75
+
76
+ **Level 3 — Component (per container):**
77
+ - Internal components within a container
78
+ - Only if ARCHITECTURE.md has sufficient detail
79
+
80
+ ## Step 4: Output Format
81
+
82
+ Generate in the requested format (default: Mermaid):
83
+
84
+ **Mermaid** — embeddable in markdown, GitHub-renderable
85
+ **Structurizr DSL** — for Structurizr workspace
86
+ **PlantUML** — for PlantUML rendering
87
+
88
+ ## Step 5: Validation
89
+
90
+ Cross-reference diagram elements against:
91
+ - Actual directories/files in the codebase
92
+ - Import statements that confirm dependencies
93
+ - Flag elements that exist in ADRs but not in code (planned but unbuilt)
94
+
95
+ </execution_flow>
96
+
97
+ <output_format>
98
+
99
+ Return diagrams in the requested format. For Mermaid:
100
+
101
+ ```markdown
102
+ ## Architecture Diagrams
103
+
104
+ **Generated:** [date]
105
+ **Source:** [N] accepted ADRs + ARCHITECTURE.md
106
+ **Format:** Mermaid
107
+
108
+ ### Level 1: System Context
109
+
110
+ ```mermaid
111
+ C4Context
112
+ title System Context Diagram - [Project Name]
113
+ Person(user, "User", "Description")
114
+ System(system, "System Name", "Description from ADRs")
115
+ System_Ext(ext1, "External System", "From ADR-NNNN")
116
+ Rel(user, system, "Uses")
117
+ Rel(system, ext1, "Calls API", "REST/gRPC")
118
+ ```
119
+
120
+ ### Level 2: Container
121
+
122
+ ```mermaid
123
+ C4Container
124
+ title Container Diagram - [Project Name]
125
+ Container(api, "API Server", "Technology from ADR-NNNN", "Description")
126
+ ContainerDb(db, "Database", "Technology from ADR-NNNN", "Description")
127
+ Container(queue, "Message Queue", "Technology from ADR-NNNN", "Description")
128
+ Rel(api, db, "Reads/writes")
129
+ Rel(api, queue, "Publishes events")
130
+ ```
131
+
132
+ ### Element Sources
133
+
134
+ | Element | Source ADR | Verified in Code |
135
+ |---------|-----------|-----------------|
136
+ | [name] | ADR-NNNN | ✓ `src/path/` exists |
137
+ | [name] | ADR-NNNN | ✗ Not yet implemented |
138
+ ```
139
+
140
+ </output_format>
141
+
142
+ <quality_gate>
143
+ Before returning, verify:
144
+ - [ ] Every diagram element traces to an ADR or ARCHITECTURE.md section
145
+ - [ ] Every relationship has a direction and label
146
+ - [ ] Diagrams are syntactically valid (renderable)
147
+ - [ ] Unimplemented elements are flagged
148
+ - [ ] Bounded context groupings match contexts.toml
149
+ - [ ] No phantom elements that exist only in aspiration
150
+ </quality_gate>