@eltonssouza/development-utility-kit 0.10.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.
Files changed (131) hide show
  1. package/.claude/agents/README.md +24 -0
  2. package/.claude/agents/analyst.md +198 -0
  3. package/.claude/agents/backend-developer.md +126 -0
  4. package/.claude/agents/brain-keeper.md +229 -0
  5. package/.claude/agents/code-reviewer.md +181 -0
  6. package/.claude/agents/database-engineer.md +94 -0
  7. package/.claude/agents/devops-engineer.md +141 -0
  8. package/.claude/agents/frontend-developer.md +97 -0
  9. package/.claude/agents/gate-keeper.md +118 -0
  10. package/.claude/agents/migrator.md +291 -0
  11. package/.claude/agents/mobile-developer.md +80 -0
  12. package/.claude/agents/n8n-specialist.md +94 -0
  13. package/.claude/agents/product-owner.md +115 -0
  14. package/.claude/agents/qa-engineer.md +232 -0
  15. package/.claude/agents/release-engineer.md +204 -0
  16. package/.claude/agents/scaffold.md +87 -0
  17. package/.claude/agents/security-engineer.md +199 -0
  18. package/.claude/agents/sprint-runner.md +46 -0
  19. package/.claude/agents/stack-resolver.md +104 -0
  20. package/.claude/agents/tech-lead.md +182 -0
  21. package/.claude/agents/update-template.md +54 -0
  22. package/.claude/agents/ux-designer.md +118 -0
  23. package/.claude/hooks/flow-guard.js +261 -0
  24. package/.claude/hooks/flow-state.js +197 -0
  25. package/.claude/local/CLAUDE.md +71 -0
  26. package/.claude/settings.json +55 -0
  27. package/.claude/skills/README.md +331 -0
  28. package/.claude/skills/active-project/SKILL.md +131 -0
  29. package/.claude/skills/api-integration-test/SKILL.md +84 -0
  30. package/.claude/skills/auto-test-guard/SKILL.md +239 -0
  31. package/.claude/skills/auto-test-guard/resources/backend-tests.md +20 -0
  32. package/.claude/skills/auto-test-guard/resources/e2e-tests.md +24 -0
  33. package/.claude/skills/auto-test-guard/resources/execution-report.md +49 -0
  34. package/.claude/skills/auto-test-guard/resources/frontend-tests.md +18 -0
  35. package/.claude/skills/auto-test-guard/resources/initial-setup.md +108 -0
  36. package/.claude/skills/auto-test-guard/resources/run-suite.md +48 -0
  37. package/.claude/skills/auto-test-guard/resources/senior-gate.md +19 -0
  38. package/.claude/skills/brain-keeper/SKILL.md +62 -0
  39. package/.claude/skills/brain-keeper/obsidian/app.json +9 -0
  40. package/.claude/skills/brain-keeper/obsidian/appearance.json +4 -0
  41. package/.claude/skills/brain-keeper/obsidian/core-plugins.json +20 -0
  42. package/.claude/skills/brain-keeper/obsidian/daily-notes.json +5 -0
  43. package/.claude/skills/brain-keeper/obsidian/graph.json +32 -0
  44. package/.claude/skills/brain-keeper/obsidian/snippets/folder-colors.css +90 -0
  45. package/.claude/skills/brain-keeper/obsidian/templates.json +5 -0
  46. package/.claude/skills/brain-keeper/templates/README.md +51 -0
  47. package/.claude/skills/brain-keeper/templates/adr.md +40 -0
  48. package/.claude/skills/brain-keeper/templates/bug.md +35 -0
  49. package/.claude/skills/brain-keeper/templates/daily.md +38 -0
  50. package/.claude/skills/brain-keeper/templates/feature.md +62 -0
  51. package/.claude/skills/brain-keeper/templates/meeting.md +34 -0
  52. package/.claude/skills/brain-keeper/templates/tech-debt.md +21 -0
  53. package/.claude/skills/caveman/SKILL.md +189 -0
  54. package/.claude/skills/create-stack-pack/SKILL.md +281 -0
  55. package/.claude/skills/grill-me/SKILL.md +80 -0
  56. package/.claude/skills/pair-debug/SKILL.md +288 -0
  57. package/.claude/skills/prd-ready-check/SKILL.md +86 -0
  58. package/.claude/skills/project-manager/SKILL.md +334 -0
  59. package/.claude/skills/quality-standards/SKILL.md +203 -0
  60. package/.claude/skills/quick-feature/SKILL.md +266 -0
  61. package/.claude/skills/run-sprint/SKILL.md +41 -0
  62. package/.claude/skills/scaffold/SKILL.md +60 -0
  63. package/.claude/skills/stack-discovery/SKILL.md +161 -0
  64. package/.claude/skills/test-coverage-auditor/SKILL.md +87 -0
  65. package/.claude/skills/to-issues/SKILL.md +163 -0
  66. package/.claude/skills/to-prd/SKILL.md +130 -0
  67. package/.claude/skills/update-template/SKILL.md +256 -0
  68. package/.claude/stacks/CODEOWNERS +30 -0
  69. package/.claude/stacks/README.md +97 -0
  70. package/.claude/stacks/_template.md +116 -0
  71. package/.claude/stacks/dotnet/aspire-9.md +528 -0
  72. package/.claude/stacks/go/gin-1.10.md +570 -0
  73. package/.claude/stacks/java/spring-boot-3.md +376 -0
  74. package/.claude/stacks/java/spring-boot-4.md +438 -0
  75. package/.claude/stacks/node/express-5.md +538 -0
  76. package/.claude/stacks/python/django-5.md +483 -0
  77. package/.claude/stacks/python/fastapi-0.115.md +522 -0
  78. package/.claude/stacks/typescript/angular-18.md +420 -0
  79. package/.claude/stacks/typescript/angular-19.md +397 -0
  80. package/.claude/stacks/typescript/angular-21.md +494 -0
  81. package/CLAUDE.md +472 -0
  82. package/README.md +412 -0
  83. package/bin/cli.js +848 -0
  84. package/bin/lib/adr.js +146 -0
  85. package/bin/lib/backup.js +62 -0
  86. package/bin/lib/detect-stack.js +476 -0
  87. package/bin/lib/doctor.js +527 -0
  88. package/bin/lib/help.js +328 -0
  89. package/bin/lib/identity.js +108 -0
  90. package/bin/lib/lint-allowlist.json +15 -0
  91. package/bin/lib/lint.js +798 -0
  92. package/bin/lib/local-dir.js +68 -0
  93. package/bin/lib/manifest.js +236 -0
  94. package/bin/lib/sync-all.js +394 -0
  95. package/bin/lib/version-check.js +398 -0
  96. package/dashboard/db.js +321 -0
  97. package/dashboard/package.json +22 -0
  98. package/dashboard/public/app.js +853 -0
  99. package/dashboard/public/content/docs/agents-reference.en.md +911 -0
  100. package/dashboard/public/content/docs/architecture-overview.en.md +252 -0
  101. package/dashboard/public/content/docs/autonomy-matrix.en.md +186 -0
  102. package/dashboard/public/content/docs/cli-reference.en.md +538 -0
  103. package/dashboard/public/content/docs/git-flow.en.md +525 -0
  104. package/dashboard/public/content/docs/honcho-memory.en.md +394 -0
  105. package/dashboard/public/content/docs/hooks-reference.en.md +404 -0
  106. package/dashboard/public/content/docs/pipeline.en.md +414 -0
  107. package/dashboard/public/content/docs/plugins.en.md +289 -0
  108. package/dashboard/public/content/docs/quality-gate.en.md +315 -0
  109. package/dashboard/public/content/docs/skills-reference.en.md +484 -0
  110. package/dashboard/public/content/docs/stack-rules.en.md +362 -0
  111. package/dashboard/public/content/docs/troubleshooting.en.md +565 -0
  112. package/dashboard/public/content/manifest.json +114 -0
  113. package/dashboard/public/content/manual/backend.en.md +1053 -0
  114. package/dashboard/public/content/manual/existing-project.en.md +848 -0
  115. package/dashboard/public/content/manual/frontend.en.md +1008 -0
  116. package/dashboard/public/content/manual/fullstack.en.md +1459 -0
  117. package/dashboard/public/content/manual/mobile.en.md +837 -0
  118. package/dashboard/public/content/manual/quickstart.en.md +169 -0
  119. package/dashboard/public/index.html +217 -0
  120. package/dashboard/public/style.css +857 -0
  121. package/dashboard/public/vendor/marked.min.js +69 -0
  122. package/dashboard/rtk.js +143 -0
  123. package/dashboard/server-app.js +421 -0
  124. package/dashboard/server.js +104 -0
  125. package/dashboard/test/sprint1.test.js +406 -0
  126. package/dashboard/test/sprint2.test.js +571 -0
  127. package/dashboard/test/sprint3.test.js +560 -0
  128. package/package.json +33 -0
  129. package/scripts/hooks/subagent-telemetry.sh +14 -0
  130. package/scripts/hooks/telemetry-writer.js +250 -0
  131. package/scripts/latest-versions.json +56 -0
