opencode-orchestrator 0.5.17 → 0.5.19

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/dist/index.d.ts CHANGED
@@ -10,191 +10,6 @@
10
10
  *
11
11
  * The agents are: Commander, Architect, Builder, Inspector, Recorder
12
12
  */
13
- import type { PluginInput } from "@opencode-ai/plugin";
14
- declare const OrchestratorPlugin: (input: PluginInput) => Promise<{
15
- tool: {
16
- call_agent: {
17
- description: string;
18
- args: {
19
- agent: import("zod").ZodEnum<{
20
- architect: "architect";
21
- builder: "builder";
22
- inspector: "inspector";
23
- recorder: "recorder";
24
- }>;
25
- task: import("zod").ZodString;
26
- context: import("zod").ZodOptional<import("zod").ZodString>;
27
- };
28
- execute(args: {
29
- agent: "architect" | "builder" | "inspector" | "recorder";
30
- task: string;
31
- context?: string | undefined;
32
- }, context: import("@opencode-ai/plugin").ToolContext): Promise<string>;
33
- };
34
- slashcommand: {
35
- description: string;
36
- args: {
37
- command: import("zod").ZodString;
38
- };
39
- execute(args: {
40
- command: string;
41
- }, context: import("@opencode-ai/plugin").ToolContext): Promise<string>;
42
- };
43
- grep_search: {
44
- description: string;
45
- args: {
46
- pattern: import("zod").ZodString;
47
- dir: import("zod").ZodOptional<import("zod").ZodString>;
48
- };
49
- execute(args: {
50
- pattern: string;
51
- dir?: string | undefined;
52
- }, context: import("@opencode-ai/plugin").ToolContext): Promise<string>;
53
- };
54
- glob_search: {
55
- description: string;
56
- args: {
57
- pattern: import("zod").ZodString;
58
- dir: import("zod").ZodOptional<import("zod").ZodString>;
59
- };
60
- execute(args: {
61
- pattern: string;
62
- dir?: string | undefined;
63
- }, context: import("@opencode-ai/plugin").ToolContext): Promise<string>;
64
- };
65
- mgrep: {
66
- description: string;
67
- args: {
68
- patterns: import("zod").ZodArray<import("zod").ZodString>;
69
- dir: import("zod").ZodOptional<import("zod").ZodString>;
70
- };
71
- execute(args: {
72
- patterns: string[];
73
- dir?: string | undefined;
74
- }, context: import("@opencode-ai/plugin").ToolContext): Promise<string>;
75
- };
76
- run_background: {
77
- description: string;
78
- args: {
79
- command: import("zod").ZodString;
80
- cwd: import("zod").ZodOptional<import("zod").ZodString>;
81
- timeout: import("zod").ZodOptional<import("zod").ZodNumber>;
82
- label: import("zod").ZodOptional<import("zod").ZodString>;
83
- };
84
- execute(args: {
85
- command: string;
86
- cwd?: string | undefined;
87
- timeout?: number | undefined;
88
- label?: string | undefined;
89
- }, context: import("@opencode-ai/plugin").ToolContext): Promise<string>;
90
- };
91
- check_background: {
92
- description: string;
93
- args: {
94
- taskId: import("zod").ZodString;
95
- tailLines: import("zod").ZodOptional<import("zod").ZodNumber>;
96
- };
97
- execute(args: {
98
- taskId: string;
99
- tailLines?: number | undefined;
100
- }, context: import("@opencode-ai/plugin").ToolContext): Promise<string>;
101
- };
102
- list_background: {
103
- description: string;
104
- args: {
105
- status: import("zod").ZodOptional<import("zod").ZodEnum<{
106
- running: "running";
107
- error: "error";
108
- done: "done";
109
- all: "all";
110
- }>>;
111
- };
112
- execute(args: {
113
- status?: "running" | "error" | "done" | "all" | undefined;
114
- }, context: import("@opencode-ai/plugin").ToolContext): Promise<string>;
115
- };
116
- kill_background: {
117
- description: string;
118
- args: {
119
- taskId: import("zod").ZodString;
120
- };
121
- execute(args: {
122
- taskId: string;
123
- }, context: import("@opencode-ai/plugin").ToolContext): Promise<string>;
124
- };
125
- webfetch: {
126
- description: string;
127
- args: {
128
- url: import("zod").ZodString;
129
- cache: import("zod").ZodOptional<import("zod").ZodBoolean>;
130
- selector: import("zod").ZodOptional<import("zod").ZodString>;
131
- };
132
- execute(args: {
133
- url: string;
134
- cache?: boolean | undefined;
135
- selector?: string | undefined;
136
- }, context: import("@opencode-ai/plugin").ToolContext): Promise<string>;
137
- };
138
- websearch: {
139
- description: string;
140
- args: {
141
- query: import("zod").ZodString;
142
- maxResults: import("zod").ZodOptional<import("zod").ZodNumber>;
143
- };
144
- execute(args: {
145
- query: string;
146
- maxResults?: number | undefined;
147
- }, context: import("@opencode-ai/plugin").ToolContext): Promise<string>;
148
- };
149
- cache_docs: {
150
- description: string;
151
- args: {
152
- action: import("zod").ZodEnum<{
153
- list: "list";
154
- get: "get";
155
- clear: "clear";
156
- stats: "stats";
157
- }>;
158
- filename: import("zod").ZodOptional<import("zod").ZodString>;
159
- };
160
- execute(args: {
161
- action: "list" | "get" | "clear" | "stats";
162
- filename?: string | undefined;
163
- }, context: import("@opencode-ai/plugin").ToolContext): Promise<string>;
164
- };
165
- codesearch: {
166
- description: string;
167
- args: {
168
- query: import("zod").ZodString;
169
- language: import("zod").ZodOptional<import("zod").ZodString>;
170
- repo: import("zod").ZodOptional<import("zod").ZodString>;
171
- };
172
- execute(args: {
173
- query: string;
174
- language?: string | undefined;
175
- repo?: string | undefined;
176
- }, context: import("@opencode-ai/plugin").ToolContext): Promise<string>;
177
- };
178
- };
179
- config: (config: Record<string, unknown>) => Promise<void>;
180
- "chat.message": (msgInput: any, msgOutput: any) => Promise<void>;
181
- "tool.execute.after": (toolInput: {
182
- tool: string;
183
- sessionID: string;
184
- callID: string;
185
- arguments?: any;
186
- }, toolOutput: {
187
- title: string;
188
- output: string;
189
- metadata: any;
190
- }) => Promise<void>;
191
- "assistant.done": (assistantInput: any, assistantOutput: any) => Promise<void>;
192
- handler: ({ event }: {
193
- event: {
194
- type: string;
195
- properties?: unknown;
196
- };
197
- }) => Promise<void>;
198
- }>;
199
- export { OrchestratorPlugin };
13
+ import type { Plugin } from "@opencode-ai/plugin";
14
+ declare const OrchestratorPlugin: Plugin;
200
15
  export default OrchestratorPlugin;
