antechamber 1.0.41 → 2.0.2
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/CHANGELOG.md +105 -0
- package/README.md +87 -141
- package/bin/opencode-antechamber +14 -4
- package/dist/cli.d.ts +1 -1
- package/dist/cli.js +1 -1
- package/dist/commands/context.d.ts +5 -2
- package/dist/commands/context.js +8 -4
- package/dist/commands/doctor.js +4 -3
- package/dist/commands/setup.js +9 -28
- package/dist/config.d.ts +6 -2
- package/dist/config.js +18 -4
- package/dist/latency.d.ts +10 -0
- package/dist/latency.js +115 -0
- package/dist/misc-routes.js +2 -10
- package/dist/route-services.d.ts +0 -2
- package/dist/routes-v1.d.ts +1 -1
- package/dist/routes-v1.js +29 -418
- package/dist/routes-v2.js +1 -1
- package/dist/self-update.d.ts +2 -1
- package/dist/self-update.js +5 -1
- package/dist/server.d.ts +1 -3
- package/dist/server.js +9 -12
- package/dist/session-store.d.ts +12 -10
- package/dist/session-store.js +238 -128
- package/dist/session-tree.js +2 -2
- package/dist/sse.d.ts +0 -2
- package/dist/sse.js +13 -46
- package/dist/tool-map.js +1 -3
- package/dist/work-status.js +1 -1
- package/extensions/antechamber/README.md +101 -0
- package/extensions/antechamber/bin/opencode-antechamber +42 -0
- package/extensions/{omo-dag/docs/DESIGN.md → antechamber/docs/GRAPH.md} +5 -5
- package/extensions/{omo-work/docs/DESIGN.md → antechamber/docs/WORK.md} +3 -3
- package/extensions/antechamber/package.json +60 -0
- package/extensions/{omo-dag → antechamber}/panel/index.html +8 -1
- package/extensions/antechamber/panel/main.js +261 -0
- package/extensions/antechamber/runtime/launcher.js +201 -0
- package/extensions/antechamber/service/main.js +930 -0
- package/package.json +75 -26
- package/extensions/omo-compat/README.md +0 -48
- package/extensions/omo-compat/icon.svg +0 -1
- package/extensions/omo-compat/package.json +0 -43
- package/extensions/omo-dag/README.md +0 -167
- package/extensions/omo-dag/package.json +0 -33
- package/extensions/omo-dag/panel/main.js +0 -176
- package/extensions/omo-dag/service/main.js +0 -457
- package/extensions/omo-work/README.md +0 -88
- package/extensions/omo-work/package.json +0 -30
- package/extensions/omo-work/service/main.js +0 -149
- /package/extensions/{omo-dag → antechamber}/icon.svg +0 -0
- /package/extensions/{omo-work → antechamber}/status/index.html +0 -0
- /package/extensions/{omo-work → antechamber}/status/main.js +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,111 @@ and this project uses [Semantic Versioning](https://semver.org/).
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [2.0.2] - 2026-11-11
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
|
|
14
|
+
- **Use as OpenCode CLI** in the OmO panel's Runtime block: once the runtime is installed, one click points
|
|
15
|
+
OpenChamber's OpenCode CLI setting at the extension's launcher (a backup of `settings.json` is kept), and Reload
|
|
16
|
+
OpenCode switches to it. Folder installs keep the path to paste.
|
|
17
|
+
|
|
18
|
+
## [2.0.1] - 2026-11-11
|
|
19
|
+
|
|
20
|
+
- test: remove two races the v2 release run hit
|
|
21
|
+
|
|
22
|
+
## [2.0.0] - 2026-11-11
|
|
23
|
+
|
|
24
|
+
### Added
|
|
25
|
+
|
|
26
|
+
- **One OpenChamber extension for everything.** `extensions/antechamber` replaces OmO Graph, OmO Work and OmO
|
|
27
|
+
Compatibility: the Graph rail panel and page, the Work Status section and the OmO tool-card headers come in one
|
|
28
|
+
package, behind one approval. Install it from `https://github.com/eliottness/antechamber` (the repository root is the
|
|
29
|
+
extension; `#extension/antechamber` also works), then
|
|
30
|
+
set Settings → OpenCode CLI to its `bin/opencode-antechamber` (the Graph panel's settings show the path). On its
|
|
31
|
+
first start the launcher installs, with Bun, the antechamber release the extension's version names and the OmO
|
|
32
|
+
that release pins, into `~/.antechamber/runtime/<version>`; the extension's service installs it ahead of time when a
|
|
33
|
+
panel opens. Updating the extension in Settings → Extensions updates antechamber and OmO together, and OpenChamber's
|
|
34
|
+
own Update action points there. `ANTECHAMBER_RUNTIME_DIR` and `ANTECHAMBER_RUNTIME_SPEC` move or replace the runtime.
|
|
35
|
+
- Warn when the event loop is blocked for more than 250 ms or an HTTP request takes more than 1000 ms.
|
|
36
|
+
Configure these thresholds with `ANTECHAMBER_EVENT_LOOP_LAG_MS` and `ANTECHAMBER_SLOW_REQUEST_MS`.
|
|
37
|
+
Request warnings use route patterns and omit query strings and path identifiers.
|
|
38
|
+
|
|
39
|
+
### Removed
|
|
40
|
+
|
|
41
|
+
- **Breaking:** OpenChamber 1.x frontend support. OpenChamber **2.3.2+** is now required.
|
|
42
|
+
The following legacy routes now use the ordinary 404 response; `/global/health`,
|
|
43
|
+
the 2.x event streams, retained uncertain compatibility probes and the CLI
|
|
44
|
+
`--version` / `upgrade` commands remain available:
|
|
45
|
+
- `GET /session`
|
|
46
|
+
- `POST /session`
|
|
47
|
+
- `GET /session/status`
|
|
48
|
+
- `GET /project/current`
|
|
49
|
+
- `GET /project`
|
|
50
|
+
- `GET /config`
|
|
51
|
+
- `GET /global/config`
|
|
52
|
+
- `GET /provider`
|
|
53
|
+
- `GET /config/providers`
|
|
54
|
+
- `GET /experimental/session`
|
|
55
|
+
- `GET /question`
|
|
56
|
+
- `GET /permission`
|
|
57
|
+
- `GET /lsp`
|
|
58
|
+
- `GET /experimental/tool/ids`
|
|
59
|
+
- `GET /provider/auth`
|
|
60
|
+
- `GET /command`
|
|
61
|
+
- `GET /path`
|
|
62
|
+
- `GET /vcs`
|
|
63
|
+
- `GET /agent`
|
|
64
|
+
- `GET /find/file`
|
|
65
|
+
- `PATCH /config`
|
|
66
|
+
- `POST /experimental/control-plane/move-session`
|
|
67
|
+
- `GET /global/event`
|
|
68
|
+
- `GET /session/{sessionID}`
|
|
69
|
+
- `PATCH /session/{sessionID}`
|
|
70
|
+
- `DELETE /session/{sessionID}`
|
|
71
|
+
- `GET /session/{sessionID}/message`
|
|
72
|
+
- `GET /session/{sessionID}/todo`
|
|
73
|
+
- `POST /session/{sessionID}/prompt_async`
|
|
74
|
+
- `POST /session/{sessionID}/message`
|
|
75
|
+
- `POST /session/{sessionID}/abort`
|
|
76
|
+
- `POST /session/{sessionID}/fork`
|
|
77
|
+
- `POST /session/{sessionID}/revert`
|
|
78
|
+
- `POST /session/{sessionID}/unrevert`
|
|
79
|
+
- `POST /session/{sessionID}/summarize`
|
|
80
|
+
- `POST /session/{sessionID}/shell`
|
|
81
|
+
- `POST /session/{sessionID}/command`
|
|
82
|
+
- `POST /session/{sessionID}/share`
|
|
83
|
+
- `DELETE /session/{sessionID}/share`
|
|
84
|
+
- `POST /question/{requestID}/reply`
|
|
85
|
+
- `POST /question/{requestID}/reject`
|
|
86
|
+
- `POST /permission/{requestID}/reply`
|
|
87
|
+
- `PUT /auth/{providerID}`
|
|
88
|
+
- `POST /provider/{providerID}/oauth/authorize`
|
|
89
|
+
- `POST /provider/{providerID}/oauth/callback`
|
|
90
|
+
- `POST /global/upgrade`
|
|
91
|
+
- `GET /event`
|
|
92
|
+
|
|
93
|
+
### Changed
|
|
94
|
+
|
|
95
|
+
- **Breaking:** the `omo-graph`, `omo-work` and `omo-compat` extensions and their `extension/omo-*` branches are
|
|
96
|
+
retired. Remove them in Settings → Extensions and install the `antechamber` extension; its Graph paths and Work
|
|
97
|
+
settings start empty because OpenChamber keys stored data by extension id.
|
|
98
|
+
- **Breaking:** the antechamber npm package depends on `omo-ai` at an exact version, and antechamber runs that OmO by
|
|
99
|
+
default. `ANTECHAMBER_PI_BINARY` still selects another agent, and `omo` on PATH is used only when the pinned one is
|
|
100
|
+
not installed.
|
|
101
|
+
- When the extension launches antechamber (`ANTECHAMBER_MANAGED=openchamber-extension`), `antechamber upgrade` and
|
|
102
|
+
`ANTECHAMBER_AUTO_UPDATE` refuse to touch npm and say to update the extension instead, and `antechamber doctor`
|
|
103
|
+
gives the same advice.
|
|
104
|
+
- Move the session registry to SQLite with WAL and row-level writes. Existing `sessions.json` registries migrate
|
|
105
|
+
automatically and remain on disk as timestamped backups. After a rollback to 1.x and back, the sessions 1.x created
|
|
106
|
+
or changed in the meantime are merged in.
|
|
107
|
+
- **Breaking:** antechamber now runs on Bun 1.4+ instead of Node.js. OmO already requires Bun, and under Bun the
|
|
108
|
+
server starts about 3 times faster and idles at about half the memory. `dist/cli.js` has a `bun` shebang,
|
|
109
|
+
`bin/opencode-antechamber` finds Bun on PATH, in `$BUN_INSTALL/bin` or in `~/.bun/bin`, and `antechamber doctor`
|
|
110
|
+
replaces its `node` check with a `bun` check. Launchers written by `antechamber setup --auto-update` now put
|
|
111
|
+
Bun's directory on PATH. A launcher written by an older version needs `bun` on OpenChamber's PATH; if it is not
|
|
112
|
+
there, rerun `antechamber setup --auto-update`. npm still installs and updates the package; building from source
|
|
113
|
+
still needs Node.js 22+.
|
|
114
|
+
|
|
10
115
|
## [1.0.41] - 2026-11-09
|
|
11
116
|
|
|
12
117
|
### Fixed
|
package/README.md
CHANGED
|
@@ -27,8 +27,7 @@ an **external OpenCode server** and sessions run on OmO.
|
|
|
27
27
|
- Tool calls rendered as native OpenChamber tool parts (bash, write, edit,
|
|
28
28
|
and so on), including subagent/task cards.
|
|
29
29
|
- Approvals and questions bridged through pi's extension-UI protocol.
|
|
30
|
-
-
|
|
31
|
-
(OpenChamber 1.x; on 2.x, the OmO Work section shows it by phase).
|
|
30
|
+
- OmO's todo list, grouped by phase, in the extension's OmO Work section.
|
|
32
31
|
- Fork, revert, and unrevert backed by the agent's session tree, not a
|
|
33
32
|
filesystem snapshot. Reverting changes conversation context only; it never
|
|
34
33
|
touches files on disk.
|
|
@@ -38,10 +37,10 @@ an **external OpenCode server** and sessions run on OmO.
|
|
|
38
37
|
ownership tracking for detached task-host processes it spawned.
|
|
39
38
|
- Idle reaping and a live-process cap (`ANTECHAMBER_MAX_LIVE`) so long-running
|
|
40
39
|
deployments don't accumulate agent processes.
|
|
41
|
-
-
|
|
42
|
-
draws the OmO sub-agents behind the open
|
|
43
|
-
|
|
44
|
-
|
|
40
|
+
- [One OpenChamber extension](#the-openchamber-extension) that installs and
|
|
41
|
+
updates antechamber and OmO for you, draws the OmO sub-agents behind the open
|
|
42
|
+
session as a live graph (**OmO Graph**), shows the todo phases and goal timer
|
|
43
|
+
in the Work Status panel (**OmO Work**), and titles OmO's tool cards.
|
|
45
44
|
|
|
46
45
|
## Supported backends
|
|
47
46
|
|
|
@@ -50,15 +49,17 @@ an **external OpenCode server** and sessions run on OmO.
|
|
|
50
49
|
| [OmO](https://github.com/code-yeongyu/oh-my-openagent) (`omo`, package `omo-ai`) | **default and supported**: titles, steering, subagent cards, structured questions, and private task-host teardown are built and tested against it |
|
|
51
50
|
| [pi](https://github.com/badlogic/pi-mono) (`@earendil-works/pi-coding-agent`) | opt-in, best effort: set `ANTECHAMBER_PI_BINARY=pi`; OmO-specific features are unavailable |
|
|
52
51
|
|
|
53
|
-
antechamber
|
|
54
|
-
|
|
52
|
+
Each antechamber release depends on one exact `omo-ai` version and runs that
|
|
53
|
+
OmO, so the pair you get is the pair that was tested together.
|
|
54
|
+
`ANTECHAMBER_PI_BINARY` selects another executable; `omo` on `PATH` is the
|
|
55
|
+
fallback when the pinned one is not installed (see
|
|
56
|
+
[docs/configuration.md](docs/configuration.md)).
|
|
55
57
|
|
|
56
58
|
## Compatibility
|
|
57
59
|
|
|
58
60
|
| OpenChamber | API | Status |
|
|
59
61
|
|---|---|---|
|
|
60
|
-
| >= 2.
|
|
61
|
-
| 1.24.x | v1 | supported |
|
|
62
|
+
| >= 2.3.2 | v2 (`/api/*`) | supported; antechamber advertises `opencode v2.999.0` on `--version` |
|
|
62
63
|
| other versions | - | not tested |
|
|
63
64
|
|
|
64
65
|
OpenChamber changes which OpenCode API calls it makes between releases. If a
|
|
@@ -69,7 +70,24 @@ and event-stream inventory.
|
|
|
69
70
|
|
|
70
71
|
## Quick start
|
|
71
72
|
|
|
72
|
-
Needs
|
|
73
|
+
Needs [Bun](https://bun.sh) 1.4+ on the machine OpenChamber runs on.
|
|
74
|
+
|
|
75
|
+
### As an OpenChamber extension (recommended)
|
|
76
|
+
|
|
77
|
+
1. In OpenChamber 2.3.2 or newer, open **Settings → Extensions → Add → URL** and
|
|
78
|
+
enter `https://github.com/eliottness/antechamber`.
|
|
79
|
+
2. Approve **sessions** and the **local service** (it runs `bun`).
|
|
80
|
+
3. Open the **OmO** rail panel's settings (the sliders icon). Once the **Runtime** block
|
|
81
|
+
says antechamber is installed, click **Use as OpenCode CLI**, then **Reload OpenCode**
|
|
82
|
+
in OpenChamber's OpenCode settings. A folder install shows the launcher path to paste
|
|
83
|
+
into **Settings → OpenCode CLI** instead.
|
|
84
|
+
|
|
85
|
+
The launcher installs the antechamber release named by the extension's version,
|
|
86
|
+
and the OmO it pins, into `~/.antechamber/runtime/<version>` the first time it
|
|
87
|
+
starts. Updating the extension in Settings → Extensions is how antechamber and
|
|
88
|
+
OmO are updated. Details: [extensions/antechamber/README.md](extensions/antechamber/README.md).
|
|
89
|
+
|
|
90
|
+
### From npm
|
|
73
91
|
|
|
74
92
|
```bash
|
|
75
93
|
npm i -g antechamber
|
|
@@ -78,9 +96,10 @@ antechamber doctor
|
|
|
78
96
|
antechamber setup --auto-update
|
|
79
97
|
```
|
|
80
98
|
|
|
81
|
-
`setup` updates OpenChamber's
|
|
82
|
-
|
|
83
|
-
|
|
99
|
+
The npm package brings its pinned OmO along. `setup` updates OpenChamber's
|
|
100
|
+
`opencodeBinary`, preserves all other settings, and backs up an existing
|
|
101
|
+
settings file before changing it. Restart OpenChamber after setup. Preview
|
|
102
|
+
changes with `antechamber setup --dry-run`.
|
|
84
103
|
|
|
85
104
|
`--auto-update` keeps antechamber current without any action from you. It
|
|
86
105
|
writes a small launcher, `~/.config/antechamber/opencode-antechamber`, and points
|
|
@@ -92,13 +111,10 @@ skips the check. It needs a global npm or bun install, so it is refused for
|
|
|
92
111
|
source checkouts and `npx`. Drop the flag (plain `antechamber setup`) to point
|
|
93
112
|
OpenChamber back at the `antechamber` bin and stop auto-updates.
|
|
94
113
|
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
permissions it asks for. On OpenChamber 2.x, add OmO Work to see monitors,
|
|
100
|
-
eval cells and the todo list in the Work Status panel. The folders are updated
|
|
101
|
-
in place by `npm update -g`.
|
|
114
|
+
`setup` ends by printing the bundled extension's folder (under
|
|
115
|
+
`$(npm root -g)/antechamber/extensions/antechamber`); add it with
|
|
116
|
+
**Settings → Extensions → Add → Folder** for the Graph, Work and tool headers.
|
|
117
|
+
OpenChamber can keep using the npm-installed `antechamber` as its OpenCode CLI.
|
|
102
118
|
|
|
103
119
|
For an isolated OpenChamber instance, leaving your main settings untouched:
|
|
104
120
|
|
|
@@ -146,9 +162,9 @@ antechamber serve --hostname 127.0.0.1 --port 4096
|
|
|
146
162
|
|---|---|
|
|
147
163
|
| `antechamber serve` | OpenCode-compatible server; `--hostname`/`--host`, `--port`, `--directory`. Bare `antechamber` also starts the server. |
|
|
148
164
|
| `antechamber setup` | Configure OpenChamber; `--settings <file>`, `--profile <dir>`, `--binary <path>`, `--dry-run`, `--systemd [unit]`, `--pi-binary <path>`, `--restart`, `--auto-update`. |
|
|
149
|
-
| `antechamber doctor` | Read-only
|
|
150
|
-
| `antechamber upgrade` | Install the latest release over a global npm or bun install, with the package manager that owns it. Refused for source checkouts
|
|
151
|
-
| `antechamber version` | Package version plus OpenCode API contract version. `--version`/`-v` deliberately print exactly `opencode v2.
|
|
165
|
+
| `antechamber doctor` | Read-only Bun, backend, agent/state directories, teardown, OpenChamber and auth checks, plus the installed, latest released and running adapter versions (a running server older than the install needs an OpenChamber restart); `--json`, `--settings <file>`, `--profile <dir>`. Exits 1 on any FAIL; warnings do not fail. |
|
|
166
|
+
| `antechamber upgrade` | Install the latest release over a global npm or bun install, with the package manager that owns it. Refused for source checkouts, `npx`, and when the extension's launcher manages antechamber (see Upgrade, uninstall and rollback below). |
|
|
167
|
+
| `antechamber version` | Package version plus OpenCode API contract version. `--version`/`-v` deliberately print exactly `opencode v2.999.0` for OpenChamber. |
|
|
152
168
|
| `antechamber help` | Usage and options; also `--help`/`-h`. |
|
|
153
169
|
|
|
154
170
|
## Upgrade, uninstall and rollback
|
|
@@ -165,13 +181,11 @@ Restart OpenChamber, or `systemctl --user restart openchamber.service` for a
|
|
|
165
181
|
managed service. Run `antechamber doctor` again. If the executable moved,
|
|
166
182
|
rerun `antechamber setup`.
|
|
167
183
|
|
|
168
|
-
OpenChamber
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
1.x shows no notice; its `POST /global/upgrade` call upgrades antechamber the
|
|
174
|
-
same way.
|
|
184
|
+
OpenChamber can show an "OpenCode update" notice. Its **Update** button runs
|
|
185
|
+
`<opencodeBinary> upgrade`: for an npm install that upgrades antechamber itself
|
|
186
|
+
(a no-op when it is already current); for the extension's launcher it only says
|
|
187
|
+
to update the extension in Settings → Extensions. Click **Reload OpenCode**
|
|
188
|
+
afterwards to restart onto the new version.
|
|
175
189
|
|
|
176
190
|
To roll back wiring, copy the backup printed by setup over the settings file:
|
|
177
191
|
|
|
@@ -196,119 +210,53 @@ git clone https://github.com/eliottness/antechamber.git
|
|
|
196
210
|
cd antechamber
|
|
197
211
|
npm ci
|
|
198
212
|
npm run build
|
|
199
|
-
|
|
200
|
-
|
|
213
|
+
bun dist/cli.js doctor
|
|
214
|
+
bun dist/cli.js setup --binary "$PWD/bin/opencode-antechamber"
|
|
201
215
|
# isolated alternative:
|
|
202
|
-
|
|
216
|
+
bun dist/cli.js setup --profile ~/.config/antechamber-openchamber \
|
|
203
217
|
--binary "$PWD/bin/opencode-antechamber"
|
|
204
218
|
```
|
|
205
219
|
|
|
206
|
-
|
|
220
|
+
Building needs Node.js 22+ for the development tooling; the built CLI runs on
|
|
221
|
+
Bun. The source launcher requires the built `dist/cli.js` and finds Bun on PATH,
|
|
222
|
+
in `$BUN_INSTALL/bin` or in `~/.bun/bin`. Pull updates, run
|
|
207
223
|
`npm ci && npm run build`, and restart OpenChamber.
|
|
208
224
|
|
|
209
|
-
`npm run build` also builds the
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
|
235
|
-
|
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
`$(npm root -g)/antechamber/` for npm installs or the checkout after
|
|
245
|
-
`npm run build`.
|
|
246
|
-
- **ZIP file**: attached to every GitHub release, or built with
|
|
247
|
-
`npm run build && npm run pack:extension -- antechamber-omo-graph.zip` (OmO
|
|
248
|
-
Graph) or `npm run pack:work-extension -- antechamber-omo-work.zip` (OmO
|
|
249
|
-
Work). OpenChamber never updates ZIP installs.
|
|
250
|
-
|
|
251
|
-
Then approve the permissions it asks for. See
|
|
252
|
-
[Upgrading the OpenChamber extensions](#upgrading-the-openchamber-extensions)
|
|
253
|
-
for how each source moves to a new release.
|
|
254
|
-
|
|
255
|
-
### OmO Graph
|
|
256
|
-
|
|
257
|
-
With the default OmO backend, OmO Graph adds a rail panel showing the open
|
|
258
|
-
session's orchestrator and every sub-agent OmO launched, grouped in waves:
|
|
259
|
-
|
|
260
|
-
- each card shows the sub-agent's live state, duration, agent and model;
|
|
261
|
-
- hovering a card highlights its input and output edges;
|
|
262
|
-
- clicking a card opens that sub-agent's session.
|
|
263
|
-
|
|
264
|
-
Its local service reads OmO's task store and antechamber's session registry
|
|
265
|
-
read-only. Details: [extensions/omo-dag/README.md](extensions/omo-dag/README.md).
|
|
266
|
-
|
|
267
|
-
### OmO Work
|
|
268
|
-
|
|
269
|
-
OmO Work adds an **OmO Work** section to OpenChamber 2.x's Work Status panel,
|
|
270
|
-
for the background work of the open session:
|
|
271
|
-
|
|
272
|
-
- the OmO todo list grouped by phase, with progress per phase;
|
|
273
|
-
- terminal monitors, with their command, filter and latest matched lines (on
|
|
274
|
-
2.x, monitors appear here instead of as subagent sessions);
|
|
275
|
-
- detached eval cells, with their output and a **Stop** button;
|
|
276
|
-
- background terminal sessions that are still running;
|
|
277
|
-
- the goal continuation timer, what it waits on, and a **Fire now** button.
|
|
278
|
-
|
|
279
|
-
Its local service talks to the running antechamber through the
|
|
280
|
-
`/antechamber/work-status` routes, authenticated by a token antechamber writes
|
|
281
|
-
into its private run record, so it never needs the server password. It needs
|
|
282
|
-
antechamber running on the same machine as OpenChamber. Details:
|
|
283
|
-
[extensions/omo-work/README.md](extensions/omo-work/README.md).
|
|
284
|
-
|
|
285
|
-
### OmO Compatibility
|
|
286
|
-
|
|
287
|
-
OmO Compatibility is a manifest with no code. It tells OpenChamber how to
|
|
288
|
-
display OmO tool calls that antechamber maps onto OpenChamber's cards; today
|
|
289
|
-
it heads eval cells with `JS Eval` or `Python Eval` and the cell's summary. It
|
|
290
|
-
needs no build. Details:
|
|
291
|
-
[extensions/omo-compat/README.md](extensions/omo-compat/README.md).
|
|
292
|
-
|
|
293
|
-
## Upgrading the OpenChamber extensions
|
|
294
|
-
|
|
295
|
-
Every antechamber release ships the three extensions at its own version. How
|
|
296
|
-
an installed extension moves to a new release depends on how it was added:
|
|
297
|
-
|
|
298
|
-
- **Git URL** (`https://github.com/eliottness/antechamber#extension/...`):
|
|
299
|
-
Settings → Extensions shows **Update available** once a release is out
|
|
300
|
-
(OpenChamber checks at most hourly; **Check for updates** checks now).
|
|
301
|
-
**Update** replaces it in place and keeps its approvals and settings.
|
|
302
|
-
- **Folder**: the folder belongs to the antechamber installation, so it
|
|
303
|
-
changes with `antechamber upgrade` (or `git pull && npm ci && npm run build`
|
|
304
|
-
in a checkout). Toggle the extension off and on to restart its service.
|
|
305
|
-
- **ZIP** (file or release URL): OpenChamber never checks these. Add the new
|
|
306
|
-
archive and choose **Reinstall**, or switch to the Git URL once: remove the
|
|
307
|
-
extension, then add it by URL.
|
|
308
|
-
|
|
309
|
-
Each extension is built against the antechamber of the same release, so
|
|
310
|
-
upgrade antechamber too and restart OpenChamber to run it; `antechamber
|
|
311
|
-
doctor` shows the running version.
|
|
225
|
+
`npm run build` also builds the extension; `setup` prints its folder
|
|
226
|
+
(`$PWD/extensions/antechamber`) to add in **Settings → Extensions → Add →
|
|
227
|
+
Folder**. To run a checkout through the extension's launcher instead, `npm pack`
|
|
228
|
+
it and set `ANTECHAMBER_RUNTIME_SPEC` to the tarball in OpenChamber's
|
|
229
|
+
environment.
|
|
230
|
+
|
|
231
|
+
## The OpenChamber extension
|
|
232
|
+
|
|
233
|
+
`extensions/antechamber` is one OpenChamber 2.3.2+ extension (web and desktop;
|
|
234
|
+
VS Code and mobile load no extensions). It replaces the OmO Graph, OmO Work and
|
|
235
|
+
OmO Compatibility extensions of antechamber 1.x: remove those, then add this
|
|
236
|
+
one.
|
|
237
|
+
|
|
238
|
+
| Part | What it does |
|
|
239
|
+
|---|---|
|
|
240
|
+
| Runtime | `bin/opencode-antechamber`, OpenChamber's OpenCode CLI: installs and runs the pinned antechamber and OmO with Bun |
|
|
241
|
+
| OmO Graph | a rail panel (and page) drawing the open session's OmO sub-agents as a live, clickable graph |
|
|
242
|
+
| OmO Work | a Work Status section with the session's todo phases, goal timer and other wake sources |
|
|
243
|
+
| Tool headers | eval cells read `JS Eval`/`Python Eval` and their summary; sub-agent cards read their agent and description |
|
|
244
|
+
|
|
245
|
+
Add it from **Settings → Extensions → Add**:
|
|
246
|
+
|
|
247
|
+
| Source | Add | Updates |
|
|
248
|
+
|---|---|---|
|
|
249
|
+
| **URL** (Git, recommended) | `https://github.com/eliottness/antechamber` (the repository root is the extension), or `…#extension/antechamber` for a clone of just the extension | OpenChamber offers **Update** after each release |
|
|
250
|
+
| **Folder** | `extensions/antechamber` of an npm install or a built checkout | changes with the installation |
|
|
251
|
+
| **ZIP** | `antechamber-openchamber.zip` from a GitHub release, or `npm run build && npm run pack:extension -- out.zip` | never; reinstall the new archive |
|
|
252
|
+
|
|
253
|
+
Both URLs install the same extension: the root `package.json` carries its
|
|
254
|
+
manifest, pointing into `extensions/antechamber/`, whose built files are
|
|
255
|
+
committed. It asks
|
|
256
|
+
for **sessions** and a **local service** (`bun`). Details, data paths and the
|
|
257
|
+
design: [extensions/antechamber/README.md](extensions/antechamber/README.md),
|
|
258
|
+
[docs/GRAPH.md](extensions/antechamber/docs/GRAPH.md),
|
|
259
|
+
[docs/WORK.md](extensions/antechamber/docs/WORK.md).
|
|
312
260
|
|
|
313
261
|
## Configuration
|
|
314
262
|
|
|
@@ -401,9 +349,7 @@ provenance and creates the GitHub release from the CHANGELOG. See
|
|
|
401
349
|
- [docs/backends/omo.md](docs/backends/omo.md) - OmO backend details (agent name, task hosts, transcripts)
|
|
402
350
|
- [RELEASE.md](RELEASE.md) - automatic patch releases to npm and GitHub on every push to `main`
|
|
403
351
|
|
|
404
|
-
- [extensions/
|
|
405
|
-
- [extensions/omo-work/README.md](extensions/omo-work/README.md) - the OmO Work status section for OpenChamber 2.x ([design](extensions/omo-work/docs/DESIGN.md))
|
|
406
|
-
- [extensions/omo-compat/README.md](extensions/omo-compat/README.md) - the OmO Compatibility display rules
|
|
352
|
+
- [extensions/antechamber/README.md](extensions/antechamber/README.md) - the OpenChamber extension: runtime launcher, OmO Graph ([design](extensions/antechamber/docs/GRAPH.md)), OmO Work ([design](extensions/antechamber/docs/WORK.md)) and tool headers
|
|
407
353
|
|
|
408
354
|
## Credits
|
|
409
355
|
|
package/bin/opencode-antechamber
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
# at this file. OpenChamber runs `<binary> serve --hostname H --port P` and
|
|
4
4
|
# `<binary> --version`, and OpenChamber 2.x's Update action runs `<binary> upgrade`;
|
|
5
5
|
# anything else is rejected.
|
|
6
|
-
# Requires a build (`npm run build`) so that dist/cli.js exists.
|
|
6
|
+
# Requires a build (`npm run build`) so that dist/cli.js exists, and Bun to run it.
|
|
7
7
|
set -eu
|
|
8
8
|
SCRIPT_PATH=$0
|
|
9
9
|
while [ -h "$SCRIPT_PATH" ]; do
|
|
@@ -20,10 +20,20 @@ if [ ! -f "$CLI" ]; then
|
|
|
20
20
|
echo "opencode-antechamber: $CLI not found; run 'npm run build' first" >&2
|
|
21
21
|
exit 1
|
|
22
22
|
fi
|
|
23
|
+
# antechamber runs on Bun. GUI apps and services often have a PATH without
|
|
24
|
+
# Bun's install directory, so also look where the Bun installer puts it.
|
|
25
|
+
BUN=$(command -v bun || true)
|
|
26
|
+
for CANDIDATE in "${BUN_INSTALL:-${HOME:-}/.bun}/bin/bun" "${HOME:-}/.bun/bin/bun"; do
|
|
27
|
+
if [ -z "$BUN" ] && [ -x "$CANDIDATE" ]; then BUN=$CANDIDATE; fi
|
|
28
|
+
done
|
|
29
|
+
if [ -z "$BUN" ]; then
|
|
30
|
+
echo "opencode-antechamber: bun not found on PATH or in ~/.bun/bin; install it from https://bun.sh" >&2
|
|
31
|
+
exit 1
|
|
32
|
+
fi
|
|
23
33
|
case "${1:-}" in
|
|
24
|
-
serve) shift; exec
|
|
25
|
-
--version|-v) exec
|
|
26
|
-
upgrade) exec
|
|
34
|
+
serve) shift; exec "$BUN" "$CLI" serve "$@" ;;
|
|
35
|
+
--version|-v) exec "$BUN" "$CLI" --version ;;
|
|
36
|
+
upgrade) exec "$BUN" "$CLI" upgrade ;;
|
|
27
37
|
esac
|
|
28
38
|
echo "opencode-antechamber: unsupported command '${1:-}' (only 'serve', '--version' and 'upgrade' are implemented)" >&2
|
|
29
39
|
exit 1
|
package/dist/cli.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
#!/usr/bin/env
|
|
1
|
+
#!/usr/bin/env bun
|
|
2
2
|
export {};
|
package/dist/cli.js
CHANGED
|
@@ -7,7 +7,10 @@ export interface CommandContext {
|
|
|
7
7
|
readonly exec: (binary: string, args: readonly string[]) => string;
|
|
8
8
|
readonly now: () => Date;
|
|
9
9
|
readonly platform: NodeJS.Platform;
|
|
10
|
-
|
|
10
|
+
/** Bun's version, or undefined when this process is not running on Bun. */
|
|
11
|
+
readonly bunVersion: string | undefined;
|
|
12
|
+
/** The running Bun executable, or undefined when this process is not running on Bun. */
|
|
13
|
+
readonly bunBinary: string | undefined;
|
|
11
14
|
readonly output: (line: string) => void;
|
|
12
15
|
readonly cliPath: string;
|
|
13
16
|
readonly launcherPath: string;
|
|
@@ -24,6 +27,6 @@ export declare function readSettings(path: string, ctx: CommandContext): Record<
|
|
|
24
27
|
export declare function shellQuote(value: string): string;
|
|
25
28
|
/** OpenChamber launcher written by `setup --auto-update`, kept beside the session registry. */
|
|
26
29
|
export declare function autoUpdateLauncherPath(ctx: CommandContext): string;
|
|
27
|
-
export declare function autoUpdateLauncherText(binary: string): string;
|
|
30
|
+
export declare function autoUpdateLauncherText(binary: string, bunBinary?: string): string;
|
|
28
31
|
export declare function autoUpdateLauncherTarget(text: string): string | undefined;
|
|
29
32
|
export declare function isPackageBinary(binary: string, ctx: CommandContext): boolean;
|
package/dist/commands/context.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { spawnSync } from "node:child_process";
|
|
2
2
|
import * as fs from "node:fs";
|
|
3
3
|
import { homedir } from "node:os";
|
|
4
|
-
import { delimiter, isAbsolute, join, resolve } from "node:path";
|
|
4
|
+
import { delimiter, dirname, isAbsolute, join, resolve } from "node:path";
|
|
5
5
|
import { fileURLToPath } from "node:url";
|
|
6
6
|
import { defaultStateDir, envSetting } from "../config.js";
|
|
7
7
|
export function createContext(overrides = {}) {
|
|
@@ -29,7 +29,8 @@ export function createContext(overrides = {}) {
|
|
|
29
29
|
},
|
|
30
30
|
now: () => new Date(),
|
|
31
31
|
platform: process.platform,
|
|
32
|
-
|
|
32
|
+
bunVersion: process.versions.bun,
|
|
33
|
+
bunBinary: process.versions.bun === undefined ? undefined : process.execPath,
|
|
33
34
|
output: console.log,
|
|
34
35
|
cliPath: packageCliPath,
|
|
35
36
|
launcherPath: fileURLToPath(new URL("../../bin/opencode-antechamber", import.meta.url)),
|
|
@@ -85,13 +86,16 @@ export function shellQuote(value) {
|
|
|
85
86
|
export function autoUpdateLauncherPath(ctx) {
|
|
86
87
|
return resolve(ctx.cwd, envSetting("STATE_DIR", ctx.env) ?? defaultStateDir(ctx.home, ctx.fs.existsSync), "opencode-antechamber");
|
|
87
88
|
}
|
|
88
|
-
export function autoUpdateLauncherText(binary) {
|
|
89
|
+
export function autoUpdateLauncherText(binary, bunBinary) {
|
|
90
|
+
const quote = (value) => `'${value.replaceAll("'", "'\\''")}'`;
|
|
89
91
|
return [
|
|
90
92
|
"#!/bin/sh",
|
|
91
93
|
"# Written by `antechamber setup --auto-update`; rerun `antechamber setup` without it to stop auto-updates.",
|
|
92
94
|
"ANTECHAMBER_AUTO_UPDATE=1",
|
|
93
95
|
"export ANTECHAMBER_AUTO_UPDATE",
|
|
94
|
-
|
|
96
|
+
// The CLI's `env bun` shebang must find Bun even when OpenChamber's PATH lacks its directory.
|
|
97
|
+
...(bunBinary === undefined ? [] : [`PATH=${quote(dirname(bunBinary))}:"$PATH"`, "export PATH"]),
|
|
98
|
+
`exec ${quote(binary)} "$@"`,
|
|
95
99
|
"",
|
|
96
100
|
].join("\n");
|
|
97
101
|
}
|
package/dist/commands/doctor.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { dirname, resolve } from "node:path";
|
|
2
2
|
import { piAgentDir } from "../agent-dir.js";
|
|
3
3
|
import { detectAgentName } from "../agent-name.js";
|
|
4
|
-
import { agentBinary, defaultStateDir, envSetting, isPlainPi } from "../config.js";
|
|
4
|
+
import { agentBinary, defaultStateDir, envSetting, isPlainPi, managedByExtension } from "../config.js";
|
|
5
5
|
import { findPidfdPython } from "../pidfd.js";
|
|
6
6
|
import { readRunningServers } from "../running-servers.js";
|
|
7
7
|
import { isNewerVersion } from "../self-update.js";
|
|
@@ -23,7 +23,8 @@ export function doctor(options = {}, ctx = createContext(), latestVersion) {
|
|
|
23
23
|
const add = (name, status, message) => {
|
|
24
24
|
checks.push({ name, status, message });
|
|
25
25
|
};
|
|
26
|
-
|
|
26
|
+
const [bunMajor = 0, bunMinor = 0] = (ctx.bunVersion ?? "").split(".").map(Number);
|
|
27
|
+
add("bun", bunMajor > 1 || (bunMajor === 1 && bunMinor >= 4) ? "PASS" : "FAIL", ctx.bunVersion === undefined ? "not running on Bun; requires Bun >=1.4" : `Bun ${ctx.bunVersion}; requires >=1.4`);
|
|
27
28
|
const backend = agentBinary(ctx.env);
|
|
28
29
|
const binary = resolveBinary(backend, ctx);
|
|
29
30
|
if (binary === undefined)
|
|
@@ -59,7 +60,7 @@ export function doctor(options = {}, ctx = createContext(), latestVersion) {
|
|
|
59
60
|
if (latestVersion instanceof Error)
|
|
60
61
|
add("version", "INFO", `${ADAPTER_VERSION}; latest unknown (${latestVersion.message})`);
|
|
61
62
|
else if (latest !== undefined && isNewerVersion(latest, ADAPTER_VERSION))
|
|
62
|
-
add("version", "WARN", `${ADAPTER_VERSION} installed; ${latest} is released: run antechamber upgrade`);
|
|
63
|
+
add("version", "WARN", `${ADAPTER_VERSION} installed; ${latest} is released: ${managedByExtension(ctx.env) ? "update the antechamber extension in OpenChamber" : "run antechamber upgrade"}`);
|
|
63
64
|
else
|
|
64
65
|
add("version", "PASS", ADAPTER_VERSION);
|
|
65
66
|
// A released fix is live only once OpenChamber relaunches the adapter.
|
package/dist/commands/setup.js
CHANGED
|
@@ -12,23 +12,12 @@ function writeAtomically(path, content, ctx) {
|
|
|
12
12
|
ctx.fs.writeFileSync(temporary, content, { mode: 0o600, flag: "wx" });
|
|
13
13
|
ctx.fs.renameSync(temporary, path);
|
|
14
14
|
}
|
|
15
|
-
/** The bundled
|
|
16
|
-
function
|
|
17
|
-
const dir = resolve(dirname(ctx.cliPath), "..", "extensions", "
|
|
18
|
-
const built = ["package.json", "panel/main.js", "service/main.js"].every((file) => ctx.fs.existsSync(join(dir, file)));
|
|
15
|
+
/** The bundled antechamber OpenChamber extension folder, when this installation has its built files. */
|
|
16
|
+
function antechamberExtensionDir(ctx) {
|
|
17
|
+
const dir = resolve(dirname(ctx.cliPath), "..", "extensions", "antechamber");
|
|
18
|
+
const built = ["package.json", "panel/main.js", "status/main.js", "service/main.js", "runtime/launcher.js"].every((file) => ctx.fs.existsSync(join(dir, file)));
|
|
19
19
|
return built ? dir : undefined;
|
|
20
20
|
}
|
|
21
|
-
/** The bundled OmO Work status-section extension folder, when this installation has its built files. */
|
|
22
|
-
function omoWorkExtensionDir(ctx) {
|
|
23
|
-
const dir = resolve(dirname(ctx.cliPath), "..", "extensions", "omo-work");
|
|
24
|
-
const built = ["package.json", "status/main.js", "service/main.js"].every((file) => ctx.fs.existsSync(join(dir, file)));
|
|
25
|
-
return built ? dir : undefined;
|
|
26
|
-
}
|
|
27
|
-
/** The bundled OmO Compatibility extension folder; it is a manifest only, so it needs no build. */
|
|
28
|
-
function omoCompatExtensionDir(ctx) {
|
|
29
|
-
const dir = resolve(dirname(ctx.cliPath), "..", "extensions", "omo-compat");
|
|
30
|
-
return ctx.fs.existsSync(join(dir, "package.json")) ? dir : undefined;
|
|
31
|
-
}
|
|
32
21
|
/** Plan all inputs before applying changes; dependencies are injected for hermetic tests. */
|
|
33
22
|
export function setup(options, ctx = createContext()) {
|
|
34
23
|
const lines = [];
|
|
@@ -49,8 +38,8 @@ export function setup(options, ctx = createContext()) {
|
|
|
49
38
|
: ctx.cliPath;
|
|
50
39
|
if (binary === undefined)
|
|
51
40
|
throw new Error(`Cannot resolve executable --binary ${options.binary}`);
|
|
52
|
-
if (binary === ctx.cliPath && !ctx.fs.readFileSync(binary, "utf8").startsWith("#!/usr/bin/env
|
|
53
|
-
throw new Error(`Package CLI ${binary} is missing its
|
|
41
|
+
if (binary === ctx.cliPath && !ctx.fs.readFileSync(binary, "utf8").startsWith("#!/usr/bin/env bun\n")) {
|
|
42
|
+
throw new Error(`Package CLI ${binary} is missing its bun shebang; run npm run build`);
|
|
54
43
|
}
|
|
55
44
|
let launcher;
|
|
56
45
|
let launcherText;
|
|
@@ -63,7 +52,7 @@ export function setup(options, ctx = createContext()) {
|
|
|
63
52
|
realpath: (path) => ctx.fs.realpathSync(path),
|
|
64
53
|
}, () => ctx.exec(npmBinaryFor(), ["root", "-g"]));
|
|
65
54
|
launcher = autoUpdateLauncherPath(ctx);
|
|
66
|
-
launcherText = autoUpdateLauncherText(binary);
|
|
55
|
+
launcherText = autoUpdateLauncherText(binary, ctx.bunBinary);
|
|
67
56
|
if (ctx.fs.existsSync(launcher))
|
|
68
57
|
oldLauncher = ctx.fs.readFileSync(launcher, "utf8");
|
|
69
58
|
}
|
|
@@ -181,17 +170,9 @@ export function setup(options, ctx = createContext()) {
|
|
|
181
170
|
if (options.profile !== undefined && options.settings === undefined) {
|
|
182
171
|
report(`OPENCHAMBER_DATA_DIR=${shellQuote(resolve(ctx.cwd, options.profile))} openchamber serve`);
|
|
183
172
|
}
|
|
184
|
-
const extension =
|
|
173
|
+
const extension = antechamberExtensionDir(ctx);
|
|
185
174
|
if (extension !== undefined) {
|
|
186
|
-
report(`Optional OmO Graph
|
|
187
|
-
}
|
|
188
|
-
const work = omoWorkExtensionDir(ctx);
|
|
189
|
-
if (work !== undefined) {
|
|
190
|
-
report(`Optional OmO Work section (todo phases, monitors, eval cells; OpenChamber 2.x): Settings \u2192 Extensions \u2192 Add \u2192 Folder: ${work}`);
|
|
191
|
-
}
|
|
192
|
-
const compat = omoCompatExtensionDir(ctx);
|
|
193
|
-
if (compat !== undefined) {
|
|
194
|
-
report(`Optional OmO Compatibility extension (eval card headers): Settings \u2192 Extensions \u2192 Add \u2192 Folder: ${compat}`);
|
|
175
|
+
report(`Optional antechamber extension (OmO Graph, OmO Work, OmO tool headers; OpenChamber 2.3.2+): Settings \u2192 Extensions \u2192 Add \u2192 Folder: ${extension}`);
|
|
195
176
|
}
|
|
196
177
|
return lines;
|
|
197
178
|
}
|