@te-river/opencode-team-mode 1.4.1 → 1.4.3
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/README.md +39 -6
- package/README.zh-CN.md +32 -4
- package/dist/agents.d.ts.map +1 -1
- package/dist/agents.js +63 -24
- package/dist/agents.js.map +1 -1
- package/dist/commands.d.ts.map +1 -1
- package/dist/commands.js +14 -11
- package/dist/commands.js.map +1 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -212,21 +212,36 @@ opencode-team-mode/
|
|
|
212
212
|
|
|
213
213
|
## 🗂️ Shared Blackboard (with automatic cleanup)
|
|
214
214
|
|
|
215
|
-
Sub-agents cannot message each other live (platform limitation), so TeamMode coordinates them through a **file blackboard
|
|
215
|
+
Sub-agents cannot message each other live (platform limitation), so TeamMode coordinates them through a **file blackboard** with strict ownership:
|
|
216
216
|
|
|
217
217
|
- Each multi-agent task gets its own directory under
|
|
218
218
|
`<repo>/.git/opencode-team/<task-slug>/` — inside `.git/`, so your working
|
|
219
219
|
tree and commits are **never polluted**. (Non-git workspaces fall back to
|
|
220
220
|
the OS temp dir.)
|
|
221
|
-
-
|
|
222
|
-
(`01-architect-design.md`, `03-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
221
|
+
- **File ownership:** every artifact is one topic-sized file written by
|
|
222
|
+
exactly one agent (`01-architect-auth-design.md`, `03-reviewer-auth-r1.md`).
|
|
223
|
+
~100 lines max per file — split topics instead of letting files balloon.
|
|
224
|
+
- **Writes are frozen:** a revision is a new round-suffixed file
|
|
225
|
+
(`…-r2.md`); nothing is ever appended to or later agents reading stale rounds.
|
|
226
|
+
- **The Team Lead is the router:** every dispatch carries a manifest —
|
|
227
|
+
`Task:` (self-contained brief), `Reads:` (only the files that work package
|
|
228
|
+
needs), `Write to:` (the one file the agent owns). Specialists read nothing
|
|
229
|
+
that isn't listed, so long tasks never drown sub-agents in unnecessary context.
|
|
230
|
+
- **`MANIFEST.md` is the lead's state board:** a file index plus a ≤50-line
|
|
231
|
+
`## Current state` section (phase, decisions still valid, next steps),
|
|
232
|
+
updated every converged round — the lead's compressed memory across long tasks.
|
|
226
233
|
- The Team Lead also enforces a review/test **feedback loop**: Critical/Major
|
|
227
234
|
findings and product bugs automatically become tracked fix tasks until the
|
|
228
235
|
deliverable converges.
|
|
229
236
|
|
|
237
|
+
### Triage — questions don't become code edits
|
|
238
|
+
|
|
239
|
+
The Team Lead classifies every incoming message before acting: a question or
|
|
240
|
+
consult gets an answer (zero file changes, fixes merely proposed and awaiting
|
|
241
|
+
your go-ahead); only explicit action requests enter the workflow. And whenever
|
|
242
|
+
you spell out what may or may not be touched, **those boundaries outrank
|
|
243
|
+
everything else** — the lead restates them in every single dispatch.
|
|
244
|
+
|
|
230
245
|
### Cleanup — two layers
|
|
231
246
|
|
|
232
247
|
| Layer | Who | When |
|
|
@@ -254,6 +269,24 @@ Default is **5 days**. To choose your own, use the tuple plugin form in
|
|
|
254
269
|
`ttlDays` accepts any number of days in `(0, 365]`; invalid values silently
|
|
255
270
|
fall back to 5.
|
|
256
271
|
|
|
272
|
+
### Default agent
|
|
273
|
+
|
|
274
|
+
TeamMode makes **`team` the default agent** (replacing the built-in `build`)
|
|
275
|
+
so every new chat starts with the team orchestrator — it appears above the
|
|
276
|
+
rest in the switcher's default slot. To keep `build` (or any other agent)
|
|
277
|
+
as the default, or pin a different one:
|
|
278
|
+
|
|
279
|
+
```jsonc
|
|
280
|
+
{
|
|
281
|
+
"plugin": [
|
|
282
|
+
["@te-river/opencode-team-mode@latest", { "defaultAgent": false }]
|
|
283
|
+
]
|
|
284
|
+
}
|
|
285
|
+
```
|
|
286
|
+
|
|
287
|
+
An explicitly configured non-`build` `default_agent` is always respected
|
|
288
|
+
untouched.
|
|
289
|
+
|
|
257
290
|
---
|
|
258
291
|
|
|
259
292
|
## 🔧 Customization
|
package/README.zh-CN.md
CHANGED
|
@@ -212,16 +212,29 @@ opencode-team-mode/
|
|
|
212
212
|
|
|
213
213
|
## 🗂️ 共享黑板(带自动清理)
|
|
214
214
|
|
|
215
|
-
子代理之间无法实时互发消息(平台限制),TeamMode
|
|
215
|
+
子代理之间无法实时互发消息(平台限制),TeamMode 通过**严格所有权的文件黑板**让它们协作:
|
|
216
216
|
|
|
217
217
|
- 每个多 Agent 任务在 `<repo>/.git/opencode-team/<task-slug>/` 下拥有独立目录 ——
|
|
218
218
|
位于 `.git/` 内,**绝不污染**你的工作区和 commit(非 git 工作区自动回退到系统临时目录)。
|
|
219
|
-
-
|
|
220
|
-
|
|
221
|
-
|
|
219
|
+
- **文件所有权**:每个制品是一个"一主题一文件",只由一个 Agent 写
|
|
220
|
+
(`01-architect-auth-design.md`、`03-reviewer-auth-r1.md`)。单文件约 ≤100 行,
|
|
221
|
+
超长就拆主题文件而不是任其膨胀。
|
|
222
|
+
- **写入即冻结**:修订 = 新的轮次后缀文件(`…-r2.md`);绝不追加旧文件,
|
|
223
|
+
后续 Agent 也永远读不到过时轮次。
|
|
224
|
+
- **Team Lead 是路由器**:每次 dispatch 携带清单——`Task:`(自包含任务书)、
|
|
225
|
+
`Reads:`(仅列出该工作包需要的文件)、`Write to:`(该 Agent 本次拥有的唯一文件)。
|
|
226
|
+
子代理不读清单之外的任何东西,超长任务因此不会把无关上下文灌进子代理。
|
|
227
|
+
- **`MANIFEST.md` 是 lead 的状态板**:文件索引 + 顶部 ≤50 行的 `## Current state`
|
|
228
|
+
节(阶段、仍然有效的决策、下一步),每轮闭环后更新——lead 跨长任务的压缩记忆。
|
|
222
229
|
- Team Lead 同时强制执行审查/测试**反馈闭环**:Critical/Major 问题和产品 bug
|
|
223
230
|
自动转化为跟踪的修复任务,直到交付物收敛。
|
|
224
231
|
|
|
232
|
+
### Triage —— 提问不会变成代码修改
|
|
233
|
+
|
|
234
|
+
Team Lead 对每条消息先分类再行动:咨询/提问只得到回答(零文件改动,发现缺陷
|
|
235
|
+
仅**提议**修复并等待你放行);只有明确的行动指令才进入工作流。并且一旦你写明
|
|
236
|
+
了哪些能碰哪些不能碰,**这些边界高于一切规则**——lead 会在每次派发中原样重申。
|
|
237
|
+
|
|
225
238
|
### 清理 —— 两层防御
|
|
226
239
|
|
|
227
240
|
| 层级 | 责任方 | 时机 |
|
|
@@ -246,6 +259,21 @@ opencode-team-mode/
|
|
|
246
259
|
|
|
247
260
|
`ttlDays` 接受 `(0, 365]` 内的天数;非法值静默回退到 5 天。
|
|
248
261
|
|
|
262
|
+
### 默认代理
|
|
263
|
+
|
|
264
|
+
TeamMode 会将 **`team` 设为默认代理**(替代内建 `build`),新会话直接由团队
|
|
265
|
+
调度者接管。若想保持 `build` 或其他代理为默认:
|
|
266
|
+
|
|
267
|
+
```jsonc
|
|
268
|
+
{
|
|
269
|
+
"plugin": [
|
|
270
|
+
["@te-river/opencode-team-mode@latest", { "defaultAgent": false }]
|
|
271
|
+
]
|
|
272
|
+
}
|
|
273
|
+
```
|
|
274
|
+
|
|
275
|
+
用户显式配置的非 `build` 默认代理永远原样保留。
|
|
276
|
+
|
|
249
277
|
---
|
|
250
278
|
|
|
251
279
|
## 🔧 自定义
|
package/dist/agents.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agents.d.ts","sourceRoot":"","sources":["../src/agents.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;
|
|
1
|
+
{"version":3,"file":"agents.d.ts","sourceRoot":"","sources":["../src/agents.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAgc7C,eAAO,MAAM,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,WAAW,CAO9C,CAAA"}
|
package/dist/agents.js
CHANGED
|
@@ -17,18 +17,25 @@
|
|
|
17
17
|
* - Research findings carry confidence tags and critical ones are verified.
|
|
18
18
|
*/
|
|
19
19
|
/* ------------------------------------------------------------------ */
|
|
20
|
-
/* Blackboard
|
|
20
|
+
/* Blackboard rules (appended to every specialist prompt) */
|
|
21
21
|
/* ------------------------------------------------------------------ */
|
|
22
22
|
const BLACKBOARD_GUARANTEE = `
|
|
23
23
|
|
|
24
|
-
## Blackboard
|
|
25
|
-
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
24
|
+
## Blackboard rules
|
|
25
|
+
- You own exactly ONE artifact file: the one named in your dispatch under
|
|
26
|
+
\`Write to:\`. Create/overwrite only that file — never append to existing
|
|
27
|
+
artifacts, never edit files owned by other roles, never rewrite history.
|
|
28
|
+
- Read ONLY the files listed in your dispatch's \`Reads:\`. Do not browse
|
|
29
|
+
the task directory for "extra context" — the lead scoped your reading
|
|
30
|
+
deliberately, and unlisted rounds will only pollute your context. If you
|
|
31
|
+
believe a needed file is missing from the list, say so in your reply
|
|
32
|
+
instead of opening files nobody authorized.
|
|
33
|
+
- Writing your artifact is ALWAYS within your role: any read-only
|
|
34
|
+
constraint applies to PROJECT SOURCES and the code under review — NEVER
|
|
35
|
+
to the blackboard. Your tools can write there; do it yourself.
|
|
29
36
|
- NEVER reply "append this verbatim for me" or hand the full deliverable
|
|
30
37
|
back to the dispatcher to transcribe — that defeats the entire point of
|
|
31
|
-
the blackboard.
|
|
38
|
+
the blackboard. Summary + your file path is the only valid reply shape.
|
|
32
39
|
- If a write genuinely fails (permissions, missing directory), start your
|
|
33
40
|
reply with the line \`BLACKBOARD WRITE FAILED: <reason>\` and only then
|
|
34
41
|
include the full content as fallback, so the lead can retry the write
|
|
@@ -49,6 +56,24 @@ const teamLead = {
|
|
|
49
56
|
You orchestrate the team: decompose work, dispatch it to specialist agents
|
|
50
57
|
via the Task tool, integrate their outputs, and enforce quality gates.
|
|
51
58
|
|
|
59
|
+
## Triage — classify before acting (Step 0, always)
|
|
60
|
+
- Question ≠ work order. When the user asks, analyzes, or consults
|
|
61
|
+
("why does X fail?", "how would we do Y?"), ANSWER it — read code if
|
|
62
|
+
useful, change nothing. If answering needs external knowledge, dispatch
|
|
63
|
+
\`researcher\`; don't grind through it yourself.
|
|
64
|
+
- Before any modification, ask explicitly: "does this request need file
|
|
65
|
+
changes?" Anything weaker than a clear yes → touch zero files.
|
|
66
|
+
- Spotted an obvious defect while answering? Propose the fix and WAIT for
|
|
67
|
+
the go-ahead — never fix-on-the-sly.
|
|
68
|
+
- Explicit action request ("fix X", "add Y", "refactor Z") → enter the
|
|
69
|
+
workflow below.
|
|
70
|
+
- Genuinely ambiguous → one targeted question, then act.
|
|
71
|
+
- USER-STATED BOUNDARIES ARE SUPREME: whenever the user details what may
|
|
72
|
+
be touched and what must not (files, modules, features), those limits
|
|
73
|
+
outrank every rule in this prompt. Enforce them in your own work AND
|
|
74
|
+
restate them inside every dispatch; if a task seems to require crossing
|
|
75
|
+
one, stop and ask — do not "balance" the conflict yourself.
|
|
76
|
+
|
|
52
77
|
## Hard rule — TodoList discipline (non-negotiable)
|
|
53
78
|
Before you touch anything on a medium-or-larger task you MUST create a todo
|
|
54
79
|
list. A task qualifies as medium-or-larger if ANY of these hold:
|
|
@@ -88,26 +113,40 @@ edits: config tweaks, typo/format fixes, doc updates, tiny glue code
|
|
|
88
113
|
(≲ 10 lines). Anything substantive — feature logic, multi-file changes,
|
|
89
114
|
API design — goes to \`implementer\`.
|
|
90
115
|
|
|
91
|
-
## Shared blackboard (
|
|
92
|
-
Sub-agents cannot message each other live
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
-
|
|
97
|
-
agent
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
116
|
+
## Shared blackboard (file ownership + your dispatch manifest)
|
|
117
|
+
Sub-agents cannot message each other live; the blackboard is their shared
|
|
118
|
+
memory and YOU are the router — you decide who writes what and who reads
|
|
119
|
+
what (root path is appended at the end of this prompt):
|
|
120
|
+
- One task directory per multi-agent task: \`<root>/<task-slug>/\`.
|
|
121
|
+
- FILE OWNERSHIP — every artifact is one topic-sized file written by
|
|
122
|
+
exactly one agent: \`NN-<role>-<topic>.md\` (e.g.
|
|
123
|
+
\`01-architect-auth-design.md\`, \`03-reviewer-auth-r1.md\`). Keep files
|
|
124
|
+
~100 lines or less; when an artifact grows past that, split it into
|
|
125
|
+
topic files instead of letting it bloat.
|
|
126
|
+
- WRITES ARE FROZEN — a revision is a NEW file with a round suffix
|
|
127
|
+
(\`02-implementer-auth-r2.md\`). Never append to an existing artifact,
|
|
128
|
+
and reference only the latest round in later dispatches, so stale
|
|
129
|
+
iterations never enter a sub-agent's context.
|
|
130
|
+
- Every dispatch must carry a manifest (all fields required):
|
|
131
|
+
Task: self-contained description, with a 2–5 line summary of the
|
|
132
|
+
prior work it builds on (summary-in-prompt + file paths is
|
|
133
|
+
the belt-and-braces protocol)
|
|
134
|
+
Reads: ONLY the files this work package needs — never "read
|
|
135
|
+
everything in the directory"
|
|
136
|
+
Write to: the one new file this agent owns for this package
|
|
137
|
+
If the user stated boundaries, restate them in the dispatch text too.
|
|
138
|
+
- MANIFEST.md is yours alone: a file index (one line per artifact — file,
|
|
139
|
+
owner, status, one-line summary) topped by a \`## Current state\` section
|
|
140
|
+
of ≤ 50 lines (phase, decisions still valid, next steps). Update it
|
|
141
|
+
after every converged round — it is your compressed memory across long
|
|
142
|
+
tasks. Do not put it on specialists' Reads lists unless one genuinely
|
|
143
|
+
needs the index.
|
|
103
144
|
- Sub-agents reply with a summary plus their file path; read the file
|
|
104
145
|
yourself when you need detail, then relay the relevant parts onward.
|
|
105
146
|
- A specialist asking you to transcribe its output verbatim is a protocol
|
|
106
147
|
violation — send it back to write the file itself. Only if its reply
|
|
107
148
|
contains \`BLACKBOARD WRITE FAILED\` may you write the artifact as a
|
|
108
149
|
fallback; note the failure in MANIFEST.md so it is not silently tolerated.
|
|
109
|
-
- Maintain \`MANIFEST.md\` in the task directory: one line per artifact
|
|
110
|
-
(file — role — status — one-line summary).
|
|
111
150
|
- After you deliver the final report, DELETE the task directory (use the
|
|
112
151
|
platform-appropriate command). The plugin also auto-sweeps directories
|
|
113
152
|
idle beyond the TTL — your deletion is the fast path, the sweeper is the
|
|
@@ -205,7 +244,7 @@ When the team lead sends back a design flaw found in review or testing:
|
|
|
205
244
|
`,
|
|
206
245
|
color: "#38BDF8", // sky blue
|
|
207
246
|
// Read-only on PROJECT sources; the blackboard artifact is explicitly
|
|
208
|
-
// writable (see Blackboard
|
|
247
|
+
// writable (see Blackboard rules).
|
|
209
248
|
permission: { edit: "allow", bash: "deny", webfetch: "allow" },
|
|
210
249
|
};
|
|
211
250
|
/* ------------------------------------------------------------------ */
|
|
@@ -301,7 +340,7 @@ by item (fixed / not fixed / partial).
|
|
|
301
340
|
`,
|
|
302
341
|
color: "#FB923C", // orange
|
|
303
342
|
// May edit ONLY the blackboard artifact; never the reviewed code
|
|
304
|
-
// (see Blackboard
|
|
343
|
+
// (see Blackboard rules + role rules).
|
|
305
344
|
permission: { edit: "allow", bash: "allow", webfetch: "allow" },
|
|
306
345
|
};
|
|
307
346
|
/* ------------------------------------------------------------------ */
|
|
@@ -401,7 +440,7 @@ by the team — flag prominently if that is the case.
|
|
|
401
440
|
color: "#A78BFA", // violet
|
|
402
441
|
permission: { edit: "allow", bash: "allow", webfetch: "allow", websearch: "allow" },
|
|
403
442
|
};
|
|
404
|
-
/* Append the blackboard
|
|
443
|
+
/* Append the blackboard rules to every specialist prompt. */
|
|
405
444
|
for (const a of [architect, implementer, reviewer, tester, researcher]) {
|
|
406
445
|
a.prompt = (a.prompt ?? "") + BLACKBOARD_GUARANTEE;
|
|
407
446
|
}
|
package/dist/agents.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agents.js","sourceRoot":"","sources":["../src/agents.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;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rC,MAAM,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAkCT;IACC,KAAK,EAAE,SAAS,EAAE,SAAS;IAC3B,UAAU,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE;CACpF,CAAA;AAED,6DAA6D;AAC7D,KAAK,MAAM,CAAC,IAAI,CAAC,SAAS,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,EAAE,UAAU,CAAC,EAAE,CAAC;IACvE,CAAC,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,MAAM,IAAI,EAAE,CAAC,GAAG,oBAAoB,CAAA;AACpD,CAAC;AAED,wEAAwE;AACxE,wEAAwE;AACxE,wEAAwE;AAExE,MAAM,CAAC,MAAM,MAAM,GAAgC;IACjD,MAAM,EAAE,QAAQ;IAChB,SAAS;IACT,WAAW;IACX,QAAQ;IACR,MAAM;IACN,UAAU;CACX,CAAA"}
|
package/dist/commands.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"commands.d.ts","sourceRoot":"","sources":["../src/commands.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,YAAY,CAAA;
|
|
1
|
+
{"version":3,"file":"commands.d.ts","sourceRoot":"","sources":["../src/commands.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,YAAY,CAAA;AA2I/C,eAAO,MAAM,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,aAAa,CAOlD,CAAA"}
|
package/dist/commands.js
CHANGED
|
@@ -101,26 +101,29 @@ const teamRun = {
|
|
|
101
101
|
$ARGUMENTS
|
|
102
102
|
|
|
103
103
|
## Workflow
|
|
104
|
-
1.
|
|
105
|
-
|
|
104
|
+
1. Triage first: if this is a question/consult rather than an action
|
|
105
|
+
request, answer it without touching files (propose fixes, wait for a
|
|
106
|
+
go-ahead). Honor and restate any user-stated boundaries everywhere.
|
|
107
|
+
2. Understand the goal and acceptance criteria.
|
|
108
|
+
3. **Create a todo list FIRST** — one item per work package, with checkable
|
|
106
109
|
done-conditions. Update statuses live (exactly one in_progress).
|
|
107
|
-
|
|
110
|
+
4. Dispatch sub-tasks to the appropriate agents:
|
|
108
111
|
- Design / architecture → architect
|
|
109
112
|
- Implementation → implementer
|
|
110
113
|
- Code review → reviewer
|
|
111
114
|
- Testing → tester
|
|
112
115
|
- Research → researcher
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
one
|
|
116
|
-
|
|
117
|
-
sub-tasks in parallel.
|
|
118
|
-
|
|
116
|
+
5. Coordinate through the shared blackboard: one task directory; every
|
|
117
|
+
dispatch carries a manifest (Task / Reads: only the files needed /
|
|
118
|
+
Write to: one owned artifact file); artifacts are frozen — revisions are
|
|
119
|
+
new round-suffixed files; keep MANIFEST.md's \`## Current state\` header
|
|
120
|
+
updated each converged round. Run independent sub-tasks in parallel.
|
|
121
|
+
6. Enforce the feedback loop: reviewer Critical/Major findings and tester
|
|
119
122
|
product-bugs become fix tasks on the list → implementer fixes → re-review
|
|
120
123
|
affected scope → re-run tests. Repeat until clean (max 2 loops, then
|
|
121
124
|
escalate).
|
|
122
|
-
|
|
123
|
-
|
|
125
|
+
7. Collect all outputs, resolve conflicts, synthesize a final result.
|
|
126
|
+
8. Present a structured summary: changes, review/test verdict, remaining
|
|
124
127
|
assumptions and risks. Then delete the task blackboard directory.`,
|
|
125
128
|
};
|
|
126
129
|
/* ------------------------------------------------------------------ */
|
package/dist/commands.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"commands.js","sourceRoot":"","sources":["../src/commands.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAIH,wEAAwE;AACxE,MAAM,QAAQ,GAAkB;IAC9B,WAAW,EACT,+FAA+F;IACjG,KAAK,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;gEAaoD;CAC/D,CAAA;AAED,wEAAwE;AACxE,MAAM,QAAQ,GAAkB;IAC9B,WAAW,EACT,2EAA2E;IAC7E,KAAK,EAAE,QAAQ;IACf,QAAQ,EAAE;;;;;;;;;;;8BAWkB;CAC7B,CAAA;AAED,wEAAwE;AACxE,MAAM,YAAY,GAAkB;IAClC,WAAW,EACT,uEAAuE;IACzE,KAAK,EAAE,YAAY;IACnB,QAAQ,EAAE;;;;;;;;;;;0DAW8C;CACzD,CAAA;AAED,wEAAwE;AACxE,MAAM,OAAO,GAAkB;IAC7B,WAAW,EACT,mGAAmG;IACrG,KAAK,EAAE,MAAM;IACb,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;sEA6B0D;CACrE,CAAA;AAED,wEAAwE;AACxE,wEAAwE;AACxE,wEAAwE;AAExE,MAAM,CAAC,MAAM,QAAQ,GAAkC;IACrD,WAAW,EAAE,QAAQ;IACrB,gBAAgB,EAAE,aAAa;IAC/B,aAAa,EAAE,UAAU;IACzB,WAAW,EAAE,QAAQ;IACrB,eAAe,EAAE,YAAY;IAC7B,UAAU,EAAE,OAAO;CACpB,CAAA"}
|
package/dist/index.d.ts
CHANGED
|
@@ -16,7 +16,9 @@
|
|
|
16
16
|
*
|
|
17
17
|
* Options (via the tuple plugin form):
|
|
18
18
|
* "plugin": [["@te-river/opencode-team-mode@latest", { "ttlDays": 7 }]]
|
|
19
|
-
* `ttlDays`
|
|
19
|
+
* - `ttlDays` → blackboard auto-cleanup TTL; default 5.
|
|
20
|
+
* - `defaultAgent` → promote Team as the default agent (replacing the
|
|
21
|
+
* built-in `build`); set `false` to opt out.
|
|
20
22
|
*/
|
|
21
23
|
import type { OpenCodePlugin } from "./types.js";
|
|
22
24
|
declare const plugin: OpenCodePlugin;
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAkB,MAAM,YAAY,CAAA;AAsBhE,QAAA,MAAM,MAAM,EAAE,cAyCb,CAAA;AAED,eAAe,MAAM,CAAA"}
|
package/dist/index.js
CHANGED
|
@@ -16,7 +16,9 @@
|
|
|
16
16
|
*
|
|
17
17
|
* Options (via the tuple plugin form):
|
|
18
18
|
* "plugin": [["@te-river/opencode-team-mode@latest", { "ttlDays": 7 }]]
|
|
19
|
-
* `ttlDays`
|
|
19
|
+
* - `ttlDays` → blackboard auto-cleanup TTL; default 5.
|
|
20
|
+
* - `defaultAgent` → promote Team as the default agent (replacing the
|
|
21
|
+
* built-in `build`); set `false` to opt out.
|
|
20
22
|
*/
|
|
21
23
|
import { agents } from "./agents.js";
|
|
22
24
|
import { commands } from "./commands.js";
|
|
@@ -65,6 +67,11 @@ const plugin = {
|
|
|
65
67
|
continue;
|
|
66
68
|
cfg.command[name] = def;
|
|
67
69
|
}
|
|
70
|
+
// ---------- make Team the default agent (opt-out: defaultAgent:false)
|
|
71
|
+
const promote = options?.defaultAgent !== false;
|
|
72
|
+
if (promote && (!cfg.default_agent || cfg.default_agent === "build")) {
|
|
73
|
+
cfg.default_agent = "team";
|
|
74
|
+
}
|
|
68
75
|
},
|
|
69
76
|
};
|
|
70
77
|
},
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAGH,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAA;AACpC,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AACx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GAAG,CAAC,KAAK,CAAC,IAAI,CAAC;wBAAE,SAAQ;oBAC7B,GAAG,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG;wBAChB,GAAG,GAAG;wBACN,MAAM,EAAE,IAAI,KAAK,MAAM,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,MAAM,IAAI,EAAE,CAAC,GAAG,IAAI,CAAC,CAAC,CAAC,GAAG,CAAC,MAAM;qBACjE,CAAA;gBACH,CAAC;gBAED,IAAI,CAAC,GAAG,CAAC,OAAO;oBAAE,GAAG,CAAC,OAAO,GAAG,EAAE,CAAA;gBAClC,KAAK,MAAM,CAAC,IAAI,EAAE,GAAG,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,CAAC;oBACnD,IAAI,GAAG,CAAC,OAAO,CAAC,IAAI,CAAC;wBAAE,SAAQ;oBAC/B,GAAG,CAAC,OAAO,CAAC,IAAI,CAAC,GAAG,GAAG,CAAA;gBACzB,CAAC;gBAED,uEAAuE;gBACvE,MAAM,OAAO,GAAG,OAAO,EAAE,YAAY,KAAK,KAAK,CAAA;gBAC/C,IAAI,OAAO,IAAI,CAAC,CAAC,GAAG,CAAC,aAAa,IAAI,GAAG,CAAC,aAAa,KAAK,OAAO,CAAC,EAAE,CAAC;oBACrE,GAAG,CAAC,aAAa,GAAG,MAAM,CAAA;gBAC5B,CAAC;YACH,CAAC;SACF,CAAA;IACH,CAAC;CACF,CAAA;AAED,eAAe,MAAM,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@te-river/opencode-team-mode",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.3",
|
|
4
4
|
"description": "Team collaboration mode plugin for OpenCode Desktop — injects specialized agents (architect, reviewer, implementer, tester, researcher) and team workflow commands into your OpenCode workspace.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|