@fredericboyer/dev-team 0.2.0 → 0.3.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/dist/bin/dev-team.js +11 -3
- package/dist/bin/dev-team.js.map +1 -1
- package/dist/create-agent.d.ts +1 -0
- package/dist/create-agent.js +106 -0
- package/dist/create-agent.js.map +1 -0
- package/dist/init.d.ts +20 -0
- package/dist/init.js +62 -11
- package/dist/init.js.map +1 -1
- package/package.json +1 -1
- package/templates/CLAUDE.md +3 -0
- package/templates/agent-memory/dev-team-lead/MEMORY.md +12 -0
- package/templates/agents/dev-team-lead.md +95 -0
- package/templates/hooks/dev-team-pre-commit-gate.js +32 -1
- package/templates/hooks/dev-team-watch-list.js +84 -0
- package/templates/settings.json +4 -0
package/dist/bin/dev-team.js
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const init_1 = require("../init");
|
|
4
4
|
const update_1 = require("../update");
|
|
5
|
+
const create_agent_1 = require("../create-agent");
|
|
5
6
|
const args = process.argv.slice(2);
|
|
6
7
|
const command = args[0];
|
|
7
8
|
if (command === "init") {
|
|
@@ -16,12 +17,19 @@ else if (command === "update") {
|
|
|
16
17
|
process.exit(1);
|
|
17
18
|
});
|
|
18
19
|
}
|
|
20
|
+
else if (command === "create-agent") {
|
|
21
|
+
(0, create_agent_1.createAgent)(process.cwd(), args[1]);
|
|
22
|
+
}
|
|
19
23
|
else {
|
|
20
24
|
console.log("dev-team — Adversarial AI agent team for any project\n");
|
|
21
25
|
console.log("Usage:");
|
|
22
|
-
console.log(" npx dev-team init
|
|
23
|
-
console.log(" npx dev-team init --all
|
|
24
|
-
console.log(" npx dev-team
|
|
26
|
+
console.log(" npx dev-team init Interactive onboarding wizard");
|
|
27
|
+
console.log(" npx dev-team init --all Install everything with defaults");
|
|
28
|
+
console.log(" npx dev-team init --preset backend Backend-heavy (API, security, architecture)");
|
|
29
|
+
console.log(" npx dev-team init --preset fullstack Full-stack (all agents)");
|
|
30
|
+
console.log(" npx dev-team init --preset data Data pipeline (backend, quality, tooling)");
|
|
31
|
+
console.log(" npx dev-team update Update agents, hooks, and skills to latest");
|
|
32
|
+
console.log(" npx dev-team create-agent <name> Scaffold a new custom agent");
|
|
25
33
|
console.log("");
|
|
26
34
|
process.exit(command === "--help" || command === "-h" ? 0 : 1);
|
|
27
35
|
}
|
package/dist/bin/dev-team.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dev-team.js","sourceRoot":"","sources":["../../src/bin/dev-team.ts"],"names":[],"mappings":";;AAAA,kCAA8B;AAC9B,sCAAmC;
|
|
1
|
+
{"version":3,"file":"dev-team.js","sourceRoot":"","sources":["../../src/bin/dev-team.ts"],"names":[],"mappings":";;AAAA,kCAA8B;AAC9B,sCAAmC;AACnC,kDAA8C;AAE9C,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;AACnC,MAAM,OAAO,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC;AAExB,IAAI,OAAO,KAAK,MAAM,EAAE,CAAC;IACvB,IAAA,UAAG,EAAC,OAAO,CAAC,GAAG,EAAE,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,GAAU,EAAE,EAAE;QACrD,OAAO,CAAC,KAAK,CAAC,UAAU,GAAG,CAAC,OAAO,EAAE,CAAC,CAAC;QACvC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC,CAAC,CAAC;AACL,CAAC;KAAM,IAAI,OAAO,KAAK,QAAQ,EAAE,CAAC;IAChC,IAAA,eAAM,EAAC,OAAO,CAAC,GAAG,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,GAAU,EAAE,EAAE;QACzC,OAAO,CAAC,KAAK,CAAC,UAAU,GAAG,CAAC,OAAO,EAAE,CAAC,CAAC;QACvC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC,CAAC,CAAC;AACL,CAAC;KAAM,IAAI,OAAO,KAAK,cAAc,EAAE,CAAC;IACtC,IAAA,0BAAW,EAAC,OAAO,CAAC,GAAG,EAAE,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC;AACtC,CAAC;KAAM,CAAC;IACN,OAAO,CAAC,GAAG,CAAC,wDAAwD,CAAC,CAAC;IACtE,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;IACtB,OAAO,CAAC,GAAG,CAAC,sEAAsE,CAAC,CAAC;IACpF,OAAO,CAAC,GAAG,CAAC,yEAAyE,CAAC,CAAC;IACvF,OAAO,CAAC,GAAG,CAAC,oFAAoF,CAAC,CAAC;IAClG,OAAO,CAAC,GAAG,CAAC,iEAAiE,CAAC,CAAC;IAC/E,OAAO,CAAC,GAAG,CAAC,mFAAmF,CAAC,CAAC;IACjG,OAAO,CAAC,GAAG,CAAC,mFAAmF,CAAC,CAAC;IACjG,OAAO,CAAC,GAAG,CAAC,oEAAoE,CAAC,CAAC;IAClF,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;IAChB,OAAO,CAAC,IAAI,CAAC,OAAO,KAAK,QAAQ,IAAI,OAAO,KAAK,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACjE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function createAgent(targetDir: string, name: string): void;
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.createAgent = createAgent;
|
|
7
|
+
const path_1 = __importDefault(require("path"));
|
|
8
|
+
const files_1 = require("./files");
|
|
9
|
+
const AGENT_TEMPLATE = `---
|
|
10
|
+
name: dev-team-AGENTNAME
|
|
11
|
+
description: ROLE. Use to TRIGGER_CONDITIONS.
|
|
12
|
+
tools: Read, Edit, Write, Bash, Grep, Glob, Agent
|
|
13
|
+
model: sonnet
|
|
14
|
+
memory: project
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
You are AGENTNAME, a ROLE. PERSPECTIVE_STATEMENT.
|
|
18
|
+
|
|
19
|
+
Your philosophy: "GUIDING_PRINCIPLE."
|
|
20
|
+
|
|
21
|
+
## How you work
|
|
22
|
+
|
|
23
|
+
Before starting:
|
|
24
|
+
1. Spawn Explore subagents in parallel to understand the codebase area.
|
|
25
|
+
2. Read the actual code. Do not rely on descriptions from other agents.
|
|
26
|
+
3. Return concise findings to the main thread.
|
|
27
|
+
|
|
28
|
+
After completing work:
|
|
29
|
+
1. Report impacts for other agents.
|
|
30
|
+
2. Spawn reviewers as background tasks.
|
|
31
|
+
|
|
32
|
+
## Focus areas
|
|
33
|
+
|
|
34
|
+
You always check for:
|
|
35
|
+
- **AREA_1**: DESCRIPTION.
|
|
36
|
+
- **AREA_2**: DESCRIPTION.
|
|
37
|
+
|
|
38
|
+
## Challenge style
|
|
39
|
+
|
|
40
|
+
DESCRIPTION_OF_HOW_THIS_AGENT_FRAMES_CHALLENGES.
|
|
41
|
+
|
|
42
|
+
## Challenge protocol
|
|
43
|
+
|
|
44
|
+
When reviewing another agent's work, classify each concern:
|
|
45
|
+
- \`[DEFECT]\`: Concretely wrong. Will produce incorrect behavior. **Blocks progress.**
|
|
46
|
+
- \`[RISK]\`: Not wrong today, but creates a likely failure mode. Advisory.
|
|
47
|
+
- \`[QUESTION]\`: Decision needs justification. Advisory.
|
|
48
|
+
- \`[SUGGESTION]\`: Works, but here is a specific improvement. Advisory.
|
|
49
|
+
|
|
50
|
+
Rules:
|
|
51
|
+
1. Every challenge must include a concrete scenario, input, or code reference.
|
|
52
|
+
2. Only \`[DEFECT]\` blocks progress.
|
|
53
|
+
3. When challenged: address directly, concede when wrong, justify with a counter-scenario when you disagree.
|
|
54
|
+
4. One exchange each before escalating to the human.
|
|
55
|
+
5. Acknowledge good work when you see it.
|
|
56
|
+
|
|
57
|
+
## Learning
|
|
58
|
+
|
|
59
|
+
After completing work, write key learnings to your MEMORY.md:
|
|
60
|
+
- DOMAIN_SPECIFIC_LEARNINGS
|
|
61
|
+
- Challenges you raised that were accepted (reinforce) or overruled (calibrate)
|
|
62
|
+
`;
|
|
63
|
+
const MEMORY_TEMPLATE = `# Agent Memory: AGENTNAME
|
|
64
|
+
<!-- First 200 lines are loaded into agent context. Keep concise. -->
|
|
65
|
+
|
|
66
|
+
## Project Conventions
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
## Patterns to Watch For
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
## Calibration Log
|
|
73
|
+
<!-- Challenges accepted/overruled — tunes adversarial intensity over time -->
|
|
74
|
+
|
|
75
|
+
`;
|
|
76
|
+
function createAgent(targetDir, name) {
|
|
77
|
+
if (!name) {
|
|
78
|
+
console.error("Usage: npx dev-team create-agent <name>");
|
|
79
|
+
console.error("Example: npx dev-team create-agent codd");
|
|
80
|
+
process.exit(1);
|
|
81
|
+
}
|
|
82
|
+
const safeName = name.toLowerCase().replace(/[^a-z0-9-]/g, "-");
|
|
83
|
+
const fullName = safeName.startsWith("dev-team-") ? safeName : `dev-team-${safeName}`;
|
|
84
|
+
const displayName = safeName.replace(/^dev-team-/, "");
|
|
85
|
+
const titleName = displayName.charAt(0).toUpperCase() + displayName.slice(1);
|
|
86
|
+
const agentPath = path_1.default.join(targetDir, ".claude", "agents", `${fullName}.md`);
|
|
87
|
+
const memoryPath = path_1.default.join(targetDir, ".claude", "agent-memory", fullName, "MEMORY.md");
|
|
88
|
+
if ((0, files_1.fileExists)(agentPath)) {
|
|
89
|
+
console.error(`Agent already exists: ${agentPath}`);
|
|
90
|
+
process.exit(1);
|
|
91
|
+
}
|
|
92
|
+
const agentContent = AGENT_TEMPLATE.replace(/AGENTNAME/g, titleName);
|
|
93
|
+
const memoryContent = MEMORY_TEMPLATE.replace(/AGENTNAME/g, `${titleName}`);
|
|
94
|
+
(0, files_1.writeFile)(agentPath, agentContent);
|
|
95
|
+
(0, files_1.writeFile)(memoryPath, memoryContent);
|
|
96
|
+
console.log(`\nCreated agent: @${fullName}\n`);
|
|
97
|
+
console.log(` Agent: ${agentPath}`);
|
|
98
|
+
console.log(` Memory: ${memoryPath}`);
|
|
99
|
+
console.log("");
|
|
100
|
+
console.log("Next steps:");
|
|
101
|
+
console.log(" 1. Edit the agent file — fill in ROLE, FOCUS_AREAS, etc.");
|
|
102
|
+
console.log(" 2. Add the agent to the table in CLAUDE.md");
|
|
103
|
+
console.log(" 3. See docs/custom-agents.md for the full authoring guide");
|
|
104
|
+
console.log("");
|
|
105
|
+
}
|
|
106
|
+
//# sourceMappingURL=create-agent.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-agent.js","sourceRoot":"","sources":["../src/create-agent.ts"],"names":[],"mappings":";;;;;AAwEA,kCAmCC;AA3GD,gDAAwB;AACxB,mCAAgD;AAEhD,MAAM,cAAc,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAqDtB,CAAC;AAEF,MAAM,eAAe,GAAG;;;;;;;;;;;;CAYvB,CAAC;AAEF,SAAgB,WAAW,CAAC,SAAiB,EAAE,IAAY;IACzD,IAAI,CAAC,IAAI,EAAE,CAAC;QACV,OAAO,CAAC,KAAK,CAAC,yCAAyC,CAAC,CAAC;QACzD,OAAO,CAAC,KAAK,CAAC,yCAAyC,CAAC,CAAC;QACzD,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;IAED,MAAM,QAAQ,GAAG,IAAI,CAAC,WAAW,EAAE,CAAC,OAAO,CAAC,aAAa,EAAE,GAAG,CAAC,CAAC;IAChE,MA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CAAC,EAAE,CAAC,CAAC;IAChB,OAAO,CAAC,GAAG,CAAC,aAAa,CAAC,CAAC;IAC3B,OAAO,CAAC,GAAG,CAAC,4DAA4D,CAAC,CAAC;IAC1E,OAAO,CAAC,GAAG,CAAC,8CAA8C,CAAC,CAAC;IAC5D,OAAO,CAAC,GAAG,CAAC,6DAA6D,CAAC,CAAC;IAC3E,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;AAClB,CAAC"}
|
package/dist/init.d.ts
CHANGED
|
@@ -1,3 +1,23 @@
|
|
|
1
|
+
interface AgentDefinition {
|
|
2
|
+
label: string;
|
|
3
|
+
file: string;
|
|
4
|
+
description: string;
|
|
5
|
+
}
|
|
6
|
+
interface HookDefinition {
|
|
7
|
+
label: string;
|
|
8
|
+
file: string;
|
|
9
|
+
description: string;
|
|
10
|
+
}
|
|
11
|
+
declare const ALL_AGENTS: AgentDefinition[];
|
|
12
|
+
declare const QUALITY_HOOKS: HookDefinition[];
|
|
13
|
+
interface PresetDefinition {
|
|
14
|
+
label: string;
|
|
15
|
+
description: string;
|
|
16
|
+
agents: string[];
|
|
17
|
+
hooks: string[];
|
|
18
|
+
}
|
|
19
|
+
declare const PRESETS: Record<string, PresetDefinition>;
|
|
20
|
+
export { PRESETS, ALL_AGENTS, QUALITY_HOOKS };
|
|
1
21
|
/**
|
|
2
22
|
* Main init flow.
|
|
3
23
|
*/
|
package/dist/init.js
CHANGED
|
@@ -36,6 +36,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
36
36
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
37
|
};
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
+
exports.QUALITY_HOOKS = exports.ALL_AGENTS = exports.PRESETS = void 0;
|
|
39
40
|
exports.run = run;
|
|
40
41
|
const path_1 = __importDefault(require("path"));
|
|
41
42
|
const files_1 = require("./files");
|
|
@@ -79,7 +80,13 @@ const ALL_AGENTS = [
|
|
|
79
80
|
file: "dev-team-release.md",
|
|
80
81
|
description: "Release Manager",
|
|
81
82
|
},
|
|
83
|
+
{
|
|
84
|
+
label: "Lead",
|
|
85
|
+
file: "dev-team-lead.md",
|
|
86
|
+
description: "Orchestrator / Team Lead",
|
|
87
|
+
},
|
|
82
88
|
];
|
|
89
|
+
exports.ALL_AGENTS = ALL_AGENTS;
|
|
83
90
|
const QUALITY_HOOKS = [
|
|
84
91
|
{
|
|
85
92
|
label: "TDD enforcement",
|
|
@@ -106,13 +113,54 @@ const QUALITY_HOOKS = [
|
|
|
106
113
|
file: "dev-team-task-loop.js",
|
|
107
114
|
description: "Iterative task loop with adversarial review gates",
|
|
108
115
|
},
|
|
116
|
+
{
|
|
117
|
+
label: "Watch list",
|
|
118
|
+
file: "dev-team-watch-list.js",
|
|
119
|
+
description: "Auto-spawn agents when file patterns match (configurable)",
|
|
120
|
+
},
|
|
109
121
|
];
|
|
122
|
+
exports.QUALITY_HOOKS = QUALITY_HOOKS;
|
|
123
|
+
const PRESETS = {
|
|
124
|
+
backend: {
|
|
125
|
+
label: "backend",
|
|
126
|
+
description: "Backend-heavy — API, security, architecture, quality",
|
|
127
|
+
agents: ["Voss", "Szabo", "Knuth", "Beck", "Deming", "Architect", "Release"],
|
|
128
|
+
hooks: QUALITY_HOOKS.map((h) => h.label),
|
|
129
|
+
},
|
|
130
|
+
fullstack: {
|
|
131
|
+
label: "fullstack",
|
|
132
|
+
description: "Full-stack — all agents for end-to-end coverage",
|
|
133
|
+
agents: ALL_AGENTS.map((a) => a.label),
|
|
134
|
+
hooks: QUALITY_HOOKS.map((h) => h.label),
|
|
135
|
+
},
|
|
136
|
+
data: {
|
|
137
|
+
label: "data",
|
|
138
|
+
description: "Data pipeline — backend, quality, security, tooling",
|
|
139
|
+
agents: ["Voss", "Szabo", "Knuth", "Beck", "Deming", "Docs"],
|
|
140
|
+
hooks: QUALITY_HOOKS.map((h) => h.label),
|
|
141
|
+
},
|
|
142
|
+
};
|
|
143
|
+
exports.PRESETS = PRESETS;
|
|
110
144
|
/**
|
|
111
145
|
* Main init flow.
|
|
112
146
|
*/
|
|
113
147
|
async function run(targetDir, flags = []) {
|
|
114
148
|
const isAll = flags.includes("--all");
|
|
149
|
+
const presetFlag = flags.find((f) => f.startsWith("--preset"));
|
|
150
|
+
let presetName;
|
|
151
|
+
if (presetFlag) {
|
|
152
|
+
const idx = flags.indexOf(presetFlag);
|
|
153
|
+
presetName = presetFlag.includes("=") ? presetFlag.split("=")[1] : flags[idx + 1];
|
|
154
|
+
}
|
|
155
|
+
const preset = presetName ? PRESETS[presetName] : undefined;
|
|
156
|
+
if (presetName && !preset) {
|
|
157
|
+
console.error(`Unknown preset: ${presetName}. Available: ${Object.keys(PRESETS).join(", ")}`);
|
|
158
|
+
process.exit(1);
|
|
159
|
+
}
|
|
115
160
|
console.log("\ndev-team — Adversarial AI agent team\n");
|
|
161
|
+
if (preset) {
|
|
162
|
+
console.log(`Using preset: ${preset.label} — ${preset.description}\n`);
|
|
163
|
+
}
|
|
116
164
|
// Step 1: Detect existing state
|
|
117
165
|
const claudeDir = path_1.default.join(targetDir, ".claude");
|
|
118
166
|
const agentsDir = path_1.default.join(claudeDir, "agents");
|
|
@@ -128,8 +176,8 @@ async function run(targetDir, flags = []) {
|
|
|
128
176
|
console.log("");
|
|
129
177
|
// Step 2: Agent selection
|
|
130
178
|
let selectedAgents;
|
|
131
|
-
if (isAll) {
|
|
132
|
-
selectedAgents = ALL_AGENTS.map((a) => a.label);
|
|
179
|
+
if (isAll || preset) {
|
|
180
|
+
selectedAgents = preset ? preset.agents : ALL_AGENTS.map((a) => a.label);
|
|
133
181
|
}
|
|
134
182
|
else {
|
|
135
183
|
selectedAgents = await prompts.checkbox("Which agents would you like to install?", ALL_AGENTS.map((a) => ({
|
|
@@ -140,8 +188,8 @@ async function run(targetDir, flags = []) {
|
|
|
140
188
|
}
|
|
141
189
|
// Step 3: Hook selection
|
|
142
190
|
let selectedHooks;
|
|
143
|
-
if (isAll) {
|
|
144
|
-
selectedHooks = QUALITY_HOOKS.map((h) => h.label);
|
|
191
|
+
if (isAll || preset) {
|
|
192
|
+
selectedHooks = preset ? preset.hooks : QUALITY_HOOKS.map((h) => h.label);
|
|
145
193
|
}
|
|
146
194
|
else {
|
|
147
195
|
selectedHooks = await prompts.checkbox("Which quality hooks do you want to enforce?", QUALITY_HOOKS.map((h) => ({
|
|
@@ -152,7 +200,7 @@ async function run(targetDir, flags = []) {
|
|
|
152
200
|
}
|
|
153
201
|
// Step 4: Issue tracker preference
|
|
154
202
|
let issueTracker;
|
|
155
|
-
if (isAll) {
|
|
203
|
+
if (isAll || preset) {
|
|
156
204
|
issueTracker = "GitHub Issues";
|
|
157
205
|
}
|
|
158
206
|
else {
|
|
@@ -166,7 +214,7 @@ async function run(targetDir, flags = []) {
|
|
|
166
214
|
}
|
|
167
215
|
// Step 5: Branch naming convention
|
|
168
216
|
let branchConvention;
|
|
169
|
-
if (isAll) {
|
|
217
|
+
if (isAll || preset) {
|
|
170
218
|
branchConvention = "feat/123-description";
|
|
171
219
|
}
|
|
172
220
|
else {
|
|
@@ -190,7 +238,7 @@ async function run(targetDir, flags = []) {
|
|
|
190
238
|
continue;
|
|
191
239
|
const src = path_1.default.join(templates, "agents", agent.file);
|
|
192
240
|
const dest = path_1.default.join(agentsDir, agent.file);
|
|
193
|
-
if ((0, files_1.fileExists)(dest) && !isAll) {
|
|
241
|
+
if ((0, files_1.fileExists)(dest) && !isAll && !preset) {
|
|
194
242
|
const overwrite = await prompts.confirm(` ${agent.file} already exists. Overwrite?`, false);
|
|
195
243
|
if (!overwrite)
|
|
196
244
|
continue;
|
|
@@ -222,7 +270,7 @@ async function run(targetDir, flags = []) {
|
|
|
222
270
|
continue;
|
|
223
271
|
const src = path_1.default.join(templates, "hooks", hook.file);
|
|
224
272
|
const dest = path_1.default.join(hooksDir, hook.file);
|
|
225
|
-
if ((0, files_1.fileExists)(dest) && !isAll) {
|
|
273
|
+
if ((0, files_1.fileExists)(dest) && !isAll && !preset) {
|
|
226
274
|
const overwrite = await prompts.confirm(` ${hook.file} already exists. Overwrite?`, false);
|
|
227
275
|
if (!overwrite)
|
|
228
276
|
continue;
|
|
@@ -269,12 +317,15 @@ async function run(targetDir, flags = []) {
|
|
|
269
317
|
const claudeResult = (0, files_1.mergeClaudeMd)(claudeMdPath, claudeMdTemplate);
|
|
270
318
|
// Save preferences
|
|
271
319
|
const prefs = {
|
|
272
|
-
version: "0.
|
|
320
|
+
version: "0.3.0",
|
|
273
321
|
agents: selectedAgents,
|
|
274
322
|
hooks: selectedHooks,
|
|
275
323
|
issueTracker,
|
|
276
324
|
branchConvention,
|
|
277
325
|
};
|
|
326
|
+
if (preset) {
|
|
327
|
+
prefs.preset = preset.label;
|
|
328
|
+
}
|
|
278
329
|
(0, files_1.writeFile)(prefsPath, JSON.stringify(prefs, null, 2) + "\n");
|
|
279
330
|
// Step 11: Print summary
|
|
280
331
|
console.log("\nDone! Installed:\n");
|
|
@@ -287,8 +338,8 @@ async function run(targetDir, flags = []) {
|
|
|
287
338
|
console.log(` Workflow: ${issueTracker}${branchConvention !== "None" ? `, branches: ${branchConvention}` : ""}`);
|
|
288
339
|
console.log("");
|
|
289
340
|
// Step 12: Optional Deming tooling scan
|
|
290
|
-
let runScan = isAll;
|
|
291
|
-
if (!isAll) {
|
|
341
|
+
let runScan = isAll || !!preset;
|
|
342
|
+
if (!isAll && !preset) {
|
|
292
343
|
runScan = await prompts.confirm("Run Deming tooling scan to check for linters, SAST, and CI gaps?", true);
|
|
293
344
|
}
|
|
294
345
|
if (runScan) {
|
package/dist/init.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"init.js","sourceRoot":"","sources":["../src/init.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAkGA,kBA0OC;AA5UD,gDAAwB;AACxB,mCASiB;AAEjB,mDAAqC;AACrC,iCAAuD;AAcvD,MAAM,UAAU,GAAs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,SAAS,CAAC,CAAC;QACxC,OAAO,CAAC,GAAG,CAAC,IAAA,uBAAgB,EAAC,QAAQ,CAAC,CAAC,CAAC;QACxC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;IAClB,CAAC;IAED,OAAO,CAAC,GAAG,CAAC,aAAa,CAAC,CAAC;IAC3B,OAAO,CAAC,GAAG,CAAC,iDAAiD,CAAC,CAAC;IAC/D,OAAO,CAAC,GAAG,CAAC,mEAAmE,CAAC,CAAC;IACjF,IAAI,CAAC,OAAO,EAAE,CAAC;QACb,OAAO,CAAC,GAAG,CAAC,0EAA0E,CAAC,CAAC;IAC1F,CAAC;IACD,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;AAClB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fredericboyer/dev-team",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "Adversarial AI agent team for any project — installs Claude Code agents, hooks, and skills that enforce quality through productive friction",
|
|
5
5
|
"main": "dist/init.js",
|
|
6
6
|
"types": "dist/init.d.ts",
|
package/templates/CLAUDE.md
CHANGED
|
@@ -17,9 +17,12 @@ This project uses [dev-team](https://github.com/dev-team) — adversarial AI age
|
|
|
17
17
|
| `@dev-team-docs` | Documentation Engineer | Doc accuracy, stale docs, README/API docs, doc-code sync |
|
|
18
18
|
| `@dev-team-architect` | Architect | Architectural review, coupling, dependency direction, ADR compliance |
|
|
19
19
|
| `@dev-team-release` | Release Manager | Versioning, changelog, release readiness, semver validation |
|
|
20
|
+
| `@dev-team-lead` | Team Lead / Orchestrator | Auto-delegates to specialists, manages review loops, resolves conflicts |
|
|
20
21
|
|
|
21
22
|
### Workflow
|
|
22
23
|
|
|
24
|
+
For automatic delegation, use `@dev-team-lead` — it analyzes the task and routes to the right specialist.
|
|
25
|
+
|
|
23
26
|
For non-trivial work: explore the area first, then implement, then review.
|
|
24
27
|
|
|
25
28
|
Agents challenge each other using classified findings:
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
# Agent Memory: Lead (Orchestrator)
|
|
2
|
+
<!-- First 200 lines are loaded into agent context. Keep concise. -->
|
|
3
|
+
|
|
4
|
+
## Delegation Patterns
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
## Conflict Resolution Log
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
## Calibration Log
|
|
11
|
+
<!-- Delegation decisions that worked well or poorly — tunes routing over time -->
|
|
12
|
+
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: dev-team-lead
|
|
3
|
+
description: Team lead / orchestrator. Use to auto-delegate tasks to the right specialist agents, manage the adversarial review loop end-to-end, and resolve conflicts between agents. Invoke with @dev-team-lead or through /dev-team:task for automatic delegation.
|
|
4
|
+
tools: Read, Edit, Write, Bash, Grep, Glob, Agent
|
|
5
|
+
model: opus
|
|
6
|
+
memory: project
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
You are Lead, the team orchestrator. You analyze tasks, delegate to specialists, and manage the adversarial review loop without the human needing to know which agent to invoke.
|
|
10
|
+
|
|
11
|
+
Your philosophy: "The right agent for the right task, with the right reviewer watching."
|
|
12
|
+
|
|
13
|
+
## How you work
|
|
14
|
+
|
|
15
|
+
When given a task:
|
|
16
|
+
|
|
17
|
+
### 1. Analyze and classify
|
|
18
|
+
|
|
19
|
+
Read the task description and determine:
|
|
20
|
+
- **Domain**: backend, frontend, security, testing, tooling, documentation, architecture, release
|
|
21
|
+
- **Type**: implementation, review, audit, refactor, bug fix
|
|
22
|
+
- **Scope**: which files/areas are affected
|
|
23
|
+
|
|
24
|
+
### 2. Select agents
|
|
25
|
+
|
|
26
|
+
Based on the classification, select:
|
|
27
|
+
|
|
28
|
+
**Implementing agent** (one):
|
|
29
|
+
| Domain | Agent | When |
|
|
30
|
+
|--------|-------|------|
|
|
31
|
+
| Backend, API, data, infrastructure | @dev-team-voss | API design, data modeling, system architecture |
|
|
32
|
+
| Frontend, UI, components | @dev-team-mori | Components, accessibility, UX patterns |
|
|
33
|
+
| Tests, TDD | @dev-team-beck | Writing tests, translating audit findings into test cases |
|
|
34
|
+
| Tooling, CI/CD, hooks, config | @dev-team-deming | Linters, formatters, CI/CD, automation |
|
|
35
|
+
| Documentation | @dev-team-docs | README, API docs, inline comments, doc-code sync |
|
|
36
|
+
| Release, versioning | @dev-team-release | Changelog, semver, release readiness |
|
|
37
|
+
|
|
38
|
+
**Reviewing agents** (one or more, spawned in parallel):
|
|
39
|
+
| Concern | Agent | Always/Conditional |
|
|
40
|
+
|---------|-------|--------------------|
|
|
41
|
+
| Security | @dev-team-szabo | Always for code changes |
|
|
42
|
+
| Quality/correctness | @dev-team-knuth | Always for code changes |
|
|
43
|
+
| Architecture | @dev-team-architect | When touching module boundaries, dependencies, or ADRs |
|
|
44
|
+
| Documentation | @dev-team-docs | When APIs or public interfaces change |
|
|
45
|
+
| Release | @dev-team-release | When version-related files change |
|
|
46
|
+
|
|
47
|
+
### 3. Delegate
|
|
48
|
+
|
|
49
|
+
1. Spawn the implementing agent with the full task description.
|
|
50
|
+
2. After implementation completes, spawn review agents **in parallel as background subagents**.
|
|
51
|
+
3. Each reviewer uses their agent definition from `.claude/agents/`.
|
|
52
|
+
|
|
53
|
+
### 4. Manage the review loop
|
|
54
|
+
|
|
55
|
+
Collect classified findings from all reviewers:
|
|
56
|
+
|
|
57
|
+
- **`[DEFECT]`** — must be fixed. Send back to the implementing agent with the specific finding.
|
|
58
|
+
- **`[RISK]`**, **`[QUESTION]`**, **`[SUGGESTION]`** — advisory. Collect and report.
|
|
59
|
+
|
|
60
|
+
If the implementing agent disagrees with a reviewer:
|
|
61
|
+
1. Each side presents their argument (one exchange).
|
|
62
|
+
2. If still unresolved, **escalate to the human** with both perspectives. Do not auto-resolve disagreements.
|
|
63
|
+
|
|
64
|
+
### 5. Complete
|
|
65
|
+
|
|
66
|
+
When no `[DEFECT]` findings remain:
|
|
67
|
+
1. Summarize what was implemented and what was reviewed.
|
|
68
|
+
2. Report any remaining `[RISK]` or `[SUGGESTION]` items.
|
|
69
|
+
3. List which agents reviewed and their verdicts.
|
|
70
|
+
4. Write learnings to agent memory files.
|
|
71
|
+
|
|
72
|
+
## Focus areas
|
|
73
|
+
|
|
74
|
+
You always check for:
|
|
75
|
+
- **Correct delegation**: Is the right agent handling this task? A frontend task should not go to Voss.
|
|
76
|
+
- **Review coverage**: Are the right reviewers assigned? Security-sensitive changes must have Szabo.
|
|
77
|
+
- **Conflict resolution**: When agents disagree, ensure each gets exactly one exchange before escalation.
|
|
78
|
+
- **Iteration limits**: The review loop should converge. If the same `[DEFECT]` persists after 3 iterations, escalate.
|
|
79
|
+
- **Cross-cutting concerns**: Tasks that span multiple domains need multiple implementing agents, coordinated sequentially.
|
|
80
|
+
|
|
81
|
+
## Challenge protocol
|
|
82
|
+
|
|
83
|
+
When reviewing the delegation itself (self-check):
|
|
84
|
+
- `[DEFECT]`: Wrong agent assigned, missing critical reviewer.
|
|
85
|
+
- `[RISK]`: Suboptimal delegation, may miss edge cases.
|
|
86
|
+
- `[QUESTION]`: Ambiguous task — need human clarification before delegating.
|
|
87
|
+
- `[SUGGESTION]`: Could add an optional reviewer for better coverage.
|
|
88
|
+
|
|
89
|
+
## Learning
|
|
90
|
+
|
|
91
|
+
After completing an orchestration, write key learnings to your MEMORY.md:
|
|
92
|
+
- Which delegations worked well or poorly
|
|
93
|
+
- Patterns in task types that map to specific agents
|
|
94
|
+
- Conflict resolutions and their outcomes
|
|
95
|
+
- Iteration counts and convergence patterns
|
|
@@ -50,8 +50,39 @@ if (hasApiFiles) {
|
|
|
50
50
|
reminders.push("@dev-team-mori for UI impact review");
|
|
51
51
|
}
|
|
52
52
|
|
|
53
|
+
// Memory freshness check: if significant work was done but no memory files were updated, remind.
|
|
54
|
+
const hasMemoryUpdates = files.some(
|
|
55
|
+
(f) => /dev-team-learnings\.md$/.test(f) || /agent-memory\/.*MEMORY\.md$/.test(f),
|
|
56
|
+
);
|
|
57
|
+
|
|
58
|
+
if (hasImplFiles && !hasMemoryUpdates) {
|
|
59
|
+
// Check unstaged memory changes too — author may have updated but not staged yet
|
|
60
|
+
let unstagedMemory = false;
|
|
61
|
+
try {
|
|
62
|
+
const unstaged = execFileSync("git", ["diff", "--name-only"], {
|
|
63
|
+
encoding: "utf-8",
|
|
64
|
+
timeout: 5000,
|
|
65
|
+
});
|
|
66
|
+
unstagedMemory = unstaged
|
|
67
|
+
.split("\n")
|
|
68
|
+
.some((f) => /dev-team-learnings\.md$/.test(f) || /agent-memory\/.*MEMORY\.md$/.test(f));
|
|
69
|
+
} catch {
|
|
70
|
+
// Ignore — best effort
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
if (unstagedMemory) {
|
|
74
|
+
reminders.push(
|
|
75
|
+
"Memory files were updated but not staged — run `git add .claude/dev-team-learnings.md .claude/agent-memory/` if learnings should be included",
|
|
76
|
+
);
|
|
77
|
+
} else {
|
|
78
|
+
reminders.push(
|
|
79
|
+
"Update .claude/dev-team-learnings.md or agent memory with any patterns, conventions, or decisions from this work",
|
|
80
|
+
);
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
53
84
|
if (reminders.length > 0) {
|
|
54
|
-
console.log(`[dev-team pre-commit] Before committing, consider
|
|
85
|
+
console.log(`[dev-team pre-commit] Before committing, consider: ${reminders.join("; ")}`);
|
|
55
86
|
}
|
|
56
87
|
|
|
57
88
|
process.exit(0);
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* dev-team-watch-list.js
|
|
5
|
+
* PostToolUse hook on Edit/Write.
|
|
6
|
+
*
|
|
7
|
+
* Reads configurable file-pattern-to-agent mappings from .claude/dev-team.json
|
|
8
|
+
* and outputs structured spawn recommendations when patterns match.
|
|
9
|
+
* Advisory only — always exits 0.
|
|
10
|
+
*
|
|
11
|
+
* Config format in dev-team.json:
|
|
12
|
+
* {
|
|
13
|
+
* "watchLists": [
|
|
14
|
+
* { "pattern": "src/db/", "agents": ["dev-team-codd"], "reason": "database code changed" },
|
|
15
|
+
* { "pattern": "\\.graphql$", "agents": ["dev-team-mori", "dev-team-voss"], "reason": "API schema changed" }
|
|
16
|
+
* ]
|
|
17
|
+
* }
|
|
18
|
+
*/
|
|
19
|
+
|
|
20
|
+
"use strict";
|
|
21
|
+
|
|
22
|
+
const fs = require("fs");
|
|
23
|
+
const path = require("path");
|
|
24
|
+
|
|
25
|
+
let input = {};
|
|
26
|
+
try {
|
|
27
|
+
input = JSON.parse(process.argv[2] || "{}");
|
|
28
|
+
} catch (err) {
|
|
29
|
+
console.warn(
|
|
30
|
+
`[dev-team watch-list] Warning: Failed to parse hook input, allowing operation. ${err.message}`,
|
|
31
|
+
);
|
|
32
|
+
process.exit(0);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
const filePath = (input.tool_input && (input.tool_input.file_path || input.tool_input.path)) || "";
|
|
36
|
+
|
|
37
|
+
if (!filePath) {
|
|
38
|
+
process.exit(0);
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
// Read watch list config
|
|
42
|
+
let watchLists = [];
|
|
43
|
+
try {
|
|
44
|
+
const prefsPath = path.join(process.cwd(), ".claude", "dev-team.json");
|
|
45
|
+
const prefs = JSON.parse(fs.readFileSync(prefsPath, "utf-8"));
|
|
46
|
+
watchLists = prefs.watchLists || [];
|
|
47
|
+
} catch {
|
|
48
|
+
// No config or invalid — skip silently
|
|
49
|
+
process.exit(0);
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
if (watchLists.length === 0) {
|
|
53
|
+
process.exit(0);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
const matches = [];
|
|
57
|
+
|
|
58
|
+
for (const entry of watchLists) {
|
|
59
|
+
if (!entry.pattern || !entry.agents) continue;
|
|
60
|
+
|
|
61
|
+
try {
|
|
62
|
+
const regex = new RegExp(entry.pattern);
|
|
63
|
+
if (regex.test(filePath)) {
|
|
64
|
+
for (const agent of entry.agents) {
|
|
65
|
+
if (!matches.some((m) => m.agent === agent)) {
|
|
66
|
+
matches.push({
|
|
67
|
+
agent,
|
|
68
|
+
reason: entry.reason || `file matched pattern: ${entry.pattern}`,
|
|
69
|
+
});
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
} catch {
|
|
74
|
+
// Invalid regex — skip this entry
|
|
75
|
+
continue;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
if (matches.length > 0) {
|
|
80
|
+
const agentList = matches.map((m) => `@${m.agent} (${m.reason})`).join(", ");
|
|
81
|
+
console.log(`[dev-team watch-list] Spawn recommended: ${agentList}`);
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
process.exit(0);
|