@@ -0,0 +1,55 @@
1
+ {
2
+ "permissions": {
3
+ "allow": [
4
+ "Read",
5
+ "Write",
6
+ "Edit",
7
+ "MultiEdit",
8
+ "Glob",
9
+ "Grep",
10
+ "Skill",
11
+ "Task",
12
+ "WebFetch",
13
+ "TodoRead",
14
+ "TodoWrite",
15
+ "NotebookRead",
16
+ "NotebookWrite",
17
+ "Bash"
18
+ ]
19
+ },
20
+ "hooks": {
21
+ "UserPromptSubmit": [
22
+ {
23
+ "matcher": "*",
24
+ "hooks": [
25
+ {
26
+ "type": "command",
27
+ "command": "node .claude/hooks/flow-guard.js"
28
+ }
29
+ ]
30
+ }
31
+ ],
32
+ "PostToolUse": [
33
+ {
34
+ "matcher": "Edit|MultiEdit|Write",
35
+ "hooks": [
36
+ {
37
+ "type": "command",
38
+ "command": "json=$(cat); file_path=$(echo \"$json\" | jq -r '.file_path // empty'); if [[ \"$file_path\" =~ \\.(ts|tsx|html|scss|css)$ ]] && command -v npx &>/dev/null && [ -f node_modules/.bin/prettier ]; then npx prettier --write \"$file_path\" 2>/dev/null; fi"
39
+ }
40
+ ]
41
+ }
42
+ ],
43
+ "Notification": [
44
+ {
45
+ "matcher": "*",
46
+ "hooks": [
47
+ {
48
+ "type": "command",
49
+ "command": "if command -v notify-send &>/dev/null; then notify-send 'Claude Code' 'Needs your attention'; elif command -v osascript &>/dev/null; then osascript -e 'display notification \"Needs your attention\" with title \"Claude Code\"'; fi"
50
+ }
51
+ ]
52
+ }
53
+ ]
54
+ }
55
+ }
@@ -0,0 +1,331 @@
1
+ # Skills — Cowork + Claude Code
2
+
3
+ > **Breaking change (2026-05-25)**: command layer deleted. Architecture is now 100% Skills + Agents. The `project-manager` skill is the catch-all entry point that routes prompts to the appropriate specialist agent. Specific skills (run-sprint, auto-test-guard, prd-ready-check, grill-me, scaffold, pair-debug, api-integration-test, brain-keeper, test-coverage-auditor, update-template, active-project, caveman) still take priority via keyword match. Standard sprint flow: `analyst` (plan) → `architect` (ADR) → `tech-lead` (approve) → `sprint-runner` (executes Sprint N delegating to `backend-developer` + `frontend-developer` + `database-engineer` in parallel) → `gate-keeper` (gate senior+) → `code-reviewer` → `tech-lead` (merge).
4
+
5
+ This directory contains the **Skills** that Cowork and Claude Code use to develop fullstack software Java 25+ / Spring Boot 4.0+ / Angular 21+ with this template's standard flow.
6
+
7
+ Unlike [agents](../agents/) (which are executors invoked via the Task tool), **Skills** are activated automatically based on trigger words in the conversation. Each skill has a `SKILL.md` with frontmatter containing `name` and `description` — the `description` is what the model uses to decide when to trigger the skill.
8
+
9
+ ## Goal
10
+
11
+ When the user describes a task, Cowork must **deliver it 100% production-ready for deploy**: backend compiles, frontend compiles, tests pass, API responds, screens open with no console errors, and the front consumes the back without failing.
12
+
13
+ ## Available skills
14
+
15
+ | Skill | Purpose | Triggers with |
16
+ |---|---|---|
17
+ | [`scaffold`](scaffold/SKILL.md) | Unified scaffold entry point — reads `## Project Identity` from CLAUDE.md, runs the appropriate pipeline: fullstack monorepo (Spring Boot 4 + Angular 21 + Docker Compose), backend-only, or frontend-only | "scaffold the project", "scaffold backend", "scaffold frontend", "bootstrap fullstack", "monta o esqueleto", "scaffolda o projeto" |
18
+ | [`sprint-runner`](run-sprint/SKILL.md) | Runs a sprint from the plan — task by task, with checkpoints | "run sprint X", "execute the sprint" |
19
+ | [`api-integration-test`](api-integration-test/SKILL.md) | Boots backend + frontend, validates integration with curl + Chrome MCP | "test integration", "smoke", "validate flow" |
20
+ | [`gate-keeper`](auto-test-guard/SKILL.md) | At the end of each task: **generates** the automated tests for the new code (JUnit+Mockito+Testcontainers, Jest+Testing Library, Playwright) and **runs the full project regression suite**. Blocks the task if any test breaks. | "run the tests", "generate the tests", "test everything", "full suite", "ensure nothing broke", "auto-test" |
21
+ | [`test-coverage-auditor`](test-coverage-auditor/SKILL.md) | Audits test coverage, flags technical debt from manual verification, updates `tech-debt.md`. Mandatory gate inside `prd-ready-check`. | "audit the tests", "test debt?", "coverage ok?", "list what has no test" |
22
+ | [`prd-ready-check`](prd-ready-check/SKILL.md) | Final production gate — tests, builds, lint, E2E, security | "PRD-ready?", "can we deploy?", "DoD" |
23
+ | [`pair-debug`](pair-debug/SKILL.md) | Hypothesis-driven debug loop: state symptom → formulate hypotheses → probe one at a time → confirm cause → fix minimal → write test. Bans "try and see" approach. | "pair debug", "investigate this bug", "find the root cause", "why is this not working" |
24
+ | [`grill-me`](grill-me/SKILL.md) | Discovery interview — one question at a time, with recommendation, until requirements are clear. Persists conclusions to `docs/plans/PLAN_*.md` or ADR. | "grill me", "interview me about", "stress-test the plan", "discover requirements with me" |
25
+ | [`brain-keeper`](brain-keeper/SKILL.md) | Upon completing a PLAN_*: records history in the Obsidian vault (`docs/brain/`) — daily, feature, ADR, bug, tech-debt + updates MOC. Provisions `.obsidian/` with per-folder color snippet on first run. | End of PLAN_*; "record in the brain", "update brain", "log of the day", "close feature in vault" |
26
+ | [`update-template`](update-template/SKILL.md) | Adopts or synchronizes an EXISTING project with the latest version of the template (merge with backup) | "update the template", "bring the new skills", "sync with development-utility-kit", "adopt the template here" |
27
+ | [`active-project`](active-project/SKILL.md) | Path-driven, non-interactive adoption of a project to the template — `/active-project <path>`. Fast lane of `update-template` (no preview/checkpoint). Preferred for scripted batch adoptions. | "/active-project `<path>`", "ativar projeto em `<path>`", "adota o projeto `<path>`", "aplica o template em `<path>`" |
28
+ | [`caveman`](caveman/SKILL.md) | Telegraphic output style — drops articles, filler, pleasantries. 65-75% fewer tokens. Always active; adjustable via "caveman lite\|full\|ultra" or "stop caveman". | Passive (always active); "caveman lite", "caveman ultra", "stop caveman" |
29
+ | [`to-prd`](to-prd/SKILL.md) | Transforms a `DISCOVERY_*.md` into a Product Requirements Document. Requires `grill-me` to have run first. Produces `docs/prd/PRD_*.md` with six required sections: Overview, Goals, User Stories (prose), Functional Requirements, Non-functional Requirements, Out of scope. Idempotent. Opt-in only — never auto-triggered. | "to-prd", "gera PRD", "cria PRD", "generate PRD", "create PRD" |
30
+ | [`to-issues`](to-issues/SKILL.md) | Decomposes a `PRD_*.md` into trackable GitHub issues. Requires `to-prd` to have run first. Produces `docs/issues/ISSUES_*.md` with `[ISSUE-N]` blocks (Labels, Body, Acceptance criteria) ready for `gh issue create`. Idempotent. Opt-in only — never auto-triggered. | "to-issues", "quebra em issues", "gera issues", "break into issues", "generate issues" |
31
+ | [`project-manager`](project-manager/SKILL.md) | **Catch-all fallback router + orchestrator** (per ADR-033). Three modes: **ROUTE** (1 domain -> 1 specialist via Task tool), **ORCHESTRATE** (2-5 domains -> mini-plan inline + parallel Task calls, no PLAN_*.md), **ESCALATE** (>5 subtasks or formal plan needed -> grill-me -> analyst -> sprint-runner). Covers the 17 specialist agents (`analyst`, `tech-lead`, `backend-developer`, `frontend-developer`, `code-reviewer`, `database-engineer`, `devops-engineer`, `mobile-developer`, `n8n-specialist`, `product-owner`, `qa-engineer`, `security-engineer`, `ux-designer`, `migrator`, `release-engineer`, `auditor`). | "create endpoint", "review my code", "dockerize", "audit security", "design DB", "create mobile app", "n8n workflow", "wireframe", "migrate spring boot 2", ad-hoc multi-domain <=5 subtasks ("CRUD products", "back + front pequenos"), any task without a more specific skill |
32
+
33
+ ## Where the code is generated
34
+
35
+ This directory (`C:\development\tools\development-utility-kit\`) is the **TEMPLATE** — it is not where Java/Angular projects live. The skills here are copied to each new project.
36
+
37
+ ### Canonical projects directory
38
+
39
+ Every fullstack project generated by this template should live in:
40
+
41
+ ```
42
+ C:\development\source\projects\<project-name>\
43
+ ```
44
+
45
+ This is the default destination — do not use other folders without justification recorded in an ADR. `bootstrap-project.sh` and the `scaffold` skill assume this path.
46
+
47
+ ### End-to-end flow, from zero to deploy
48
+
49
+ ```
50
+ 1. Create the project (interactive wrapper — recommended)
51
+ On Windows (double-click or prompt):
52
+ > C:\development\tools\development-utility-kit\scripts\new-project.bat
53
+ On Git Bash / WSL / Mac / Linux:
54
+ $ bash /c/development/tools/development-utility-kit/scripts/new-project.sh
55
+
56
+ The wrapper asks:
57
+ - Project name (kebab-case)
58
+ - Type: [1] Backend Java | [2] Frontend | [3] Fullstack
59
+ - If Frontend: [1] Angular 21 | [2] HTML + Vite Vanilla
60
+
61
+ Then creates it in C:\development\source\projects\<name>\ and
62
+ opens Claude Code directly in the folder.
63
+
64
+ (Non-interactive alternative:
65
+ bash .../scripts/bootstrap-project.sh my-app C:/development/source/projects \
66
+ --tipo=fullstack --frontend-stack=angular)
67
+
68
+ 2. First instruction in Cowork/Claude Code (the right skill is fired by the type)
69
+
70
+ 3. First instruction (empty project)
71
+ Any type → "scaffold the project" → triggers scaffold skill → dispatches to scaffold agent
72
+
73
+ The scaffold agent reads `## Project Identity` in the project's `CLAUDE.md` to decide
74
+ what to generate (backend | frontend | fullstack). Type is injected there by bootstrap-project.sh.
75
+
76
+ 4. Subsequent conversations (features)
77
+ "implement product registration with name, price and stock"
78
+ → triggers run-sprint
79
+ → Stage 0: checks backend/pom.xml and frontend/angular.json (OK)
80
+ → Stage 1 → analyst → docs/plans/PLAN_product-registration.md
81
+ │ ⏸️ CHECKPOINT
82
+ → Stage 2 → (architecture) → ADR if any new decision
83
+ │ ⏸️ CHECKPOINT
84
+ → Stage 3 → run-sprint → backend-developer + frontend-developer
85
+ │ (code goes to backend/src/main/java/... and frontend/src/app/...)
86
+ → Stage 4 → api-integration-test (boots back+front, curl + Chrome MCP)
87
+ │ ⏸️ CHECKPOINT
88
+ → Stage 5 → prd-ready-check (GO / NO-GO with mvn test, npm test, builds, E2E)
89
+ │ ⏸️ CHECKPOINT
90
+ → Stage 6 → brain-keeper (records daily + feature + ADR + tech-debt + MOC in docs/brain/)
91
+ │ ⏸️ CHECKPOINT
92
+ → Stage 7 → commit + PR
93
+ ```
94
+
95
+ **Summary**: the entry point is `new-project.bat` (or `.sh`). It creates the structure in `C:\development\source\projects\<name>\` and opens Claude Code. From there on, the skills do all the work — the code is never generated in `development-utility-kit/`.
96
+
97
+ ### Adoption/update flow (existing project)
98
+
99
+ If you already have a project and want to **bring it into the template's standard** (or update with new skills when the template evolves), use `update-project`. Two equivalent paths:
100
+
101
+ **(a) Outside the project — interactive wrapper**
102
+
103
+ ```cmd
104
+ REM Windows
105
+ C:\development\tools\development-utility-kit\scripts\update-project.bat REM asks for the folder
106
+ C:\development\tools\development-utility-kit\scripts\update-project.bat C:\path\project REM passes directly
107
+ C:\development\tools\development-utility-kit\scripts\update-project.bat --dry-run REM simulates
108
+ ```
109
+
110
+ ```bash
111
+ # Git Bash / WSL / Mac / Linux
112
+ bash /c/development/tools/development-utility-kit/scripts/update-project.sh /path/to/project
113
+ bash /c/development/tools/development-utility-kit/scripts/update-project.sh --dry-run
114
+ ```
115
+
116
+ **(b) Inside the project — skill in Cowork**
117
+
118
+ Open the project in Cowork and ask:
119
+
120
+ ```
121
+ update the template
122
+ ```
123
+
124
+ The `update-template` skill shows a preview (what will be merged, what will be created) and asks for confirmation before writing anything.
125
+
126
+ **What the adoption/update does (idempotent, safe to run multiple times)**
127
+
128
+ 1. **Detects the type** of the project by looking at `backend/pom.xml`, `frontend/angular.json`, `frontend/vite.config.*`.
129
+ 2. **Merges `.claude/`** — backs up the current one in `.claude.backup-YYYYMMDD-HHMMSS/` and copies the template files on top, **preserving local custom skills/agents** that do not exist in the template.
130
+ 3. **Injects the "Project type" block** into `CLAUDE.md` if missing. If it already exists, just checks consistency.
131
+
132
+ Anything overwritten is backed up. Local files that the template does not have are **never removed**.
133
+
134
+ ## How Cowork triggers skills
135
+
136
+ Cowork reads the `description` field of the frontmatter. When the user's message matches the trigger words listed there, the skill is automatically triggered and its `SKILL.md` is loaded into the context.
137
+
138
+ There is no need to call explicitly — just describe the task. If you want to force a specific skill, use `/skill <name>` (Claude Code) or mention explicitly: "use the `analyst` skill".
139
+
140
+ ## Canonical precedence — skill ↔ agent
141
+
142
+ Two-layer architecture. Commands layer was deleted on 2026-05-25 (replaced by the `project-manager` skill catch-all).
143
+
144
+ | Layer | Role | Trigger | Owns what |
145
+ |---|---|---|---|
146
+ | **Skill** (`.claude/skills/<name>/SKILL.md`) | **Entry point** | Auto-trigger via `description` (Cowork classifier) OR explicit `/skill <name>` | Orchestration logic, checkpoints, stage → agent mapping |
147
+ | **Agent** (`.claude/agents/<name>.md`) | **Executor** | Invoked by a skill via `Task(subagent_type="<name>", ...)` | System prompt, decision framework, `model:` declaration |
148
+
149
+ ### Runtime hierarchy
150
+
151
+ ```
152
+ USER MESSAGE
153
+
154
+ ├─ keyword match → specific SKILL
155
+ │ │
156
+ │ ├─ Pattern 1 (Facade pair) → same-name AGENT (executor)
157
+ │ │ brain-keeper, update-template, scaffold
158
+ │ │
159
+ │ ├─ Pattern 2 (Orchestration) → one or more differently-named AGENTs
160
+ │ │ run-sprint → sprint-runner
161
+ │ │ auto-test-guard → gate-keeper
162
+ │ │ grill-me → analyst
163
+ │ │ to-prd, to-issues → analyst / product-owner
164
+ │ │
165
+ │ └─ Pattern 3 (Standalone) → no agent; executes inline
166
+ │ caveman, pair-debug, project-manager, active-project,
167
+ │ prd-ready-check, api-integration-test, test-coverage-auditor
168
+
169
+ └─ no match → PROJECT-MANAGER SKILL (catch-all fallback)
170
+ ↓ analyzes prompt, picks ONE specialist
171
+ ↓ Task(subagent_type="<agent>")
172
+ AGENT (executor)
173
+ ```
174
+
175
+ ### When name overlaps
176
+
177
+ For names that exist in both skill + agent (`sprint-runner`, `gate-keeper`, `brain-keeper`, `scaffold`, `update-template`), they describe the **same flow**. The skill is the interface contract; the agent is the execution contract. See Pattern 1 in `## Pattern catalog` below.
178
+
179
+ ### When a name exists only in one layer
180
+
181
+ - **Skill only** (`caveman`, `pair-debug`, `grill-me`, `active-project`, `project-manager`, `to-prd`, `to-issues`, `prd-ready-check`, `api-integration-test`, `test-coverage-auditor`): execute inline or orchestrate via Bash/Read/Write/Task. No dedicated agent counterpart. See Pattern 3 in `## Pattern catalog` below. The last three were demoted to Pattern 3 in ADR-037 (their same-name agents never existed on disk; the calling session executes them inline).
182
+ - **Agent only** (`tech-lead`, `product-owner`, `architect`, `security-engineer`, `database-engineer`, `devops-engineer`, `code-reviewer`, `ux-designer`, `analyst`, `backend-developer`, `frontend-developer`, `qa-engineer`, `mobile-developer`, `n8n-specialist`, `migrator`, `release-engineer`, `auditor`): invoked via Task tool by skills — commonly by `project-manager` (for tasks without a dedicated skill) or by `sprint-runner` (for sprint tasks).
183
+
184
+ ### Required mapping in router skills
185
+
186
+ Every skill that orchestrates multiple stages MUST declare a `stage → subagent_type` table using actual agent names (from `.claude/agents/`). This prevents the parent (Opus) from billing inline work that should run on Sonnet/Haiku.
187
+
188
+ ---
189
+
190
+ ## Pattern catalog
191
+
192
+ Three patterns govern every skill/agent pair in the harness. New entries MUST be classified into one of these patterns before being merged.
193
+
194
+ ### Pattern 1 — Facade pair
195
+
196
+ A skill and an agent share the **same kebab-case name**. The skill is the **interface contract**; the agent is the **execution contract**.
197
+
198
+ **Interface contract (skill MUST contain):**
199
+ - `## When to trigger` — keyword triggers, user-facing scenarios.
200
+ - `## Prerequisites` — required artifacts/context before invoking.
201
+ - `## Do NOT use for` — scope boundaries.
202
+ - `## Dispatch` — `Task(subagent_type: "<same-name-agent>", ...)` call.
203
+ - `## Handoff` — pointer to the agent for execution rules.
204
+
205
+ **Interface contract (skill MUST NOT contain):**
206
+ - Step-by-step execution checklist (belongs to the agent).
207
+ - Inline decision framework.
208
+ - Model selection rules.
209
+
210
+ **Execution contract (agent MUST contain):**
211
+ - Full step-by-step checklist / phases.
212
+ - Decision framework and golden rules.
213
+ - Tool list and model declaration.
214
+
215
+ **Execution contract (agent MUST NOT contain):**
216
+ - User-facing PT-language trigger phrases in the body (only in frontmatter `description`).
217
+ - Redundant "when to use" prose already in the skill.
218
+
219
+ **Current instances (post-ADR-037):**
220
+
221
+ | Skill | Agent |
222
+ |---|---|
223
+ | `brain-keeper` | `brain-keeper` |
224
+ | `update-template` | `update-template` |
225
+ | `scaffold` | `scaffold` |
226
+
227
+ > `prd-ready-check`, `api-integration-test`, `test-coverage-auditor` were demoted to Pattern 3 (skill-only) by ADR-037 on 2026-05-29 — their same-name agents never existed on disk, and the calling session executes their gates/probes inline.
228
+
229
+ ### Pattern 2 — Orchestration skill
230
+
231
+ A skill dispatches to **one or more agents with different names**. The skill owns the multi-stage orchestration; each agent owns its execution slice.
232
+
233
+ **Rules:**
234
+ - The skill's frontmatter `description` lists user-facing triggers.
235
+ - The skill body contains a `stage → subagent_type` mapping table.
236
+ - Each agent in the chain is independent — the skill passes explicit context on each `Task(...)` call.
237
+
238
+ **Current instances:**
239
+
240
+ | Skill | Agent(s) dispatched |
241
+ |---|---|
242
+ | `run-sprint` | `sprint-runner` |
243
+ | `auto-test-guard` | `gate-keeper` |
244
+ | `grill-me` | `analyst` |
245
+ | `to-prd` | `analyst`, `product-owner` |
246
+ | `to-issues` | `analyst`, `product-owner` |
247
+
248
+ > Note: `scaffold` is simultaneously Pattern 1 (skill + same-name agent) and could be considered orchestration when the scaffold agent itself delegates to `backend-developer` / `frontend-developer`. The classification is Pattern 1 — the skill-to-agent boundary is the primary contract.
249
+
250
+ ### Pattern 3 — Standalone skill
251
+
252
+ A skill with **no companion agent**. It executes its logic inline (Bash, Read, Write, Edit, Task to a generic specialist) without a dedicated executor agent.
253
+
254
+ **Justification required** — a skill is standalone only when it falls into one of these categories:
255
+
256
+ | Category | Description | Examples |
257
+ |---|---|---|
258
+ | **Mode/style** | Changes the output style of the parent session, not a task | `caveman` |
259
+ | **Router** | Catch-all dispatcher — by definition has no fixed agent target | `project-manager` |
260
+ | **Inline transform** | Short-lived transformation that doesn't warrant a dedicated agent | `active-project` |
261
+ | **Interview / generation** | Multi-turn interview + file write, no persistent agent needed | `pair-debug`, `to-prd`, `to-issues`, `grill-me`* |
262
+
263
+ *`grill-me` is listed here for its inline interview phase; its output handoff to `analyst` makes it also Pattern 2. Primary classification: Pattern 2.
264
+
265
+ **Current instances (pure Pattern 3):**
266
+
267
+ | Skill | Justification |
268
+ |---|---|
269
+ | `caveman` | Mode — output style toggle |
270
+ | `pair-debug` | Inline transform — hypothesis loop, no persistent executor |
271
+ | `project-manager` | Router — catch-all; fixed agent target undefined by design |
272
+ | `active-project` | Inline transform — fast-lane adoption, no dedicated agent |
273
+ | `prd-ready-check` | Inline gate — production checklist executed in the calling session (per ADR-037); needs Chrome MCP + Bash inline, would lose tools if dispatched to a child |
274
+ | `api-integration-test` | Inline probes — docker compose + curl + Chrome MCP run in the calling session (per ADR-037); dispatch to a child would lose Chrome MCP access |
275
+ | `test-coverage-auditor` | Inline scan — Glob/Grep over source + dailies, writes to tech-debt.md directly (per ADR-037); stateless instruction set |
276
+
277
+ ---
278
+
279
+ ## Decision rules
280
+
281
+ Rules D1–D4 govern how new skills and agents are classified and when specialist agents are promoted to paired skills.
282
+
283
+ ### D1 — Pattern 1 contract split (enforced at review)
284
+
285
+ When a skill+agent pair shares a name (Pattern 1), the split between skill (interface) and agent (execution) MUST be enforced. Violations are caught at `code-reviewer` / `tech-lead` review:
286
+
287
+ - If the skill body contains execution steps, checklists, or `./mvnw` / `npm run` commands → **REJECT**.
288
+ - If the agent body contains PT-language user-facing triggers (outside frontmatter `description`) → **REJECT**.
289
+
290
+ ### D3 — Defer promotion (specialist agents stay agent-only)
291
+
292
+ Specialist agents (`release-engineer`, `migrator`, `code-reviewer`, `security-engineer`, etc.) remain **agent-only** — routed via `project-manager` catch-all. Promote a specialist to a paired skill only when **both** conditions are met:
293
+
294
+ 1. Telemetry or repeated session history shows direct keyword invocation for this specialist that bypasses `project-manager`.
295
+ 2. The specialist has gained a ceremony of **three or more distinct phases** that benefit from a named orchestration entry point.
296
+
297
+ The following agents are candidates to watch — eligible for promotion if the conditions above are met:
298
+
299
+ | Agent | Reason to watch |
300
+ |---|---|
301
+ | `release-engineer` | Multi-phase ceremony: version bump → CHANGELOG → tag → push |
302
+ | `migrator` | Multi-phase: audit → plan → migrate → validate |
303
+ | `code-reviewer` | Frequent direct invocation: "review my PR", "review this code" |
304
+ | `security-engineer` | Frequent direct invocation: "audit security", "OWASP scan" |
305
+
306
+ Promotion decision: `tech-lead` approves after reviewing telemetry.
307
+
308
+ ### D4 — Standalone skills require justification
309
+
310
+ A new standalone skill (Pattern 3) MUST declare its justification category from the table in `## Pattern catalog — Pattern 3`. Accepted categories: **mode/style**, **infrastructure**, **router**, **inline transform**, **interview/generation**. A skill submitted without a justification category is rejected at `code-reviewer` review.
311
+
312
+ ---
313
+
314
+ ## Claude Code (terminal) usage
315
+
316
+ Skills auto-trigger via `description` keywords. To force a specific skill, type `/skill <name>` (Claude Code) or mention by name ("use the `analyst` skill"). The `project-manager` skill catches anything that did not match a more specific skill.
317
+
318
+ ## Conventions of each SKILL.md
319
+
320
+ - **Frontmatter** with `name` (kebab-case) and `description` (rich in trigger words).
321
+ - **Explicit checkpoints** (⏸️) for skills that orchestrate.
322
+ - **Inviolable rules** at the end.
323
+ - **American English** in every instruction.
324
+
325
+ ## Adding a new skill
326
+
327
+ 1. Create the folder: `.claude/skills/<name>/`.
328
+ 2. Create `SKILL.md` with the minimal frontmatter (`name`, `description`).
329
+ 3. Structure the content following the pattern of existing skills.
330
+ 4. Update this README.
331
+ 5. Test by triggering via Cowork.
@@ -0,0 +1,131 @@
1
+ ---
2
+ name: active-project
3
+ description: Use to ACTIVATE/ADOPT a project to the `development-utility-kit` template in ONE shot — accepts the project path as the FIRST argument and runs `scripts/adopt-project.sh` directly without preview/checkpoint. Triggers when the user types `/active-project <path>` or says "active project at <path>", "activate project <path>", "ativar projeto", "adota o projeto X", "aplica o template no projeto Y", "ativar template em <path>". Same end-result as `update-template`, but path-driven and non-interactive — preferred for scripted batch adoptions. Supports `--dry-run`, `--force-type=<backend|frontend|fullstack>`, `--template=<path>`. Do NOT use to develop features (use run-sprint), scaffold empty projects (use scaffold), or update the current project's template from inside it (use update-template). PT triggers: 'ativar projeto', 'adota o projeto', 'aplica o template', 'ativa o template em', 'ativar projeto em', 'sincronizar template no projeto'.
4
+ tools: Read, Write, Glob, Grep, Bash(bash:*), Bash(git:*)
5
+ model: sonnet
6
+ ---
7
+
8
+ # Active Project — Adopt a project to the template (path-driven, non-interactive)
9
+
10
+ Always reply in **Brazilian Portuguese**.
11
+
12
+ ---
13
+
14
+ ## 1. When it triggers
15
+
16
+ Exact invocations:
17
+ - `/active-project /path/to/project`
18
+ - `/active-project /path/to/project --dry-run`
19
+ - `/active-project /path/to/project --force-type=fullstack`
20
+ - `/active-project /path/to/project --template=/alt/template`
21
+
22
+ Natural-language equivalents:
23
+ - "ativar projeto em `/path`"
24
+ - "adota o projeto em `/path` com template fullstack"
25
+ - "aplica o template no projeto X em modo dry-run"
26
+
27
+ If the user asks **without a path**, ask for it before running anything.
28
+
29
+ ---
30
+
31
+ ## 2. What it does
32
+
33
+ Single-shot wrapper around `scripts/adopt-project.sh`:
34
+
35
+ 1. Detects project type (`backend | frontend | fullstack` + stack `angular | vite-vanilla`) from `backend/pom.xml`, `frontend/angular.json`, `frontend/vite.config.*`.
36
+ 2. Backs up the existing `.claude/` to `.claude.backup-YYYYMMDD-HHMMSS/`.
37
+ 3. Copies the template `.claude/` into the project, preserving local files outside the template.
38
+ 4. Copies the template `CLAUDE.md` and appends the **"Identidade deste projeto"** block (project name, type, stack, adoption date).
39
+ 5. Copies `.claude-version.json` and flags as outdated when versions diverge.
40
+ 6. Reports backup paths, detected type, and any `[WARN]`/`[ERROR]` from the script.
41
+
42
+ This is the **fast path** of `update-template`: no preview, no checkpoint, no confirmation.
43
+
44
+ ---
45
+
46
+ ## 3. Difference from `update-template`
47
+
48
+ | | `active-project` (this) | `update-template` |
49
+ |---|---|---|
50
+ | Path | First positional ARG | Current working directory |
51
+ | Preview/checkpoint | NO (direct execution) | YES (interactive) |
52
+ | Best for | Scripts, batch adoptions | Manual flow inside Claude Code with confirmation |
53
+ | Idempotent | YES (same as adopt-project.sh) | YES |
54
+
55
+ Both ultimately call `scripts/adopt-project.sh` — they share the engine.
56
+
57
+ ---
58
+
59
+ ## 4. Procedure
60
+
61
+ 1. **Parse the user message** to extract:
62
+ - PROJECT_PATH (first non-flag argument; absolute path expected)
63
+ - FLAGS (`--dry-run`, `--force-type=<tipo>`, `--template=<path>`)
64
+ 2. **Validate** that PROJECT_PATH exists:
65
+ ```bash
66
+ [ -d "<PROJECT_PATH>" ] || echo "[ERROR] Pasta nao existe: <PROJECT_PATH>"
67
+ ```
68
+ If it does not exist, STOP and tell the user.
69
+ 3. **Locate the template** (default: `C:\development\tools\development-utility-kit` on Windows, `~/workspace/tools/development-utility-kit` on Linux/Mac). Override with `--template` if provided.
70
+ 4. **Run** via the `terminal` tool:
71
+ ```bash
72
+ bash <TEMPLATE>/scripts/adopt-project.sh "<PROJECT_PATH>" [FLAGS]
73
+ ```
74
+ 5. **Capture full stdout/stderr** and surface it to the user in **PT-BR**, including:
75
+ - Detected (or forced) type
76
+ - Backup paths created
77
+ - `[OK]/[WARN]/[ERROR]` messages from the script
78
+ - The final "Adoption/update finished" block
79
+ - Whether the project was flagged as outdated (template/project version mismatch)
80
+ 6. If the script reports `[WARN] Could not detect project type`, suggest re-running with `--force-type=<backend|frontend|fullstack>`.
81
+
82
+ ---
83
+
84
+ ## 5. Quick Reference
85
+
86
+ | Case | Command |
87
+ |---|---|
88
+ | Adopt a fullstack project | `bash adopt-project.sh /path/to/project` |
89
+ | Force the type (no code yet) | `bash adopt-project.sh /path --force-type=fullstack` |
90
+ | Simulate without applying | `bash adopt-project.sh /path --dry-run` |
91
+ | Alternative template | `bash adopt-project.sh /path --template=/other/template` |
92
+
93
+ ---
94
+
95
+ ## 6. Pitfalls
96
+
97
+ - **Path does not exist** → script aborts with `[ERROR] Folder does not exist`. Validate before invoking.
98
+ - **No `backend/` or `frontend/`** → script fails with `[WARN] Could not detect project type`. Use `--force-type=<tipo>` for projects without code yet.
99
+ - **Path with spaces** → always wrap in quotes when building the command.
100
+ - **Already adopted** → script silently creates a backup (`.claude.backup-*`). Mention this to the user.
101
+ - **Output verbosity** → if the user requests "mostre tudo" / "literal output", echo the captured stdout verbatim (do NOT summarize).
102
+
103
+ ---
104
+
105
+ ## 7. Verification
106
+
107
+ After applying (no `--dry-run`):
108
+
109
+ 1. `<PROJECT_PATH>/.claude/agents`, `<PROJECT_PATH>/.claude/commands`, `<PROJECT_PATH>/.claude/skills` exist.
110
+ 2. `<PROJECT_PATH>/CLAUDE.md` contains the block `## Identidade deste projeto`.
111
+ 3. `<PROJECT_PATH>/.claude-version.json` matches the template's version (otherwise report as outdated).
112
+ 4. The script printed `Adoption/update finished: <project-name>`.
113
+
114
+ ---
115
+
116
+ ## 8. Inviolable rules
117
+
118
+ 1. NEVER infer or invent a `PROJECT_PATH` from context — if the user did not provide one, ASK.
119
+ 2. NEVER execute without `--dry-run` if the user explicitly asked for a simulation.
120
+ 3. ALWAYS surface `[WARN]`/`[ERROR]` lines verbatim — do not omit them in the summary.
121
+ 4. ALWAYS report the backup paths so the user can recover.
122
+ 5. If invoked non-interactively (e.g. from a script), prefer non-blocking mode (no interactive prompts).
123
+
124
+ ---
125
+
126
+ ## 9. References
127
+
128
+ - Engine script: `scripts/adopt-project.sh`
129
+ - Interactive sibling: [`update-template`](../update-template/SKILL.md)
130
+ - Bootstrap (different purpose — creates new projects): [`scaffold`](../scaffold/SKILL.md)
131
+ - Canonical project directory: `C:\development\source\projects\<name>\`
@@ -0,0 +1,84 @@
1
+ ---
2
+ name: api-integration-test
3
+ description: Use to validate that backend and frontend talk correctly BEFORE the production gate. Triggers on phrases like "test the integration", "validate that the front is calling the API", "spin everything up and test the flow", "smoke test", "verify that the screen actually works", "open the browser and test", "do the quick E2E". This skill brings up the backend (mvn spring-boot:run or docker compose), brings up the frontend (ng serve), hits the endpoints with curl, opens a headless browser via Chrome MCP, runs the main flows, validates the console has no errors, and validates the network has no failing requests. It does not replace prd-ready-check (which is the formal gate); it serves to shorten the feedback loop during implementation. Do NOT use for unit tests (use auto-test-guard) nor for the final production gate (use prd-ready-check). PT triggers: 'testa a integração', 'valida que o front tá chamando a API', 'sobe tudo e testa', 'smoke test', 'verifica se a tela funciona', 'abre o browser e testa', 'faz o E2E rápido'.
4
+ tools: Read, Write, Glob, Grep, Bash(curl:*), Bash(docker:*), Bash(mvn:*), Bash(npm:*)
5
+ model: sonnet
6
+ ---
7
+
8
+ # API Integration Test — End-to-End Validation
9
+
10
+ Skill that invokes the `api-integration-test` agent. Always reply in **American English**.
11
+
12
+ ---
13
+
14
+ ## When to trigger
15
+
16
+ - "test the integration", "validate that the front is calling the API"
17
+ - "spin everything up and test the flow", "smoke test"
18
+ - "verify that the screen actually works", "open the browser and test"
19
+ - "do the quick E2E"
20
+ - PT: "testa a integração", "sobe tudo e testa", "verifica se a tela funciona", "faz o E2E rápido"
21
+
22
+ ## 2. When NOT to trigger
23
+
24
+ ## Prerequisites
25
+
26
+ - `gate-keeper` (auto-test-guard) has run and returned GREEN on the current code.
27
+ - Backend and frontend code compile locally without errors.
28
+ - Docker (or local Postgres/Redis) is available for dependent services.
29
+ - Chrome MCP extension is installed and connected (for browser validation).
30
+
31
+ ---
32
+
33
+ ## Do NOT use for
34
+
35
+ - Unit or integration tests — use `gate-keeper` (auto-test-guard skill).
36
+ - The final production gate — use `prd-ready-check`.
37
+ - Writing test code — use `qa-engineer` / `backend-developer` / `frontend-developer`.
38
+
39
+ 1. `navigate` to each main screen.
40
+ 2. `read_console_messages` — assert zero errors.
41
+ 3. `read_network_requests` — assert zero unexpected 4xx/5xx, zero asset 404.
42
+ 4. Run minimum CRUD flow: create → list → edit → delete.
43
+
44
+ ## Execution
45
+
46
+ Standalone skill (Pattern 3 per ADR-037). The calling session executes the smoke E2E inline using the frontmatter `tools:` + Chrome MCP — no Task dispatch (dispatching would lose Chrome MCP access in the child).
47
+
48
+ ### Sequence
49
+
50
+ 1. **Boot backend** — stack-appropriate (`./mvnw spring-boot:run`, `docker compose up -d backend`, `uvicorn`, `go run`, ...) from the pack `## Build & run commands`.
51
+ 2. **Boot frontend** — `npm start` / `ng serve` / framework equivalent.
52
+ 3. **Curl smoke** — hit each endpoint in the OpenAPI/spec; assert 2xx for happy path + 4xx for known invalid input.
53
+ 4. **Browser flow via Chrome MCP**:
54
+ - `navigate` to each main screen.
55
+ - `read_console_messages` → assert zero errors.
56
+ - `read_network_requests` → assert zero unexpected 4xx/5xx, zero asset 404.
57
+ - Run minimum CRUD: create → list → edit → delete.
58
+ 5. **Tear down on exit** — always, even on failure (use `trap` if shelling).
59
+
60
+ ### Inviolable rules
61
+
62
+ 1. **Never "prove it works" by reading code only** — must boot and observe live.
63
+ 2. **Zero console errors** is a hard requirement.
64
+ 3. **Tear down processes on exit** (`trap` for shell, finally for Node/Python).
65
+ 4. **Document tested URLs, methods, responses** in the report.
66
+ 5. **Failure returns to a specialist via `project-manager`** — never to the human.
67
+
68
+ ### Output format
69
+
70
+ ```
71
+ API Integration Test — <date> — <project>
72
+
73
+ Endpoint smoke
74
+ [OK] GET /api/v1/health → 200
75
+ [OK] POST /api/v1/products → 201 (id=42)
76
+ [FAIL] GET /api/v1/products/42 → 500 (NullPointerException at ProductController.java:42)
77
+
78
+ Browser smoke (Chrome MCP)
79
+ [OK] /login — navigated, console clean
80
+ [FAIL] /products list — 404 on chunk-asset.js
81
+
82
+ Verdict: FAIL
83
+ Routing: backend-developer (NPE on GET /products/{id}) + frontend-developer (asset 404)
84
+ ```