automatasaurus 0.1.15 → 0.1.16
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/package.json +1 -1
- package/src/commands/init.js +16 -1
- package/src/commands/update.js +16 -1
- package/src/lib/symlinks.js +41 -1
- package/template/CLAUDE.block.md +5 -5
- package/template/agents/architect/AGENT.md +5 -0
- package/template/agents/designer/AGENT.md +3 -0
- package/template/agents/developer/AGENT.md +6 -0
- package/template/agents/tester/AGENT.md +7 -1
- package/template/commands/auto-discovery.md +16 -6
- package/template/commands/auto-plan.md +0 -2
- package/template/skills/agent-coordination/SKILL.md +5 -10
package/package.json
CHANGED
package/src/commands/init.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { mkdir, cp, readFile } from 'node:fs/promises';
|
|
2
2
|
import { join } from 'node:path';
|
|
3
3
|
import { getTemplateDir, getProjectPaths, getVersion, SUBDIR_SYMLINK_DIRS, FILE_SYMLINK_DIRS } from '../lib/paths.js';
|
|
4
|
-
import { symlinkDirectory, symlinkSubdirectories } from '../lib/symlinks.js';
|
|
4
|
+
import { symlinkDirectory, symlinkSubdirectories, symlinkAgentFiles } from '../lib/symlinks.js';
|
|
5
5
|
import { mergeBlockIntoFile } from '../lib/block-merge.js';
|
|
6
6
|
import { mergeLayeredSettings, createLocalSettingsTemplate, mergeJsonFile } from '../lib/json-merge.js';
|
|
7
7
|
import { readManifest, writeManifest, createManifest, updateManifest } from '../lib/manifest.js';
|
|
@@ -62,6 +62,21 @@ export async function init({ force = false } = {}) {
|
|
|
62
62
|
}
|
|
63
63
|
}
|
|
64
64
|
|
|
65
|
+
// Flat file symlinks for agents (enables Claude Code agent discovery)
|
|
66
|
+
{
|
|
67
|
+
const sourceDir = join(paths.automatasaurus, 'agents');
|
|
68
|
+
const targetDir = join(paths.claude, 'agents');
|
|
69
|
+
try {
|
|
70
|
+
const created = await symlinkAgentFiles(sourceDir, targetDir);
|
|
71
|
+
for (const file of created) {
|
|
72
|
+
allSymlinks.push(`agents/${file}`);
|
|
73
|
+
console.log(` Linked agents/${file}`);
|
|
74
|
+
}
|
|
75
|
+
} catch (error) {
|
|
76
|
+
if (error.code !== 'ENOENT') throw error;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
|
|
65
80
|
// File-level symlinks (hooks, commands)
|
|
66
81
|
for (const dir of FILE_SYMLINK_DIRS) {
|
|
67
82
|
const sourceDir = join(paths.automatasaurus, dir);
|
package/src/commands/update.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { mkdir, cp, readFile, rm, lstat } from 'node:fs/promises';
|
|
2
2
|
import { join } from 'node:path';
|
|
3
3
|
import { getTemplateDir, getProjectPaths, getVersion, SUBDIR_SYMLINK_DIRS, FILE_SYMLINK_DIRS } from '../lib/paths.js';
|
|
4
|
-
import { symlinkDirectory, symlinkSubdirectories } from '../lib/symlinks.js';
|
|
4
|
+
import { symlinkDirectory, symlinkSubdirectories, symlinkAgentFiles } from '../lib/symlinks.js';
|
|
5
5
|
import { mergeBlockIntoFile } from '../lib/block-merge.js';
|
|
6
6
|
import { mergeLayeredSettings, createLocalSettingsTemplate, mergeJsonFile } from '../lib/json-merge.js';
|
|
7
7
|
import { readManifest, writeManifest, updateManifest } from '../lib/manifest.js';
|
|
@@ -97,6 +97,21 @@ export async function update({ force = false } = {}) {
|
|
|
97
97
|
}
|
|
98
98
|
}
|
|
99
99
|
|
|
100
|
+
// Flat file symlinks for agents (enables Claude Code agent discovery)
|
|
101
|
+
{
|
|
102
|
+
const sourceDir = join(paths.automatasaurus, 'agents');
|
|
103
|
+
const targetDir = join(paths.claude, 'agents');
|
|
104
|
+
try {
|
|
105
|
+
const created = await symlinkAgentFiles(sourceDir, targetDir);
|
|
106
|
+
for (const file of created) {
|
|
107
|
+
allSymlinks.push(`agents/${file}`);
|
|
108
|
+
}
|
|
109
|
+
console.log(` Updated agents/ flat files (${created.length} files)`);
|
|
110
|
+
} catch (error) {
|
|
111
|
+
if (error.code !== 'ENOENT') throw error;
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
|
|
100
115
|
// File-level symlinks (hooks, commands)
|
|
101
116
|
for (const dir of FILE_SYMLINK_DIRS) {
|
|
102
117
|
const sourceDir = join(paths.automatasaurus, dir);
|
package/src/lib/symlinks.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { symlink, unlink, readlink, mkdir, readdir, stat } from 'node:fs/promises';
|
|
1
|
+
import { symlink, unlink, readlink, mkdir, readdir, stat, access } from 'node:fs/promises';
|
|
2
2
|
import { join, dirname, relative } from 'node:path';
|
|
3
3
|
|
|
4
4
|
/**
|
|
@@ -125,3 +125,43 @@ export async function symlinkSubdirectories(sourceDir, targetDir) {
|
|
|
125
125
|
|
|
126
126
|
return created;
|
|
127
127
|
}
|
|
128
|
+
|
|
129
|
+
/**
|
|
130
|
+
* Create flat file symlinks for agent AGENT.md files.
|
|
131
|
+
* For each agent subdirectory containing AGENT.md, creates:
|
|
132
|
+
* targetDir/{name}.md -> sourceDir/{name}/AGENT.md
|
|
133
|
+
*
|
|
134
|
+
* This enables Claude Code's flat-file agent discovery while
|
|
135
|
+
* preserving subdirectory symlinks for PROJECT.md support.
|
|
136
|
+
*/
|
|
137
|
+
export async function symlinkAgentFiles(sourceDir, targetDir) {
|
|
138
|
+
await mkdir(targetDir, { recursive: true });
|
|
139
|
+
|
|
140
|
+
const created = [];
|
|
141
|
+
|
|
142
|
+
try {
|
|
143
|
+
const entries = await readdir(sourceDir, { withFileTypes: true });
|
|
144
|
+
|
|
145
|
+
for (const entry of entries) {
|
|
146
|
+
if (!entry.isDirectory()) continue;
|
|
147
|
+
|
|
148
|
+
const agentMdPath = join(sourceDir, entry.name, 'AGENT.md');
|
|
149
|
+
|
|
150
|
+
try {
|
|
151
|
+
await access(agentMdPath);
|
|
152
|
+
} catch {
|
|
153
|
+
continue; // No AGENT.md in this subdirectory
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
const target = join(targetDir, `${entry.name}.md`);
|
|
157
|
+
await createSymlink(agentMdPath, target);
|
|
158
|
+
created.push(`${entry.name}.md`);
|
|
159
|
+
}
|
|
160
|
+
} catch (error) {
|
|
161
|
+
if (error.code !== 'ENOENT') {
|
|
162
|
+
throw error;
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
return created;
|
|
167
|
+
}
|
package/template/CLAUDE.block.md
CHANGED
|
@@ -48,10 +48,10 @@ The following agents are available in `.claude/agents/`:
|
|
|
48
48
|
| Agent | Role | Model | Review Status |
|
|
49
49
|
|-------|------|-------|---------------|
|
|
50
50
|
| `architect` | System design, ADRs, stuck-issue analysis, PR review | Opus | **Required** |
|
|
51
|
-
| `evolver` | PROJECT.md generation, context synthesis |
|
|
52
|
-
| `designer` | UI/UX specs, accessibility, design review |
|
|
53
|
-
| `developer` | Implementation, PRs, addressing feedback |
|
|
54
|
-
| `tester` | QA, Playwright, verification |
|
|
51
|
+
| `evolver` | PROJECT.md generation, context synthesis | Opus | N/A |
|
|
52
|
+
| `designer` | UI/UX specs, accessibility, design review | Opus | If UI changes |
|
|
53
|
+
| `developer` | Implementation, PRs, addressing feedback | Opus | N/A |
|
|
54
|
+
| `tester` | QA, Playwright, verification | Opus | **Required** |
|
|
55
55
|
|
|
56
56
|
**Note:** Commands handle orchestration. Agents are autonomous workers invoked by commands.
|
|
57
57
|
|
|
@@ -255,7 +255,7 @@ When the `/auto-work-issue` or `/auto-work-all` commands spawn agents, they:
|
|
|
255
255
|
3. **Read the agent's report** after the Task returns
|
|
256
256
|
4. **Include report summary** in the next agent's briefing
|
|
257
257
|
|
|
258
|
-
|
|
258
|
+
Claude Code auto-loads each agent's system prompt from `.claude/agents/{name}.md` when spawned with matching `subagent_type`. Agents follow a **briefing protocol**:
|
|
259
259
|
1. Read the briefing file first
|
|
260
260
|
2. Do their work
|
|
261
261
|
3. Write a report before completing
|
|
@@ -3,12 +3,17 @@ name: architect
|
|
|
3
3
|
description: Software Architect for system design, technical decisions, and code review. Use for reviewing discovery plans, reviewing PRs, or analyzing stuck issues. Required reviewer for all PRs.
|
|
4
4
|
tools: Read, Edit, Write, Grep, Glob, Bash, WebSearch
|
|
5
5
|
model: opus
|
|
6
|
+
skills:
|
|
7
|
+
- code-review
|
|
6
8
|
---
|
|
7
9
|
|
|
8
10
|
# Architect Agent
|
|
9
11
|
|
|
10
12
|
You are a senior Software Architect responsible for technical vision and structural integrity of the codebase.
|
|
11
13
|
|
|
14
|
+
## Project Context
|
|
15
|
+
If `.claude/agents/architect/PROJECT.md` exists, read it before starting any task. It contains project-specific context, conventions, and guidance tailored to your role.
|
|
16
|
+
|
|
12
17
|
## Responsibilities
|
|
13
18
|
|
|
14
19
|
1. **Discovery Review**: Review discovery plans for technical feasibility
|
|
@@ -9,6 +9,9 @@ model: opus
|
|
|
9
9
|
|
|
10
10
|
You are a UI/UX Designer responsible for creating intuitive, accessible, and visually coherent user experiences.
|
|
11
11
|
|
|
12
|
+
## Project Context
|
|
13
|
+
If `.claude/agents/designer/PROJECT.md` exists, read it before starting any task. It contains project-specific context, conventions, and guidance tailored to your role.
|
|
14
|
+
|
|
12
15
|
## Design Philosophy
|
|
13
16
|
|
|
14
17
|
When creating or reviewing designs, apply these principles:
|
|
@@ -3,12 +3,18 @@ name: developer
|
|
|
3
3
|
description: Developer persona for implementing features, fixing bugs, and writing code. Use when writing code, implementing designs, fixing issues, or creating pull requests.
|
|
4
4
|
tools: Read, Edit, Write, Bash, Grep, Glob
|
|
5
5
|
model: opus
|
|
6
|
+
skills:
|
|
7
|
+
- pr-writing
|
|
8
|
+
permissionMode: acceptEdits
|
|
6
9
|
---
|
|
7
10
|
|
|
8
11
|
# Developer Agent
|
|
9
12
|
|
|
10
13
|
You are a Software Developer responsible for implementing features, fixing bugs, and maintaining code quality.
|
|
11
14
|
|
|
15
|
+
## Project Context
|
|
16
|
+
If `.claude/agents/developer/PROJECT.md` exists, read it before starting any task. It contains project-specific context, conventions, and guidance tailored to your role.
|
|
17
|
+
|
|
12
18
|
## First Steps
|
|
13
19
|
|
|
14
20
|
Before writing code:
|
|
@@ -1,12 +1,18 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: tester
|
|
3
3
|
description: QA/Tester agent that EXECUTES browser tests using Playwright MCP. Does not write test plans - actually navigates, clicks, and verifies using mcp__playwright__* tools. Unit tests alone are NOT sufficient. Escalates if app cannot run.
|
|
4
|
-
tools: Read, Edit, Write, Bash, Grep, Glob
|
|
4
|
+
tools: Read, Edit, Write, Bash, Grep, Glob
|
|
5
5
|
model: opus
|
|
6
|
+
mcpServers:
|
|
7
|
+
playwright: {}
|
|
8
|
+
permissionMode: acceptEdits
|
|
6
9
|
---
|
|
7
10
|
|
|
8
11
|
# Tester Agent
|
|
9
12
|
|
|
13
|
+
## Project Context
|
|
14
|
+
If `.claude/agents/tester/PROJECT.md` exists, read it before starting any task. It contains project-specific context, conventions, and guidance tailored to your role.
|
|
15
|
+
|
|
10
16
|
## Your Role: QA Engineer (Not a Developer)
|
|
11
17
|
|
|
12
18
|
**You are a QA Engineer.** Your job is to TEST the software by actually using it - clicking buttons, filling forms, navigating pages, and verifying behavior.
|
|
@@ -223,16 +223,26 @@ After creating discovery.md, get feedback from specialist agents:
|
|
|
223
223
|
|
|
224
224
|
### Architect Review
|
|
225
225
|
```
|
|
226
|
-
Use the
|
|
227
|
-
|
|
228
|
-
|
|
226
|
+
Use the Task tool with:
|
|
227
|
+
subagent_type: "architect"
|
|
228
|
+
model: "opus"
|
|
229
|
+
description: "Architect review discovery plan"
|
|
230
|
+
prompt: |
|
|
231
|
+
Review this discovery plan for technical feasibility.
|
|
232
|
+
Focus on: architecture fit, scalability, security implications, technology choices.
|
|
233
|
+
The discovery plan is at: [path to discovery.md]
|
|
229
234
|
```
|
|
230
235
|
|
|
231
236
|
### Designer Review
|
|
232
237
|
```
|
|
233
|
-
Use the
|
|
234
|
-
|
|
235
|
-
|
|
238
|
+
Use the Task tool with:
|
|
239
|
+
subagent_type: "designer"
|
|
240
|
+
model: "opus"
|
|
241
|
+
description: "Designer review discovery plan"
|
|
242
|
+
prompt: |
|
|
243
|
+
Review this discovery plan for UI/UX considerations.
|
|
244
|
+
Focus on: user flows, accessibility, responsive design, missing UI requirements.
|
|
245
|
+
The discovery plan is at: [path to discovery.md]
|
|
236
246
|
```
|
|
237
247
|
|
|
238
248
|
Present the feedback to the user. Refine the discovery document based on feedback.
|
|
@@ -216,9 +216,8 @@ Agent: {role}
|
|
|
216
216
|
- PR created with "Closes #{number}"
|
|
217
217
|
|
|
218
218
|
3. Use Task tool with:
|
|
219
|
+
subagent_type: "developer"
|
|
219
220
|
prompt: |
|
|
220
|
-
You are the Developer agent. Load your role from .claude/agents/developer/AGENT.md
|
|
221
|
-
|
|
222
221
|
Read orchestration/issues/{number}-{slug}/BRIEFING-implement.md first.
|
|
223
222
|
|
|
224
223
|
After completing your work, write your report to:
|
|
@@ -254,9 +253,8 @@ Agent: {role}
|
|
|
254
253
|
- OR ❌ CHANGES REQUESTED - Architect
|
|
255
254
|
|
|
256
255
|
2. Use Task tool with:
|
|
256
|
+
subagent_type: "architect"
|
|
257
257
|
prompt: |
|
|
258
|
-
You are the Architect agent. Load your role from .claude/agents/architect/AGENT.md
|
|
259
|
-
|
|
260
258
|
Read orchestration/issues/{number}-{slug}/BRIEFING-architect-review.md first.
|
|
261
259
|
|
|
262
260
|
After completing your review, write your report to:
|
|
@@ -286,9 +284,8 @@ Agent: {role}
|
|
|
286
284
|
Post design specifications as issue comment following AGENT.md template.
|
|
287
285
|
|
|
288
286
|
2. Use Task tool with:
|
|
287
|
+
subagent_type: "designer"
|
|
289
288
|
prompt: |
|
|
290
|
-
You are the Designer agent. Load your role from .claude/agents/designer/AGENT.md
|
|
291
|
-
|
|
292
289
|
Read orchestration/issues/{number}-{slug}/BRIEFING-design-specs.md first.
|
|
293
290
|
|
|
294
291
|
After completing your specs, write your report to:
|
|
@@ -324,9 +321,8 @@ Agent: {role}
|
|
|
324
321
|
- OR N/A - No UI changes
|
|
325
322
|
|
|
326
323
|
2. Use Task tool with:
|
|
324
|
+
subagent_type: "designer"
|
|
327
325
|
prompt: |
|
|
328
|
-
You are the Designer agent. Load your role from .claude/agents/designer/AGENT.md
|
|
329
|
-
|
|
330
326
|
Read orchestration/issues/{number}-{slug}/BRIEFING-designer-review.md first.
|
|
331
327
|
|
|
332
328
|
After completing your review, write your report to:
|
|
@@ -362,9 +358,8 @@ Agent: {role}
|
|
|
362
358
|
- OR ❌ CHANGES REQUESTED - Tester
|
|
363
359
|
|
|
364
360
|
2. Use Task tool with:
|
|
361
|
+
subagent_type: "tester"
|
|
365
362
|
prompt: |
|
|
366
|
-
You are the Tester agent. Load your role from .claude/agents/tester/AGENT.md
|
|
367
|
-
|
|
368
363
|
Read orchestration/issues/{number}-{slug}/BRIEFING-test.md first.
|
|
369
364
|
|
|
370
365
|
After completing verification, write your report to:
|