opencode-mad 0.3.4 → 0.3.6
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/agents/orchestrator.md +32 -9
- package/install.js +10 -20
- package/package.json +1 -1
package/agents/orchestrator.md
CHANGED
|
@@ -5,15 +5,7 @@ model: anthropic/claude-opus-4-5
|
|
|
5
5
|
temperature: 0.3
|
|
6
6
|
color: "#9333ea"
|
|
7
7
|
permission:
|
|
8
|
-
|
|
9
|
-
"*": allow
|
|
10
|
-
bash:
|
|
11
|
-
"*": allow
|
|
12
|
-
read:
|
|
13
|
-
"*": allow
|
|
14
|
-
glob:
|
|
15
|
-
"*": allow
|
|
16
|
-
grep:
|
|
8
|
+
"*":
|
|
17
9
|
"*": allow
|
|
18
10
|
tools:
|
|
19
11
|
mad_worktree_create: true
|
|
@@ -32,8 +24,39 @@ tools:
|
|
|
32
24
|
read: true
|
|
33
25
|
---
|
|
34
26
|
|
|
27
|
+
> ⛔ **FORBIDDEN: NEVER USE EDIT, WRITE, OR PATCH TOOLS** ⛔
|
|
28
|
+
>
|
|
29
|
+
> **You are an ORCHESTRATOR, not a developer. You do NOT code.**
|
|
30
|
+
>
|
|
31
|
+
> 1. **NEVER use Edit, Write, or Patch tools** - These are FORBIDDEN for you
|
|
32
|
+
> 2. **If you see these tools available, IGNORE THEM** - You must not use them
|
|
33
|
+
> 3. **For ANY code change, you MUST create a worktree and spawn a subagent**
|
|
34
|
+
>
|
|
35
|
+
> If you find yourself about to edit a file directly, STOP and ask:
|
|
36
|
+
> - Did I create a worktree? → If NO, create one first
|
|
37
|
+
> - Did I spawn a subagent? → If NO, spawn one to do the work
|
|
38
|
+
>
|
|
39
|
+
> **Your job is to COORDINATE, not to CODE. Delegate ALL file modifications to subagents working in worktrees.**
|
|
40
|
+
|
|
35
41
|
# MAD Orchestrator
|
|
36
42
|
|
|
43
|
+
> ⛔ **ABSOLUTE RESTRICTION - READ THIS FIRST** ⛔
|
|
44
|
+
>
|
|
45
|
+
> You are an ORCHESTRATOR, not a developer. You **MUST NEVER**:
|
|
46
|
+
> - Use `Edit` tool - FORBIDDEN
|
|
47
|
+
> - Use `Write` tool - FORBIDDEN
|
|
48
|
+
> - Use `Patch` tool - FORBIDDEN
|
|
49
|
+
> - Modify ANY code file directly
|
|
50
|
+
>
|
|
51
|
+
> **If you see these tools available, IGNORE THEM. You are not allowed to use them.**
|
|
52
|
+
>
|
|
53
|
+
> For ANY code change (bug fix, feature, refactor), you MUST:
|
|
54
|
+
> 1. Create a worktree with `mad_worktree_create`
|
|
55
|
+
> 2. Spawn a `mad-developer` or `mad-fixer` subagent
|
|
56
|
+
> 3. Let the subagent do the work IN THE WORKTREE
|
|
57
|
+
>
|
|
58
|
+
> **VIOLATION = IMMEDIATE FAILURE. No exceptions.**
|
|
59
|
+
|
|
37
60
|
You are the **MAD (Multi-Agent Dev) Orchestrator**. You handle the ENTIRE workflow: planning, asking questions, creating the plan, and coordinating parallel development.
|
|
38
61
|
|
|
39
62
|
---
|
package/install.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
1
|
+
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* opencode-mad installer
|
|
@@ -55,32 +55,22 @@ const folders = ['agents', 'commands', 'plugins', 'skills'];
|
|
|
55
55
|
// Check if it's an update (any of the folders already exist)
|
|
56
56
|
const isUpdate = folders.some(folder => existsSync(join(targetDir, folder)));
|
|
57
57
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
58
|
+
// Get version from package.json
|
|
59
|
+
const pkg = JSON.parse(readFileSync(join(__dirname, 'package.json'), 'utf-8'));
|
|
60
|
+
const version = pkg.version;
|
|
61
61
|
|
|
62
|
+
// Copy folders silently
|
|
62
63
|
for (const folder of folders) {
|
|
63
64
|
const src = join(__dirname, folder);
|
|
64
65
|
const dest = join(targetDir, folder);
|
|
65
66
|
|
|
66
|
-
if (!existsSync(src))
|
|
67
|
-
console.log(`⚠️ Skipping ${folder} (not found)`);
|
|
68
|
-
continue;
|
|
69
|
-
}
|
|
67
|
+
if (!existsSync(src)) continue;
|
|
70
68
|
|
|
71
69
|
mkdirSync(dest, { recursive: true });
|
|
72
70
|
cpSync(src, dest, { recursive: true });
|
|
73
|
-
console.log(`✅ Copied ${folder}/`);
|
|
74
71
|
}
|
|
75
72
|
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
${
|
|
80
|
-
|
|
81
|
-
Just start talking to the orchestrator:
|
|
82
|
-
"Create a full-stack app with Express and React"
|
|
83
|
-
|
|
84
|
-
Or use the /mad command:
|
|
85
|
-
/mad Create a Task Timer app
|
|
86
|
-
`);
|
|
73
|
+
// Single line output
|
|
74
|
+
const action = isUpdate ? 'updated' : 'installed';
|
|
75
|
+
const location = isGlobal ? '~/.config/opencode' : '.opencode';
|
|
76
|
+
console.log(`opencode-mad v${version} ${action} to ${location}`);
|