antechamber 1.0.37 → 1.0.39
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
CHANGED
|
@@ -7,6 +7,20 @@ and this project uses [Semantic Versioning](https://semver.org/).
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [1.0.39] - 2026-11-04
|
|
11
|
+
|
|
12
|
+
- fix(v2): give each task batch card its own tool id (#90)
|
|
13
|
+
|
|
14
|
+
## [1.0.38] - 2026-11-03
|
|
15
|
+
|
|
16
|
+
### Fixed
|
|
17
|
+
|
|
18
|
+
- Reverting a `/compact` message works again. The revert was rejected as an unknown message and OpenChamber 2.x
|
|
19
|
+
dropped the error silently. It now returns the conversation to where it was before the compaction.
|
|
20
|
+
- Batched `task` calls (`tasks: [...]`) no longer show as interrupted in OpenChamber 2.x. Every card went out under
|
|
21
|
+
the same tool id, so OpenChamber merged them into one, showed the wrong titles, and marked the leftovers
|
|
22
|
+
"Interrupted" when the message completed. Each card now has its own id.
|
|
23
|
+
|
|
10
24
|
## [1.0.37] - 2026-11-03
|
|
11
25
|
|
|
12
26
|
- feat(session-hosts): tear down private OmO hosts on macOS (#85)
|
package/dist/session-tree.js
CHANGED
|
@@ -319,8 +319,12 @@ export function bindMessageEntries(s, tree) {
|
|
|
319
319
|
s.tree.localShellTurns = localShellTurns.filter((turn) => s.tree.messageEntries[turn.messages[1].info.id] === undefined);
|
|
320
320
|
}
|
|
321
321
|
function entryForMessage(s, tree, messageID) {
|
|
322
|
+
// A compaction's `/compact` row is never bound; its ID carries the native compaction entry ID.
|
|
323
|
+
const compaction = /^msg_compaction_(.+)$/.exec(messageID)?.[1];
|
|
322
324
|
const entryId = s.tree.messageEntries[messageID];
|
|
323
|
-
const entry =
|
|
325
|
+
const entry = entryId !== undefined
|
|
326
|
+
? tree.entries.find((candidate) => candidate.id === entryId)
|
|
327
|
+
: tree.entries.find((candidate) => candidate.type === "compaction" && candidate.id === compaction);
|
|
324
328
|
if (!entry || !s.messages?.some((message) => message.info.id === messageID)) {
|
|
325
329
|
throw new SessionTreeError(`Unknown messageID: ${messageID}`);
|
|
326
330
|
}
|
package/dist/v2.js
CHANGED
|
@@ -203,17 +203,28 @@ function backgroundShell(part) {
|
|
|
203
203
|
return undefined;
|
|
204
204
|
return { output: typeof output === "string" ? output : "", metadata: { ...metadata, status: "running", shellID } };
|
|
205
205
|
}
|
|
206
|
+
/**
|
|
207
|
+
* OpenChamber 2.x keys a tool part by this id alone, but one `task` call with `tasks` expands into a card per item
|
|
208
|
+
* (`taskParts`), all sharing the call id. Items after the first get their own id, or the cards merge into one and
|
|
209
|
+
* the leftovers are marked "Interrupted" when the message completes.
|
|
210
|
+
*/
|
|
211
|
+
function v2ToolId(part) {
|
|
212
|
+
const prefix = `prt_task_${part.callID}_`;
|
|
213
|
+
const index = part.id.startsWith(prefix) ? part.id.slice(prefix.length) : "0";
|
|
214
|
+
return index === "0" ? part.callID : `${part.callID}#${index}`;
|
|
215
|
+
}
|
|
206
216
|
function toolContent(part) {
|
|
207
217
|
const st = part.state;
|
|
208
218
|
const name = v2ToolName(part.tool);
|
|
209
219
|
const start = st.status === "pending" ? undefined : st.time.start;
|
|
210
220
|
const end = st.status === "pending" || st.status === "running" ? undefined : st.time.end;
|
|
221
|
+
const id = v2ToolId(part);
|
|
211
222
|
const base = {
|
|
212
223
|
type: "tool",
|
|
213
|
-
id
|
|
224
|
+
id,
|
|
214
225
|
name,
|
|
215
226
|
// keep the SDK v1 spellings too — harmless and tolerates older readers
|
|
216
|
-
callID:
|
|
227
|
+
callID: id,
|
|
217
228
|
tool: name,
|
|
218
229
|
executed: false,
|
|
219
230
|
time: {
|
|
@@ -610,7 +621,7 @@ export class V2EventTranslator {
|
|
|
610
621
|
}
|
|
611
622
|
ts.callID = part.callID;
|
|
612
623
|
const frames = [];
|
|
613
|
-
const base = { sessionID: part.sessionID, assistantMessageID: part.messageID, id: part
|
|
624
|
+
const base = { sessionID: part.sessionID, assistantMessageID: part.messageID, id: v2ToolId(part) };
|
|
614
625
|
const state = part.state;
|
|
615
626
|
if (state.status === "pending") {
|
|
616
627
|
if (!ts.started) {
|