snap-squad 0.1.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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 paulyuk
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,129 @@
1
+ # Snap Squad
2
+
3
+ **Get started with [Squad](https://github.com/bradygaster/squad) in seconds.**
4
+
5
+ > Skip the interview. Start building.
6
+
7
+ ## What Is Squad?
8
+
9
+ [Squad](https://github.com/bradygaster/squad) gives you AI agent teams for any project — a multi-agent runtime built on GitHub Copilot. You define your team, route work to specialists, and ship faster.
10
+
11
+ The catch? Setting up a new squad takes time. You interview agents, define roles, configure routing. For a big project, that's worth it. For a quick POC or a workflow you've done before? It's friction.
12
+
13
+ ## What Snap Squad Does
14
+
15
+ Snap Squad gives you **ready-to-hire squads trained by builders at CoreAI**. These aren't blank templates — they're squad configurations shaped by real project experience, with tested routing rules, proven agent roles, and practical defaults.
16
+
17
+ ```bash
18
+ npx snap-squad init --type dash
19
+ # → .squad/ created with a speed-focused team
20
+ # → Hook chain (AGENTS.md, CLAUDE.md, copilot-instructions) wired up
21
+ # → Ready for squad up
22
+ ```
23
+
24
+ One command, full squad, zero interview. Built by people who actually ship with Squad.
25
+
26
+ ## Presets
27
+
28
+ | Preset | Vibe | Best For |
29
+ |--------|------|----------|
30
+ | **neighbors** | Generalist | General-purpose projects, reliable building |
31
+ | **dash** | Speed | Rapid POCs, hackathons, zero fluff |
32
+ | **sages** | Mentor | Learning, best practices, architecture review |
33
+ | **artisans** | Precision | Niche specialization, DB tuning, security hardening |
34
+
35
+ ## Quick Start
36
+
37
+ Starting from an empty folder — no installs needed:
38
+
39
+ ```bash
40
+ mkdir my-project && cd my-project
41
+ npx snap-squad init I need a fast team for a hackathon
42
+ ```
43
+
44
+ That's it. One command does everything:
45
+ 1. Downloads snap-squad temporarily (no global install)
46
+ 2. Picks the right squad preset from your description (`dash` for speed)
47
+ 3. Creates the full `.squad/` directory with agents, routing, and decisions
48
+ 4. Writes the hook chain (`AGENTS.md`, `CLAUDE.md`, `.github/copilot-instructions.md`)
49
+ 5. Runs `squad up` to start your team
50
+
51
+ If Squad isn't installed yet, snap-squad tells you exactly what to do:
52
+
53
+ ```
54
+ Note: Squad CLI not found. Install it to run your squad:
55
+ npm install -g @bradygaster/squad-cli
56
+ squad up
57
+ ```
58
+
59
+ ### After Bootstrap: Plain English Works
60
+
61
+ Once snap-squad has run, your AI assistant knows your squad. In Copilot CLI or any AI tool:
62
+
63
+ ```
64
+ > switch my squad to the sages preset
65
+ > add a security specialist to my team
66
+ > show me my squad routing rules
67
+ ```
68
+
69
+ The generated copilot-instructions teach the assistant how to manage your squad.
70
+
71
+ ### More Examples
72
+
73
+ ```bash
74
+ npx snap-squad init help me learn best practices # → sages
75
+ npx snap-squad init database security hardening # → artisans
76
+ npx snap-squad init # → neighbors (default)
77
+ npx snap-squad init --type dash # → pick directly
78
+ npx snap-squad list # → see all presets
79
+ ```
80
+
81
+ ## What Gets Created
82
+
83
+ ```
84
+ your-project/
85
+ ├── .squad/
86
+ │ ├── team.md # Who's on the team
87
+ │ ├── routing.md # How work gets routed
88
+ │ ├── decisions.md # Decision log
89
+ │ ├── mcp-config.md # MCP tool config
90
+ │ └── agents/
91
+ │ ├── blueprint/charter.md
92
+ │ ├── wrench/charter.md
93
+ │ └── ...
94
+ ├── AGENTS.md # AI agent instructions (any tool)
95
+ ├── CLAUDE.md # Claude/Copilot CLI session memory
96
+ └── .github/
97
+ └── copilot-instructions.md # GitHub Copilot instructions
98
+ ```
99
+
100
+ The hook chain (`AGENTS.md` + `CLAUDE.md` + `copilot-instructions.md`) makes every AI session squad-aware — regardless of which tool opens your workspace.
101
+
102
+ ## List Presets
103
+
104
+ ```bash
105
+ npx snap-squad list
106
+ ```
107
+
108
+ ## Why Not Just Use Squad Directly?
109
+
110
+ You should! Squad's built-in setup is great for tailored teams. Snap Squad is for when you want to:
111
+
112
+ - **Start fast** — POC in minutes, not an hour
113
+ - **Learn from others** — Presets are trained by builders at CoreAI who ship with Squad daily
114
+ - **Reuse patterns** — Same team shape across multiple projects
115
+ - **Onboard people** — Give someone a working squad without the interview
116
+
117
+ The goal is to contribute these presets upstream to Squad if the maintainer agrees.
118
+
119
+ ## Status
120
+
121
+ 🚧 **Alpha** — Built by its own squad (dogfooding FTW).
122
+
123
+ ## How This Was Built
124
+
125
+ This project was built with AI assistance, steered by a human builder. The full story — every steering moment, key decision, and evolution arc — is in the [build journal](JOURNAL.md).
126
+
127
+ ## License
128
+
129
+ MIT
package/dist/cli.d.ts ADDED
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export {};
3
+ //# sourceMappingURL=cli.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":""}
package/dist/cli.js ADDED
@@ -0,0 +1,103 @@
1
+ #!/usr/bin/env node
2
+ import { Command } from 'commander';
3
+ import { existsSync } from 'node:fs';
4
+ import { resolve } from 'node:path';
5
+ import { execSync } from 'node:child_process';
6
+ import chalk from 'chalk';
7
+ import { loadPreset, listPresets } from './registry/loader.js';
8
+ import { generateSquad } from './generator/index.js';
9
+ import { matchPreset } from './matcher.js';
10
+ const program = new Command();
11
+ program
12
+ .name('snap-squad')
13
+ .description('Get started with Squad faster — ready-made squad presets')
14
+ .version('0.1.0');
15
+ program
16
+ .command('init')
17
+ .description('Initialize a squad — describe what you need or pick a preset')
18
+ .argument('[description...]', 'describe your project in plain English')
19
+ .option('-t, --type <preset>', 'pick a preset directly (neighbors, dash, sages, artisans)')
20
+ .option('-d, --dir <directory>', 'target directory', '.')
21
+ .option('-n, --name <name>', 'project name')
22
+ .option('-o, --owner <owner>', 'project owner')
23
+ .option('-f, --force', 'overwrite existing .squad/ directory', false)
24
+ .option('--no-up', 'skip running squad up after init')
25
+ .action((descriptionWords, opts) => {
26
+ const targetDir = resolve(opts.dir);
27
+ const squadDir = resolve(targetDir, '.squad');
28
+ if (existsSync(squadDir) && !opts.force) {
29
+ console.error(chalk.red('✗ .squad/ already exists. Use --force to overwrite.'));
30
+ process.exit(1);
31
+ }
32
+ // Resolve preset: explicit --type wins, otherwise match from description
33
+ let presetName;
34
+ if (opts.type) {
35
+ presetName = opts.type;
36
+ }
37
+ else if (descriptionWords.length > 0) {
38
+ const description = descriptionWords.join(' ');
39
+ const match = matchPreset(description);
40
+ presetName = match.preset;
41
+ console.log(chalk.dim(` "${description}" → ${chalk.bold(match.preset)} (${match.why})\n`));
42
+ }
43
+ else {
44
+ presetName = 'neighbors';
45
+ }
46
+ let preset;
47
+ try {
48
+ preset = loadPreset(presetName);
49
+ }
50
+ catch (err) {
51
+ console.error(chalk.red(`✗ ${err.message}`));
52
+ process.exit(1);
53
+ }
54
+ console.log(chalk.blue(`⚡ Snapping in ${chalk.bold(preset.displayName)}...`));
55
+ const created = generateSquad({
56
+ targetDir,
57
+ preset,
58
+ projectName: opts.name,
59
+ owner: opts.owner,
60
+ });
61
+ console.log(chalk.green(`\n✓ Squad ready! (${preset.displayName})\n`));
62
+ console.log(chalk.dim('Created:'));
63
+ for (const file of created) {
64
+ console.log(chalk.dim(` ${file}`));
65
+ }
66
+ // Run squad up unless --no-up
67
+ if (opts.up !== false) {
68
+ try {
69
+ execSync('squad --version', { stdio: 'ignore' });
70
+ console.log(chalk.blue(`\n🚀 Running ${chalk.bold('squad up')}...\n`));
71
+ execSync('squad up', { cwd: targetDir, stdio: 'inherit' });
72
+ }
73
+ catch {
74
+ console.log(`\n${chalk.yellow('Note:')} Squad CLI not found. Install it to run your squad:\n`);
75
+ console.log(chalk.dim(' npm install -g @bradygaster/squad-cli'));
76
+ console.log(chalk.dim(` cd ${targetDir}`));
77
+ console.log(chalk.dim(' squad up\n'));
78
+ }
79
+ }
80
+ });
81
+ program
82
+ .command('list')
83
+ .description('List available presets')
84
+ .action(() => {
85
+ const presets = listPresets();
86
+ if (presets.length === 0) {
87
+ console.log(chalk.yellow('No presets found.'));
88
+ return;
89
+ }
90
+ console.log(chalk.blue('Available presets:\n'));
91
+ for (const name of presets) {
92
+ try {
93
+ const p = loadPreset(name);
94
+ console.log(` ${chalk.bold(name)} — ${p.description}`);
95
+ }
96
+ catch {
97
+ console.log(` ${chalk.bold(name)}`);
98
+ }
99
+ }
100
+ console.log();
101
+ });
102
+ program.parse();
103
+ //# sourceMappingURL=cli.js.map
@@ -0,0 +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,MAAM,SAAS,CAAC;AACrC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAC9C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ACzB,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"}
@@ -0,0 +1,9 @@
1
+ import type { Preset } from '../registry/loader.js';
2
+ export interface GenerateOptions {
3
+ targetDir: string;
4
+ preset: Preset;
5
+ projectName?: string;
6
+ owner?: string;
7
+ }
8
+ export declare function generateSquad(options: GenerateOptions): string[];
9
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +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;AAE3D,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;CAChB;AAED,wBAAgB,aAAa,CAAC,OAAO,EAAE,eAAe,GAAG,MAAM,EAAE,CA4DhE"}
@@ -0,0 +1,307 @@
1
+ import { mkdirSync, writeFileSync } from 'node:fs';
2
+ import { join } from 'node:path';
3
+ export function generateSquad(options) {
4
+ const { targetDir, preset, projectName, owner } = options;
5
+ const squadDir = join(targetDir, '.squad');
6
+ const githubDir = join(targetDir, '.github');
7
+ const created = [];
8
+ // Create directories
9
+ mkdirSync(squadDir, { recursive: true });
10
+ mkdirSync(githubDir, { recursive: true });
11
+ for (const agent of preset.agents) {
12
+ mkdirSync(join(squadDir, 'agents', agent.name.toLowerCase()), { recursive: true });
13
+ }
14
+ // Generate team.md
15
+ const teamMd = generateTeamMd(preset, projectName, owner);
16
+ writeFileSync(join(squadDir, 'team.md'), teamMd);
17
+ created.push('.squad/team.md');
18
+ // Generate routing.md
19
+ const routingMd = generateRoutingMd(preset);
20
+ writeFileSync(join(squadDir, 'routing.md'), routingMd);
21
+ created.push('.squad/routing.md');
22
+ // Generate agent charters
23
+ for (const agent of preset.agents) {
24
+ const charter = generateCharter(agent);
25
+ const charterPath = join(squadDir, 'agents', agent.name.toLowerCase(), 'charter.md');
26
+ writeFileSync(charterPath, charter);
27
+ created.push(`.squad/agents/${agent.name.toLowerCase()}/charter.md`);
28
+ }
29
+ // Generate decisions.md
30
+ const decisionsMd = generateDecisionsMd(preset);
31
+ writeFileSync(join(squadDir, 'decisions.md'), decisionsMd);
32
+ created.push('.squad/decisions.md');
33
+ // Generate mcp-config.md
34
+ const mcpMd = generateMcpConfigMd(preset);
35
+ writeFileSync(join(squadDir, 'mcp-config.md'), mcpMd);
36
+ created.push('.squad/mcp-config.md');
37
+ // Generate hook chain: AGENTS.md, CLAUDE.md, .github/copilot-instructions.md
38
+ const agentsMd = generateAgentsMd(preset, projectName);
39
+ writeFileSync(join(targetDir, 'AGENTS.md'), agentsMd);
40
+ created.push('AGENTS.md');
41
+ const claudeMd = generateClaudeMd(preset, projectName, owner);
42
+ writeFileSync(join(targetDir, 'CLAUDE.md'), claudeMd);
43
+ created.push('CLAUDE.md');
44
+ const copilotMd = generateCopilotInstructions(preset);
45
+ writeFileSync(join(githubDir, 'copilot-instructions.md'), copilotMd);
46
+ created.push('.github/copilot-instructions.md');
47
+ // Generate JOURNAL.md (Ledger's home)
48
+ const journalMd = generateJournalMd(preset, projectName);
49
+ writeFileSync(join(targetDir, 'JOURNAL.md'), journalMd);
50
+ created.push('JOURNAL.md');
51
+ return created;
52
+ }
53
+ function generateTeamMd(arch, projectName, owner) {
54
+ const name = projectName || arch.team.name;
55
+ const agentRows = arch.agents
56
+ .map((a) => `| ${a.name} | ${a.role} | \`.squad/agents/${a.name.toLowerCase()}/charter.md\` | ✅ Active |`)
57
+ .join('\n');
58
+ return `# ${arch.team.name} — ${name}
59
+
60
+ > ${arch.team.description}
61
+
62
+ ## Coordinator
63
+
64
+ | Name | Role | Notes |
65
+ |------|------|-------|
66
+ | Squad | Coordinator | Routes work, enforces handoffs and reviewer gates. Does not generate domain artifacts. |
67
+
68
+ ## Members
69
+
70
+ | Name | Role | Charter | Status |
71
+ |------|------|---------|--------|
72
+ ${agentRows}
73
+ | Scribe | Session Logger | \`.squad/agents/scribe/charter.md\` | 📋 Silent |
74
+
75
+ ## Coding Agent
76
+
77
+ <!-- copilot-auto-assign: false -->
78
+
79
+ | Name | Role | Charter | Status |
80
+ |------|------|---------|--------|
81
+ | @copilot | Coding Agent | — | 🤖 Coding Agent |
82
+
83
+ ## Project Context
84
+
85
+ - **Owner:** ${owner || 'unknown'}
86
+ - **Stack:** (configure after init)
87
+ - **Description:** ${arch.description}
88
+ - **Universe:** ${arch.theme}
89
+ - **Created:** ${new Date().toISOString().split('T')[0]}
90
+ `;
91
+ }
92
+ function generateRoutingMd(arch) {
93
+ const rows = arch.routing.rules
94
+ .map((r) => `| ${r.pattern} | ${r.agent} | ${r.description} |`)
95
+ .join('\n');
96
+ return `# Routing Rules — ${arch.team.name}
97
+
98
+ ## Work Type → Agent
99
+
100
+ | Work Type | Agent | Examples |
101
+ |-----------|-------|---------|
102
+ ${rows}
103
+
104
+ ## Routing Principles
105
+
106
+ 1. **Eager by default** — spawn agents who could usefully start work.
107
+ 2. **Scribe always runs** after substantial work, in background. Never blocks.
108
+ 3. **Quick facts → coordinator answers directly.** Don't spawn for trivial questions.
109
+ 4. **Two agents could handle it** → pick the one whose domain is the primary concern.
110
+ 5. **Anticipate downstream.** Feature being built? Spawn tester simultaneously.
111
+ `;
112
+ }
113
+ function generateCharter(agent) {
114
+ return `# ${agent.name} — ${agent.role}
115
+
116
+ > ${agent.description}
117
+
118
+ ## Identity
119
+
120
+ - **Name:** ${agent.name}
121
+ - **Role:** ${agent.role}
122
+ - **Expertise:** ${agent.expertise.join(', ')}
123
+ - **Style:** ${agent.style}
124
+
125
+ ## How I Work
126
+
127
+ - Follow routing rules — handle my domain, defer others
128
+ - Check \`.squad/decisions.md\` before starting work
129
+ - Log decisions after completing work
130
+ - If unsure, say so and suggest who might know
131
+
132
+ ## Voice
133
+
134
+ ${agent.voice}
135
+
136
+ ## Model
137
+
138
+ - **Preferred:** auto
139
+ - **Fallback:** Standard chain
140
+
141
+ ## Collaboration
142
+
143
+ Before starting work, read \`.squad/decisions.md\` for team decisions that affect me.
144
+ After making a decision others should know, log it to \`.squad/decisions.md\`.
145
+ If I need another team member's input, say so — the coordinator will bring them in.
146
+ `;
147
+ }
148
+ function generateDecisionsMd(arch) {
149
+ return `# Decisions — ${arch.team.name}
150
+
151
+ > Significant decisions made during development. Check before starting work.
152
+
153
+ ## Active Decisions
154
+
155
+ ### D-001: Squad initialized with ${arch.displayName} preset
156
+ - **By:** snap-squad
157
+ - **Date:** ${new Date().toISOString().split('T')[0]}
158
+ - **Context:** Project initialized using snap-squad warm-start
159
+ - **Decision:** Using the "${arch.name}" preset (${arch.vibe} vibe, ${arch.theme} theme)
160
+ `;
161
+ }
162
+ function generateMcpConfigMd(arch) {
163
+ let skillSection = '';
164
+ if (arch.skills.length > 0) {
165
+ const skillList = arch.skills.map((s) => `- **${s.name}** — ${s.description}`).join('\n');
166
+ skillSection = `\n## Available Skills\n\n${skillList}\n`;
167
+ }
168
+ return `# MCP Integration — ${arch.team.name}
169
+
170
+ MCP (Model Context Protocol) servers extend the squad with external tools.
171
+ ${skillSection}
172
+ ## Config Locations
173
+
174
+ 1. **Repository-level:** \`.copilot/mcp-config.json\`
175
+ 2. **Workspace-level:** \`.vscode/mcp.json\`
176
+ 3. **User-level:** \`~/.copilot/mcp-config.json\`
177
+ `;
178
+ }
179
+ function generateAgentsMd(arch, projectName) {
180
+ const name = projectName || arch.team.name;
181
+ const agentTable = arch.agents
182
+ .map((a) => `| ${a.name} | ${a.role} | ${a.expertise.slice(0, 2).join(', ')} |`)
183
+ .join('\n');
184
+ return `# AGENTS.md — ${name} Operating Instructions
185
+
186
+ > This file is read by AI agents working in this repository.
187
+
188
+ ## You Are Part of a Squad
189
+
190
+ This repository uses [Squad](https://github.com/bradygaster/squad).
191
+ Before doing any work, read and follow the squad configuration:
192
+
193
+ 1. **Read \`.squad/team.md\`** — Know the team and project context
194
+ 2. **Read \`.squad/routing.md\`** — Route work to the right agent
195
+ 3. **Read agent charters in \`.squad/agents/*/charter.md\`** — Understand expertise and boundaries
196
+ 4. **Check \`.squad/decisions.md\`** — Review existing decisions
197
+ 5. **Check \`.squad/mcp-config.md\`** — Know available tools
198
+ 6. **Update \`JOURNAL.md\`** after milestones — capture steering moments and key decisions
199
+
200
+ ## Quick Reference
201
+
202
+ | Agent | Role | Ask them about... |
203
+ |-------|------|-------------------|
204
+ ${agentTable}
205
+
206
+ ## Preset: ${arch.displayName}
207
+
208
+ ${arch.description}
209
+ `;
210
+ }
211
+ function generateClaudeMd(arch, projectName, owner) {
212
+ const name = projectName || arch.team.name;
213
+ return `# CLAUDE.md — ${name} Session Memory
214
+
215
+ > Read this at the start of every session. Update when context changes.
216
+
217
+ ## Identity
218
+
219
+ You are working in a repository using the **${arch.displayName}** squad preset.
220
+
221
+ **You are part of a squad.** Read \`.squad/team.md\` for the full roster.
222
+
223
+ ## Project Context
224
+
225
+ - **Owner:** ${owner || 'unknown'}
226
+ - **Squad:** ${arch.displayName} (${arch.vibe})
227
+ - **Theme:** ${arch.theme}
228
+
229
+ ## Squad Operating Rules
230
+
231
+ Before starting work:
232
+ 1. Read \`.squad/team.md\` — know the team
233
+ 2. Read \`.squad/routing.md\` — route work correctly
234
+ 3. Check \`.squad/decisions.md\` — respect existing decisions
235
+ 4. Identify which agent you're acting as for this task
236
+
237
+ After completing work:
238
+ 1. Log decisions to \`.squad/decisions.md\`
239
+ 2. Update \`JOURNAL.md\` with what happened and why
240
+ 3. Update relevant docs if behavior changed
241
+ `;
242
+ }
243
+ function generateCopilotInstructions(arch) {
244
+ return `# Copilot Instructions — ${arch.team.name}
245
+
246
+ > **You are part of a squad.** This repository uses multi-agent team coordination.
247
+
248
+ ## On Every Session
249
+
250
+ 1. Read \`AGENTS.md\` at repo root for universal squad instructions
251
+ 2. Read \`CLAUDE.md\` at repo root for session memory and project context
252
+ 3. Read \`.squad/team.md\` for the full team roster
253
+ 4. Read \`.squad/routing.md\` for work routing rules
254
+ 5. Check \`.squad/decisions.md\` before starting work
255
+
256
+ ## Squad-Aware Behavior
257
+
258
+ - Identify which squad member is best suited for the current task
259
+ - Adopt their expertise, voice, and boundaries
260
+ - Log significant decisions to \`.squad/decisions.md\` after completing work
261
+
262
+ ## Managing This Squad
263
+
264
+ This squad was created with [snap-squad](https://github.com/paulyuk/snap-squad).
265
+ If the user asks to change, reset, or switch their squad:
266
+
267
+ \`\`\`bash
268
+ npx snap-squad init --type <preset> --force # switch to a different preset
269
+ npx snap-squad list # see available presets
270
+ \`\`\`
271
+
272
+ Available presets: neighbors (general), dash (speed), sages (mentor), artisans (specialists)
273
+ `;
274
+ }
275
+ function generateJournalMd(arch, projectName) {
276
+ const name = projectName || arch.team.name;
277
+ const date = new Date().toISOString().split('T')[0];
278
+ return `# JOURNAL.md — Build Story
279
+
280
+ > How this project was built, the steering moments that shaped it, and why things are the way they are.
281
+ > Maintained by the Historian / Build Journalist. Update after milestones.
282
+
283
+ ---
284
+
285
+ ## ${date} — Project Bootstrapped
286
+
287
+ ### Setup
288
+
289
+ - **Squad:** ${arch.displayName} (${arch.vibe})
290
+ - **Preset:** ${arch.name}
291
+ - **Theme:** ${arch.theme}
292
+ - **Created with:** \`npx snap-squad init\`
293
+
294
+ ### What Happened
295
+
296
+ Project initialized with the ${arch.displayName} squad preset. The full \`.squad/\` directory, hook chain (AGENTS.md, CLAUDE.md, copilot-instructions.md), and this journal were generated automatically.
297
+
298
+ ### Next
299
+
300
+ Start building. Update this journal as the project evolves — capture steering moments, key decisions, and the reasoning behind changes.
301
+
302
+ ---
303
+
304
+ *Keep this journal alive. The code shows what was built. The journal shows why.*
305
+ `;
306
+ }
307
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/generator/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AACnD,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAUjC,MAAM,UAAU,aAAa,CAAC,OAAwB;IACpD,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,WAAW,EAAE,KAAK,EAAE,GAAG,OAAO,CAAC;IAC1D,MAAM,QAAQ,GAAG,IAAI,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;IAC3C,MAAM,SAAS,GAAG,IAAI,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC;IAC7C,MAAM,OAAO,GAAa,EAAE,CAAC;IAE7B,qBAAqB;IACrB,SAAS,CAAC,QAAQ,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;IACzC,SAAS,CAAC,SAAS,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;IAC1C,KAAK,MAAM,KAAK,IAAI,MAAM,CAAC,MAAM,EAAE,CAAC;QAClC,SAAS,CAAC,IAAI,CAAC,QAAQ,EAAE,QAAQ,EAAE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E,WAAoB,EAAE,KAAc;IAC1E,MAAM,IAAI,GAAG,WAAW,IAAI,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC;IAE3C,OAAO,iBAAiB,IAAI;;;;;;8CAMgB,IAAI,CAAC,WAAW;;;;;;eAM/C,KAAK,IAAI,SAAS;eAClB,IAAI,CAAC,WAAW,KAAK,IAAI,CAAC,IAAI;eAC9B,IAAI,CAAC,KAAK;;;;;;;;;;;;;;CAcxB,CAAC;AACF,CAAC;AAED,SAAS,2BAA2B,CAAC,IAAY;IAC/C,OAAO,4BAA4B,IAAI,CAAC,IAAI,CAAC,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA6BlD,CAAC;AACF,CAAC;AAED,SAAS,iBAAiB,CAAC,IAAY,EAAE,WAAoB;IAC3D,MAAM,IAAI,GAAG,WAAW,IAAI,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC;IAC3C,MAAM,IAAI,GAAG,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;IAEpD,OAAO;;;;;;;KAOJ,IAAI;;;;eAIM,IAAI,CAAC,WAAW,KAAK,IAAI,CAAC,IAAI;gBAC7B,IAAI,CAAC,IAAI;eACV,IAAI,CAAC,KAAK;;;;;+BAKM,IAAI,CAAC,WAAW;;;;;;;;;CAS9C,CAAC;AACF,CAAC"}
@@ -0,0 +1,5 @@
1
+ export { loadPreset, listPresets } from './registry/loader.js';
2
+ export { generateSquad } from './generator/index.js';
3
+ export type { Preset, Agent, RoutingRule, SkillRef } from './registry/loader.js';
4
+ export type { GenerateOptions } from './generator/index.js';
5
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAC/D,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,YAAY,EAAE,MAAM,EAAE,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AACjF,YAAY,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,3 @@
1
+ export { loadPreset, listPresets } from './registry/loader.js';
2
+ export { generateSquad } from './generator/index.js';
3
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAC/D,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC"}
@@ -0,0 +1,8 @@
1
+ interface PresetMatch {
2
+ preset: string;
3
+ score: number;
4
+ why: string;
5
+ }
6
+ export declare function matchPreset(description: string): PresetMatch;
7
+ export {};
8
+ //# sourceMappingURL=matcher.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"matcher.d.ts","sourceRoot":"","sources":["../src/matcher.ts"],"names":[],"mappings":"AAAA,UAAU,WAAW;IACnB,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,CAAC;CACb;AAwDD,wBAAgB,WAAW,CAAC,WAAW,EAAE,MAAM,GAAG,WAAW,CAuC5D"}
@@ -0,0 +1,87 @@
1
+ const KEYWORDS = {
2
+ // Dash signals
3
+ fast: [{ preset: 'dash', weight: 3 }],
4
+ quick: [{ preset: 'dash', weight: 3 }],
5
+ speed: [{ preset: 'dash', weight: 3 }],
6
+ rapid: [{ preset: 'dash', weight: 3 }],
7
+ poc: [{ preset: 'dash', weight: 4 }],
8
+ prototype: [{ preset: 'dash', weight: 4 }],
9
+ hackathon: [{ preset: 'dash', weight: 5 }],
10
+ demo: [{ preset: 'dash', weight: 3 }],
11
+ mvp: [{ preset: 'dash', weight: 4 }],
12
+ 'ship fast': [{ preset: 'dash', weight: 5 }],
13
+ 'no fluff': [{ preset: 'dash', weight: 4 }],
14
+ // Sages signals
15
+ learn: [{ preset: 'sages', weight: 4 }],
16
+ teach: [{ preset: 'sages', weight: 4 }],
17
+ mentor: [{ preset: 'sages', weight: 5 }],
18
+ explain: [{ preset: 'sages', weight: 3 }],
19
+ 'best practice': [{ preset: 'sages', weight: 4 }],
20
+ 'best practices': [{ preset: 'sages', weight: 4 }],
21
+ onboard: [{ preset: 'sages', weight: 3 }],
22
+ training: [{ preset: 'sages', weight: 4 }],
23
+ understand: [{ preset: 'sages', weight: 3 }],
24
+ why: [{ preset: 'sages', weight: 2 }],
25
+ review: [{ preset: 'sages', weight: 2 }],
26
+ // Artisans signals
27
+ database: [{ preset: 'artisans', weight: 4 }],
28
+ postgres: [{ preset: 'artisans', weight: 5 }],
29
+ security: [{ preset: 'artisans', weight: 5 }],
30
+ hardening: [{ preset: 'artisans', weight: 5 }],
31
+ performance: [{ preset: 'artisans', weight: 3 }],
32
+ optimize: [{ preset: 'artisans', weight: 3 }],
33
+ specialist: [{ preset: 'artisans', weight: 4 }],
34
+ deep: [{ preset: 'artisans', weight: 2 }],
35
+ tuning: [{ preset: 'artisans', weight: 4 }],
36
+ infrastructure: [{ preset: 'artisans', weight: 3 }],
37
+ devops: [{ preset: 'artisans', weight: 3 }],
38
+ ui: [{ preset: 'artisans', weight: 2 }],
39
+ accessibility: [{ preset: 'artisans', weight: 4 }],
40
+ cicd: [{ preset: 'artisans', weight: 3 }],
41
+ // Neighbors signals (general/default)
42
+ general: [{ preset: 'neighbors', weight: 3 }],
43
+ 'all purpose': [{ preset: 'neighbors', weight: 3 }],
44
+ balanced: [{ preset: 'neighbors', weight: 3 }],
45
+ reliable: [{ preset: 'neighbors', weight: 3 }],
46
+ standard: [{ preset: 'neighbors', weight: 2 }],
47
+ project: [{ preset: 'neighbors', weight: 1 }],
48
+ app: [{ preset: 'neighbors', weight: 1 }],
49
+ build: [{ preset: 'neighbors', weight: 1 }],
50
+ };
51
+ export function matchPreset(description) {
52
+ const lower = description.toLowerCase();
53
+ const scores = {
54
+ neighbors: 0,
55
+ dash: 0,
56
+ sages: 0,
57
+ artisans: 0,
58
+ };
59
+ for (const [keyword, mappings] of Object.entries(KEYWORDS)) {
60
+ if (lower.includes(keyword)) {
61
+ for (const { preset, weight } of mappings) {
62
+ scores[preset] += weight;
63
+ }
64
+ }
65
+ }
66
+ // Find winner
67
+ let best = 'neighbors';
68
+ let bestScore = 0;
69
+ for (const [preset, score] of Object.entries(scores)) {
70
+ if (score > bestScore) {
71
+ best = preset;
72
+ bestScore = score;
73
+ }
74
+ }
75
+ const reasons = {
76
+ neighbors: 'Good all-around team for general projects',
77
+ dash: 'Speed-focused team for rapid building',
78
+ sages: 'Mentor team that explains the "why" behind decisions',
79
+ artisans: 'Specialist team for deep, precise work',
80
+ };
81
+ return {
82
+ preset: best,
83
+ score: bestScore,
84
+ why: reasons[best],
85
+ };
86
+ }
87
+ //# sourceMappingURL=matcher.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"matcher.js","sourceRoot":"","sources":["../src/matcher.ts"],"names":[],"mappings":"AAMA,MAAM,QAAQ,GAAyD;IACrE,eAAe;IACf,IAAI,EAAE,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,EAAE,CAAC;IACrC,KAAK,EAAE,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,EAAE,CAAC;IACtC,KAAK,EAAE,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,EAAE,CAAC;IACtC,KAAK,EAAE,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,EAAE,CAAC;IACtC,GAAG,EAAE,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,EAAE,CAAC;IACpC,SAAS,EAAE,CAAC,EAAE,MAAM,E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AAQ,CAAC,OAAO,CAAC,EAAE,CAAC;YAC5B,KAAK,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,QAAQ,EAAE,CAAC;gBAC1C,MAAM,CAAC,MAAM,CAAC,IAAI,MAAM,CAAC;YAC3B,CAAC;QACH,CAAC;IACH,CAAC;IAED,cAAc;IACd,IAAI,IAAI,GAAG,WAAW,CAAC;IACvB,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,MAAM,OAAO,GAA2B;QACtC,SAAS,EAAE,2CAA2C;QACtD,IAAI,EAAE,uCAAuC;QAC7C,KAAK,EAAE,sDAAsD;QAC7D,QAAQ,EAAE,wCAAwC;KACnD,CAAC;IAEF,OAAO;QACL,MAAM,EAAE,IAAI;QACZ,KAAK,EAAE,SAAS;QAChB,GAAG,EAAE,OAAO,CAAC,IAAI,CAAC;KACnB,CAAC;AACJ,CAAC"}
@@ -0,0 +1,38 @@
1
+ export interface Agent {
2
+ name: string;
3
+ role: string;
4
+ description: string;
5
+ expertise: string[];
6
+ style: string;
7
+ voice: string;
8
+ }
9
+ export interface RoutingRule {
10
+ pattern: string;
11
+ agent: string;
12
+ description: string;
13
+ }
14
+ export interface SkillRef {
15
+ name: string;
16
+ description: string;
17
+ }
18
+ export interface Preset {
19
+ name: string;
20
+ displayName: string;
21
+ description: string;
22
+ vibe: string;
23
+ theme: string;
24
+ team: {
25
+ name: string;
26
+ description: string;
27
+ projectContext: string;
28
+ };
29
+ agents: Agent[];
30
+ routing: {
31
+ rules: RoutingRule[];
32
+ defaultAgent: string;
33
+ };
34
+ skills: SkillRef[];
35
+ }
36
+ export declare function loadPreset(name: string): Preset;
37
+ export declare function listPresets(): string[];
38
+ //# sourceMappingURL=loader.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"loader.d.ts","sourceRoot":"","sources":["../../src/registry/loader.ts"],"names":[],"mappings":"AAQA,MAAM,WAAW,KAAK;IACpB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,SAAS,EAAE,MAAM,EAAE,CAAC;IACpB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,WAAW,WAAW;IAC1B,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,MAAM;IACrB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE;QACJ,IAAI,EAAE,MAAM,CAAC;QACb,WAAW,EAAE,MAAM,CAAC;QACpB,cAAc,EAAE,MAAM,CAAC;KACxB,CAAC;IACF,MAAM,EAAE,KAAK,EAAE,CAAC;IAChB,OAAO,EAAE;QACP,KAAK,EAAE,WAAW,EAAE,CAAC;QACrB,YAAY,EAAE,MAAM,CAAC;KACtB,CAAC;IACF,MAAM,EAAE,QAAQ,EAAE,CAAC;CACpB;AAID,wBAAgB,UAAU,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAmB/C;AAED,wBAAgB,WAAW,IAAI,MAAM,EAAE,CAetC"}
@@ -0,0 +1,44 @@
1
+ import { readFileSync, readdirSync } from 'node:fs';
2
+ import { join, dirname } from 'node:path';
3
+ import { fileURLToPath } from 'node:url';
4
+ import { parse as parseYaml } from 'yaml';
5
+ const __filename = fileURLToPath(import.meta.url);
6
+ const __dirname = dirname(__filename);
7
+ const PRESETS_DIR = join(__dirname, '..', 'registry', 'presets');
8
+ export function loadPreset(name) {
9
+ // Resolve from compiled dist or source
10
+ let dir = PRESETS_DIR;
11
+ try {
12
+ readdirSync(dir);
13
+ }
14
+ catch {
15
+ // Fallback: try relative to source
16
+ dir = join(__dirname, '..', '..', 'src', 'registry', 'presets');
17
+ }
18
+ const filePath = join(dir, `${name}.yaml`);
19
+ try {
20
+ const content = readFileSync(filePath, 'utf-8');
21
+ return parseYaml(content);
22
+ }
23
+ catch (err) {
24
+ throw new Error(`Preset "${name}" not found. Available: ${listPresets().join(', ')}`);
25
+ }
26
+ }
27
+ export function listPresets() {
28
+ let dir = PRESETS_DIR;
29
+ try {
30
+ readdirSync(dir);
31
+ }
32
+ catch {
33
+ dir = join(__dirname, '..', '..', 'src', 'registry', 'presets');
34
+ }
35
+ try {
36
+ return readdirSync(dir)
37
+ .filter((f) => f.endsWith('.yaml'))
38
+ .map((f) => f.replace('.yaml', ''));
39
+ }
40
+ catch {
41
+ return [];
42
+ }
43
+ }
44
+ //# sourceMappingURL=loader.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"loader.js","sourceRoot":"","sources":["../../src/registry/loader.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AACpD,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,KAAK,IAAI,SAAS,EAAE,MAAM,MAAM,CAAC;AAE1C,MAAM,UAAU,GAAG,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAClD,MAAM,SAAS,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;AAyCtC,MAAM,WAA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C,OAAO,EAAE,EAAE,CAAC,CAAC,CAAC;IACxC,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,EAAE,CAAC;IACZ,CAAC;AACH,CAAC"}
package/package.json ADDED
@@ -0,0 +1,47 @@
1
+ {
2
+ "name": "snap-squad",
3
+ "version": "0.1.0",
4
+ "description": "Get started with Squad faster — ready-made squad presets for instant deployment",
5
+ "type": "module",
6
+ "bin": {
7
+ "snap-squad": "./dist/cli.js"
8
+ },
9
+ "files": [
10
+ "dist",
11
+ "src/registry/presets"
12
+ ],
13
+ "scripts": {
14
+ "build": "tsc",
15
+ "prepublishOnly": "npm run build",
16
+ "dev": "tsc --watch",
17
+ "test": "vitest run",
18
+ "test:watch": "vitest",
19
+ "lint": "tsc --noEmit"
20
+ },
21
+ "engines": {
22
+ "node": ">=20.0.0"
23
+ },
24
+ "keywords": [
25
+ "squad",
26
+ "copilot",
27
+ "multi-agent",
28
+ "warm-start",
29
+ "mcp"
30
+ ],
31
+ "author": "paulyuk",
32
+ "license": "MIT",
33
+ "repository": {
34
+ "type": "git",
35
+ "url": "https://github.com/paulyuk/snap-squad.git"
36
+ },
37
+ "dependencies": {
38
+ "commander": "^13.0.0",
39
+ "yaml": "^2.7.0",
40
+ "chalk": "^5.4.0"
41
+ },
42
+ "devDependencies": {
43
+ "typescript": "^5.7.0",
44
+ "vitest": "^3.0.0",
45
+ "@types/node": "^22.0.0"
46
+ }
47
+ }
@@ -0,0 +1,86 @@
1
+ name: artisans
2
+ displayName: The Artisans
3
+ description: Precision specialist squad — niche expertise, deep tooling, quality over speed.
4
+ vibe: precision
5
+ theme: Master Workshop
6
+
7
+ team:
8
+ name: The Artisans
9
+ description: Specialists who go deep. Database tuning, security hardening, UI polish, infra optimization.
10
+ projectContext: |
11
+ A squad of specialists for when you need depth over breadth.
12
+ Each artisan brings deep expertise in a specific domain.
13
+ Use the Skill Locker to snap in domain-specific MCP tools.
14
+
15
+ agents:
16
+ - name: Forge
17
+ role: Lead / Integration Architect
18
+ description: Coordinates specialists. Ensures deep work integrates cleanly.
19
+ expertise: [system integration, API design, cross-concern coordination]
20
+ style: Precise, integration-minded, thinks about seams
21
+ voice: "The specialist's specialist. Makes sure the DB tuning doesn't break the API contract."
22
+
23
+ - name: Anvil
24
+ role: Backend / Data Specialist
25
+ description: Database tuning, query optimization, data modeling, caching.
26
+ expertise: [PostgreSQL, Redis, query optimization, data modeling, caching strategies]
27
+ style: Methodical, benchmark-driven, measures everything
28
+ voice: "If you can't measure it, you can't optimize it. Show me the query plan."
29
+
30
+ - name: Chisel
31
+ role: Security / Hardening Specialist
32
+ description: Security review, auth patterns, secret management, compliance.
33
+ expertise: [auth, encryption, secret management, OWASP, compliance]
34
+ style: Paranoid (in a good way), thorough, defense-in-depth
35
+ voice: "Assumes everything is a threat until proven otherwise. Will reject 'we'll add auth later.'"
36
+
37
+ - name: Prism
38
+ role: UI/UX / Frontend Specialist
39
+ description: UI polish, accessibility, responsive design, component architecture.
40
+ expertise: [CSS, accessibility, responsive design, component patterns, animation]
41
+ style: Visual, detail-obsessed, pixel-perfect
42
+ voice: "The 2px margin matters. Accessibility is not optional. If it's not keyboard-navigable, it's not done."
43
+
44
+ - name: Loom
45
+ role: Infra / DevOps Specialist
46
+ description: CI/CD, container orchestration, IaC, monitoring, observability.
47
+ expertise: [Docker, Kubernetes, Terraform, GitHub Actions, monitoring]
48
+ style: Automation-first, infrastructure-as-code, observable by default
49
+ voice: "If it's not automated, it's a bug. If it's not monitored, it's invisible."
50
+
51
+ - name: Ledger
52
+ role: Historian / Build Journalist
53
+ description: Journals the builder's prompts, steering, and key evolution moments. Tracks how specialist decisions compound.
54
+ expertise: [build journals, decision history, prompt curation, specialist workflow narratives, markdown review]
55
+ style: Narrative, precise, connects specialist work to the bigger picture
56
+ voice: "When three specialists touch the same system, the story of how their work fit together is more valuable than any one commit. Write it down or lose it."
57
+
58
+ routing:
59
+ rules:
60
+ - pattern: architecture
61
+ agent: Forge
62
+ description: Integration design, cross-concern coordination
63
+ - pattern: backend
64
+ agent: Anvil
65
+ description: Database, queries, caching, data modeling
66
+ - pattern: security
67
+ agent: Chisel
68
+ description: Auth, encryption, secrets, compliance
69
+ - pattern: frontend
70
+ agent: Prism
71
+ description: UI, UX, accessibility, components
72
+ - pattern: infrastructure
73
+ agent: Loom
74
+ description: CI/CD, containers, IaC, monitoring
75
+ - pattern: history
76
+ agent: Ledger
77
+ description: Build journal, evolution narrative, specialist coordination story
78
+ defaultAgent: Forge
79
+
80
+ skills:
81
+ - name: postgres-toolbox
82
+ description: PostgreSQL MCP tools for query analysis and optimization
83
+ - name: security-scanner
84
+ description: Security scanning and vulnerability detection tools
85
+ - name: azure-toolkit
86
+ description: Azure resource management and deployment tools
@@ -0,0 +1,52 @@
1
+ name: dash
2
+ displayName: The Dash Squad
3
+ description: Rapid POC squad — speed over ceremony, zero fluff, ship fast.
4
+ vibe: speed
5
+ theme: Racing Crew
6
+
7
+ team:
8
+ name: The Dash Squad
9
+ description: Built for speed. Minimal ceremony, maximum velocity.
10
+ projectContext: |
11
+ A squad optimized for rapid POCs and hackathons.
12
+ Skip the meetings, ship the demo. Polish comes later.
13
+
14
+ agents:
15
+ - name: Turbo
16
+ role: Lead / Architect
17
+ description: Makes fast decisions. Scope is tiny by design.
18
+ expertise: [rapid prototyping, scope cutting, quick decisions]
19
+ style: Terse, decisive, velocity-obsessed
20
+ voice: "If it takes more than a sentence to explain, it's too complex. Ship now, refine later."
21
+
22
+ - name: Bolt
23
+ role: Full-Stack Dev
24
+ description: Writes all the code. Frontend, backend, infra — whatever it takes.
25
+ expertise: [full-stack, rapid coding, scaffolding, API design]
26
+ style: Fast, pragmatic, copies good patterns shamelessly
27
+ voice: "The fastest path between idea and demo. Will scaffold an entire app while you're writing the spec."
28
+
29
+ - name: Flash
30
+ role: Tester + DevRel
31
+ description: Smoke tests and writes the README. Two jobs, zero complaints.
32
+ expertise: [smoke testing, README, quick docs, demo scripts]
33
+ style: Efficient, gets it done, minimal prose
34
+ voice: "Three tests for the happy path, a README with one example, and we ship. That's the deal."
35
+
36
+ routing:
37
+ rules:
38
+ - pattern: architecture
39
+ agent: Turbo
40
+ description: Quick scope decisions, tech stack picks
41
+ - pattern: implementation
42
+ agent: Bolt
43
+ description: All code — frontend, backend, infra, whatever
44
+ - pattern: testing
45
+ agent: Flash
46
+ description: Smoke tests, basic coverage
47
+ - pattern: documentation
48
+ agent: Flash
49
+ description: README, quickstart, demo script
50
+ defaultAgent: Turbo
51
+
52
+ skills: []
@@ -0,0 +1,89 @@
1
+ name: neighbors
2
+ displayName: The Neighbors
3
+ description: Default generalist squad — reliable, well-rounded, good for any project.
4
+ vibe: friendly
5
+ theme: Community Builders
6
+
7
+ team:
8
+ name: The Neighbors
9
+ description: A friendly, well-rounded squad for general-purpose projects.
10
+ projectContext: |
11
+ A reliable generalist team that handles any project type.
12
+ Good defaults, clear communication, balanced skill coverage.
13
+
14
+ agents:
15
+ - name: Blueprint
16
+ role: Lead / Architect
17
+ description: Sees the whole picture. Keeps the project on track.
18
+ expertise: [system design, scope management, code review]
19
+ style: Clear, decisive, thinks in systems
20
+ voice: "Prefers simple solutions. Will ask 'do we actually need this?' before building."
21
+
22
+ - name: Wrench
23
+ role: Core Dev
24
+ description: Makes it work. Practical, fast, reliable.
25
+ expertise: [implementation, debugging, refactoring]
26
+ style: Hands-on, pragmatic, ships working code
27
+ voice: "The one who actually writes the code. Thinks the best abstraction is a good function name."
28
+
29
+ - name: Lens
30
+ role: Tester / QA
31
+ description: Finds what's broken before users do.
32
+ expertise: [testing, edge cases, quality gates]
33
+ style: Thorough, skeptical, detail-oriented
34
+ voice: "If it's not tested, it's not done. Will block a PR for missing tests."
35
+
36
+ - name: Quill
37
+ role: Docs / DevRel
38
+ description: Makes the project approachable. Writes docs that people actually read.
39
+ expertise: [documentation, README, onboarding, examples]
40
+ style: Warm, clear, example-driven
41
+ voice: "Believes the README is the front door. If onboarding takes more than 3 steps, something is wrong."
42
+
43
+ - name: Mosaic
44
+ role: Prompt Engineer
45
+ description: Crafts the prompts and agent voices.
46
+ expertise: [system prompts, agent design, manifest curation]
47
+ style: Precise with words, thoughtful
48
+ voice: "Every token in a prompt earns its place. Filler without function is noise."
49
+
50
+ - name: Relay
51
+ role: GitOps / Release
52
+ description: Manages git workflow, CI/CD, releases, and multi-account GitHub auth.
53
+ expertise: [git workflow, GitHub CLI, CI/CD, releases, multi-account auth]
54
+ style: Methodical, automation-first, knows every gh CLI flag
55
+ voice: "If you can't push, check gh auth status first. Automate the release or it won't happen."
56
+
57
+ - name: Ledger
58
+ role: Historian / Build Journalist
59
+ description: Journals the builder's prompts, steering, and key evolution moments. Writes the story of how the project was built.
60
+ expertise: [build journals, decision history, prompt curation, markdown review, git log storytelling]
61
+ style: Narrative, observant, captures the why behind the what
62
+ 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."
63
+
64
+ routing:
65
+ rules:
66
+ - pattern: architecture
67
+ agent: Blueprint
68
+ description: System design, scope, trade-offs, code review
69
+ - pattern: implementation
70
+ agent: Wrench
71
+ description: Feature code, CLI, runtime, file operations
72
+ - pattern: testing
73
+ agent: Lens
74
+ description: Tests, quality gates, edge cases, CI/CD
75
+ - pattern: documentation
76
+ agent: Quill
77
+ description: README, docs, messaging, onboarding, examples
78
+ - pattern: prompts
79
+ agent: Mosaic
80
+ description: Agent charters, system prompts, manifest design
81
+ - pattern: git
82
+ agent: Relay
83
+ description: Git workflow, pushes, PRs, releases, GitHub auth, CI/CD
84
+ - pattern: history
85
+ agent: Ledger
86
+ description: Build journal, decision history, evolution narrative, prompt curation, markdown review
87
+ defaultAgent: Blueprint
88
+
89
+ skills: []
@@ -0,0 +1,80 @@
1
+ name: sages
2
+ displayName: The Sages
3
+ description: Mentor squad — explains the "why", focuses on best practices and learning.
4
+ vibe: mentor
5
+ theme: Library Council
6
+
7
+ team:
8
+ name: The Sages
9
+ description: A teaching-first squad that explains decisions, shares patterns, and builds understanding.
10
+ projectContext: |
11
+ A squad for learning and best practices. Every code change comes
12
+ with an explanation. Architecture decisions include rationale.
13
+ Great for onboarding, training projects, and establishing patterns.
14
+
15
+ agents:
16
+ - name: Oracle
17
+ role: Lead / Architect
18
+ description: Explains architectural decisions with context and trade-offs.
19
+ expertise: [architecture, design patterns, trade-off analysis]
20
+ style: Socratic, explains the "why", teaches through questions
21
+ voice: "Never just says 'do it this way.' Always explains why, what alternatives exist, and what we're trading off."
22
+
23
+ - name: Scriptor
24
+ role: Core Dev / Mentor
25
+ description: Writes exemplary code with inline explanations.
26
+ expertise: [clean code, design patterns, refactoring, code review]
27
+ style: Thorough, well-commented, pedagogical
28
+ voice: "Code is read more than it's written. Every function tells a story. Comments explain intent, not mechanics."
29
+
30
+ - name: Proof
31
+ role: Tester / Quality Mentor
32
+ description: Teaches testing as a design tool, not a chore.
33
+ expertise: [TDD, test design, coverage strategy, property testing]
34
+ style: Patient, systematic, teaches by example
35
+ voice: "Tests are specifications written in code. A good test suite IS the documentation."
36
+
37
+ - name: Chronicle
38
+ role: Docs / Knowledge Manager
39
+ description: Writes docs that teach, not just describe. Maintains decision records.
40
+ expertise: [technical writing, ADRs, tutorials, knowledge management]
41
+ style: Structured, reference-quality, builds learning paths
42
+ voice: "Good documentation answers the question you'll have in 6 months. Great documentation prevents the question."
43
+
44
+ - name: Pattern
45
+ role: Prompt Engineer / Pattern Curator
46
+ description: Designs prompts as reusable patterns with documented rationale.
47
+ expertise: [prompt patterns, system design, reusable templates]
48
+ style: Methodical, pattern-oriented, documents everything
49
+ voice: "A prompt is a pattern. Document it, version it, test it, share it."
50
+
51
+ - name: Ledger
52
+ role: Historian / Build Journalist
53
+ description: Journals how the project was built — captures the builder's steering, reasoning, and teaching moments.
54
+ expertise: [build journals, decision history, prompt curation, learning narratives, markdown review]
55
+ style: Narrative, reflective, captures the lesson behind the code
56
+ voice: "The best learning resource isn't documentation — it's the story of how and why things were built. Every steering moment from the builder is a lesson worth preserving."
57
+
58
+ routing:
59
+ rules:
60
+ - pattern: architecture
61
+ agent: Oracle
62
+ description: Design decisions with full rationale and alternatives
63
+ - pattern: implementation
64
+ agent: Scriptor
65
+ description: Clean, well-documented code with inline explanations
66
+ - pattern: testing
67
+ agent: Proof
68
+ description: Test-driven development, coverage strategy
69
+ - pattern: documentation
70
+ agent: Chronicle
71
+ description: Tutorials, ADRs, learning paths, reference docs
72
+ - pattern: prompts
73
+ agent: Pattern
74
+ description: Reusable prompt patterns, agent design rationale
75
+ - pattern: history
76
+ agent: Ledger
77
+ description: Build journal, evolution narrative, steering moments, prompt curation
78
+ defaultAgent: Oracle
79
+
80
+ skills: []