@stigmer/runner 0.1.0 → 0.1.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.
@@ -1 +1 @@
1
- {"hash":"9ac3c1b119ed74a8","builtAt":"2026-11-05T11:02:34.439Z","fileCount":385}
1
+ {"hash":"9ac3c1b119ed74a8","builtAt":"2026-11-06T23:48:07.437Z","fileCount":385}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stigmer/runner",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "description": "Embeddable Temporal worker that runs Stigmer's agent sessions — handles agent execution and MCP server management",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",
@@ -119,14 +119,14 @@
119
119
  "@opentelemetry/sdk-metrics": "^2.0.0",
120
120
  "@opentelemetry/sdk-trace-base": "^2.0.0",
121
121
  "@opentelemetry/sdk-trace-node": "^2.0.0",
122
- "@stigmer/artifact-fetch": "0.1.0",
123
- "@stigmer/eval-runtime": "0.1.0",
124
- "@stigmer/outbound": "0.1.0",
125
- "@stigmer/apis": "0.1.0",
126
- "@stigmer/temporal-codecs": "0.1.0",
127
- "@stigmer/session-log": "0.1.0",
128
- "@stigmer/tool-vocabulary": "0.1.0",
129
- "@stigmer/zip-structure": "0.1.0",
122
+ "@stigmer/artifact-fetch": "0.1.2",
123
+ "@stigmer/eval-runtime": "0.1.2",
124
+ "@stigmer/outbound": "0.1.2",
125
+ "@stigmer/apis": "0.1.2",
126
+ "@stigmer/temporal-codecs": "0.1.2",
127
+ "@stigmer/session-log": "0.1.2",
128
+ "@stigmer/tool-vocabulary": "0.1.2",
129
+ "@stigmer/zip-structure": "0.1.2",
130
130
  "@temporalio/activity": "1.16.2",
131
131
  "@temporalio/common": "1.16.2",
132
132
  "@temporalio/interceptors-opentelemetry": "1.16.2",
@@ -38,6 +38,7 @@ import {
38
38
  } from "../__test-utils__/paused-session-fixture.js";
39
39
  import { THINK_CALL_ID, THINK_RETIREMENT_MESSAGE, thinkBoundSession } from "../__test-utils__/think-bound-session.js";
40
40
  import { ApprovalAction, ToolCallStatus } from "../../../gen/turn/ai/stigmer/runner/turn/v1/enum_pb.js";
41
+ import { toolUseEventId } from "../../../harness/events/ids.js";
41
42
 
42
43
  const LIVE_MODEL = "claude-haiku-4.5";
43
44
  const MAX_COST_USD = 0.05;
@@ -88,8 +89,21 @@ describe.skipIf(!liveSecret("ANTHROPIC_API_KEY"))("ExecuteDeepAgent live — a s
88
89
  const executed = rows.filter((r) => r.id === EXECUTE_CALL_A.id);
89
90
  expect(executed, `the approved command ran once; rows: [${seen}]`).toHaveLength(1);
90
91
  expect(executed[0]?.status).toBe(ToolCallStatus.TOOL_CALL_COMPLETED);
91
- expect(rows.filter((r) => r.id === THINK_CALL_ID), "the old think row stays").toHaveLength(1);
92
- expect(rows.filter((r) => r.name === "think" && r.id !== THINK_CALL_ID), "the model calls no new think").toHaveLength(0);
92
+ // The old engine's think call is the session log's, written once with the
93
+ // paused turn; the resumed rows carry no copy of it (#2267), as the
94
+ // hermetic twin asserts.
95
+ const thinkUse = toolUseEventId(record.executionId, THINK_CALL_ID);
96
+ const thinkEvents = record.sessionEvents.flatMap((e) => {
97
+ if (e.event.case === "agentToolUse" && e.event.value.id === thinkUse) return [["use", e.event.value.name]];
98
+ if (e.event.case === "agentToolResult" && e.event.value.toolUseId === thinkUse) return [["result", e.event.value.isError]];
99
+ return [];
100
+ });
101
+ expect(thinkEvents, "the old engine's think call stays in the log, once").toEqual([
102
+ ["use", "think"],
103
+ ["result", false],
104
+ ]);
105
+ expect(rows.some((r) => r.id === THINK_CALL_ID), "the resumed rows carry no copy of it").toBe(false);
106
+ expect(rows.filter((r) => r.name === "think"), "the model calls no new think").toHaveLength(0);
93
107
  expect(record.lastFullRows?.messages.at(-1)?.content, "the model answered after the command").not.toBe("I will run the command.");
94
108
  expect(record.lastFullRows?.messages.at(-1)?.content.length).toBeGreaterThan(0);
95
109
  expect(cost).toBeGreaterThan(0);