@gempack/squad-mcp 0.6.5 → 0.8.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/.claude-plugin/marketplace.json +2 -2
- package/.claude-plugin/plugin.json +11 -6
- package/CHANGELOG.md +62 -0
- package/INSTALL.md +37 -22
- package/README.md +54 -18
- package/agents/code-explorer.md +77 -0
- package/agents/product-owner.md +10 -1
- package/agents/senior-architect.md +12 -0
- package/agents/senior-dba.md +15 -1
- package/agents/senior-dev-reviewer.md +101 -30
- package/agents/senior-dev-security.md +13 -0
- package/agents/senior-developer.md +15 -0
- package/agents/senior-qa.md +14 -1
- package/agents/tech-lead-consolidator.md +10 -0
- package/agents/tech-lead-planner.md +17 -0
- package/commands/brainstorm.md +12 -2
- package/commands/implement.md +32 -0
- package/commands/next.md +24 -0
- package/commands/question.md +20 -0
- package/commands/review.md +30 -0
- package/commands/task.md +29 -0
- package/commands/tasks.md +21 -0
- package/dist/config/ownership-matrix.d.ts +1 -1
- package/dist/config/ownership-matrix.js +21 -20
- package/dist/config/ownership-matrix.js.map +1 -1
- package/dist/config/squad-yaml.d.ts +1 -1
- package/dist/config/squad-yaml.js +4 -8
- package/dist/config/squad-yaml.js.map +1 -1
- package/dist/errors.js.map +1 -1
- package/dist/exec/git.d.ts +1 -1
- package/dist/exec/git.js +0 -0
- package/dist/exec/git.js.map +1 -1
- package/dist/format/pr-review.js +1 -3
- package/dist/format/pr-review.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/learning/format.js +1 -5
- package/dist/learning/format.js.map +1 -1
- package/dist/learning/store.d.ts +1 -1
- package/dist/learning/store.js +90 -17
- package/dist/learning/store.js.map +1 -1
- package/dist/observability/logger.d.ts +2 -2
- package/dist/observability/logger.js +20 -20
- package/dist/observability/logger.js.map +1 -1
- package/dist/prompts/registry.js.map +1 -1
- package/dist/resources/agent-loader.js +1 -0
- package/dist/resources/agent-loader.js.map +1 -1
- package/dist/resources/registry.js +28 -28
- package/dist/tasks/select.js.map +1 -1
- package/dist/tasks/store.d.ts +2 -2
- package/dist/tasks/store.js +50 -12
- package/dist/tasks/store.js.map +1 -1
- package/dist/tools/_shared/schemas.d.ts +21 -0
- package/dist/tools/_shared/schemas.js +25 -0
- package/dist/tools/_shared/schemas.js.map +1 -0
- package/dist/tools/agents.d.ts +3 -3
- package/dist/tools/agents.js +9 -9
- package/dist/tools/agents.js.map +1 -1
- package/dist/tools/classify-work-type.d.ts +5 -5
- package/dist/tools/classify-work-type.js +0 -0
- package/dist/tools/classify-work-type.js.map +1 -1
- package/dist/tools/compose-advisory-bundle.d.ts +8 -0
- package/dist/tools/compose-advisory-bundle.js +12 -14
- package/dist/tools/compose-advisory-bundle.js.map +1 -1
- package/dist/tools/compose-prd-parse.js.map +1 -1
- package/dist/tools/compose-squad-workflow.d.ts +30 -1
- package/dist/tools/compose-squad-workflow.js +0 -0
- package/dist/tools/compose-squad-workflow.js.map +1 -1
- package/dist/tools/consolidate.js +1 -3
- package/dist/tools/consolidate.js.map +1 -1
- package/dist/tools/detect-changed-files.d.ts +5 -6
- package/dist/tools/detect-changed-files.js +0 -0
- package/dist/tools/detect-changed-files.js.map +1 -1
- package/dist/tools/list-tasks.js +1 -8
- package/dist/tools/list-tasks.js.map +1 -1
- package/dist/tools/mode/exec-mode.d.ts +124 -0
- package/dist/tools/mode/exec-mode.js +153 -0
- package/dist/tools/mode/exec-mode.js.map +1 -0
- package/dist/tools/next-task.js +1 -8
- package/dist/tools/next-task.js.map +1 -1
- package/dist/tools/read-learnings.js +3 -5
- package/dist/tools/read-learnings.js.map +1 -1
- package/dist/tools/read-squad-config.js +1 -1
- package/dist/tools/read-squad-config.js.map +1 -1
- package/dist/tools/record-learning.d.ts +1 -1
- package/dist/tools/record-learning.js +1 -1
- package/dist/tools/record-tasks.js.map +1 -1
- package/dist/tools/registry.js +2 -4
- package/dist/tools/registry.js.map +1 -1
- package/dist/tools/score-risk.d.ts +3 -3
- package/dist/tools/score-risk.js +15 -15
- package/dist/tools/score-rubric.js.map +1 -1
- package/dist/tools/select-squad.d.ts +5 -5
- package/dist/tools/select-squad.js +0 -0
- package/dist/tools/select-squad.js.map +1 -1
- package/dist/tools/slice-files-for-task.js.map +1 -1
- package/dist/tools/slice-files.d.ts +2 -2
- package/dist/tools/slice-files.js +0 -0
- package/dist/tools/slice-files.js.map +1 -1
- package/dist/tools/update-task-status.js +1 -8
- package/dist/tools/update-task-status.js.map +1 -1
- package/dist/tools/validate-plan-text.d.ts +3 -3
- package/dist/tools/validate-plan-text.js +0 -0
- package/dist/tools/validate-plan-text.js.map +1 -1
- package/dist/util/file-lock.d.ts +10 -0
- package/dist/util/file-lock.js +102 -0
- package/dist/util/file-lock.js.map +1 -0
- package/dist/util/override-allowlist.d.ts +4 -4
- package/dist/util/override-allowlist.js +36 -27
- package/dist/util/override-allowlist.js.map +1 -1
- package/dist/util/path-internal.js +10 -8
- package/dist/util/path-internal.js.map +1 -1
- package/dist/util/path-safety.d.ts +15 -0
- package/dist/util/path-safety.js +47 -13
- package/dist/util/path-safety.js.map +1 -1
- package/package.json +13 -2
- package/shared/Skill-Squad-Dev.md +46 -35
- package/shared/Skill-Squad-Review.md +64 -41
- package/shared/_Severity-and-Ownership.md +6 -6
- package/skills/brainstorm/SKILL.md +50 -37
- package/skills/commit-suggest/SKILL.md +32 -14
- package/skills/question/SKILL.md +110 -0
- package/skills/squad/SKILL.md +70 -26
- package/tools/_tasks-io.mjs +25 -16
- package/tools/list-tasks.mjs +1 -4
- package/tools/next-task.mjs +4 -13
- package/tools/post-review.mjs +20 -30
- package/tools/record-learning.mjs +8 -11
- package/tools/record-tasks.mjs +2 -9
- package/tools/update-task-status.mjs +2 -9
- package/commands/squad-review.md +0 -20
- package/commands/squad.md +0 -22
|
@@ -1,29 +1,31 @@
|
|
|
1
1
|
# Skill: Squad Dev
|
|
2
2
|
|
|
3
3
|
## Objective
|
|
4
|
-
|
|
4
|
+
|
|
5
|
+
Development skill that takes a user prompt, builds an implementation plan, runs gated advisory with specialized agents, implements, and consolidates via TechLead-Consolidator. Codex is optional (`/squad:implement --codex`) and may be auto-suggested when the plan is high-risk.
|
|
5
6
|
|
|
6
7
|
## Skill Name
|
|
7
|
-
|
|
8
|
+
|
|
9
|
+
`/squad:implement`
|
|
8
10
|
|
|
9
11
|
## Agent Registry
|
|
10
12
|
|
|
11
|
-
| subagent_type
|
|
12
|
-
|
|
|
13
|
-
| `po`
|
|
14
|
-
| `tech-lead-planner`
|
|
15
|
-
| `tech-lead-consolidator`
|
|
16
|
-
| `senior-architect`
|
|
17
|
-
| `senior-dba`
|
|
18
|
-
| `senior-developer`
|
|
19
|
-
| `senior-dev-reviewer`
|
|
20
|
-
| `senior-dev-security`
|
|
21
|
-
| `senior-qa`
|
|
13
|
+
| subagent_type | Purpose |
|
|
14
|
+
| ------------------------ | -------------------------------------------- |
|
|
15
|
+
| `po` | Business value, UX, requirements fit |
|
|
16
|
+
| `tech-lead-planner` | Pre-implementation trade-offs and viability |
|
|
17
|
+
| `tech-lead-consolidator` | Post-implementation final verdict |
|
|
18
|
+
| `senior-architect` | Boundaries, DI, scalability |
|
|
19
|
+
| `senior-dba` | Queries, migrations, EF, cache |
|
|
20
|
+
| `senior-developer` | Correctness, robustness, APIs, observability |
|
|
21
|
+
| `senior-dev-reviewer` | Readability, idioms, naming |
|
|
22
|
+
| `senior-dev-security` | OWASP, authz, sensitive data |
|
|
23
|
+
| `senior-qa` | Test coverage, strategy, reliability |
|
|
22
24
|
|
|
23
25
|
## General Flow
|
|
24
26
|
|
|
25
27
|
```
|
|
26
|
-
User -> /squad {prompt}
|
|
28
|
+
User -> /squad:implement {prompt}
|
|
27
29
|
|
|
|
28
30
|
v
|
|
29
31
|
[0. Pre-Check]
|
|
@@ -86,11 +88,13 @@ Summary + modified files + tests + validations + rollback plan + next steps.
|
|
|
86
88
|
## Phase Details
|
|
87
89
|
|
|
88
90
|
### Phase 0 — Pre-Check
|
|
91
|
+
|
|
89
92
|
1. Run `git status`; capture current branch.
|
|
90
93
|
2. If uncommitted, unrelated changes are present, warn and ask the user before proceeding.
|
|
91
94
|
3. Record starting SHA for the delivery report.
|
|
92
95
|
|
|
93
96
|
### Phase 1 — Understanding and Risk
|
|
97
|
+
|
|
94
98
|
- Read `$ARGUMENTS`; detect `--codex`.
|
|
95
99
|
- Classify type: Feature / Bug Fix / Refactor / Performance / Security / Business Rule.
|
|
96
100
|
- Explore the codebase (Glob, Grep, Read) to locate the affected area and patterns.
|
|
@@ -188,6 +192,7 @@ Be direct. If the plan is good, say so. Do not invent problems.
|
|
|
188
192
|
Absorb relevant suggestions and show an adjusted-plan diff summary.
|
|
189
193
|
|
|
190
194
|
### Phase 4 — Gate 1: User Approval
|
|
195
|
+
|
|
191
196
|
Present the final plan and wait for explicit approval. Do not proceed without it.
|
|
192
197
|
|
|
193
198
|
### Phase 5 — Advisory Squad
|
|
@@ -204,6 +209,7 @@ Present the final plan and wait for explicit approval. Do not proceed without it
|
|
|
204
209
|
| Business Rule | po, senior-developer, senior-qa | +senior-dba if data-bound |
|
|
205
210
|
|
|
206
211
|
**Hard conditionals based on touched files:**
|
|
212
|
+
|
|
207
213
|
- Query / Migration / EF / Cache → `senior-dba` required
|
|
208
214
|
- DI / Boundaries / new project or module → `senior-architect` required
|
|
209
215
|
- Endpoint / Auth / Middleware → `senior-dev-security` required
|
|
@@ -237,13 +243,16 @@ Stay inside your ownership. Forward anything outside your scope.
|
|
|
237
243
|
Send all selected agents in a single message with multiple tool calls so they run in parallel.
|
|
238
244
|
|
|
239
245
|
### Phase 6 — Gate 2: Blocker Halt
|
|
246
|
+
|
|
240
247
|
- Any advisory Blocker → HALT. Surface blockers and ask the user how to proceed (revise plan, accept risk, abort).
|
|
241
248
|
- Major/Minor → proceed, capturing them as acceptance criteria for implementation.
|
|
242
249
|
|
|
243
250
|
### Phase 7 — Escalation Round (optional)
|
|
251
|
+
|
|
244
252
|
If an advisory agent forwarded a Blocker/Major to an agent that was not selected, spawn that missing agent with only that forwarded item (not a full review).
|
|
245
253
|
|
|
246
254
|
### Phase 8 — Implementation
|
|
255
|
+
|
|
247
256
|
- Follow the plan and advisory acceptance criteria.
|
|
248
257
|
- Read → Edit/Write each file. Respect project patterns.
|
|
249
258
|
- Method names in English. No emojis.
|
|
@@ -285,6 +294,7 @@ Be direct. If it is good, say so. Do not request cosmetic refactors.
|
|
|
285
294
|
Spawn `tech-lead-consolidator` with every advisory report and the delivered delta. Consolidator produces the final verdict and rollback plan.
|
|
286
295
|
|
|
287
296
|
### Phase 11 — Gate 3: Reject Loop (max 2 iterations)
|
|
297
|
+
|
|
288
298
|
- APPROVED / CHANGES REQUIRED (non-blocker) → apply fixes, then deliver.
|
|
289
299
|
- REJECTED → apply the fix list, re-run affected agents on the delta, re-consolidate.
|
|
290
300
|
- After 2 iterations, stop and hand the situation to the user.
|
|
@@ -338,13 +348,13 @@ Spawn `tech-lead-consolidator` with every advisory report and the delivered delt
|
|
|
338
348
|
|
|
339
349
|
## Skill Parameters
|
|
340
350
|
|
|
341
|
-
| Parameter | Type | Default | Description
|
|
342
|
-
|
|
343
|
-
| --codex | flag | off | Enable Codex for plan validation and implementation review
|
|
351
|
+
| Parameter | Type | Default | Description |
|
|
352
|
+
| --------- | ------ | ------- | ---------------------------------------------------------------------------------- |
|
|
353
|
+
| --codex | flag | off | Enable Codex for plan validation and implementation review |
|
|
344
354
|
| --quick | flag | off | Quick mode (see below). Trades depth for speed. Mutually exclusive with `--codex`. |
|
|
345
|
-
| squad | string | auto | Specific squad or "auto" for detection
|
|
346
|
-
| plan-only | bool | false | Build the plan only, do not execute
|
|
347
|
-
| verbose | bool | false | Show individual agent reports inline
|
|
355
|
+
| squad | string | auto | Specific squad or "auto" for detection |
|
|
356
|
+
| plan-only | bool | false | Build the plan only, do not execute |
|
|
357
|
+
| verbose | bool | false | Show individual agent reports inline |
|
|
348
358
|
|
|
349
359
|
## Quick Mode (`--quick`)
|
|
350
360
|
|
|
@@ -352,41 +362,42 @@ Reduced agent set, terse prompts, condensed delivery. Suitable for small fixes,
|
|
|
352
362
|
|
|
353
363
|
Phase deltas vs. normal mode:
|
|
354
364
|
|
|
355
|
-
| Phase
|
|
356
|
-
|
|
357
|
-
| Plan
|
|
358
|
-
| Codex plan validation
|
|
359
|
-
| User approval gate
|
|
360
|
-
| Squad
|
|
361
|
-
| Agent prompts
|
|
362
|
-
| Codex review
|
|
363
|
-
| Tech-lead consolidator | Always
|
|
364
|
-
| Delivery
|
|
365
|
+
| Phase | Normal | Quick |
|
|
366
|
+
| ---------------------- | --------------------------------------- | ----------------------------------------------------------------------------------------------- |
|
|
367
|
+
| Plan | Full plan with risks/decisions/tests | Condensed: objective, files, top 1-2 risks. Skip alternatives table. |
|
|
368
|
+
| Codex plan validation | Opt-in via `--codex` | Force-disabled. `--quick --codex` is rejected. |
|
|
369
|
+
| User approval gate | Always required | Auto-proceed when risk Low AND scope ≤3 files AND no security/data path. Otherwise still gates. |
|
|
370
|
+
| Squad | Auto-detect 3-7 specialists + tech-lead | Hard cap: 1 specialist + tech-lead. Specialist = work-type primary. |
|
|
371
|
+
| Agent prompts | Full template | "Flag only Blocker/Major. ≤200 words. No long template. If clean, reply 'No issues in scope.'" |
|
|
372
|
+
| Codex review | Opt-in | Skipped (force-disabled with `--quick`) |
|
|
373
|
+
| Tech-lead consolidator | Always | Skipped when zero Blocker/Major from specialist |
|
|
374
|
+
| Delivery | Full report | Condensed: objective, files, tests, residual risks |
|
|
365
375
|
|
|
366
376
|
Critical-change auto-fallback: if scope touches `auth`, `crypto`, `permissions`, `Program.cs`, `Startup.cs`, migrations, EF mappings, or `appsettings`, fall back to normal mode with warning `Quick mode disabled — change touches security/data layer. Running full workflow.`.
|
|
367
377
|
|
|
368
378
|
## Usage Examples
|
|
369
379
|
|
|
370
380
|
```
|
|
371
|
-
/squad implement dollar balance endpoint
|
|
381
|
+
/squad:implement implement dollar balance endpoint
|
|
372
382
|
-> No Codex
|
|
373
383
|
-> Plan + Planner -> User approves -> Advisory -> Implement -> Consolidator
|
|
374
384
|
|
|
375
|
-
/squad --codex fix cache bug in ParameterService
|
|
385
|
+
/squad:implement --codex fix cache bug in ParameterService
|
|
376
386
|
-> With Codex
|
|
377
387
|
-> Plan + Planner -> Codex validates -> User approves -> Advisory -> Implement -> Codex reviews -> Consolidator
|
|
378
388
|
|
|
379
|
-
/squad refactor ExchangeUsdService to split responsibilities
|
|
389
|
+
/squad:implement refactor ExchangeUsdService to split responsibilities
|
|
380
390
|
-> Plan + Planner -> User approves -> Advisory -> Implement -> Consolidator
|
|
381
391
|
|
|
382
|
-
/squad --quick rename a misspelled local variable in BalanceController
|
|
392
|
+
/squad:implement --quick rename a misspelled local variable in BalanceController
|
|
383
393
|
-> Quick mode: condensed plan, 1 specialist + tech-lead, terse prompts, condensed delivery
|
|
384
394
|
|
|
385
|
-
/squad --quick --codex anything
|
|
395
|
+
/squad:implement --quick --codex anything
|
|
386
396
|
-> Error: --quick is mutually exclusive with --codex
|
|
387
397
|
```
|
|
388
398
|
|
|
389
399
|
## Inviolable Rules
|
|
400
|
+
|
|
390
401
|
1. Every implementation starts from a plan (approved explicitly, or auto-proceeded under `--quick` when risk Low).
|
|
391
402
|
2. Codex only runs with user consent (flag or confirmed auto-suggestion). Never combined with `--quick`.
|
|
392
403
|
3. TechLead-Consolidator always delivers the final verdict in normal mode. Under `--quick`, skipped only when the specialist reports zero Blocker/Major findings.
|
|
@@ -1,17 +1,19 @@
|
|
|
1
1
|
# Skill: Squad Review
|
|
2
2
|
|
|
3
3
|
## Objective
|
|
4
|
+
|
|
4
5
|
Skill that takes a user prompt, interprets intent, selects the relevant agents, distributes tasks in parallel, and consolidates the results through TechLead-Consolidator.
|
|
5
6
|
|
|
6
7
|
## Skill Name
|
|
7
|
-
|
|
8
|
+
|
|
9
|
+
`/squad:review`
|
|
8
10
|
|
|
9
11
|
## How It Works
|
|
10
12
|
|
|
11
13
|
### General Flow
|
|
12
14
|
|
|
13
15
|
```
|
|
14
|
-
User -> /squad
|
|
16
|
+
User -> /squad:review {prompt}
|
|
15
17
|
|
|
|
16
18
|
v
|
|
17
19
|
[1. Prompt Analysis]
|
|
@@ -56,51 +58,63 @@ User -> /squad-review {prompt}
|
|
|
56
58
|
The user can request a generic review or target a focus area. The skill maps the intent to the correct squad.
|
|
57
59
|
|
|
58
60
|
#### Full Squad (default for PR review)
|
|
61
|
+
|
|
59
62
|
All specialized agents + TechLead-Consolidator.
|
|
63
|
+
|
|
60
64
|
- **When**: Complete PR review, branch ready to merge
|
|
61
|
-
- **Triggers**: `/squad
|
|
65
|
+
- **Triggers**: `/squad:review`, `/squad:review PR`, `/squad:review branch`
|
|
62
66
|
|
|
63
67
|
#### Code Squad
|
|
68
|
+
|
|
64
69
|
`senior-dev-reviewer` + `senior-developer` + `senior-qa` + `tech-lead-consolidator`
|
|
70
|
+
|
|
65
71
|
- **When**: Focused review on code quality and correctness
|
|
66
|
-
- **Triggers**: `/squad
|
|
72
|
+
- **Triggers**: `/squad:review code`
|
|
67
73
|
|
|
68
74
|
#### Data Squad
|
|
75
|
+
|
|
69
76
|
`senior-dba` + `senior-developer` + `tech-lead-consolidator`
|
|
77
|
+
|
|
70
78
|
- **When**: Changes to queries, migrations, cache, EF
|
|
71
|
-
- **Triggers**: `/squad
|
|
79
|
+
- **Triggers**: `/squad:review data`
|
|
72
80
|
|
|
73
81
|
#### Security Squad
|
|
82
|
+
|
|
74
83
|
`senior-dev-security` + `senior-developer` + `senior-dev-reviewer` + `tech-lead-consolidator`
|
|
84
|
+
|
|
75
85
|
- **When**: Focused security review
|
|
76
|
-
- **Triggers**: `/squad
|
|
86
|
+
- **Triggers**: `/squad:review security`
|
|
77
87
|
|
|
78
88
|
#### Architecture Squad
|
|
89
|
+
|
|
79
90
|
`senior-architect` + `senior-developer` + `senior-dba` + `tech-lead-consolidator`
|
|
91
|
+
|
|
80
92
|
- **When**: Structural changes, new modules, large refactors
|
|
81
|
-
- **Triggers**: `/squad
|
|
93
|
+
- **Triggers**: `/squad:review arch`
|
|
82
94
|
|
|
83
95
|
#### Business Squad
|
|
96
|
+
|
|
84
97
|
`po` + `senior-developer` + `senior-qa` + `tech-lead-consolidator`
|
|
98
|
+
|
|
85
99
|
- **When**: New feature, business-rule change
|
|
86
|
-
- **Triggers**: `/squad
|
|
100
|
+
- **Triggers**: `/squad:review business`
|
|
87
101
|
|
|
88
102
|
### Automatic Squad Detection
|
|
89
103
|
|
|
90
104
|
When the user does not specify a squad, the skill analyzes the modified files to infer it:
|
|
91
105
|
|
|
92
|
-
| Modified Files
|
|
93
|
-
|
|
94
|
-
| Controllers, DTOs, Requests, Responses | senior-developer, senior-dev-security, po
|
|
95
|
-
| Services (business logic)
|
|
96
|
-
| Repositories, Queries
|
|
97
|
-
| Migrations, Schema
|
|
98
|
-
| Startup, Program.cs, DI
|
|
99
|
-
| appsettings, configs
|
|
100
|
-
| Tests
|
|
101
|
-
| Middlewares, Filters
|
|
102
|
-
| Dockerfile, pipeline, CI/CD
|
|
103
|
-
| Multiple layers
|
|
106
|
+
| Modified Files | Selected Agents |
|
|
107
|
+
| -------------------------------------- | ------------------------------------------------------- |
|
|
108
|
+
| Controllers, DTOs, Requests, Responses | senior-developer, senior-dev-security, po |
|
|
109
|
+
| Services (business logic) | senior-developer, senior-dev-reviewer, po, senior-qa |
|
|
110
|
+
| Repositories, Queries | senior-dba, senior-developer |
|
|
111
|
+
| Migrations, Schema | senior-dba, senior-architect |
|
|
112
|
+
| Startup, Program.cs, DI | senior-architect, senior-dev-security |
|
|
113
|
+
| appsettings, configs | senior-dev-security, senior-architect |
|
|
114
|
+
| Tests | senior-qa, senior-dev-reviewer |
|
|
115
|
+
| Middlewares, Filters | senior-dev-security, senior-architect, senior-developer |
|
|
116
|
+
| Dockerfile, pipeline, CI/CD | tech-lead-consolidator |
|
|
117
|
+
| Multiple layers | Full Squad |
|
|
104
118
|
|
|
105
119
|
TechLead-Consolidator is mandatory in any squad.
|
|
106
120
|
|
|
@@ -156,6 +170,7 @@ If an agent did not participate, mark as "Not evaluated".
|
|
|
156
170
|
## Implementation
|
|
157
171
|
|
|
158
172
|
### Step 1: Collect Context
|
|
173
|
+
|
|
159
174
|
```
|
|
160
175
|
- git status
|
|
161
176
|
- git diff master...HEAD (or specified branch)
|
|
@@ -164,6 +179,7 @@ If an agent did not participate, mark as "Not evaluated".
|
|
|
164
179
|
```
|
|
165
180
|
|
|
166
181
|
### Step 2: Determine Squad
|
|
182
|
+
|
|
167
183
|
```
|
|
168
184
|
- If the user specified one, use it
|
|
169
185
|
- Otherwise, analyze modified files and infer the squad
|
|
@@ -171,6 +187,7 @@ If an agent did not participate, mark as "Not evaluated".
|
|
|
171
187
|
```
|
|
172
188
|
|
|
173
189
|
### Step 3: Spawn Agents in Parallel
|
|
190
|
+
|
|
174
191
|
```
|
|
175
192
|
- Use the Agent tool with subagent_type for each agent
|
|
176
193
|
- All in parallel (single message with multiple tool calls)
|
|
@@ -178,18 +195,21 @@ If an agent did not participate, mark as "Not evaluated".
|
|
|
178
195
|
```
|
|
179
196
|
|
|
180
197
|
### Step 4: Collect Results
|
|
198
|
+
|
|
181
199
|
```
|
|
182
200
|
- Wait for all agents to finish
|
|
183
201
|
- Gather every report
|
|
184
202
|
```
|
|
185
203
|
|
|
186
204
|
### Step 5: Consolidate via TechLead-Consolidator
|
|
205
|
+
|
|
187
206
|
```
|
|
188
207
|
- Spawn tech-lead-consolidator with every report
|
|
189
208
|
- Consolidator produces the final verdict
|
|
190
209
|
```
|
|
191
210
|
|
|
192
211
|
### Step 6: Present to the User
|
|
212
|
+
|
|
193
213
|
```
|
|
194
214
|
- Display the consolidated report
|
|
195
215
|
- If any agent raised a Blocker, highlight it at the top
|
|
@@ -226,12 +246,12 @@ If an agent did not participate, mark as "Not evaluated".
|
|
|
226
246
|
|
|
227
247
|
## Skill Parameters
|
|
228
248
|
|
|
229
|
-
| Parameter | Type | Default | Description
|
|
230
|
-
|
|
231
|
-
| squad | string | auto | Specific squad or "auto" for automatic detection
|
|
232
|
-
| scope | string | branch | "branch" (branch diff), "file:path" (specific file), "commit:hash"
|
|
233
|
-
| base | string | master | Base branch for the diff
|
|
234
|
-
| verbose | bool | false | If true, show full individual reports; if false, only the consolidated one
|
|
249
|
+
| Parameter | Type | Default | Description |
|
|
250
|
+
| --------- | ------ | ------- | ---------------------------------------------------------------------------------- |
|
|
251
|
+
| squad | string | auto | Specific squad or "auto" for automatic detection |
|
|
252
|
+
| scope | string | branch | "branch" (branch diff), "file:path" (specific file), "commit:hash" |
|
|
253
|
+
| base | string | master | Base branch for the diff |
|
|
254
|
+
| verbose | bool | false | If true, show full individual reports; if false, only the consolidated one |
|
|
235
255
|
| --quick | flag | off | Quick mode (see below). Trades depth for speed. Mutually exclusive with `--codex`. |
|
|
236
256
|
|
|
237
257
|
## Quick Mode (`--quick`)
|
|
@@ -240,14 +260,14 @@ Reduced agent set, terse prompts, condensed output. Goal: usable verdict in roug
|
|
|
240
260
|
|
|
241
261
|
Phase deltas vs. normal mode:
|
|
242
262
|
|
|
243
|
-
| Aspect
|
|
244
|
-
|
|
245
|
-
| Agents
|
|
246
|
-
| Per-agent prompt
|
|
247
|
-
| Tech-lead consolidator
|
|
248
|
-
| Codex
|
|
249
|
-
| Critical-change auto-fallback | N/A
|
|
250
|
-
| Output
|
|
263
|
+
| Aspect | Normal | Quick |
|
|
264
|
+
| ----------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
265
|
+
| Agents | Auto-detect 3-7 specialists + tech-lead | Hard cap: 1 specialist + tech-lead. Specialist defaults to `senior-dev-reviewer` (or focus mode primary) |
|
|
266
|
+
| Per-agent prompt | Full template | "Flag only Blocker/Major in your domain. ≤200 words. No scorecard. No comments-by-file table. If clean: 'No issues in scope.'" |
|
|
267
|
+
| Tech-lead consolidator | Always runs | Skipped when zero Blocker/Major reported by specialist |
|
|
268
|
+
| Codex | Opt-in via `--codex` | Force-disabled. `--quick --codex` rejected. |
|
|
269
|
+
| Critical-change auto-fallback | N/A | Diff touching `auth`, `crypto`, `permissions`, `Program.cs`, `Startup.cs`, migrations, `appsettings` falls back to normal mode with warning |
|
|
270
|
+
| Output | Full Markdown with scorecard, per-file comments, individual reports | Condensed: verdict + top 3 issues + "run without --quick for full review" hint |
|
|
251
271
|
|
|
252
272
|
Quick agent prompt:
|
|
253
273
|
|
|
@@ -297,41 +317,44 @@ Verdict: APPROVED — no Blocker or Major findings.
|
|
|
297
317
|
## Usage Examples
|
|
298
318
|
|
|
299
319
|
```
|
|
300
|
-
/squad
|
|
320
|
+
/squad:review
|
|
301
321
|
-> Auto-detects the squad; reviews diff of current branch vs. master
|
|
302
322
|
|
|
303
|
-
/squad
|
|
323
|
+
/squad:review security
|
|
304
324
|
-> Security squad; reviews current branch diff
|
|
305
325
|
|
|
306
|
-
/squad
|
|
326
|
+
/squad:review arch Services/ParameterService.cs
|
|
307
327
|
-> Architecture squad; focused on the specified file
|
|
308
328
|
|
|
309
|
-
/squad
|
|
329
|
+
/squad:review full
|
|
310
330
|
-> Every agent; complete review
|
|
311
331
|
|
|
312
|
-
/squad
|
|
332
|
+
/squad:review --quick
|
|
313
333
|
-> Quick mode: 1 specialist + tech-lead, terse prompts, condensed output
|
|
314
334
|
|
|
315
|
-
/squad
|
|
335
|
+
/squad:review --quick code
|
|
316
336
|
-> Quick code-quality review (senior-dev-reviewer + tech-lead)
|
|
317
337
|
|
|
318
|
-
/squad
|
|
338
|
+
/squad:review --quick --codex
|
|
319
339
|
-> Error: --quick is mutually exclusive with --codex
|
|
320
340
|
```
|
|
321
341
|
|
|
322
342
|
## Considerations
|
|
323
343
|
|
|
324
344
|
### Performance
|
|
345
|
+
|
|
325
346
|
- Parallel agents minimize total time
|
|
326
347
|
- TechLead-Consolidator runs sequentially after the others (needs their reports)
|
|
327
348
|
- For large reviews, consider splitting by area or module
|
|
328
349
|
|
|
329
350
|
### Cost
|
|
351
|
+
|
|
330
352
|
- Each agent consumes tokens independently
|
|
331
353
|
- Full squad = 7 specialist agents + TechLead-Consolidator = 8 calls
|
|
332
354
|
- For small changes, auto-selection avoids unnecessary agents
|
|
333
355
|
|
|
334
356
|
### Limitations
|
|
357
|
+
|
|
335
358
|
- Agents do not talk to each other (only through TechLead-Consolidator)
|
|
336
359
|
- Forwarded items are informational — they do not trigger new executions in this skill
|
|
337
360
|
- TechLead-Consolidator consolidates but does not re-execute agents
|
|
@@ -41,12 +41,12 @@ Shared reference for the squad. Each topic has a single primary owner. Other age
|
|
|
41
41
|
|
|
42
42
|
Every finding carries a severity. Agents must use these labels consistently.
|
|
43
43
|
|
|
44
|
-
| Level | Meaning
|
|
45
|
-
| ---------- |
|
|
46
|
-
| Blocker | Cannot ship: correctness break, security hole, data loss, production outage likely
|
|
47
|
-
| Major | Significant risk or violation with no reasonable justification
|
|
48
|
-
| Minor | Quality issue, local smell, limited impact
|
|
49
|
-
| Suggestion | Improvement opportunity, nitpick, or stylistic preference
|
|
44
|
+
| Level | Meaning | Merge Impact |
|
|
45
|
+
| ---------- | ---------------------------------------------------------------------------------- | ---------------------------- |
|
|
46
|
+
| Blocker | Cannot ship: correctness break, security hole, data loss, production outage likely | Halts merge |
|
|
47
|
+
| Major | Significant risk or violation with no reasonable justification | Halts merge unless justified |
|
|
48
|
+
| Minor | Quality issue, local smell, limited impact | Does not block |
|
|
49
|
+
| Suggestion | Improvement opportunity, nitpick, or stylistic preference | Does not block |
|
|
50
50
|
|
|
51
51
|
## Standard Section: Assumptions and Limitations
|
|
52
52
|
|