@tangle-network/agent-runtime 0.92.0 → 0.92.1

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.
Files changed (29) hide show
  1. package/dist/agent.js +47 -45
  2. package/dist/agent.js.map +1 -1
  3. package/dist/{chunk-RSWM2ZKM.js → chunk-4FPXIMSI.js} +3 -3
  4. package/dist/{chunk-I7WVPJBZ.js → chunk-BVVRQ4YC.js} +4 -4
  5. package/dist/{chunk-3BE7KTMU.js → chunk-FDJ7AHXG.js} +2 -2
  6. package/dist/{chunk-APVPRF4Y.js → chunk-J2K6WIG6.js} +13 -7
  7. package/dist/{chunk-APVPRF4Y.js.map → chunk-J2K6WIG6.js.map} +1 -1
  8. package/dist/{chunk-7VJJJ2T2.js → chunk-LQQPGRKT.js} +2 -2
  9. package/dist/{chunk-IGGZGKJD.js → chunk-P6B3Z7PR.js} +3 -3
  10. package/dist/{chunk-GDAQUFG6.js → chunk-R5GWDTM3.js} +2 -2
  11. package/dist/{chunk-AUEIDTR3.js → chunk-TKJ3Q6CQ.js} +2 -2
  12. package/dist/{chunk-6O5USWVH.js → chunk-UO2L5VTP.js} +2 -2
  13. package/dist/index.js +8 -8
  14. package/dist/intelligence.js +3 -4
  15. package/dist/intelligence.js.map +1 -1
  16. package/dist/knowledge.js +3 -3
  17. package/dist/loop-runner-bin.js +5 -5
  18. package/dist/loops.js +4 -4
  19. package/dist/mcp/bin.js +3 -3
  20. package/dist/mcp/index.js +6 -6
  21. package/package.json +30 -16
  22. /package/dist/{chunk-RSWM2ZKM.js.map → chunk-4FPXIMSI.js.map} +0 -0
  23. /package/dist/{chunk-I7WVPJBZ.js.map → chunk-BVVRQ4YC.js.map} +0 -0
  24. /package/dist/{chunk-3BE7KTMU.js.map → chunk-FDJ7AHXG.js.map} +0 -0
  25. /package/dist/{chunk-7VJJJ2T2.js.map → chunk-LQQPGRKT.js.map} +0 -0
  26. /package/dist/{chunk-IGGZGKJD.js.map → chunk-P6B3Z7PR.js.map} +0 -0
  27. /package/dist/{chunk-GDAQUFG6.js.map → chunk-R5GWDTM3.js.map} +0 -0
  28. /package/dist/{chunk-AUEIDTR3.js.map → chunk-TKJ3Q6CQ.js.map} +0 -0
  29. /package/dist/{chunk-6O5USWVH.js.map → chunk-UO2L5VTP.js.map} +0 -0
@@ -4,7 +4,7 @@ import {
4
4
  runAgentic,
5
5
  sample,
6
6
  sampleThenRefine
7
- } from "./chunk-3BE7KTMU.js";
7
+ } from "./chunk-FDJ7AHXG.js";
8
8
  import {
9
9
  createExecutor,
10
10
  createExecutorRegistry,
@@ -15,13 +15,13 @@ import {
15
15
  probeSandboxCapabilities,
16
16
  runLoop,
17
17
  supervise
18
- } from "./chunk-6O5USWVH.js";
18
+ } from "./chunk-UO2L5VTP.js";
19
19
  import {
20
20
  createSupervisor,
21
21
  notifyRuntimeHookEvent,
22
22
  settledToIteration,
23
23
  withDriverExecutor
24
- } from "./chunk-APVPRF4Y.js";
24
+ } from "./chunk-J2K6WIG6.js";
25
25
  import {
26
26
  InMemoryResultBlobStore,
27
27
  InMemorySpawnJournal
@@ -5126,4 +5126,4 @@ export {
5126
5126
  computeFindingId,
5127
5127
  makeFinding
5128
5128
  };
5129
- //# sourceMappingURL=chunk-I7WVPJBZ.js.map
5129
+ //# sourceMappingURL=chunk-BVVRQ4YC.js.map
@@ -2,7 +2,7 @@ import {
2
2
  createSupervisor,
3
3
  routerToolLoop,
4
4
  withDriverExecutor
5
- } from "./chunk-APVPRF4Y.js";
5
+ } from "./chunk-J2K6WIG6.js";
6
6
  import {
7
7
  InMemoryResultBlobStore,
8
8
  InMemorySpawnJournal
@@ -1226,4 +1226,4 @@ export {
1226
1226
  defaultExtractCandidate,
1227
1227
  structuralRollout
1228
1228
  };
1229
- //# sourceMappingURL=chunk-3BE7KTMU.js.map
1229
+ //# sourceMappingURL=chunk-FDJ7AHXG.js.map
@@ -1694,7 +1694,7 @@ function buildRuntimeEventOtelSpans(events, traceId, parentSpanId, options = {})
1694
1694
  }
1695
1695
  }
1696
1696
  const startMs = eventTimestampMs(event);
1697
- const endMs = event.type === "llm_call" && event.latencyMs !== void 0 ? startMs + event.latencyMs : startMs;
1697
+ const endMs = event.type === "llm_call" && event.latencyMs !== void 0 && Number.isFinite(event.latencyMs) ? startMs + event.latencyMs : startMs;
1698
1698
  const span = flatOtelSpan(name, attrs, traceId, startMs, parentSpanId, endMs);
1699
1699
  if (event.type === "backend_error" || event.type === "final" && event.status !== "completed") {
1700
1700
  span.status = { code: 2, message: attrs["error.message"]?.toString() ?? event.type };
@@ -1902,13 +1902,19 @@ function parseHeadersFromEnv() {
1902
1902
  return out;
1903
1903
  }
1904
1904
  function toAttributes(record) {
1905
- return Object.entries(record).map(([key, value]) => ({
1906
- key,
1907
- value: typeof value === "number" ? Number.isInteger(value) ? { intValue: value.toString() } : { doubleValue: value } : typeof value === "boolean" ? { boolValue: value } : { stringValue: value }
1908
- }));
1905
+ return Object.entries(record).flatMap(([key, value]) => {
1906
+ if (typeof value === "number" && !Number.isFinite(value)) return [];
1907
+ return [
1908
+ {
1909
+ key,
1910
+ value: typeof value === "number" ? Number.isInteger(value) ? { intValue: value.toString() } : { doubleValue: value } : typeof value === "boolean" ? { boolValue: value } : { stringValue: value }
1911
+ }
1912
+ ];
1913
+ });
1909
1914
  }
1910
1915
  function msToNs(ms) {
1911
- return (BigInt(Math.floor(ms)) * 1000000n).toString();
1916
+ const safeMs = Number.isFinite(ms) ? ms : Date.now();
1917
+ return (BigInt(Math.floor(safeMs)) * 1000000n).toString();
1912
1918
  }
1913
1919
  function padSpanId(id) {
1914
1920
  const cleaned = id.replace(/-/g, "");
@@ -2163,4 +2169,4 @@ export {
2163
2169
  INTELLIGENCE_WIRE_VERSION,
2164
2170
  exportEvalRuns
2165
2171
  };
2166
- //# sourceMappingURL=chunk-APVPRF4Y.js.map
2172
+ //# sourceMappingURL=chunk-J2K6WIG6.js.map