agent-orchestration 0.5.0 → 0.6.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/.cursor/rules/orchestrator-auto.mdc +2 -0
- package/.cursor/rules/orchestrator-main.mdc +37 -7
- package/.cursor/rules/orchestrator-sub.mdc +89 -27
- package/README.md +278 -66
- package/dist/bin/cli.d.ts +1 -0
- package/dist/bin/cli.d.ts.map +1 -1
- package/dist/bin/cli.js +54 -157
- package/dist/bin/cli.js.map +1 -1
- package/dist/bin/cursorCommands.d.ts +3 -0
- package/dist/bin/cursorCommands.d.ts.map +1 -0
- package/dist/bin/cursorCommands.js +330 -0
- package/dist/bin/cursorCommands.js.map +1 -0
- package/dist/database.d.ts +32 -1
- package/dist/database.d.ts.map +1 -1
- package/dist/database.js +105 -5
- package/dist/database.js.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +6 -2
- package/dist/index.js.map +1 -1
- package/dist/models.d.ts +59 -0
- package/dist/models.d.ts.map +1 -1
- package/dist/models.js +69 -0
- package/dist/models.js.map +1 -1
- package/dist/providers/cursor.d.ts +14 -0
- package/dist/providers/cursor.d.ts.map +1 -0
- package/dist/providers/cursor.js +203 -0
- package/dist/providers/cursor.js.map +1 -0
- package/dist/providers/types.d.ts +60 -0
- package/dist/providers/types.d.ts.map +1 -0
- package/dist/providers/types.js +2 -0
- package/dist/providers/types.js.map +1 -0
- package/dist/tools/agent.d.ts.map +1 -1
- package/dist/tools/agent.js +5 -0
- package/dist/tools/agent.js.map +1 -1
- package/dist/tools/coordination.d.ts.map +1 -1
- package/dist/tools/coordination.js +47 -0
- package/dist/tools/coordination.js.map +1 -1
- package/dist/tools/index.d.ts +3 -0
- package/dist/tools/index.d.ts.map +1 -1
- package/dist/tools/index.js +3 -0
- package/dist/tools/index.js.map +1 -1
- package/dist/tools/memory.d.ts.map +1 -1
- package/dist/tools/memory.js +6 -1
- package/dist/tools/memory.js.map +1 -1
- package/dist/tools/provider.d.ts +3 -0
- package/dist/tools/provider.d.ts.map +1 -0
- package/dist/tools/provider.js +403 -0
- package/dist/tools/provider.js.map +1 -0
- package/dist/tools/proxy.d.ts +6 -0
- package/dist/tools/proxy.d.ts.map +1 -0
- package/dist/tools/proxy.js +107 -0
- package/dist/tools/proxy.js.map +1 -0
- package/dist/tools/research.d.ts +9 -0
- package/dist/tools/research.d.ts.map +1 -0
- package/dist/tools/research.js +182 -0
- package/dist/tools/research.js.map +1 -0
- package/dist/tools/task.d.ts.map +1 -1
- package/dist/tools/task.js +98 -9
- package/dist/tools/task.js.map +1 -1
- package/dist/tools/utility.d.ts.map +1 -1
- package/dist/tools/utility.js +85 -16
- package/dist/tools/utility.js.map +1 -1
- package/dist/utils/autoDocumentation.d.ts +8 -0
- package/dist/utils/autoDocumentation.d.ts.map +1 -0
- package/dist/utils/autoDocumentation.js +140 -0
- package/dist/utils/autoDocumentation.js.map +1 -0
- package/dist/utils/autoDocumentation.test.d.ts +2 -0
- package/dist/utils/autoDocumentation.test.d.ts.map +1 -0
- package/dist/utils/autoDocumentation.test.js +47 -0
- package/dist/utils/autoDocumentation.test.js.map +1 -0
- package/dist/utils/contextSync.d.ts.map +1 -1
- package/dist/utils/contextSync.js +21 -1
- package/dist/utils/contextSync.js.map +1 -1
- package/dist/utils/cursorCli.d.ts +46 -0
- package/dist/utils/cursorCli.d.ts.map +1 -0
- package/dist/utils/cursorCli.js +176 -0
- package/dist/utils/cursorCli.js.map +1 -0
- package/dist/utils/cursorCli.test.d.ts +2 -0
- package/dist/utils/cursorCli.test.d.ts.map +1 -0
- package/dist/utils/cursorCli.test.js +134 -0
- package/dist/utils/cursorCli.test.js.map +1 -0
- package/dist/utils/delegatedTaskRuntime.d.ts +45 -0
- package/dist/utils/delegatedTaskRuntime.d.ts.map +1 -0
- package/dist/utils/delegatedTaskRuntime.js +147 -0
- package/dist/utils/delegatedTaskRuntime.js.map +1 -0
- package/dist/utils/delegationKnowledge.d.ts +51 -0
- package/dist/utils/delegationKnowledge.d.ts.map +1 -0
- package/dist/utils/delegationKnowledge.js +197 -0
- package/dist/utils/delegationKnowledge.js.map +1 -0
- package/dist/utils/delegationRecovery.d.ts +17 -0
- package/dist/utils/delegationRecovery.d.ts.map +1 -0
- package/dist/utils/delegationRecovery.js +63 -0
- package/dist/utils/delegationRecovery.js.map +1 -0
- package/dist/utils/delegationRecovery.test.d.ts +2 -0
- package/dist/utils/delegationRecovery.test.d.ts.map +1 -0
- package/dist/utils/delegationRecovery.test.js +42 -0
- package/dist/utils/delegationRecovery.test.js.map +1 -0
- package/dist/utils/orchestratorConfig.d.ts +19 -0
- package/dist/utils/orchestratorConfig.d.ts.map +1 -0
- package/dist/utils/orchestratorConfig.js +38 -0
- package/dist/utils/orchestratorConfig.js.map +1 -0
- package/dist/utils/subprocess.d.ts +27 -0
- package/dist/utils/subprocess.d.ts.map +1 -0
- package/dist/utils/subprocess.js +84 -0
- package/dist/utils/subprocess.js.map +1 -0
- package/package.json +17 -5
- package/templates/AGENTS.md +164 -0
- package/activeContext.md +0 -37
- package/src/bin/cli.ts +0 -430
- package/src/database.ts +0 -764
- package/src/index.ts +0 -71
- package/src/models.ts +0 -226
- package/src/tools/agent.ts +0 -241
- package/src/tools/coordination.ts +0 -152
- package/src/tools/index.ts +0 -9
- package/src/tools/memory.ts +0 -150
- package/src/tools/task.ts +0 -334
- package/src/tools/utility.ts +0 -202
- package/src/utils/contextSync.ts +0 -144
- package/tsconfig.json +0 -20
|
@@ -17,6 +17,8 @@ This project uses **Agent Orchestration**. You MUST follow these rules.
|
|
|
17
17
|
bootstrap
|
|
18
18
|
```
|
|
19
19
|
|
|
20
|
+
**Important**: `bootstrap` is an MCP tool invocation inside your agent/IDE, not a terminal command.
|
|
21
|
+
|
|
20
22
|
This registers you with the orchestrator and shows you:
|
|
21
23
|
- Current project focus
|
|
22
24
|
- Tasks assigned to you
|
|
@@ -13,12 +13,13 @@ You are the **main orchestrator agent** in a multi-agent coordination system. Fo
|
|
|
13
13
|
**IMMEDIATELY** when starting any task, register yourself:
|
|
14
14
|
|
|
15
15
|
```
|
|
16
|
-
|
|
16
|
+
bootstrap:
|
|
17
17
|
name: "main-orchestrator"
|
|
18
18
|
role: "main"
|
|
19
|
-
capabilities: ["planning", "coordination", "review"]
|
|
20
19
|
```
|
|
21
20
|
|
|
21
|
+
**Important**: `bootstrap` is an MCP tool invocation inside your agent/IDE, not a terminal command.
|
|
22
|
+
|
|
22
23
|
## Your Responsibilities
|
|
23
24
|
|
|
24
25
|
1. **Set the Focus** - Always set the current focus so other agents know what we're working on:
|
|
@@ -35,7 +36,7 @@ agent_register:
|
|
|
35
36
|
title: "<clear task title>"
|
|
36
37
|
description: "<detailed requirements>"
|
|
37
38
|
priority: "normal" | "high" | "urgent"
|
|
38
|
-
|
|
39
|
+
complexity: "trivial" | "simple" | "moderate" | "complex" (optional, auto-detected)
|
|
39
40
|
```
|
|
40
41
|
|
|
41
42
|
3. **Store Decisions** - Document architectural decisions:
|
|
@@ -52,9 +53,22 @@ agent_register:
|
|
|
52
53
|
task_list
|
|
53
54
|
```
|
|
54
55
|
|
|
56
|
+
## Task Complexity Guidelines
|
|
57
|
+
|
|
58
|
+
When creating tasks, consider the appropriate complexity:
|
|
59
|
+
|
|
60
|
+
| Complexity | Use For | Research Required |
|
|
61
|
+
|------------|---------|-------------------|
|
|
62
|
+
| `trivial` | Typo fixes, config changes | None |
|
|
63
|
+
| `simple` | Bug fixes, small refactors | context, files |
|
|
64
|
+
| `moderate` | New endpoints, components | + requirements |
|
|
65
|
+
| `complex` | New features, migrations | + design |
|
|
66
|
+
|
|
67
|
+
Complexity is auto-detected from keywords, but you can override it.
|
|
68
|
+
|
|
55
69
|
## Workflow
|
|
56
70
|
|
|
57
|
-
1. Register yourself
|
|
71
|
+
1. Register yourself with `bootstrap`
|
|
58
72
|
2. Check `coordination_status` to see current state
|
|
59
73
|
3. Set `context:current_focus` with the goal
|
|
60
74
|
4. Create tasks for work that needs to be done
|
|
@@ -75,12 +89,28 @@ This prevents contradicting decisions made by other agents.
|
|
|
75
89
|
## When Delegating
|
|
76
90
|
|
|
77
91
|
1. Create a clear task with `task_create`
|
|
78
|
-
2.
|
|
79
|
-
3.
|
|
80
|
-
4.
|
|
92
|
+
2. Set appropriate complexity for research requirements
|
|
93
|
+
3. Optionally assign to a specific sub-agent
|
|
94
|
+
4. Wait for task completion before creating dependent tasks
|
|
95
|
+
5. Use task dependencies when order matters
|
|
96
|
+
|
|
97
|
+
## Reviewing Research
|
|
98
|
+
|
|
99
|
+
Before approving implementation, check sub-agent research:
|
|
100
|
+
```
|
|
101
|
+
research_status:
|
|
102
|
+
task_id: "<task_id>"
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
Search past research for relevant context:
|
|
106
|
+
```
|
|
107
|
+
research_query:
|
|
108
|
+
query: "<search term>"
|
|
109
|
+
```
|
|
81
110
|
|
|
82
111
|
## Communication Pattern
|
|
83
112
|
|
|
84
113
|
- Use `memory_set` in namespace `context` for current state
|
|
85
114
|
- Use `memory_set` in namespace `blockers` for issues
|
|
115
|
+
- Use `memory_set` in namespace `decisions` for architectural choices
|
|
86
116
|
- Check `agent_list` to see who's available
|
|
@@ -19,59 +19,120 @@ claim_todo:
|
|
|
19
19
|
description: "<details if any>"
|
|
20
20
|
```
|
|
21
21
|
|
|
22
|
+
**Important**: tool calls like `claim_todo` / `bootstrap` are MCP tool invocations inside your agent/IDE, not terminal commands.
|
|
23
|
+
|
|
22
24
|
**DO NOT start coding until you have claimed your task.**
|
|
23
25
|
|
|
24
26
|
This:
|
|
25
27
|
1. Registers you with the orchestrator
|
|
26
28
|
2. Creates the task if it doesn't exist
|
|
27
|
-
3.
|
|
28
|
-
4.
|
|
29
|
+
3. Assigns it to you
|
|
30
|
+
4. Shows you the **research checklist** based on task complexity
|
|
29
31
|
|
|
30
32
|
---
|
|
31
33
|
|
|
32
|
-
##
|
|
34
|
+
## 🔬 Research-First Workflow
|
|
35
|
+
|
|
36
|
+
After claiming, you'll see a research checklist based on task complexity:
|
|
37
|
+
|
|
38
|
+
| Complexity | Research Required |
|
|
39
|
+
|------------|-------------------|
|
|
40
|
+
| `trivial` | None - start immediately |
|
|
41
|
+
| `simple` | context, files |
|
|
42
|
+
| `moderate` | context, files, requirements |
|
|
43
|
+
| `complex` | context, files, requirements, design |
|
|
33
44
|
|
|
34
|
-
|
|
45
|
+
### For Non-Trivial Tasks
|
|
46
|
+
|
|
47
|
+
**BEFORE coding**, document your research:
|
|
48
|
+
|
|
49
|
+
1. **Context** - Understand the current state:
|
|
35
50
|
```
|
|
36
|
-
|
|
37
|
-
key: "
|
|
38
|
-
|
|
51
|
+
memory_set:
|
|
52
|
+
key: "understanding"
|
|
53
|
+
value: "<what you learned about the codebase>"
|
|
54
|
+
namespace: "research:<task_id>:context"
|
|
39
55
|
```
|
|
40
56
|
|
|
41
|
-
2. **
|
|
57
|
+
2. **Files** - Identify affected files:
|
|
42
58
|
```
|
|
43
|
-
|
|
44
|
-
|
|
59
|
+
memory_set:
|
|
60
|
+
key: "affected_files"
|
|
61
|
+
value: "<list of files you'll modify>"
|
|
62
|
+
namespace: "research:<task_id>:files"
|
|
45
63
|
```
|
|
46
64
|
|
|
47
|
-
3. **
|
|
65
|
+
3. **Requirements** (moderate/complex):
|
|
48
66
|
```
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
67
|
+
memory_set:
|
|
68
|
+
key: "specs"
|
|
69
|
+
value: "<requirements, acceptance criteria, edge cases>"
|
|
70
|
+
namespace: "research:<task_id>:requirements"
|
|
52
71
|
```
|
|
53
72
|
|
|
54
|
-
|
|
73
|
+
4. **Design** (complex only):
|
|
74
|
+
```
|
|
75
|
+
memory_set:
|
|
76
|
+
key: "architecture"
|
|
77
|
+
value: "<design decisions, component structure>"
|
|
78
|
+
namespace: "research:<task_id>:design"
|
|
79
|
+
```
|
|
55
80
|
|
|
56
|
-
|
|
81
|
+
### Mark Research Complete
|
|
82
|
+
|
|
83
|
+
When all items are documented:
|
|
57
84
|
|
|
58
|
-
Update progress periodically:
|
|
59
85
|
```
|
|
60
|
-
|
|
86
|
+
research_ready:
|
|
61
87
|
task_id: "<your_task_id>"
|
|
62
|
-
progress: 50
|
|
63
88
|
```
|
|
64
89
|
|
|
65
|
-
|
|
90
|
+
### Then Start Implementation
|
|
91
|
+
|
|
66
92
|
```
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
value: "<details>"
|
|
70
|
-
namespace: "findings"
|
|
93
|
+
task_claim:
|
|
94
|
+
task_id: "<your_task_id>"
|
|
71
95
|
```
|
|
72
96
|
|
|
73
97
|
---
|
|
74
98
|
|
|
99
|
+
## Check Research Status
|
|
100
|
+
|
|
101
|
+
To see what's done and what's missing:
|
|
102
|
+
|
|
103
|
+
```
|
|
104
|
+
research_status:
|
|
105
|
+
task_id: "<your_task_id>"
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
---
|
|
109
|
+
|
|
110
|
+
## While Working
|
|
111
|
+
|
|
112
|
+
1. **Lock files** before editing:
|
|
113
|
+
```
|
|
114
|
+
lock_acquire:
|
|
115
|
+
resource: "<file_path>"
|
|
116
|
+
reason: "<what you're doing>"
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
2. **Update progress** periodically:
|
|
120
|
+
```
|
|
121
|
+
task_update:
|
|
122
|
+
task_id: "<your_task_id>"
|
|
123
|
+
progress: 50
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
3. **Store findings** for others:
|
|
127
|
+
```
|
|
128
|
+
memory_set:
|
|
129
|
+
key: "<finding>"
|
|
130
|
+
value: "<details>"
|
|
131
|
+
namespace: "findings"
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
---
|
|
135
|
+
|
|
75
136
|
## When Done
|
|
76
137
|
|
|
77
138
|
1. Complete the task:
|
|
@@ -109,6 +170,7 @@ memory_set:
|
|
|
109
170
|
## Important Rules
|
|
110
171
|
|
|
111
172
|
1. **ALWAYS claim your task first** with `claim_todo`
|
|
112
|
-
2. **ALWAYS
|
|
113
|
-
3. **ALWAYS
|
|
114
|
-
4. **
|
|
173
|
+
2. **ALWAYS complete research** before implementation (non-trivial tasks)
|
|
174
|
+
3. **ALWAYS lock files** before editing shared resources
|
|
175
|
+
4. **ALWAYS complete your task** when done
|
|
176
|
+
5. **Check shared memory** before making decisions that affect others
|