@hueyexe/opencode-ensemble 0.6.0 → 0.6.1

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.js CHANGED
@@ -1,12 +1,16 @@
1
1
  // @bun
2
2
  var __defProp = Object.defineProperty;
3
+ var __returnValue = (v) => v;
4
+ function __exportSetter(name, newValue) {
5
+ this[name] = __returnValue.bind(null, newValue);
6
+ }
3
7
  var __export = (target, all) => {
4
8
  for (var name in all)
5
9
  __defProp(target, name, {
6
10
  get: all[name],
7
11
  enumerable: true,
8
12
  configurable: true,
9
- set: (newValue) => all[name] = () => newValue
13
+ set: __exportSetter.bind(all, name)
10
14
  });
11
15
  };
12
16
 
@@ -15283,7 +15287,7 @@ class OpencodeClient extends HeyApiClient {
15283
15287
  }
15284
15288
  }
15285
15289
  // src/index.ts
15286
- import path3 from "path";
15290
+ import path2 from "path";
15287
15291
  import { mkdirSync } from "fs";
15288
15292
 
15289
15293
  // src/db.ts
@@ -15749,6 +15753,8 @@ function buildLeadSystemPrompt(db, teamId) {
15749
15753
  "",
15750
15754
  "Teammates work asynchronously and message you when done.",
15751
15755
  "Do NOT poll team_status or team_tasks_list repeatedly \u2014 wait for messages.",
15756
+ "Spawn teammates ONE at a time \u2014 do not send multiple team_spawn calls in a single response.",
15757
+ "After each team_spawn, verify the output confirms the spawn succeeded before spawning the next.",
15752
15758
  "After spawning teammates, tell the user what you've set up and wait.",
15753
15759
  "When all teammates finish, summarize results and suggest next steps."
15754
15760
  ].join(`
@@ -15824,7 +15830,6 @@ async function executeTeamCreate(deps, args, sessionId) {
15824
15830
  }
15825
15831
 
15826
15832
  // src/tools/team-spawn.ts
15827
- import path2 from "path";
15828
15833
  async function executeTeamSpawn(deps, args, sessionId) {
15829
15834
  const nameError = validateMemberName(args.name);
15830
15835
  if (nameError)
@@ -15908,16 +15913,6 @@ async function executeTeamSpawn(deps, args, sessionId) {
15908
15913
  context.push("", "IMPORTANT: You are in PLAN MODE.", "Read and explore the codebase, then send your implementation plan to the lead via team_message.", "Do NOT write or modify any files until the lead approves your plan.", "Wait for the lead's approval message before proceeding with implementation.");
15909
15914
  }
15910
15915
  context.push("", "Tools available to you:", "- team_message: send a message to the lead or another teammate", "- team_broadcast: send a message to all team members", "- team_tasks_list: view the shared team task board", "- team_tasks_add: add tasks to the shared board", "- team_tasks_complete: mark a task complete on the shared board", "- team_claim: claim a pending task from the shared board", "", "When you finish your task:", "1. If you claimed a task, mark it complete using team_tasks_complete.", "2. Send ONE message to the lead with your findings using team_message.", "3. STOP. Do not send follow-up confirmations, status updates, or 'standing by' messages.", "", "If you are blocked, send ONE message to the lead describing the specific blocker.", "", "Your plain text output is NOT visible to the team. You MUST use team_message to communicate.");
15911
- try {
15912
- const agentsPath = path2.join(deps.directory, "AGENTS.md");
15913
- const file2 = Bun.file(agentsPath);
15914
- if (await file2.exists()) {
15915
- const content = await file2.text();
15916
- const truncated = content.length > 2000 ? content.slice(0, 2000) + `
15917
- ...(truncated)` : content;
15918
- context.push("", "Project guidelines (from AGENTS.md):", truncated);
15919
- }
15920
- } catch {}
15921
15916
  context.push("", "Your task:", args.prompt);
15922
15917
  if (args.claim_task) {
15923
15918
  context.push("", `You have been assigned task ${args.claim_task}. Mark it complete when done.`);
@@ -16446,7 +16441,7 @@ var DEFAULT_WATCHDOG_TTL_MS = 30 * 60 * 1000;
16446
16441
  var DEFAULT_WATCHDOG_CHECK_MS = 60 * 1000;
16447
16442
  var plugin = async (input) => {
16448
16443
  const dbPath = getDbPath();
16449
- mkdirSync(path3.dirname(dbPath), { recursive: true });
16444
+ mkdirSync(path2.dirname(dbPath), { recursive: true });
16450
16445
  const db = createDb(dbPath);
16451
16446
  const registry2 = new MemberRegistry;
16452
16447
  const tracker = new DescendantTracker;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hueyexe/opencode-ensemble",
3
- "version": "0.6.0",
3
+ "version": "0.6.1",
4
4
  "description": "Agent teams for OpenCode — parallel agents with peer-to-peer communication, shared tasks, and coordinated execution",
5
5
  "module": "src/index.ts",
6
6
  "main": "dist/index.js",
@@ -47,6 +47,8 @@ export function buildLeadSystemPrompt(db: Database, teamId: string): string {
47
47
  "",
48
48
  "Teammates work asynchronously and message you when done.",
49
49
  "Do NOT poll team_status or team_tasks_list repeatedly — wait for messages.",
50
+ "Spawn teammates ONE at a time — do not send multiple team_spawn calls in a single response.",
51
+ "After each team_spawn, verify the output confirms the spawn succeeded before spawning the next.",
50
52
  "After spawning teammates, tell the user what you've set up and wait.",
51
53
  "When all teammates finish, summarize results and suggest next steps.",
52
54
  ].join("\n")
@@ -1,7 +1,6 @@
1
1
  import type { ToolDeps, PermissionRule } from "../types"
2
2
  import { generateId, validateMemberName } from "../util"
3
3
  import { findTeamBySession } from "../types"
4
- import path from "path"
5
4
 
6
5
  /**
7
6
  * Execute the team_spawn tool. Creates a child session and starts a teammate.
@@ -145,17 +144,6 @@ export async function executeTeamSpawn(
145
144
  "Your plain text output is NOT visible to the team. You MUST use team_message to communicate.",
146
145
  )
147
146
 
148
- // Load project AGENTS.md if it exists
149
- try {
150
- const agentsPath = path.join(deps.directory, "AGENTS.md")
151
- const file = Bun.file(agentsPath)
152
- if (await file.exists()) {
153
- const content = await file.text()
154
- const truncated = content.length > 2000 ? content.slice(0, 2000) + "\n...(truncated)" : content
155
- context.push("", "Project guidelines (from AGENTS.md):", truncated)
156
- }
157
- } catch { /* file may not exist or be unreadable */ }
158
-
159
147
  context.push(
160
148
  "",
161
149
  "Your task:",