@amaster.ai/employee-runtime-connector 0.1.1-beta.50 → 0.1.1-beta.52

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.
@@ -8403,13 +8403,31 @@ function maybeCapturePiMessage(event, messages, usage) {
8403
8403
  }
8404
8404
  function piMcpToolResults(event) {
8405
8405
  const results = [];
8406
+ const seen = /* @__PURE__ */ new Set();
8407
+ const retain = (parsed) => {
8408
+ if (!parsed) return;
8409
+ const invocationId = readString(parsed.invocationId);
8410
+ const intentId = readString(asRecord(parsed.artifactIntent).intentId);
8411
+ const identities = [
8412
+ ...invocationId ? [`invocation:${invocationId}`] : [],
8413
+ ...intentId ? [`artifact-intent:${intentId}`] : []
8414
+ ];
8415
+ if (identities.some((identity2) => seen.has(identity2))) return;
8416
+ for (const identity2 of identities) seen.add(identity2);
8417
+ results.push(parsed);
8418
+ };
8406
8419
  const messages = [event?.message, ...Array.isArray(event?.messages) ? event.messages : []];
8407
8420
  for (const rawMessage of messages) {
8408
8421
  const message = asRecord(rawMessage);
8409
8422
  if (message.role !== "toolResult") continue;
8410
8423
  const structuredContent = asRecord(asRecord(asRecord(message.details).mcpResult).structuredContent);
8411
- const parsed = governedMcpToolResult(structuredContent);
8412
- if (parsed) results.push(parsed);
8424
+ retain(governedMcpToolResult(structuredContent));
8425
+ }
8426
+ if (readString(event?.type) === "tool_execution_end") {
8427
+ const structuredContent = asRecord(
8428
+ asRecord(asRecord(asRecord(event?.result).details).mcpResult).structuredContent
8429
+ );
8430
+ retain(governedMcpToolResult(structuredContent));
8413
8431
  }
8414
8432
  return results;
8415
8433
  }
@@ -10134,7 +10152,7 @@ var source_acquisition_compatibility_default = {
10134
10152
  };
10135
10153
 
10136
10154
  // src/amaster-runtime-daemon.mjs
10137
- var CONNECTOR_VERSION = "0.1.1-beta.50";
10155
+ var CONNECTOR_VERSION = "0.1.1-beta.52";
10138
10156
  var CONNECTOR_CONTRACT_VERSION = "2026-06-04.v1";
10139
10157
  var SOURCE_ACQUISITION_CAPABILITY = source_acquisition_compatibility_default.profileVersion;
10140
10158
  var SOURCE_ACQUISITION_PROFILE_VERSION = source_acquisition_compatibility_default.profileVersion;
@@ -6,7 +6,7 @@ import { basename, dirname, join, resolve } from "node:path";
6
6
  import { homedir, hostname } from "node:os";
7
7
  import { fileURLToPath } from "node:url";
8
8
 
9
- const CONNECTOR_VERSION = "0.1.1-beta.50";
9
+ const CONNECTOR_VERSION = "0.1.1-beta.52";
10
10
 
11
11
  const CAPABILITIES = [
12
12
  "remote_registration",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@amaster.ai/employee-runtime-connector",
3
- "version": "0.1.1-beta.50",
3
+ "version": "0.1.1-beta.52",
4
4
  "description": "MirrorX runtime connector CLI and daemon",
5
5
  "license": "MIT",
6
6
  "type": "module",