snap-squad 0.5.0 → 0.7.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/README.md +14 -5
- package/dist/cli.js +16 -7
- package/dist/cli.js.map +1 -1
- package/dist/generator/index.d.ts +8 -1
- package/dist/generator/index.d.ts.map +1 -1
- package/dist/generator/index.js +453 -29
- package/dist/generator/index.js.map +1 -1
- package/dist/matcher.js +35 -35
- package/dist/matcher.js.map +1 -1
- package/dist/registry/role-map.js +20 -20
- package/dist/registry/role-map.js.map +1 -1
- package/package.json +1 -1
- package/src/registry/presets/{neighbors.yaml → default.yaml} +7 -7
- package/src/registry/presets/{dash.yaml → fast.yaml} +3 -3
- package/src/registry/presets/{sages.yaml → mentors.yaml} +6 -6
package/README.md
CHANGED
|
@@ -33,9 +33,18 @@ npx snap-squad init help me learn best practices # → Sages (mentor)
|
|
|
33
33
|
npx snap-squad init database security hardening # → Specialists (precision)
|
|
34
34
|
npx snap-squad init something is on fire debug help # → Specialists (Chuck is already on his way)
|
|
35
35
|
npx snap-squad init # → Neighbors (default)
|
|
36
|
-
npx snap-squad init --type
|
|
36
|
+
npx snap-squad init --type fast # → pick directly
|
|
37
37
|
```
|
|
38
38
|
|
|
39
|
+
### Regenerate safely
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
npx snap-squad init --force # refresh structural templates, keep JOURNAL.md + .squad/decisions.md
|
|
43
|
+
npx snap-squad init --reset-all # overwrite every generated file for a true clean slate
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
When `--force` preserves a content file, Snap Squad prints a warning so you know it left your journal or decisions log alone.
|
|
47
|
+
|
|
39
48
|
---
|
|
40
49
|
|
|
41
50
|
## What Is Squad?
|
|
@@ -50,9 +59,9 @@ The catch? Setting up a new squad takes time. Interviews, charters, routing conf
|
|
|
50
59
|
|
|
51
60
|
| Preset | Vibe | Agents | Best For |
|
|
52
61
|
|--------|------|--------|----------|
|
|
53
|
-
| [**
|
|
54
|
-
| [**
|
|
55
|
-
| [**
|
|
62
|
+
| [**default**](docs/presets/default.md) | Generalist | Blueprint *(architect)*, Wrench *(dev)*, Lens *(QA)*, Quill *(docs)*, Mosaic *(prompts)*, Relay *(GitOps)*, Val *(light evals)*, Scout *(researcher)*, Ledger *(historian)* | General-purpose projects, reliable building |
|
|
63
|
+
| [**fast**](docs/presets/fast.md) | Speed | Turbo *(architect)*, Bolt *(full-stack)*, Flash *(test + docs)* | Rapid POCs, hackathons, zero fluff |
|
|
64
|
+
| [**mentors**](docs/presets/mentors.md) | Mentor | Polaris *(architect)*, Scriptor *(mentor dev)*, Proof *(test mentor)*, Chronicle *(docs)*, Pattern *(prompts)*, Measure *(evals)*, Scout *(researcher)*, Ledger *(historian)* | Learning, best practices, architecture review |
|
|
56
65
|
| [**specialists**](docs/presets/specialists.md) | Precision | Chuck 🥋 *(debugger)*, Forge *(architect)*, Anvil *(data)*, Chisel *(security)*, Prism *(UI/UX)*, Loom *(infra)*, Caliber *(deep evals)*, Sensei *(skill audit)*, Waza *(skill bench)*, Blitz *(mass ops)*, Recon *(deep research)*, Ledger *(historian)* | DB tuning, security hardening, mass ops, troubleshooting |
|
|
57
66
|
|
|
58
67
|
> **Neighbors** does light evals (Val spots-checks baselines). Need a full eval pipeline? **Specialists** brings Caliber for deep eval architecture plus Sensei and Waza for skill benchmarking.
|
|
@@ -87,7 +96,7 @@ The hook chain (`AGENTS.md` + `CLAUDE.md` + `copilot-instructions.md`) makes eve
|
|
|
87
96
|
Once your squad is initialized, just talk to it:
|
|
88
97
|
|
|
89
98
|
```
|
|
90
|
-
> switch my squad to the
|
|
99
|
+
> switch my squad to the mentors preset
|
|
91
100
|
> add a security specialist to my team
|
|
92
101
|
> show me my squad routing rules
|
|
93
102
|
```
|
package/dist/cli.js
CHANGED
|
@@ -24,14 +24,16 @@ program
|
|
|
24
24
|
.option('-d, --dir <directory>', 'target directory', '.')
|
|
25
25
|
.option('-n, --name <name>', 'project name')
|
|
26
26
|
.option('-o, --owner <owner>', 'project owner')
|
|
27
|
-
.option('-f, --force', 'overwrite
|
|
27
|
+
.option('-f, --force', 'overwrite structural files but preserve JOURNAL.md and .squad/decisions.md', false)
|
|
28
|
+
.option('--reset-all', 'overwrite every generated file, including JOURNAL.md and .squad/decisions.md', false)
|
|
28
29
|
.option('--explain', 'show why a preset was chosen')
|
|
29
30
|
.option('--dry-run', 'show what would be created without writing files')
|
|
30
31
|
.action((descriptionWords, opts) => {
|
|
31
32
|
const targetDir = resolve(opts.dir);
|
|
32
33
|
const squadDir = resolve(targetDir, '.squad');
|
|
33
|
-
|
|
34
|
-
|
|
34
|
+
const canRegenerate = opts.force || opts.resetAll;
|
|
35
|
+
if (existsSync(squadDir) && !canRegenerate) {
|
|
36
|
+
console.error(chalk.red('✗ .squad/ already exists. Use --force to refresh templates or --reset-all for a clean slate.'));
|
|
35
37
|
process.exit(1);
|
|
36
38
|
}
|
|
37
39
|
// Resolve preset: explicit --type wins, otherwise match from description
|
|
@@ -53,7 +55,7 @@ program
|
|
|
53
55
|
}
|
|
54
56
|
}
|
|
55
57
|
else {
|
|
56
|
-
presetName = availablePresets.includes('
|
|
58
|
+
presetName = availablePresets.includes('default') ? 'default' : availablePresets[0] ?? 'default';
|
|
57
59
|
}
|
|
58
60
|
let preset;
|
|
59
61
|
try {
|
|
@@ -72,15 +74,22 @@ program
|
|
|
72
74
|
return;
|
|
73
75
|
}
|
|
74
76
|
console.log(chalk.blue(`⚡ Snapping in ${chalk.bold(preset.displayName)}...`));
|
|
75
|
-
const
|
|
77
|
+
const { written, skipped } = generateSquad({
|
|
76
78
|
targetDir,
|
|
77
79
|
preset,
|
|
78
80
|
projectName: opts.name,
|
|
79
81
|
owner: opts.owner,
|
|
82
|
+
overwriteMode: opts.resetAll ? 'all' : opts.force ? 'structural' : 'all',
|
|
80
83
|
});
|
|
84
|
+
if (skipped.length > 0) {
|
|
85
|
+
console.log();
|
|
86
|
+
for (const file of skipped) {
|
|
87
|
+
console.log(chalk.yellow(`⚠ Skipping ${file} (contains user content)`));
|
|
88
|
+
}
|
|
89
|
+
}
|
|
81
90
|
console.log(chalk.green(`\n✓ Squad ready! (${preset.displayName})\n`));
|
|
82
|
-
console.log(chalk.dim('
|
|
83
|
-
for (const file of
|
|
91
|
+
console.log(chalk.dim('Written:'));
|
|
92
|
+
for (const file of written) {
|
|
84
93
|
console.log(chalk.dim(` ${file}`));
|
|
85
94
|
}
|
|
86
95
|
console.log(`\n${chalk.yellow('Next:')} Open ${chalk.bold('Copilot CLI')} or ${chalk.bold('VS Code')} in this folder — your AI is already squad-aware.\n`);
|
package/dist/cli.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli.js","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AAEA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACnD,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAC/D,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAE3C,MAAM,UAAU,GAAG,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAClD,MAAM,SAAS,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;AACtC,MAAM,GAAG,GAAG,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,EAAE,cAAc,CAAC,EAAE,OAAO,CAAC,CAAC,CAAC;AAErF,MAAM,gBAAgB,GAAG,WAAW,EAAE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,EAAE,CAAC;QACzB,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,mBAAmB,CAAC,CAAC,CAAC;QAC/C,OAAO;IACT,CAAC;IAED,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,IAAI,CAAC,sBAAsB,CAAC,CAAC,CAAC;IAChD,KAAK,MAAM,IAAI,IAAI,OAAO,EAAE,CAAC;QAC3B,IAAI,CAAC;YACH,MAAM,CAAC,GAAG,UAAU,CAAC,IAAI,CAAC,CAAC;YAC3B,OAAO,CAAC,GAAG,CAAC,KAAK,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,WAAW,EAAE,CAAC,CAAC;QAC1D,CAAC;QAAC,MAAM,CAAC;YACP,OAAO,CAAC,GAAG,CAAC,KAAK,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;QACvC,CAAC;IACH,CAAC;IACD,OAAO,CAAC,GAAG,EAAE,CAAC;AAChB,CAAC,CAAC,CAAC;AAEL,OAAO,CAAC,KAAK,EAAE,CAAC"}
|
|
@@ -1,9 +1,16 @@
|
|
|
1
1
|
import type { Preset } from '../registry/loader.js';
|
|
2
|
+
type OverwriteMode = 'all' | 'structural';
|
|
2
3
|
export interface GenerateOptions {
|
|
3
4
|
targetDir: string;
|
|
4
5
|
preset: Preset;
|
|
5
6
|
projectName?: string;
|
|
6
7
|
owner?: string;
|
|
8
|
+
overwriteMode?: OverwriteMode;
|
|
7
9
|
}
|
|
8
|
-
export
|
|
10
|
+
export interface GenerateResult {
|
|
11
|
+
written: string[];
|
|
12
|
+
skipped: string[];
|
|
13
|
+
}
|
|
14
|
+
export declare function generateSquad(options: GenerateOptions): GenerateResult;
|
|
15
|
+
export {};
|
|
9
16
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/generator/index.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,MAAM,EAAS,MAAM,uBAAuB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/generator/index.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,MAAM,EAAS,MAAM,uBAAuB,CAAC;AAI3D,KAAK,aAAa,GAAG,KAAK,GAAG,YAAY,CAAC;AAS1C,MAAM,WAAW,eAAe;IAC9B,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,aAAa,CAAC,EAAE,aAAa,CAAC;CAC/B;AAED,MAAM,WAAW,cAAc;IAC7B,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,OAAO,EAAE,MAAM,EAAE,CAAC;CACnB;AAOD,wBAAgB,aAAa,CAAC,OAAO,EAAE,eAAe,GAAG,cAAc,CAiGtE"}
|
package/dist/generator/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { mkdirSync, writeFileSync, rmSync } from 'node:fs';
|
|
1
|
+
import { mkdirSync, writeFileSync, rmSync, existsSync, readFileSync } from 'node:fs';
|
|
2
2
|
import { join, dirname } from 'node:path';
|
|
3
3
|
import { listPresets } from '../registry/loader.js';
|
|
4
4
|
// Sanitize user input for markdown templates
|
|
@@ -6,57 +6,94 @@ function sanitize(input) {
|
|
|
6
6
|
return input.replace(/[[\](){}|`*_~<>#]/g, '\\$&');
|
|
7
7
|
}
|
|
8
8
|
export function generateSquad(options) {
|
|
9
|
-
const { targetDir, preset, projectName, owner } = options;
|
|
9
|
+
const { targetDir, preset, projectName, owner, overwriteMode = 'all' } = options;
|
|
10
10
|
const safeName = projectName ? sanitize(projectName) : undefined;
|
|
11
11
|
const safeOwner = owner ? sanitize(owner) : undefined;
|
|
12
12
|
const squadDir = join(targetDir, '.squad');
|
|
13
13
|
const githubDir = join(targetDir, '.github');
|
|
14
14
|
// Phase 1: Generate all content in memory (no I/O)
|
|
15
15
|
const files = [];
|
|
16
|
-
files.push({ path: join(squadDir, 'team.md'), content: generateTeamMd(preset, safeName, safeOwner), label: '.squad/team.md' });
|
|
17
|
-
files.push({ path: join(squadDir, 'routing.md'), content: generateRoutingMd(preset), label: '.squad/routing.md' });
|
|
16
|
+
files.push({ path: join(squadDir, 'team.md'), content: generateTeamMd(preset, safeName, safeOwner), label: '.squad/team.md', kind: 'structural' });
|
|
17
|
+
files.push({ path: join(squadDir, 'routing.md'), content: generateRoutingMd(preset), label: '.squad/routing.md', kind: 'structural' });
|
|
18
18
|
for (const agent of preset.agents) {
|
|
19
19
|
files.push({
|
|
20
20
|
path: join(squadDir, 'agents', agent.name.toLowerCase(), 'charter.md'),
|
|
21
21
|
content: generateCharter(agent),
|
|
22
22
|
label: `.squad/agents/${agent.name.toLowerCase()}/charter.md`,
|
|
23
|
+
kind: 'structural',
|
|
23
24
|
});
|
|
24
25
|
}
|
|
25
|
-
files.push({ path: join(squadDir, 'decisions.md'), content: generateDecisionsMd(preset), label: '.squad/decisions.md' });
|
|
26
|
-
files.push({ path: join(squadDir, 'mcp-config.md'), content: generateMcpConfigMd(preset), label: '.squad/mcp-config.md' });
|
|
27
|
-
files.push({ path: join(targetDir, 'AGENTS.md'), content: generateAgentsMd(preset, safeName), label: 'AGENTS.md' });
|
|
28
|
-
files.push({ path: join(targetDir, 'CLAUDE.md'), content: generateClaudeMd(preset, safeName, safeOwner), label: 'CLAUDE.md' });
|
|
29
|
-
files.push({ path: join(githubDir, 'copilot-instructions.md'), content: generateCopilotInstructions(preset), label: '.github/copilot-instructions.md' });
|
|
30
|
-
files.push({ path: join(targetDir, 'JOURNAL.md'), content: generateJournalMd(preset, safeName), label: 'JOURNAL.md' });
|
|
26
|
+
files.push({ path: join(squadDir, 'decisions.md'), content: generateDecisionsMd(preset), label: '.squad/decisions.md', kind: 'content' });
|
|
27
|
+
files.push({ path: join(squadDir, 'mcp-config.md'), content: generateMcpConfigMd(preset), label: '.squad/mcp-config.md', kind: 'structural' });
|
|
28
|
+
files.push({ path: join(targetDir, 'AGENTS.md'), content: generateAgentsMd(preset, safeName), label: 'AGENTS.md', kind: 'structural' });
|
|
29
|
+
files.push({ path: join(targetDir, 'CLAUDE.md'), content: generateClaudeMd(preset, safeName, safeOwner), label: 'CLAUDE.md', kind: 'structural' });
|
|
30
|
+
files.push({ path: join(githubDir, 'copilot-instructions.md'), content: generateCopilotInstructions(preset), label: '.github/copilot-instructions.md', kind: 'structural' });
|
|
31
|
+
files.push({ path: join(targetDir, 'JOURNAL.md'), content: generateJournalMd(preset, safeName), label: 'JOURNAL.md', kind: 'content' });
|
|
32
|
+
const skipped = new Set(files
|
|
33
|
+
.filter(({ kind, path }) => overwriteMode === 'structural' && kind === 'content' && existsSync(path))
|
|
34
|
+
.map(({ label }) => label));
|
|
35
|
+
const filesToWrite = files.filter(({ label }) => !skipped.has(label));
|
|
31
36
|
// Phase 2: Create directories
|
|
32
|
-
const
|
|
33
|
-
|
|
34
|
-
|
|
37
|
+
const createdDirs = [];
|
|
38
|
+
const dirs = [...new Set(filesToWrite.map((file) => dirname(file.path)))];
|
|
39
|
+
let currentDir = '';
|
|
40
|
+
try {
|
|
41
|
+
for (const dir of dirs) {
|
|
42
|
+
currentDir = dir;
|
|
43
|
+
if (existsSync(dir)) {
|
|
44
|
+
continue;
|
|
45
|
+
}
|
|
35
46
|
mkdirSync(dir, { recursive: true });
|
|
47
|
+
createdDirs.push(dir);
|
|
36
48
|
}
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
49
|
+
}
|
|
50
|
+
catch (err) {
|
|
51
|
+
for (const createdDir of [...createdDirs].reverse()) {
|
|
52
|
+
try {
|
|
53
|
+
rmSync(createdDir, { recursive: true, force: true });
|
|
54
|
+
}
|
|
55
|
+
catch { }
|
|
40
56
|
}
|
|
57
|
+
const message = err instanceof Error ? err.message : String(err);
|
|
58
|
+
throw new Error(`Failed to create directory "${currentDir}": ${message}`);
|
|
41
59
|
}
|
|
42
|
-
// Phase 3: Write all files (with
|
|
60
|
+
// Phase 3: Write all files (with rollback for overwritten content)
|
|
43
61
|
const written = [];
|
|
62
|
+
const writtenFiles = [];
|
|
63
|
+
const previousContents = new Map();
|
|
44
64
|
try {
|
|
45
|
-
for (const
|
|
46
|
-
|
|
47
|
-
|
|
65
|
+
for (const file of filesToWrite) {
|
|
66
|
+
if (existsSync(file.path)) {
|
|
67
|
+
previousContents.set(file.path, readFileSync(file.path, 'utf-8'));
|
|
68
|
+
}
|
|
69
|
+
writeFileSync(file.path, file.content);
|
|
70
|
+
written.push(file.label);
|
|
71
|
+
writtenFiles.push(file);
|
|
48
72
|
}
|
|
49
73
|
}
|
|
50
74
|
catch (err) {
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
75
|
+
for (const file of [...writtenFiles].reverse()) {
|
|
76
|
+
try {
|
|
77
|
+
const previous = previousContents.get(file.path);
|
|
78
|
+
if (previous !== undefined) {
|
|
79
|
+
writeFileSync(file.path, previous);
|
|
80
|
+
}
|
|
81
|
+
else {
|
|
82
|
+
rmSync(file.path, { force: true });
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
catch { }
|
|
86
|
+
}
|
|
87
|
+
for (const createdDir of [...createdDirs].reverse()) {
|
|
88
|
+
try {
|
|
89
|
+
rmSync(createdDir, { recursive: true, force: true });
|
|
90
|
+
}
|
|
91
|
+
catch { }
|
|
54
92
|
}
|
|
55
|
-
catch { }
|
|
56
93
|
const message = err instanceof Error ? err.message : String(err);
|
|
57
|
-
throw new Error(`Squad generation failed after writing ${written.length}/${
|
|
94
|
+
throw new Error(`Squad generation failed after writing ${written.length}/${filesToWrite.length} files: ${message}`);
|
|
58
95
|
}
|
|
59
|
-
return written;
|
|
96
|
+
return { written, skipped: [...skipped] };
|
|
60
97
|
}
|
|
61
98
|
function generateTeamMd(arch, projectName, owner) {
|
|
62
99
|
const name = projectName || arch.team.name;
|
|
@@ -136,6 +173,7 @@ Resolve those gaps or explicitly report them before ending the session.
|
|
|
136
173
|
`;
|
|
137
174
|
}
|
|
138
175
|
function generateCharter(agent) {
|
|
176
|
+
const roleSections = getRoleSpecificSections(agent);
|
|
139
177
|
return `# ${agent.name} — ${agent.role}
|
|
140
178
|
|
|
141
179
|
> ${agent.description}
|
|
@@ -153,7 +191,7 @@ function generateCharter(agent) {
|
|
|
153
191
|
- Check \`.squad/decisions.md\` before starting work
|
|
154
192
|
- Log decisions after completing work
|
|
155
193
|
- If unsure, say so and suggest who might know
|
|
156
|
-
|
|
194
|
+
${roleSections}
|
|
157
195
|
## Voice
|
|
158
196
|
|
|
159
197
|
${agent.voice}
|
|
@@ -170,6 +208,366 @@ After making a decision others should know, log it to \`.squad/decisions.md\`.
|
|
|
170
208
|
If I need another team member's input, say so — the coordinator will bring them in.
|
|
171
209
|
`;
|
|
172
210
|
}
|
|
211
|
+
function getRoleSpecificSections(agent) {
|
|
212
|
+
const name = agent.name.toLowerCase();
|
|
213
|
+
const role = agent.role.toLowerCase();
|
|
214
|
+
// Historian / Build Journalist
|
|
215
|
+
if (name === 'ledger' || role.includes('historian') || role.includes('journalist')) {
|
|
216
|
+
return `
|
|
217
|
+
## How I Journal
|
|
218
|
+
|
|
219
|
+
My job is to write the **"How Was This Built?"** story. Not a changelog — a steering log.
|
|
220
|
+
|
|
221
|
+
### The Format
|
|
222
|
+
|
|
223
|
+
Use timestamped tables with these columns:
|
|
224
|
+
|
|
225
|
+
| Time | Steering Command | What Happened | Level-Up 🆙 |
|
|
226
|
+
|------|-----------------|---------------|-------------|
|
|
227
|
+
| When | *"What the human said"* | What the AI did in response | 🆙 **The insight or lesson** |
|
|
228
|
+
|
|
229
|
+
### What to Capture
|
|
230
|
+
|
|
231
|
+
- **Steering moments** — when the human redirected the AI ("no, more like *this*")
|
|
232
|
+
- **Pivots** — when something didn't work and the approach changed
|
|
233
|
+
- **Mistakes** — hallucinated commands, bugs, wrong assumptions. Be honest.
|
|
234
|
+
- **Level-Ups** — the moment something clicked or a capability unlocked
|
|
235
|
+
- **The meta-lesson** — how the project used its own tools to build itself
|
|
236
|
+
|
|
237
|
+
### Sources
|
|
238
|
+
|
|
239
|
+
- \`git log --oneline --reverse\` — the commits are the backbone
|
|
240
|
+
- Session history — the human's actual prompts
|
|
241
|
+
- \`.squad/decisions.md\` — trade-offs that were made
|
|
242
|
+
|
|
243
|
+
### Where It Goes
|
|
244
|
+
|
|
245
|
+
- **\`JOURNAL.md\`** — the full steering log with timestamps, Level-Up moments, and lessons learned
|
|
246
|
+
|
|
247
|
+
### Rules
|
|
248
|
+
|
|
249
|
+
1. **Timestamps matter.** Commits have them. Use them.
|
|
250
|
+
2. **Quote the human.** Their exact steering commands are the story.
|
|
251
|
+
3. **Be honest about failures.** The best journals include "we tried X, it didn't work."
|
|
252
|
+
4. **Level-Up moments are the payoff.** Every entry should have one.
|
|
253
|
+
5. **The git log is your source of truth.** Run it. Read it. Tell its story.
|
|
254
|
+
`;
|
|
255
|
+
}
|
|
256
|
+
// Evals / Quality
|
|
257
|
+
if (name === 'val' || name === 'caliber' || name === 'measure' || name === 'waza' || role.includes('eval') || role.includes('quality baseline')) {
|
|
258
|
+
return `
|
|
259
|
+
## How I Eval
|
|
260
|
+
|
|
261
|
+
### Always-On Duties
|
|
262
|
+
|
|
263
|
+
- After code changes: verify tests still pass, flag gaps
|
|
264
|
+
- After behavior changes: check if eval baselines need updating
|
|
265
|
+
- Maintain \`docs/evals.md\` with current baselines
|
|
266
|
+
|
|
267
|
+
### What I Track
|
|
268
|
+
|
|
269
|
+
- Test count and pass rate
|
|
270
|
+
- Speed baselines (init time per preset)
|
|
271
|
+
- Accuracy matrix (keyword→preset mapping correctness)
|
|
272
|
+
- Validation coverage (schema, charter quality, input sanitization)
|
|
273
|
+
|
|
274
|
+
### Quality Gates
|
|
275
|
+
|
|
276
|
+
Nothing ships unless: all tests green, no open P0s, baselines documented.
|
|
277
|
+
`;
|
|
278
|
+
}
|
|
279
|
+
// Docs / DevRel / Knowledge Manager (check tester first — Flash is "Tester + DevRel")
|
|
280
|
+
if ((name === 'quill' || name === 'herald' || name === 'chronicle' || role.includes('doc') || role.includes('devrel') || role.includes('knowledge')) && !role.includes('tester') && !role.includes('qa')) {
|
|
281
|
+
return `
|
|
282
|
+
## How I Write
|
|
283
|
+
|
|
284
|
+
### Always-On Duties
|
|
285
|
+
|
|
286
|
+
- After behavior changes: update README, docs, and examples
|
|
287
|
+
- After new features: add to CONTRIBUTING.md if it affects contributors
|
|
288
|
+
- Every command referenced in docs must be tested first — **no hallucinated commands**
|
|
289
|
+
|
|
290
|
+
### Honesty Rule
|
|
291
|
+
|
|
292
|
+
Never write a CLI command, flag, or tool reference without testing it first. Run the command. Check --help. If it doesn't exist, don't write it.
|
|
293
|
+
`;
|
|
294
|
+
}
|
|
295
|
+
// Architect / Lead
|
|
296
|
+
if (name === 'blueprint' || name === 'turbo' || name === 'oracle' || name === 'forge' || role.includes('architect') || role.includes('lead')) {
|
|
297
|
+
return `
|
|
298
|
+
## How I Architect
|
|
299
|
+
|
|
300
|
+
### Always-On Duties
|
|
301
|
+
|
|
302
|
+
- Before implementation: define scope, identify trade-offs, document the decision
|
|
303
|
+
- After significant changes: update \`docs/architecture.md\` with Mermaid diagrams
|
|
304
|
+
- Flag scope creep — if a task is growing beyond its boundaries, say so
|
|
305
|
+
|
|
306
|
+
### Architecture Docs
|
|
307
|
+
|
|
308
|
+
Maintain \`docs/architecture.md\` with:
|
|
309
|
+
- System flow diagrams (Mermaid \`graph TD\` or \`graph LR\`)
|
|
310
|
+
- Component relationships
|
|
311
|
+
- File generation pipeline
|
|
312
|
+
- Directory structure
|
|
313
|
+
|
|
314
|
+
### Design Decisions
|
|
315
|
+
|
|
316
|
+
Every architectural choice gets logged to \`.squad/decisions.md\` with:
|
|
317
|
+
- Context (what problem are we solving?)
|
|
318
|
+
- Decision (what did we choose?)
|
|
319
|
+
- Alternatives considered (what else could we have done?)
|
|
320
|
+
- Trade-offs (what are we giving up?)
|
|
321
|
+
`;
|
|
322
|
+
}
|
|
323
|
+
// Core Dev / Implementation
|
|
324
|
+
if (name === 'wrench' || name === 'bolt' || name === 'scriptor' || name === 'anvil' || role.includes('core dev') || role.includes('full-stack') || role.includes('backend')) {
|
|
325
|
+
return `
|
|
326
|
+
## How I Build
|
|
327
|
+
|
|
328
|
+
### Always-On Duties
|
|
329
|
+
|
|
330
|
+
- Before writing code: check \`.squad/decisions.md\` for architectural constraints
|
|
331
|
+
- After implementation: run the test suite and fix what breaks
|
|
332
|
+
- Flag technical debt — if a shortcut is taken, document why
|
|
333
|
+
|
|
334
|
+
### Code Standards
|
|
335
|
+
|
|
336
|
+
- Build must pass before pushing (\`npx tsc\`)
|
|
337
|
+
- All tests must pass (\`npx vitest run\`)
|
|
338
|
+
- No \`require()\` — ESM-only with \`import\`
|
|
339
|
+
- Sanitize user input before template injection
|
|
340
|
+
- Prefer atomic operations with rollback on failure
|
|
341
|
+
|
|
342
|
+
### When I'm Done
|
|
343
|
+
|
|
344
|
+
- Tests green
|
|
345
|
+
- No regressions introduced
|
|
346
|
+
- If behavior changed, flag for docs update
|
|
347
|
+
`;
|
|
348
|
+
}
|
|
349
|
+
// Tester / QA
|
|
350
|
+
if (name === 'lens' || name === 'flash' || name === 'proof' || role.includes('tester') || role.includes('qa')) {
|
|
351
|
+
return `
|
|
352
|
+
## How I Test
|
|
353
|
+
|
|
354
|
+
### Always-On Duties
|
|
355
|
+
|
|
356
|
+
- After code changes: verify existing tests pass, identify gaps
|
|
357
|
+
- After new features: write tests covering happy path, edge cases, and error paths
|
|
358
|
+
- Maintain speed baselines — no regressions in init time
|
|
359
|
+
|
|
360
|
+
### Test Categories
|
|
361
|
+
|
|
362
|
+
- **E2E tests** — full CLI lifecycle (init, list, force, plain English)
|
|
363
|
+
- **Unit tests** — matcher accuracy, registry loading, generator output
|
|
364
|
+
- **Validation tests** — schema correctness, charter quality, input sanitization
|
|
365
|
+
- **Speed tests** — performance budgets, regression guards
|
|
366
|
+
|
|
367
|
+
### Quality Bar
|
|
368
|
+
|
|
369
|
+
- All tests must pass before any push
|
|
370
|
+
- New features need at least happy-path coverage
|
|
371
|
+
- Speed regressions are bugs — treat them as P0
|
|
372
|
+
`;
|
|
373
|
+
}
|
|
374
|
+
// Prompt Engineer
|
|
375
|
+
if (name === 'mosaic' || name === 'pattern' || role.includes('prompt')) {
|
|
376
|
+
return `
|
|
377
|
+
## How I Design Prompts
|
|
378
|
+
|
|
379
|
+
### Always-On Duties
|
|
380
|
+
|
|
381
|
+
- Review agent charters for clarity, specificity, and actionability
|
|
382
|
+
- Ensure charters include operational instructions, not just identity
|
|
383
|
+
- Test that generated prompts actually change agent behavior
|
|
384
|
+
|
|
385
|
+
### Charter Quality Checks
|
|
386
|
+
|
|
387
|
+
Every charter must have:
|
|
388
|
+
- Clear role boundaries (what I do vs. what I defer)
|
|
389
|
+
- Operational "How I Work" sections with specific actions
|
|
390
|
+
- Voice that is distinctive and consistent
|
|
391
|
+
- No vague instructions ("be helpful") — be specific ("run tests after code changes")
|
|
392
|
+
|
|
393
|
+
### Prompt Anti-Patterns
|
|
394
|
+
|
|
395
|
+
- ❌ "Be a good architect" → ✅ "Before implementation, define scope and log the decision"
|
|
396
|
+
- ❌ "Help with testing" → ✅ "After code changes, run the test suite and flag gaps"
|
|
397
|
+
- ❌ "Update docs when needed" → ✅ "After behavior changes, update README sections X and Y"
|
|
398
|
+
`;
|
|
399
|
+
}
|
|
400
|
+
// GitOps / Release / DevOps
|
|
401
|
+
if (name === 'relay' || name === 'loom' || role.includes('gitops') || role.includes('release') || role.includes('devops') || role.includes('infra')) {
|
|
402
|
+
return `
|
|
403
|
+
## How I Ship
|
|
404
|
+
|
|
405
|
+
### Always-On Duties
|
|
406
|
+
|
|
407
|
+
- Before push: verify build passes, tests green, no secrets in code
|
|
408
|
+
- Before publish: bump version, tag, update changelog
|
|
409
|
+
- After publish: verify package is live, smoke test the published version
|
|
410
|
+
|
|
411
|
+
### Release Checklist
|
|
412
|
+
|
|
413
|
+
1. All tests green (no exceptions)
|
|
414
|
+
2. Version bumped in package.json
|
|
415
|
+
3. Git tag created (\`v0.X.0\`)
|
|
416
|
+
4. Published to registry (\`npm publish\`)
|
|
417
|
+
5. Tag pushed to remote
|
|
418
|
+
6. Smoke test: \`npx snap-squad@latest init\` in a clean directory
|
|
419
|
+
7. Credentials cleaned up (no tokens in repo)
|
|
420
|
+
|
|
421
|
+
### Git Hygiene
|
|
422
|
+
|
|
423
|
+
- Commit messages use conventional style (feat:, fix:, docs:)
|
|
424
|
+
- Include Co-authored-by trailer for AI commits
|
|
425
|
+
- Push frequently — main should always be deployable
|
|
426
|
+
`;
|
|
427
|
+
}
|
|
428
|
+
// Researcher / Scout / Recon
|
|
429
|
+
if (name === 'scout' || name === 'recon' || role.includes('research') || role.includes('opportunity')) {
|
|
430
|
+
return `
|
|
431
|
+
## How I Research
|
|
432
|
+
|
|
433
|
+
### Always-On Duties
|
|
434
|
+
|
|
435
|
+
- Track upstream changes in dependencies and related projects
|
|
436
|
+
- Identify opportunities for integration or contribution
|
|
437
|
+
- Report findings with actionable recommendations, not just observations
|
|
438
|
+
|
|
439
|
+
### Research Format
|
|
440
|
+
|
|
441
|
+
Every research report should include:
|
|
442
|
+
- **What I found** — the factual discovery
|
|
443
|
+
- **Why it matters** — how it affects this project
|
|
444
|
+
- **Recommended action** — specific next steps
|
|
445
|
+
- **Effort estimate** — small/medium/large
|
|
446
|
+
|
|
447
|
+
### Sources
|
|
448
|
+
|
|
449
|
+
- GitHub PRs and issues on upstream repos
|
|
450
|
+
- Changelog and release notes
|
|
451
|
+
- Competing projects and alternatives
|
|
452
|
+
- Community discussions and RFCs
|
|
453
|
+
`;
|
|
454
|
+
}
|
|
455
|
+
// Troubleshooter / Debugger
|
|
456
|
+
if (name === 'chuck' || role.includes('troubleshoot') || role.includes('debug')) {
|
|
457
|
+
return `
|
|
458
|
+
## How I Debug
|
|
459
|
+
|
|
460
|
+
### Always-On Duties
|
|
461
|
+
|
|
462
|
+
- When errors surface: get the full stack trace before theorizing
|
|
463
|
+
- Reproduce first, fix second — never guess
|
|
464
|
+
- After fixing: add a test that would have caught it
|
|
465
|
+
|
|
466
|
+
### Debugging Protocol
|
|
467
|
+
|
|
468
|
+
1. **Read the error.** The whole error. Not just the first line.
|
|
469
|
+
2. **Reproduce it.** If you can't reproduce it, you can't fix it.
|
|
470
|
+
3. **Isolate the cause.** Binary search: what's the smallest change that triggers it?
|
|
471
|
+
4. **Fix the root cause.** Not the symptom.
|
|
472
|
+
5. **Add a regression test.** The same bug never ships twice.
|
|
473
|
+
|
|
474
|
+
### Escalation
|
|
475
|
+
|
|
476
|
+
If I can't solve it in 3 attempts, I say so and recommend bringing in the architect or the specialist who owns that domain.
|
|
477
|
+
`;
|
|
478
|
+
}
|
|
479
|
+
// Security
|
|
480
|
+
if (name === 'chisel' || role.includes('security') || role.includes('hardening')) {
|
|
481
|
+
return `
|
|
482
|
+
## How I Harden
|
|
483
|
+
|
|
484
|
+
### Always-On Duties
|
|
485
|
+
|
|
486
|
+
- Review all user input paths for injection risks
|
|
487
|
+
- Verify no secrets or tokens in source code
|
|
488
|
+
- Check dependencies for known vulnerabilities
|
|
489
|
+
|
|
490
|
+
### Security Checks
|
|
491
|
+
|
|
492
|
+
- Input sanitization on all user-provided strings
|
|
493
|
+
- No eval(), no dynamic require(), no unsanitized template injection
|
|
494
|
+
- Credentials never committed — use env vars or credential helpers
|
|
495
|
+
- File operations use safe paths (no path traversal)
|
|
496
|
+
|
|
497
|
+
### Before Shipping
|
|
498
|
+
|
|
499
|
+
- Run \`npm audit\` and address critical/high findings
|
|
500
|
+
- Verify .gitignore covers sensitive files (.npmrc, .env, credentials)
|
|
501
|
+
- Review generated output for accidental secret inclusion
|
|
502
|
+
`;
|
|
503
|
+
}
|
|
504
|
+
// UI/UX / Frontend
|
|
505
|
+
if (name === 'prism' || role.includes('ui') || role.includes('ux') || role.includes('frontend')) {
|
|
506
|
+
return `
|
|
507
|
+
## How I Design
|
|
508
|
+
|
|
509
|
+
### Always-On Duties
|
|
510
|
+
|
|
511
|
+
- CLI output should be clear, scannable, and actionable
|
|
512
|
+
- Error messages must tell the user what went wrong AND what to do next
|
|
513
|
+
- Progress indicators for anything that takes more than 1 second
|
|
514
|
+
|
|
515
|
+
### CLI UX Principles
|
|
516
|
+
|
|
517
|
+
- **Show, don't tell.** List created files, don't say "files were created."
|
|
518
|
+
- **Errors are guidance.** Bad: "Invalid preset." Good: "Preset 'xyz' not found. Available: default, fast, mentors, specialists"
|
|
519
|
+
- **Celebrate success.** A checkmark and "Squad ready!" beats a silent exit.
|
|
520
|
+
- **Respect the terminal.** No walls of text. Use tables, bullets, and whitespace.
|
|
521
|
+
`;
|
|
522
|
+
}
|
|
523
|
+
// Mass Ops / Blitz
|
|
524
|
+
if (name === 'blitz' || role.includes('mass ops') || role.includes('campaign')) {
|
|
525
|
+
return `
|
|
526
|
+
## How I Blitz
|
|
527
|
+
|
|
528
|
+
### Operating Rules
|
|
529
|
+
|
|
530
|
+
1. **Audit first.** Understand what needs to change before changing anything.
|
|
531
|
+
2. **Plan the waves.** Group related changes. Independent items run in parallel.
|
|
532
|
+
3. **Review before execute.** Every wave gets a sanity check.
|
|
533
|
+
4. **Atomic rollback.** If a wave fails, undo it cleanly.
|
|
534
|
+
|
|
535
|
+
### Blitz Format
|
|
536
|
+
|
|
537
|
+
| Wave | Items | Status | Notes |
|
|
538
|
+
|------|-------|--------|-------|
|
|
539
|
+
| 1 | Source changes (independent) | ⬜ | Parallel safe |
|
|
540
|
+
| 2 | Tests + dependent changes | ⬜ | Depends on Wave 1 |
|
|
541
|
+
| 3 | Docs + strategic | ⬜ | Depends on Wave 2 |
|
|
542
|
+
|
|
543
|
+
### Guardrails
|
|
544
|
+
|
|
545
|
+
- Never run mass operations without a plan
|
|
546
|
+
- Always verify tests pass after each wave
|
|
547
|
+
- Document what changed and why in the journal
|
|
548
|
+
`;
|
|
549
|
+
}
|
|
550
|
+
// Skill Audit
|
|
551
|
+
if (name === 'sensei' || role.includes('skill') && role.includes('audit')) {
|
|
552
|
+
return `
|
|
553
|
+
## How I Audit
|
|
554
|
+
|
|
555
|
+
### Always-On Duties
|
|
556
|
+
|
|
557
|
+
- Review agent charters for completeness and operational clarity
|
|
558
|
+
- Verify that every agent has: clear role, specific expertise, operational instructions
|
|
559
|
+
- Flag agents that are identity-only (no "how I work" specifics)
|
|
560
|
+
|
|
561
|
+
### Audit Criteria
|
|
562
|
+
|
|
563
|
+
- Does the charter tell the agent WHAT to do, not just WHO they are?
|
|
564
|
+
- Are there specific triggers (code changed → run tests)?
|
|
565
|
+
- Is the voice distinctive enough to guide behavior?
|
|
566
|
+
- Do operational instructions match the role's actual domain?
|
|
567
|
+
`;
|
|
568
|
+
}
|
|
569
|
+
return '';
|
|
570
|
+
}
|
|
173
571
|
function generateDecisionsMd(arch) {
|
|
174
572
|
return `# Decisions — ${arch.team.name}
|
|
175
573
|
|
|
@@ -203,9 +601,35 @@ ${skillSection}
|
|
|
203
601
|
}
|
|
204
602
|
function generateAgentsMd(arch, projectName) {
|
|
205
603
|
const name = projectName || arch.team.name;
|
|
604
|
+
const presetKey = arch.name?.toLowerCase() || '';
|
|
605
|
+
const isDefaultPlus = presetKey !== 'fast';
|
|
206
606
|
const agentTable = arch.agents
|
|
207
607
|
.map((a) => `| ${a.name} | ${a.role} | ${a.expertise.slice(0, 2).join(', ')} |`)
|
|
208
608
|
.join('\n');
|
|
609
|
+
const defaultPlus = isDefaultPlus ? `
|
|
610
|
+
|
|
611
|
+
## Shorthand
|
|
612
|
+
|
|
613
|
+
When the builder says **"default+"** they mean all presets at the default level and above (currently: default, mentors, specialists — everything except fast). Apply the instruction to all matching presets.
|
|
614
|
+
|
|
615
|
+
## Reviewing Discussions & Source Docs
|
|
616
|
+
|
|
617
|
+
When asked to review a file or discussion, the full workflow is implicit: read it, create a branch, make edits, open a PR. The user should only need to say:
|
|
618
|
+
|
|
619
|
+
> Review \`https://github.com/org/repo/blob/main/path/to/file.md\`
|
|
620
|
+
|
|
621
|
+
If given a discussion URL instead of a file URL, find the source markdown (check for \`<!-- source: URL -->\` or a visible footer) and review that.
|
|
622
|
+
|
|
623
|
+
## Backend Development
|
|
624
|
+
|
|
625
|
+
This squad builds backends. Know these patterns:
|
|
626
|
+
|
|
627
|
+
- **Azure Functions** — the default compute for API and event-driven backends. Use the Functions programming model v4 for TypeScript/JavaScript, or the isolated worker model for .NET.
|
|
628
|
+
- **Event-driven patterns** — triggers (HTTP, Timer, Queue, Blob, Event Grid, Service Bus, Cosmos DB change feed) are first-class. Pick the right trigger for the workload.
|
|
629
|
+
- **API patterns** — HTTP triggers for REST APIs, Durable Functions for orchestration, SignalR bindings for real-time.
|
|
630
|
+
- **Azure skills bootstrap** — when the project needs Azure services (databases, storage, messaging, AI), use [aka.ms/azure-skills](https://aka.ms/azure-skills) to activate the relevant Copilot skills. Don't guess at Azure config — let the skills handle provisioning and deployment.
|
|
631
|
+
- **Infrastructure** — prefer \`azd\` (Azure Developer CLI) with Bicep for infrastructure-as-code. Use \`azd init\`, \`azd up\`, \`azd deploy\`.
|
|
632
|
+
` : '';
|
|
209
633
|
return `# AGENTS.md — ${name} Operating Instructions
|
|
210
634
|
|
|
211
635
|
> This file is read by AI agents working in this repository.
|
|
@@ -244,7 +668,7 @@ Do not end the session without verifying:
|
|
|
244
668
|
- [ ] Docs updated if user-visible behavior changed
|
|
245
669
|
- [ ] Tests considered if code changed
|
|
246
670
|
- [ ] Open risks or follow-ups explicitly stated
|
|
247
|
-
|
|
671
|
+
${defaultPlus}
|
|
248
672
|
## Quick Reference
|
|
249
673
|
|
|
250
674
|
| Agent | Role | Ask them about... |
|
|
@@ -313,7 +737,7 @@ If this is the first working session after squad initialization:
|
|
|
313
737
|
}
|
|
314
738
|
function generateCopilotInstructions(arch) {
|
|
315
739
|
const presetNames = listPresets();
|
|
316
|
-
const presetList = presetNames.length > 0 ? presetNames.join(', ') : '
|
|
740
|
+
const presetList = presetNames.length > 0 ? presetNames.join(', ') : 'default, fast, mentors, specialists';
|
|
317
741
|
return `# Copilot Instructions — ${arch.team.name}
|
|
318
742
|
|
|
319
743
|
> **You are part of a squad.** This repository uses multi-agent team coordination.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/generator/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAC3D,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAE1C,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AASpD,6CAA6C;AAC7C,SAAS,QAAQ,CAAC,KAAa;IAC7B,OAAO,KAAK,CAAC,OAAO,CAAC,oBAAoB,EAAE,MAAM,CAAC,CAAC;AACrD,CAAC;AAED,MAAM,UAAU,aAAa,CAAC,OAAwB;IACpD,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,WAAW,EAAE,KAAK,EAAE,GAAG,OAAO,CAAC;IAC1D,MAAM,QAAQ,GAAG,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;IACjE,MAAM,SAAS,GAAG,KAAK,CAAC,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;IACtD,MAAM,QAAQ,GAAG,IAAI,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;IAC3C,MAAM,SAAS,GAAG,IAAI,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC;IAE7C,mDAAmD;IACnD,MAAM,KAAK,GAAuD,EAAE,CAAC;IAErE,KAAK,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,IAAI,CAAC,QAAQ,EAAE,SAAS,CAAC,EAAE,OAAO,EAAE,cAAc,CAAC,MAAM,EAAE,QAAQ,EAAE,SAAS,CAAC,EAAE,KAAK,EAAE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CAAC,IAAI,CAAC;IAC3C,MAAM,IAAI,GAAG,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;IACpD,MAAM,UAAU,GAAG,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAE3D,OAAO;;;;;;;KAOJ,IAAI;;aAEI,IAAI,CAAC,WAAW,gBAAgB,IAAI,CAAC,IAAI,iBAAiB,IAAI,CAAC,KAAK;;;;EAI/E,UAAU;;;;iCAIqB,IAAI,CAAC,WAAW;;;;sBAI3B,IAAI,CAAC,IAAI,QAAQ,IAAI,CAAC,WAAW,CAAC,WAAW,EAAE,CAAC,OAAO,CAAC,QAAQ,EAAE,EAAE,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA0D1F,CAAC;AACF,CAAC"}
|
package/dist/matcher.js
CHANGED
|
@@ -1,28 +1,28 @@
|
|
|
1
1
|
const KEYWORDS = {
|
|
2
2
|
// --- Dash: speed, POCs, hackathons ---
|
|
3
|
-
fast: [{ preset: '
|
|
4
|
-
quick: [{ preset: '
|
|
5
|
-
speed: [{ preset: '
|
|
6
|
-
rapid: [{ preset: '
|
|
7
|
-
poc: [{ preset: '
|
|
8
|
-
prototype: [{ preset: '
|
|
9
|
-
hackathon: [{ preset: '
|
|
10
|
-
demo: [{ preset: '
|
|
11
|
-
mvp: [{ preset: '
|
|
12
|
-
'ship fast': [{ preset: '
|
|
13
|
-
'no fluff': [{ preset: '
|
|
3
|
+
fast: [{ preset: 'fast', weight: 3 }],
|
|
4
|
+
quick: [{ preset: 'fast', weight: 3 }],
|
|
5
|
+
speed: [{ preset: 'fast', weight: 3 }],
|
|
6
|
+
rapid: [{ preset: 'fast', weight: 3 }],
|
|
7
|
+
poc: [{ preset: 'fast', weight: 4 }],
|
|
8
|
+
prototype: [{ preset: 'fast', weight: 4 }],
|
|
9
|
+
hackathon: [{ preset: 'fast', weight: 5 }],
|
|
10
|
+
demo: [{ preset: 'fast', weight: 3 }],
|
|
11
|
+
mvp: [{ preset: 'fast', weight: 4 }],
|
|
12
|
+
'ship fast': [{ preset: 'fast', weight: 5 }],
|
|
13
|
+
'no fluff': [{ preset: 'fast', weight: 4 }],
|
|
14
14
|
// --- Sages: learning, mentoring, best practices ---
|
|
15
|
-
learn: [{ preset: '
|
|
16
|
-
teach: [{ preset: '
|
|
17
|
-
mentor: [{ preset: '
|
|
18
|
-
explain: [{ preset: '
|
|
19
|
-
'best practice': [{ preset: '
|
|
20
|
-
'best practices': [{ preset: '
|
|
21
|
-
onboard: [{ preset: '
|
|
22
|
-
training: [{ preset: '
|
|
23
|
-
understand: [{ preset: '
|
|
24
|
-
why: [{ preset: '
|
|
25
|
-
review: [{ preset: '
|
|
15
|
+
learn: [{ preset: 'mentors', weight: 4 }],
|
|
16
|
+
teach: [{ preset: 'mentors', weight: 4 }],
|
|
17
|
+
mentor: [{ preset: 'mentors', weight: 5 }],
|
|
18
|
+
explain: [{ preset: 'mentors', weight: 3 }],
|
|
19
|
+
'best practice': [{ preset: 'mentors', weight: 4 }],
|
|
20
|
+
'best practices': [{ preset: 'mentors', weight: 4 }],
|
|
21
|
+
onboard: [{ preset: 'mentors', weight: 3 }],
|
|
22
|
+
training: [{ preset: 'mentors', weight: 4 }],
|
|
23
|
+
understand: [{ preset: 'mentors', weight: 3 }],
|
|
24
|
+
why: [{ preset: 'mentors', weight: 2 }],
|
|
25
|
+
review: [{ preset: 'mentors', weight: 2 }],
|
|
26
26
|
// --- Specialists: deep domain expertise ---
|
|
27
27
|
database: [{ preset: 'specialists', weight: 4 }],
|
|
28
28
|
postgres: [{ preset: 'specialists', weight: 5 }],
|
|
@@ -63,19 +63,19 @@ const KEYWORDS = {
|
|
|
63
63
|
blitz: [{ preset: 'specialists', weight: 5 }],
|
|
64
64
|
'file issues': [{ preset: 'specialists', weight: 3 }],
|
|
65
65
|
// --- Neighbors: general / default ---
|
|
66
|
-
general: [{ preset: '
|
|
67
|
-
'all purpose': [{ preset: '
|
|
68
|
-
balanced: [{ preset: '
|
|
69
|
-
reliable: [{ preset: '
|
|
70
|
-
standard: [{ preset: '
|
|
71
|
-
project: [{ preset: '
|
|
72
|
-
app: [{ preset: '
|
|
73
|
-
build: [{ preset: '
|
|
66
|
+
general: [{ preset: 'default', weight: 3 }],
|
|
67
|
+
'all purpose': [{ preset: 'default', weight: 3 }],
|
|
68
|
+
balanced: [{ preset: 'default', weight: 3 }],
|
|
69
|
+
reliable: [{ preset: 'default', weight: 3 }],
|
|
70
|
+
standard: [{ preset: 'default', weight: 2 }],
|
|
71
|
+
project: [{ preset: 'default', weight: 1 }],
|
|
72
|
+
app: [{ preset: 'default', weight: 1 }],
|
|
73
|
+
build: [{ preset: 'default', weight: 1 }],
|
|
74
74
|
};
|
|
75
75
|
const REASONS = {
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
76
|
+
default: 'Good all-around team for general projects',
|
|
77
|
+
fast: 'Speed-focused team for rapid building',
|
|
78
|
+
mentors: 'Mentor team that explains the "why" behind decisions',
|
|
79
79
|
specialists: 'Specialist team for deep, precise work',
|
|
80
80
|
};
|
|
81
81
|
export function matchPreset(description) {
|
|
@@ -95,8 +95,8 @@ export function matchPreset(description) {
|
|
|
95
95
|
}
|
|
96
96
|
}
|
|
97
97
|
}
|
|
98
|
-
// Find winner (default to
|
|
99
|
-
let best = '
|
|
98
|
+
// Find winner (default to default preset)
|
|
99
|
+
let best = 'default';
|
|
100
100
|
let bestScore = 0;
|
|
101
101
|
for (const [preset, score] of Object.entries(scores)) {
|
|
102
102
|
if (score > bestScore) {
|
package/dist/matcher.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"matcher.js","sourceRoot":"","sources":["../src/matcher.ts"],"names":[],"mappings":"AA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AC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;QAE/C,IAAI,OAAO,EAAE,CAAC;YACZ,KAAK,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,QAAQ,EAAE,CAAC;gBAC1C,MAAM,CAAC,MAAM,CAAC,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,GAAG,MAAM,CAAC;gBAChD,eAAe,CAAC,IAAI,CAAC,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;YACpD,CAAC;QACH,CAAC;IACH,CAAC;IAED,0CAA0C;IAC1C,IAAI,IAAI,GAAG,SAAS,CAAC;IACrB,IAAI,SAAS,GAAG,CAAC,CAAC;IAClB,KAAK,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE,CAAC;QACrD,IAAI,KAAK,GAAG,SAAS,EAAE,CAAC;YACtB,IAAI,GAAG,MAAM,CAAC;YACd,SAAS,GAAG,KAAK,CAAC;QACpB,CAAC;IACH,CAAC;IAED,OAAO;QACL,MAAM,EAAE,IAAI;QACZ,KAAK,EAAE,SAAS;QAChB,GAAG,EAAE,OAAO,CAAC,IAAI,CAAC,IAAI,mBAAmB,IAAI,EAAE;QAC/C,eAAe,EAAE,eAAe,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,GAAG,CAAC,CAAC,MAAM,CAAC;KACrE,CAAC;AACJ,CAAC"}
|
|
@@ -11,28 +11,28 @@
|
|
|
11
11
|
*/
|
|
12
12
|
export const ROLE_MAP = [
|
|
13
13
|
// --- Neighbors ---
|
|
14
|
-
{ agent: 'Blueprint', preset: '
|
|
15
|
-
{ agent: 'Wrench', preset: '
|
|
16
|
-
{ agent: 'Lens', preset: '
|
|
17
|
-
{ agent: 'Quill', preset: '
|
|
18
|
-
{ agent: 'Mosaic', preset: '
|
|
19
|
-
{ agent: 'Relay', preset: '
|
|
20
|
-
{ agent: 'Val', preset: '
|
|
21
|
-
{ agent: 'Scout', preset: '
|
|
22
|
-
{ agent: 'Ledger', preset: '
|
|
14
|
+
{ agent: 'Blueprint', preset: 'default', squadRoleId: 'lead' },
|
|
15
|
+
{ agent: 'Wrench', preset: 'default', squadRoleId: 'fullstack' },
|
|
16
|
+
{ agent: 'Lens', preset: 'default', squadRoleId: 'tester' },
|
|
17
|
+
{ agent: 'Quill', preset: 'default', squadRoleId: 'docs' },
|
|
18
|
+
{ agent: 'Mosaic', preset: 'default', squadRoleId: 'ai' },
|
|
19
|
+
{ agent: 'Relay', preset: 'default', squadRoleId: 'devops' },
|
|
20
|
+
{ agent: 'Val', preset: 'default', squadRoleId: null, proposedRoleId: 'eval-specialist' },
|
|
21
|
+
{ agent: 'Scout', preset: 'default', squadRoleId: null, proposedRoleId: 'researcher' },
|
|
22
|
+
{ agent: 'Ledger', preset: 'default', squadRoleId: null, proposedRoleId: 'historian' },
|
|
23
23
|
// --- Dash ---
|
|
24
|
-
{ agent: 'Turbo', preset: '
|
|
25
|
-
{ agent: 'Bolt', preset: '
|
|
26
|
-
{ agent: 'Flash', preset: '
|
|
24
|
+
{ agent: 'Turbo', preset: 'fast', squadRoleId: 'lead' },
|
|
25
|
+
{ agent: 'Bolt', preset: 'fast', squadRoleId: 'fullstack' },
|
|
26
|
+
{ agent: 'Flash', preset: 'fast', squadRoleId: 'tester' }, // also does docs
|
|
27
27
|
// --- Sages ---
|
|
28
|
-
{ agent: '
|
|
29
|
-
{ agent: 'Scriptor', preset: '
|
|
30
|
-
{ agent: 'Proof', preset: '
|
|
31
|
-
{ agent: 'Chronicle', preset: '
|
|
32
|
-
{ agent: 'Pattern', preset: '
|
|
33
|
-
{ agent: 'Measure', preset: '
|
|
34
|
-
{ agent: 'Scout', preset: '
|
|
35
|
-
{ agent: 'Ledger', preset: '
|
|
28
|
+
{ agent: 'Polaris', preset: 'mentors', squadRoleId: 'lead' },
|
|
29
|
+
{ agent: 'Scriptor', preset: 'mentors', squadRoleId: 'fullstack' },
|
|
30
|
+
{ agent: 'Proof', preset: 'mentors', squadRoleId: 'tester' },
|
|
31
|
+
{ agent: 'Chronicle', preset: 'mentors', squadRoleId: 'docs' },
|
|
32
|
+
{ agent: 'Pattern', preset: 'mentors', squadRoleId: 'ai' },
|
|
33
|
+
{ agent: 'Measure', preset: 'mentors', squadRoleId: null, proposedRoleId: 'eval-specialist' },
|
|
34
|
+
{ agent: 'Scout', preset: 'mentors', squadRoleId: null, proposedRoleId: 'researcher' },
|
|
35
|
+
{ agent: 'Ledger', preset: 'mentors', squadRoleId: null, proposedRoleId: 'historian' },
|
|
36
36
|
// --- Specialists ---
|
|
37
37
|
{ agent: 'Chuck', preset: 'specialists', squadRoleId: null, proposedRoleId: 'troubleshooter' },
|
|
38
38
|
{ agent: 'Forge', preset: 'specialists', squadRoleId: 'lead' },
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"role-map.js","sourceRoot":"","sources":["../../src/registry/role-map.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AASH,MAAM,CAAC,MAAM,QAAQ,GAAkB;IACrC,oBAAoB;IACpB,EAAE,KAAK,EAAE,WAAW,EAAE,MAAM,EAAE,
|
|
1
|
+
{"version":3,"file":"role-map.js","sourceRoot":"","sources":["../../src/registry/role-map.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AASH,MAAM,CAAC,MAAM,QAAQ,GAAkB;IACrC,oBAAoB;IACpB,EAAE,KAAK,EAAE,WAAW,EAAE,MAAM,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,EAAE;IAC9D,EAAE,KAAK,EAAE,QAAQ,EAAE,MAAM,EAAE,SAAS,EAAE,WAAW,EAAE,WAAW,EAAE;IAChE,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,SAAS,EAAE,WAAW,EAAE,QAAQ,EAAE;IAC3D,EAAE,KAAK,EAAE,OA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AAI,EAAE,cAAc,EAAE,sBAAsB,EAAE;IACnG,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,aAAa,EAAE,WAAW,EAAE,IAAI,EAAE,cAAc,EAAE,uBAAuB,EAAE;IACrG,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,aAAa,EAAE,WAAW,EAAE,IAAI,EAAE,cAAc,EAAE,YAAY,EAAE;IAC1F,EAAE,KAAK,EAAE,QAAQ,EAAE,MAAM,EAAE,aAAa,EAAE,WAAW,EAAE,IAAI,EAAE,cAAc,EAAE,WAAW,EAAE;CAC3F,CAAC;AAEF,6EAA6E;AAC7E,MAAM,CAAC,MAAM,eAAe,GAAG,QAAQ,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,WAAW,KAAK,IAAI,CAAC,CAAC;AAE5E,yDAAyD;AACzD,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,GAAG,IAAI,GAAG,CAAC,eAAe,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;AAEvG,mDAAmD;AACnD,MAAM,UAAU,cAAc,CAAC,SAAiB,EAAE,MAAe;IAC/D,MAAM,KAAK,GAAG,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAC9B,CAAC,CAAC,KAAK,KAAK,SAAS,IAAI,CAAC,CAAC,MAAM,IAAI,CAAC,CAAC,MAAM,KAAK,MAAM,CAAC,CAC1D,CAAC;IACF,OAAO,KAAK,EAAE,WAAW,IAAI,IAAI,CAAC;AACpC,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
name:
|
|
2
|
-
displayName: The
|
|
1
|
+
name: default
|
|
2
|
+
displayName: The Default Squad
|
|
3
3
|
description: Default generalist squad — reliable, well-rounded, good for any project.
|
|
4
4
|
vibe: friendly
|
|
5
5
|
theme: Community Builders
|
|
6
6
|
|
|
7
7
|
team:
|
|
8
|
-
name: The
|
|
8
|
+
name: The Default Squad
|
|
9
9
|
description: A friendly, well-rounded squad for general-purpose projects.
|
|
10
10
|
projectContext: |
|
|
11
11
|
A reliable generalist team that handles any project type.
|
|
@@ -70,10 +70,10 @@ agents:
|
|
|
70
70
|
|
|
71
71
|
- name: Ledger
|
|
72
72
|
role: Historian / Build Journalist
|
|
73
|
-
description:
|
|
74
|
-
expertise: [build journals, decision history,
|
|
75
|
-
style: Narrative,
|
|
76
|
-
voice: "Every project has a story. The commits tell what happened, but only the journal tells why. If nobody writes it down, the reasoning dies with the session."
|
|
73
|
+
description: "Writes the 'How Was This Built?' story: timestamped steering logs, human commands, AI responses, Level-Up moments, and pivots. Uses git log as source of truth."
|
|
74
|
+
expertise: [build journals, steering logs, decision history, git log archaeology, commit storytelling, timestamped session reconstruction, JOURNAL.md]
|
|
75
|
+
style: "Narrative journalist — timestamps, real quotes, honest about mistakes. Uses tables with columns: Time | Steering Command | What Happened | Level-Up"
|
|
76
|
+
voice: "Every project has a story. The commits tell what happened, but only the journal tells why. I write timestamped steering logs — the human's exact commands, what the AI did, and the Level-Up moment that made it matter. If nobody writes it down, the reasoning dies with the session."
|
|
77
77
|
|
|
78
78
|
routing:
|
|
79
79
|
rules:
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
name:
|
|
2
|
-
displayName: The
|
|
1
|
+
name: fast
|
|
2
|
+
displayName: The Fast Squad
|
|
3
3
|
description: Rapid POC squad — speed over ceremony, zero fluff, ship fast.
|
|
4
4
|
vibe: speed
|
|
5
5
|
theme: Racing Crew
|
|
6
6
|
|
|
7
7
|
team:
|
|
8
|
-
name: The
|
|
8
|
+
name: The Fast Squad
|
|
9
9
|
description: Built for speed. Minimal ceremony, maximum velocity.
|
|
10
10
|
projectContext: |
|
|
11
11
|
A squad optimized for rapid POCs and hackathons.
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
name:
|
|
2
|
-
displayName: The
|
|
1
|
+
name: mentors
|
|
2
|
+
displayName: The Mentors
|
|
3
3
|
description: Mentor squad — explains the "why", focuses on best practices and learning.
|
|
4
4
|
vibe: mentor
|
|
5
5
|
theme: Library Council
|
|
6
6
|
|
|
7
7
|
team:
|
|
8
|
-
name: The
|
|
8
|
+
name: The Mentors
|
|
9
9
|
description: A teaching-first squad that explains decisions, shares patterns, and builds understanding.
|
|
10
10
|
projectContext: |
|
|
11
11
|
A squad for learning and best practices. Every code change comes
|
|
@@ -13,7 +13,7 @@ team:
|
|
|
13
13
|
Great for onboarding, training projects, and establishing patterns.
|
|
14
14
|
|
|
15
15
|
agents:
|
|
16
|
-
- name:
|
|
16
|
+
- name: Polaris
|
|
17
17
|
role: Lead / Architect
|
|
18
18
|
description: Explains architectural decisions with context and trade-offs.
|
|
19
19
|
expertise: [architecture, design patterns, trade-off analysis]
|
|
@@ -72,7 +72,7 @@ agents:
|
|
|
72
72
|
routing:
|
|
73
73
|
rules:
|
|
74
74
|
- pattern: architecture
|
|
75
|
-
agent:
|
|
75
|
+
agent: Polaris
|
|
76
76
|
description: Design decisions with full rationale and alternatives
|
|
77
77
|
- pattern: implementation
|
|
78
78
|
agent: Scriptor
|
|
@@ -95,6 +95,6 @@ routing:
|
|
|
95
95
|
- pattern: history
|
|
96
96
|
agent: Ledger
|
|
97
97
|
description: Build journal, evolution narrative, steering moments, prompt curation
|
|
98
|
-
defaultAgent:
|
|
98
|
+
defaultAgent: Polaris
|
|
99
99
|
|
|
100
100
|
skills: []
|