package/dist/index.js CHANGED
@@ -16472,17 +16472,20 @@ var OrchestratorPlugin = async (input) => {
16472
16472
  [AGENT_NAMES.COMMANDER]: {
16473
16473
  name: AGENT_NAMES.COMMANDER,
16474
16474
  description: "Autonomous orchestrator - executes until mission complete",
16475
- systemPrompt: AGENTS.commander.systemPrompt
16475
+ mode: "primary",
16476
+ prompt: AGENTS.commander.systemPrompt,
16477
+ thinking: { type: "enabled", budgetTokens: 32e3 },
16478
+ color: "#FF6B6B"
16476
16479
  },
16477
16480
  [AGENT_NAMES.LIBRARIAN]: {
16478
16481
  name: AGENT_NAMES.LIBRARIAN,
16479
16482
  description: "Documentation research specialist - reduces hallucination",
16480
- systemPrompt: AGENTS.librarian?.systemPrompt || ""
16483
+ prompt: AGENTS.librarian?.systemPrompt || ""
16481
16484
  },
16482
16485
  [AGENT_NAMES.RESEARCHER]: {
16483
16486
  name: AGENT_NAMES.RESEARCHER,
16484
16487
  description: "Pre-task investigation - gathers all info before implementation",
16485
- systemPrompt: AGENTS.researcher?.systemPrompt || ""
16488
+ prompt: AGENTS.researcher?.systemPrompt || ""
16486
16489
  }
16487
16490
  };
16488
16491
  config2.command = { ...orchestratorCommands, ...existingCommands };
