@te-river/opencode-team-mode 1.5.6 → 1.5.8
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 +354 -528
- package/README.zh-CN.md +346 -480
- package/dist/agents.d.ts.map +1 -1
- package/dist/agents.js +44 -26
- package/dist/agents.js.map +1 -1
- package/dist/approval-gate.d.ts +5 -0
- package/dist/approval-gate.d.ts.map +1 -1
- package/dist/approval-gate.js +29 -0
- package/dist/approval-gate.js.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +27 -0
- package/dist/index.js.map +1 -1
- package/dist/prompts/lead.d.ts +1 -1
- package/dist/prompts/lead.d.ts.map +1 -1
- package/dist/prompts/lead.js +7 -4
- package/dist/prompts/lead.js.map +1 -1
- package/dist/prompts/shared.d.ts +1 -1
- package/dist/prompts/shared.d.ts.map +1 -1
- package/dist/prompts/shared.js +15 -13
- package/dist/prompts/shared.js.map +1 -1
- package/dist/prompts/specialists.d.ts +2 -2
- package/dist/prompts/specialists.d.ts.map +1 -1
- package/dist/prompts/specialists.js +31 -5
- package/dist/prompts/specialists.js.map +1 -1
- package/dist/tm/args-schema.d.ts +6 -0
- package/dist/tm/args-schema.d.ts.map +1 -1
- package/dist/tm/args-schema.js +23 -1
- package/dist/tm/args-schema.js.map +1 -1
- package/dist/tm/browser.d.ts.map +1 -1
- package/dist/tm/browser.js +35 -6
- package/dist/tm/browser.js.map +1 -1
- package/dist/tm/config.d.ts +16 -5
- package/dist/tm/config.d.ts.map +1 -1
- package/dist/tm/config.js +23 -6
- package/dist/tm/config.js.map +1 -1
- package/dist/tm/index.d.ts +11 -4
- package/dist/tm/index.d.ts.map +1 -1
- package/dist/tm/index.js +20 -6
- package/dist/tm/index.js.map +1 -1
- package/dist/tm/memory.d.ts +8 -2
- package/dist/tm/memory.d.ts.map +1 -1
- package/dist/tm/memory.js +31 -21
- package/dist/tm/memory.js.map +1 -1
- package/dist/tm/perm-ask.d.ts +37 -0
- package/dist/tm/perm-ask.d.ts.map +1 -0
- package/dist/tm/perm-ask.js +41 -0
- package/dist/tm/perm-ask.js.map +1 -0
- package/dist/tm/pipelines.d.ts.map +1 -1
- package/dist/tm/pipelines.js +7 -0
- package/dist/tm/pipelines.js.map +1 -1
- package/dist/tm/preview.d.ts.map +1 -1
- package/dist/tm/preview.js +32 -5
- package/dist/tm/preview.js.map +1 -1
- package/dist/tm/ptc/gate.d.ts.map +1 -1
- package/dist/tm/ptc/gate.js +4 -1
- package/dist/tm/ptc/gate.js.map +1 -1
- package/dist/tm/ptc/summary.d.ts.map +1 -1
- package/dist/tm/ptc/summary.js +5 -0
- package/dist/tm/ptc/summary.js.map +1 -1
- package/dist/tm/ptc/tool.d.ts.map +1 -1
- package/dist/tm/ptc/tool.js +2 -1
- package/dist/tm/ptc/tool.js.map +1 -1
- package/dist/tm/search.d.ts +58 -0
- package/dist/tm/search.d.ts.map +1 -0
- package/dist/tm/search.js +253 -0
- package/dist/tm/search.js.map +1 -0
- package/dist/tm/shell-bridge.d.ts +1 -1
- package/dist/tm/shell-bridge.d.ts.map +1 -1
- package/dist/tm/shell-bridge.js +52 -6
- package/dist/tm/shell-bridge.js.map +1 -1
- package/dist/tm/tools.js +1 -1
- package/dist/tm/webfetch.d.ts +36 -8
- package/dist/tm/webfetch.d.ts.map +1 -1
- package/dist/tm/webfetch.js +144 -23
- package/dist/tm/webfetch.js.map +1 -1
- package/docs/installation.md +219 -0
- package/package.json +3 -2
|
@@ -0,0 +1,219 @@
|
|
|
1
|
+
# TeamMode Installation Guide / 安装指南
|
|
2
|
+
|
|
3
|
+
> **For LLM agents:** your user asked you to install `@te-river/opencode-team-mode`. This document is the complete, self-contained procedure. Read it fully, then execute. Do not improvise package names or config locations — everything you need is here.
|
|
4
|
+
>
|
|
5
|
+
> **面向 LLM 智能体:** 用户要求你安装 `@te-river/opencode-team-mode`。本文档是完整、自包含的安装规程。通读后再执行。不要 improvised 包名或配置路径——所需信息全在这里。
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Part A — English
|
|
10
|
+
|
|
11
|
+
### What you are installing
|
|
12
|
+
|
|
13
|
+
An OpenCode plugin that injects a **six-agent development team** (Team Lead, Architect, Implementer, Reviewer, Tester, Researcher) plus six slash commands and nine governed `tm_*` tools into the user's OpenCode. npm package: [`@te-river/opencode-team-mode`](https://www.npmjs.com/package/@te-river/opencode-team-mode). It runs entirely locally; no telemetry, no API keys.
|
|
14
|
+
|
|
15
|
+
### Step 1 — Locate the OpenCode config file
|
|
16
|
+
|
|
17
|
+
Check, in order:
|
|
18
|
+
|
|
19
|
+
1. **Project config:** `opencode.json` or `opencode.jsonc` in the current project root.
|
|
20
|
+
2. **Global config:** `~/.config/opencode/opencode.json` (or `.jsonc`) — on Windows typically `C:\Users\<user>\.config\opencode\opencode.json`.
|
|
21
|
+
|
|
22
|
+
If neither exists, create the global one (`~/.config/opencode/opencode.jsonc`) so the team is available in every project.
|
|
23
|
+
|
|
24
|
+
### Step 2 — Add the plugin entry
|
|
25
|
+
|
|
26
|
+
Merge (do not replace unrelated keys) into the config's `"plugin"` array:
|
|
27
|
+
|
|
28
|
+
```jsonc
|
|
29
|
+
{
|
|
30
|
+
"$schema": "https://opencode.ai/config.json",
|
|
31
|
+
"plugin": [
|
|
32
|
+
"@te-river/opencode-team-mode@latest"
|
|
33
|
+
]
|
|
34
|
+
}
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
If a `"plugin"` array already exists, append the string to it. If the entry is already present, the user may want an **update** instead — see Updating below.
|
|
38
|
+
|
|
39
|
+
### Step 3 — Restart OpenCode
|
|
40
|
+
|
|
41
|
+
The plugin is resolved and loaded **once at startup**. The user must fully quit and restart OpenCode (Desktop: quit from the tray/menu, not just close the window; CLI: restart the `opencode` process).
|
|
42
|
+
|
|
43
|
+
### Network note (mainland China)
|
|
44
|
+
|
|
45
|
+
This guide is served from `raw.githubusercontent.com`, which is often
|
|
46
|
+
unreachable from mainland-China networks. If fetching it fails, retry with
|
|
47
|
+
the mirror prefix — `https://ghproxy.net/` + the same full URL. Both hosts
|
|
48
|
+
are on TeamMode's seeded `tm_webfetch` allowlist, so the governed fetch tool
|
|
49
|
+
can read either. After the plugin is installed and OpenCode restarted, the
|
|
50
|
+
same guide also ships inside the package at
|
|
51
|
+
`<opencode-cache>/packages/@te_river+opencode-team-mode@<version>/docs/installation.md`.
|
|
52
|
+
|
|
53
|
+
### Step 4 — Verify
|
|
54
|
+
|
|
55
|
+
After restart, verify in this order:
|
|
56
|
+
|
|
57
|
+
1. The agent picker (`@` mentions) lists: **team, architect, implementer, reviewer, tester, researcher**.
|
|
58
|
+
2. Slash commands `/team-plan`, `/team-implement`, `/team-review`, `/team-test`, `/team-research`, `/team-run` autocomplete.
|
|
59
|
+
3. Optional deeper check: `npm view @te-river/opencode-team-mode version` shows the latest published version; ask the user to start a chat and confirm the **team** agent responds.
|
|
60
|
+
|
|
61
|
+
Report which checks passed. If verification fails, see Troubleshooting.
|
|
62
|
+
|
|
63
|
+
### Updating
|
|
64
|
+
|
|
65
|
+
> The installer is idempotent: **re-running it IS the update.** It re-patches
|
|
66
|
+
> the config (no-op when present), purges the stale plugin cache, and
|
|
67
|
+
> re-resolves any npm-installed copy. This exists because OpenCode caches
|
|
68
|
+
> plugins by spec string (`~/.cache/opencode/packages/<name>@latest`) and
|
|
69
|
+
> does not re-resolve `@latest` when a new version publishes (upstream
|
|
70
|
+
> limitation).
|
|
71
|
+
|
|
72
|
+
**Path 1 — re-run the one-line installer:**
|
|
73
|
+
|
|
74
|
+
macOS / Linux (bash):
|
|
75
|
+
|
|
76
|
+
```bash
|
|
77
|
+
curl -fsSL https://ghproxy.net/https://raw.githubusercontent.com/Te-River/Opencode-TeamMode/main/scripts/install.sh | bash
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
Windows (PowerShell):
|
|
81
|
+
|
|
82
|
+
```powershell
|
|
83
|
+
irm https://ghproxy.net/https://raw.githubusercontent.com/Te-River/Opencode-TeamMode/main/scripts/install.ps1 | iex
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
**Path 2 — let an agent do it.** Paste this to any coding agent:
|
|
87
|
+
|
|
88
|
+
```text
|
|
89
|
+
Update the OpenCode plugin @te-river/opencode-team-mode following
|
|
90
|
+
https://raw.githubusercontent.com/Te-River/Opencode-TeamMode/main/docs/installation.md
|
|
91
|
+
(the "Updating" section), then verify the install using the checks in that guide.
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
**Path 3 — manual** (what the scripts automate):
|
|
95
|
+
|
|
96
|
+
1. Delete the cached package directory: `rm -rf ~/.cache/opencode/packages/@te_river+opencode-team-mode@latest` (Windows PowerShell: `Remove-Item -Recurse -Force "$env:LOCALAPPDATA\opencode\cache\packages\@te_river+opencode-team-mode@latest"` — also check `~/.cache/opencode/packages/` under the user profile; remove any directory matching `*opencode-team-mode*`).
|
|
97
|
+
2. If the plugin was also npm-installed into `~/.config/opencode` (check its `package.json` / `package-lock.json`), run `npm install @te-river/opencode-team-mode@latest` there.
|
|
98
|
+
3. Restart OpenCode and re-verify.
|
|
99
|
+
|
|
100
|
+
### Uninstalling
|
|
101
|
+
|
|
102
|
+
1. Remove the entry from the `"plugin"` array in the config file(s) you edited.
|
|
103
|
+
2. Delete the cache directory (path above) if you want to reclaim the disk space.
|
|
104
|
+
3. Restart OpenCode — the agents, commands and tools disappear.
|
|
105
|
+
|
|
106
|
+
### Troubleshooting
|
|
107
|
+
|
|
108
|
+
| Symptom | Cause | Fix |
|
|
109
|
+
|---|---|---|
|
|
110
|
+
| Agents don't appear | OpenCode not restarted, or config file is the wrong one | Fully restart; confirm the file you edited is the one OpenCode loads |
|
|
111
|
+
| Version is old despite `@latest` | Plugin cache never invalidates | See Updating — delete the cache dir |
|
|
112
|
+
| Node version error on startup | npm needs Node ≥ 18 | Upgrade Node |
|
|
113
|
+
| Env-var commands suddenly prompt for confirmation | That's the plugin's R6 protection working as designed | Approve once per operation, or set `TM_ENV_PROTECT=off` (not recommended) |
|
|
114
|
+
| A user-defined agent named `team`/`architect`/… got shadowed | Plugin injects defaults; your own definitions always win | The plugin never clobbers user agents — check for typos in your agent names |
|
|
115
|
+
|
|
116
|
+
---
|
|
117
|
+
|
|
118
|
+
## Part B — 中文
|
|
119
|
+
|
|
120
|
+
### 你在安装什么
|
|
121
|
+
|
|
122
|
+
一个 OpenCode 插件,向用户的 OpenCode 注入**六人开发团队**(Team Lead、Architect、Implementer、Reviewer、Tester、Researcher)+ 六个斜杠命令 + 九个受治理的 `tm_*` 工具。npm 包:[`@te-river/opencode-team-mode`](https://www.npmjs.com/package/@te-river/opencode-team-mode)。完全本地运行,无遥测、无 API Key。
|
|
123
|
+
|
|
124
|
+
### 第 1 步 — 找到 OpenCode 配置文件
|
|
125
|
+
|
|
126
|
+
按顺序检查:
|
|
127
|
+
|
|
128
|
+
1. **项目配置:** 当前项目根目录下的 `opencode.json` 或 `opencode.jsonc`。
|
|
129
|
+
2. **全局配置:** `~/.config/opencode/opencode.json`(或 `.jsonc`)——Windows 下通常是 `C:\Users\<用户名>\.config\opencode\opencode.json`。
|
|
130
|
+
|
|
131
|
+
都不存在时,创建全局配置(`~/.config/opencode/opencode.jsonc`),让团队在每个项目里都可用。
|
|
132
|
+
|
|
133
|
+
### 第 2 步 — 加入插件条目
|
|
134
|
+
|
|
135
|
+
合并(不要动无关的键)进配置的 `"plugin"` 数组:
|
|
136
|
+
|
|
137
|
+
```jsonc
|
|
138
|
+
{
|
|
139
|
+
"$schema": "https://opencode.ai/config.json",
|
|
140
|
+
"plugin": [
|
|
141
|
+
"@te-river/opencode-team-mode@latest"
|
|
142
|
+
]
|
|
143
|
+
}
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
已有 `"plugin"` 数组就把字符串追加进去。如果条目已经存在,用户想要的可能是**更新**——见下文"更新"。
|
|
147
|
+
|
|
148
|
+
### 第 3 步 — 重启 OpenCode
|
|
149
|
+
|
|
150
|
+
插件只在**启动时**解析和加载一次。用户需要完全退出并重启 OpenCode(桌面版:从托盘/菜单退出,不是只关窗口;CLI:重启 `opencode` 进程)。
|
|
151
|
+
|
|
152
|
+
### 网络提示(中国大陆)
|
|
153
|
+
|
|
154
|
+
本指南托管在 `raw.githubusercontent.com`,中国大陆网络经常无法直达。抓取
|
|
155
|
+
失败时改用镜像前缀重试——`https://ghproxy.net/` + 同样的完整 URL。两个主机
|
|
156
|
+
都在 TeamMode 的 `tm_webfetch` 种子白名单内,受治理的抓取工具可以直读。
|
|
157
|
+
插件装好、OpenCode 重启之后,同一份指南也在包内:
|
|
158
|
+
`<opencode-cache>/packages/@te_river+opencode-team-mode@<版本>/docs/installation.md`。
|
|
159
|
+
|
|
160
|
+
### 第 4 步 — 验证
|
|
161
|
+
|
|
162
|
+
重启后按顺序验证:
|
|
163
|
+
|
|
164
|
+
1. Agent 选择器(`@` 提及)里出现:**team、architect、implementer、reviewer、tester、researcher**。
|
|
165
|
+
2. 斜杠命令 `/team-plan`、`/team-implement`、`/team-review`、`/team-test`、`/team-research`、`/team-run` 可以自动补全。
|
|
166
|
+
3. 可选的深度检查:`npm view @te-river/opencode-team-mode version` 显示最新发布版本;请用户开一个会话确认 **team** agent 能正常响应。
|
|
167
|
+
|
|
168
|
+
报告哪些检查通过。验证失败时看"故障排查"。
|
|
169
|
+
|
|
170
|
+
### 更新
|
|
171
|
+
|
|
172
|
+
> 安装器是幂等的:**重跑安装器就是更新。** 它会补齐配置(已存在则跳过)、
|
|
173
|
+
> 清掉过期插件缓存、并重解析 npm 安装的副本。之所以需要这一步:OpenCode
|
|
174
|
+
> 按 spec 字符串缓存插件(`~/.cache/opencode/packages/<name>@latest`),
|
|
175
|
+
> 新版本发布后不会重新解析 `@latest`(上游已知问题)。
|
|
176
|
+
|
|
177
|
+
**路径一 —— 重跑一行安装器:**
|
|
178
|
+
|
|
179
|
+
macOS / Linux(bash):
|
|
180
|
+
|
|
181
|
+
```bash
|
|
182
|
+
curl -fsSL https://ghproxy.net/https://raw.githubusercontent.com/Te-River/Opencode-TeamMode/main/scripts/install.sh | bash
|
|
183
|
+
```
|
|
184
|
+
|
|
185
|
+
Windows(PowerShell):
|
|
186
|
+
|
|
187
|
+
```powershell
|
|
188
|
+
irm https://ghproxy.net/https://raw.githubusercontent.com/Te-River/Opencode-TeamMode/main/scripts/install.ps1 | iex
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
**路径二 —— 让 agent 更新。** 把这段话粘给任意编码 agent:
|
|
192
|
+
|
|
193
|
+
```text
|
|
194
|
+
更新 OpenCode 插件 @te-river/opencode-team-mode:按照
|
|
195
|
+
https://raw.githubusercontent.com/Te-River/Opencode-TeamMode/main/docs/installation.md
|
|
196
|
+
的"更新"章节执行,并按该指南里的检查项验证。
|
|
197
|
+
```
|
|
198
|
+
|
|
199
|
+
**路径三 —— 手动**(脚本自动化的内容):
|
|
200
|
+
|
|
201
|
+
1. 删除缓存的包目录:`rm -rf ~/.cache/opencode/packages/@te_river+opencode-team-mode@latest`(Windows PowerShell:`Remove-Item -Recurse -Force "$env:LOCALAPPDATA\opencode\cache\packages\@te_river+opencode-team-mode@latest"`——用户目录下的 `~/.cache/opencode/packages/` 也要检查;删除所有匹配 `*opencode-team-mode*` 的目录)。
|
|
202
|
+
2. 如果插件还被 npm 装进了 `~/.config/opencode`(检查它的 `package.json` / `package-lock.json`),在那里执行 `npm install @te-river/opencode-team-mode@latest`。
|
|
203
|
+
3. 重启 OpenCode 并重新验证。
|
|
204
|
+
|
|
205
|
+
### 卸载
|
|
206
|
+
|
|
207
|
+
1. 从你编辑过的配置文件里的 `"plugin"` 数组移除该条目。
|
|
208
|
+
2. 想回收磁盘空间的话删除上面的缓存目录。
|
|
209
|
+
3. 重启 OpenCode——agents、命令和工具全部消失。
|
|
210
|
+
|
|
211
|
+
### 故障排查
|
|
212
|
+
|
|
213
|
+
| 症状 | 原因 | 修复 |
|
|
214
|
+
|---|---|---|
|
|
215
|
+
| Agents 没出现 | OpenCode 没重启,或改错了配置文件 | 完全重启;确认改的文件就是 OpenCode 加载的那个 |
|
|
216
|
+
| 用着 `@latest` 版本还是旧的 | 插件缓存永不失效 | 见"更新"——删除缓存目录 |
|
|
217
|
+
| 启动报 Node 版本错误 | npm 需要 Node ≥ 18 | 升级 Node |
|
|
218
|
+
| 环境变量命令突然弹确认框 | 这是插件的 R6 保护在正常工作 | 每个操作选"一次",或设 `TM_ENV_PROTECT=off`(不推荐) |
|
|
219
|
+
| 用户自定义的 `team`/`architect` 等 agent 被遮蔽 | 插件注入默认值;你的定义永远优先 | 插件从不覆盖用户 agent——检查你的 agent 名字有没有拼错 |
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@te-river/opencode-team-mode",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.8",
|
|
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",
|
|
@@ -15,7 +15,8 @@
|
|
|
15
15
|
"dist",
|
|
16
16
|
"README.md",
|
|
17
17
|
"README.zh-CN.md",
|
|
18
|
-
"LICENSE"
|
|
18
|
+
"LICENSE",
|
|
19
|
+
"docs"
|
|
19
20
|
],
|
|
20
21
|
"scripts": {
|
|
21
22
|
"build": "tsc",
|