@@ -16762,8 +16765,10 @@ ${stateSession.graph.getTaskSummary()}`;
16762
16765
  },
16763
16766
  // -----------------------------------------------------------------
16764
16767
  // Event handler - cleans up when sessions are deleted
16768
+ // Uses 'event' hook (not 'handler') to match oh-my-opencode pattern
16765
16769
  // -----------------------------------------------------------------
16766
- handler: async ({ event }) => {
16770
+ event: async (input2) => {
16771
+ const { event } = input2;
16767
16772
  try {
16768
16773
  const manager = ParallelAgentManager.getInstance();
16769
16774
  manager.handleEvent(event);
@@ -16783,6 +16788,5 @@ ${stateSession.graph.getTaskSummary()}`;
16783
16788
  };
16784
16789
  var index_default = OrchestratorPlugin;
16785
16790
  export {
16786
- OrchestratorPlugin,
16787
16791
  index_default as default
16788
16792
  };
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "opencode-orchestrator",
3
3
  "displayName": "OpenCode Orchestrator",
4
4
  "description": "Distributed Cognitive Architecture for OpenCode. Turns simple prompts into specialized multi-agent workflows (Planner, Coder, Reviewer).",
5
- "version": "0.5.17",
5
+ "version": "0.5.19",
6
6
  "author": "agnusdei1207",
7
7
  "license": "MIT",
8
8
  "repository": {
@@ -57,8 +57,8 @@
57
57
  "dev:status": "echo '=== NVM ===' && ls -la $(npm root -g)/opencode-orchestrator 2>/dev/null || echo 'Not linked'; echo '=== Homebrew ===' && ls -la /opt/homebrew/lib/node_modules/opencode-orchestrator 2>/dev/null || echo 'Not linked'",
58
58
  "dev:test": "node dist/scripts/postinstall.js && echo '---' && node dist/scripts/preuninstall.js",
59
59
  "dev:cache": "npm run build && rm -rf ~/.cache/opencode/node_modules/opencode-orchestrator && cp -r . ~/.cache/opencode/node_modules/opencode-orchestrator && echo 'SUCCESS: Copied to OpenCode cache. Restart OpenCode.'",
60
- "reset:local": "npm run dev:unlink || true && npm uninstall -g opencode-orchestrator 2>/dev/null; /opt/homebrew/bin/npm uninstall -g opencode-orchestrator 2>/dev/null; brew uninstall opencode 2>/dev/null; rm -rf ~/.config/opencode ~/.opencode ~/.local/share/opencode && echo '=== Clean done ===' && brew install opencode && npm run dev:link && echo '=== Reset (Dev) complete ==='",
61
- "reset:prod": "npm run dev:unlink || true && npm uninstall -g opencode-orchestrator 2>/dev/null; /opt/homebrew/bin/npm uninstall -g opencode-orchestrator 2>/dev/null; brew uninstall opencode 2>/dev/null; rm -rf ~/.config/opencode ~/.opencode ~/.local/share/opencode && echo '=== Clean done ===' && brew install opencode && /opt/homebrew/bin/npm install -g opencode-orchestrator && echo '=== Reset (Prod) complete ==='"
60
+ "reset:local": "brew uninstall opencode 2>/dev/null; rm -rf ~/.config/opencode ~/.opencode ~/.local/share/opencode ~/.cache/opencode/node_modules/opencode-orchestrator && echo '=== Clean done ===' && brew install opencode && echo '{\"plugin\": [\"opencode-orchestrator\"], \"$schema\": \"https://opencode.ai/config.json\"}' > ~/.config/opencode/opencode.json && echo '=== Reset (Dev) complete. Run: opencode ==='",
61
+ "reset:prod": "brew uninstall opencode 2>/dev/null; rm -rf ~/.config/opencode ~/.opencode ~/.local/share/opencode ~/.cache/opencode/node_modules/opencode-orchestrator && echo '=== Clean done ===' && brew install opencode && echo '{\"plugin\": [\"opencode-orchestrator\"], \"$schema\": \"https://opencode.ai/config.json\"}' > ~/.config/opencode/opencode.json && echo '=== Reset (Prod) complete. Run: opencode ==='"
62
62
  },
63
63
  "dependencies": {
64
64
  "@opencode-ai/plugin": "^1.1.1",