@tangle-network/agent-runtime 10.0.23 → 10.0.25

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 (81) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/dist/{activation-D_J9qCzU.js → activation-Cisx6g4A.js} +2 -2
  3. package/dist/{activation-D_J9qCzU.js.map → activation-Cisx6g4A.js.map} +1 -1
  4. package/dist/{activation-DOzkzTrl.d.ts → activation-oYJrqzpN.d.ts} +2 -2
  5. package/dist/agent.d.ts +1 -1
  6. package/dist/agent.js +3 -3
  7. package/dist/{delegate-DCZPcYy8.js → delegate-CwMTrSRm.js} +2 -2
  8. package/dist/{delegate-DCZPcYy8.js.map → delegate-CwMTrSRm.js.map} +1 -1
  9. package/dist/{driver-control-acknowledgers-CgGt3NcX.js → driver-control-acknowledgers-B213ctJ9.js} +7 -7
  10. package/dist/{driver-control-acknowledgers-CgGt3NcX.js.map → driver-control-acknowledgers-B213ctJ9.js.map} +1 -1
  11. package/dist/durable-writer-thread.js +2 -2
  12. package/dist/durable.d.ts +1 -1
  13. package/dist/durable.js +14 -13
  14. package/dist/durable.js.map +1 -1
  15. package/dist/{graph-B3pBmvnf.js → graph-DP8O_w3P.js} +7 -6
  16. package/dist/{graph-B3pBmvnf.js.map → graph-DP8O_w3P.js.map} +1 -1
  17. package/dist/{improve-DhOOHHRz.js → improve-WN8sqSH1.js} +5 -5
  18. package/dist/{improve-DhOOHHRz.js.map → improve-WN8sqSH1.js.map} +1 -1
  19. package/dist/index.d.ts +41 -6
  20. package/dist/index.js +55 -21
  21. package/dist/index.js.map +1 -1
  22. package/dist/intelligence.d.ts +2 -2
  23. package/dist/intelligence.js +4 -4
  24. package/dist/kernel.d.ts +2 -2
  25. package/dist/kernel.js +15 -15
  26. package/dist/{loop-runner-L594gDYR.js → loop-runner-B4Vjh1p9.js} +2 -2
  27. package/dist/{loop-runner-L594gDYR.js.map → loop-runner-B4Vjh1p9.js.map} +1 -1
  28. package/dist/{loop-runner-CcXKPnMR.d.ts → loop-runner-Dc-Vij6a.d.ts} +2 -2
  29. package/dist/loop-runner-bin.d.ts +1 -1
  30. package/dist/loop-runner-bin.js +1 -1
  31. package/dist/mcp/bin.js +3 -3
  32. package/dist/mcp/index.d.ts +1 -1
  33. package/dist/mcp/index.js +6 -6
  34. package/dist/mcp/memory-bin.js +1 -1
  35. package/dist/profiles.d.ts +1 -1
  36. package/dist/{provision-supervisor-Be-6HBsX.js → provision-supervisor-CqPcPBTA.js} +5 -5
  37. package/dist/{provision-supervisor-Be-6HBsX.js.map → provision-supervisor-CqPcPBTA.js.map} +1 -1
  38. package/dist/{result-blob-store-CJjp44Mz.js → result-blob-store-BZwRmrFF.js} +2 -2
  39. package/dist/{result-blob-store-CJjp44Mz.js.map → result-blob-store-BZwRmrFF.js.map} +1 -1
  40. package/dist/{run-cancellation-BNBmsY3a.js → run-cancellation-uCwV2Ra7.js} +2 -2
  41. package/dist/{run-cancellation-BNBmsY3a.js.map → run-cancellation-uCwV2Ra7.js.map} +1 -1
  42. package/dist/{run-reopen-Cr2SHmYa.js → run-reopen-YJwUAmv6.js} +6 -6
  43. package/dist/{run-reopen-Cr2SHmYa.js.map → run-reopen-YJwUAmv6.js.map} +1 -1
  44. package/dist/{run-state-Bko0BF0_.js → run-state-DXePNDvP.js} +5 -5
  45. package/dist/{run-state-Bko0BF0_.js.map → run-state-DXePNDvP.js.map} +1 -1
  46. package/dist/{runtime-Dfwc9cjt.js → runtime-DdfY-j79.js} +59 -38
  47. package/dist/{runtime-Dfwc9cjt.js.map → runtime-DdfY-j79.js.map} +1 -1
  48. package/dist/{search-executor-DnWnh4kj.js → search-executor-COdCsn9r.js} +4 -4
  49. package/dist/{search-executor-DnWnh4kj.js.map → search-executor-COdCsn9r.js.map} +1 -1
  50. package/dist/{server-RCsa_gyH.js → server-WSOQ-lg5.js} +4 -4
  51. package/dist/{server-RCsa_gyH.js.map → server-WSOQ-lg5.js.map} +1 -1
  52. package/dist/{settle-record-BlIw2MU1.js → settle-record-DWae7fwV.js} +2 -2
  53. package/dist/{settle-record-BlIw2MU1.js.map → settle-record-DWae7fwV.js.map} +1 -1
  54. package/dist/{structural-rollout-BLflx9cs.js → structural-rollout-kOx5PFfU.js} +4 -4
  55. package/dist/{structural-rollout-BLflx9cs.js.map → structural-rollout-kOx5PFfU.js.map} +1 -1
  56. package/dist/{supervise-037R-zl1.js → supervise-DEHDPDDb.js} +21 -11
  57. package/dist/supervise-DEHDPDDb.js.map +1 -0
  58. package/dist/{supervise-identity-CtxWEk1I.js → supervise-identity-DLPzZTp3.js} +2 -2
  59. package/dist/{supervise-identity-CtxWEk1I.js.map → supervise-identity-DLPzZTp3.js.map} +1 -1
  60. package/dist/{supervision-discovery-DKxqbnHf.js → supervision-discovery-8XnVtdOD.js} +3 -3
  61. package/dist/{supervision-discovery-DKxqbnHf.js.map → supervision-discovery-8XnVtdOD.js.map} +1 -1
  62. package/dist/{supervisor-DL4hO7UW.js → supervisor-C2KuUDnF.js} +507 -33
  63. package/dist/supervisor-C2KuUDnF.js.map +1 -0
  64. package/dist/{supervisor-accounting-DlDUl58C.js → supervisor-accounting-B0ofgTZX.js} +91 -14
  65. package/dist/supervisor-accounting-B0ofgTZX.js.map +1 -0
  66. package/dist/{supervisor-root-contract-BCbu1A4n.js → supervisor-root-contract-N7rW4Ynu.js} +3 -3
  67. package/dist/{supervisor-root-contract-BCbu1A4n.js.map → supervisor-root-contract-N7rW4Ynu.js.map} +1 -1
  68. package/dist/testing.d.ts +1 -1
  69. package/dist/testing.js +11 -11
  70. package/dist/{tool-server-n4XYpCok.js → tool-server-I63dnHZC.js} +39 -3
  71. package/dist/{tool-server-n4XYpCok.js.map → tool-server-I63dnHZC.js.map} +1 -1
  72. package/dist/{top-web-B-sHmI3g.js → top-web-BZM3es-m.js} +7 -7
  73. package/dist/{top-web-B-sHmI3g.js.map → top-web-BZM3es-m.js.map} +1 -1
  74. package/dist/tui/bin.js +3 -3
  75. package/dist/tui/index.d.ts +1 -1
  76. package/dist/tui/index.js +2 -2
  77. package/dist/{types-Pi5uCS88.d.ts → types-CMSBna4M.d.ts} +61 -41
  78. package/package.json +1 -1
  79. package/dist/supervise-037R-zl1.js.map +0 -1
  80. package/dist/supervisor-DL4hO7UW.js.map +0 -1
  81. package/dist/supervisor-accounting-DlDUl58C.js.map +0 -1
@@ -1,8 +1,8 @@
1
1
  import { c as publishExclusiveFenced, f as writeAtomicFenced, i as appendRunLinesFenced, p as becomeDurableWriter, t as appendDurableFenced, w as runWithWriteClaim } from "./durable-file-pao7FijS.js";
2
- import { a as closeStreamFile, c as openStreamFileFenced, d as syncStreamFileFenced, f as writeStreamLinesFenced } from "./supervisor-accounting-DlDUl58C.js";
2
+ import { a as closeStreamFile, c as openStreamFileFenced, d as syncStreamFileFenced, f as writeStreamLinesFenced } from "./supervisor-accounting-B0ofgTZX.js";
3
3
  import { i as prepareJsonlTailFenced, u as appendCommittedLine } from "./jsonl-file-B2ESMrTh.js";
4
4
  import { i as acquireRunLockFenced, o as releaseRunLockFenced } from "./run-lock-Dcr79Wql.js";
5
- import { n as makeRunDirectoryFenced, r as reopenSettleFenced } from "./run-reopen-Cr2SHmYa.js";
5
+ import { n as makeRunDirectoryFenced, r as reopenSettleFenced } from "./run-reopen-YJwUAmv6.js";
6
6
  import { parentPort, workerData } from "node:worker_threads";
7
7
  // src/durable/durable-writer-thread.ts
8
8
  /**
package/dist/durable.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { $d as PursuitNodeProjection, $m as CoordinationRejectReason, Ab as QuestionEscalationOutcome, Bb as AuthorizedDownMessage, Bd as VersionVerdict, Da as SupervisedResult, Db as EscalateQuestion, Ea as RootStreamReceipt, F as NodeId, Fd as PursuitVersionChain, Gd as SupervisedPursuitResult, Gm as CoordinationAuthentication, Gp as ParkedRun, Hb as ContinuityMode, Hd as SuperviseGraphPursuitOptions, Id as PursuitVersionStop, Jd as RunReopen, Jm as CoordinationPublicAddress, Jp as RunParkingRecord, Kd as superviseGraphPursuit, Kp as RunParkedError, Ld as PursuitVersions, Md as JudgedPursuitVersion, Nd as NextPursuitVersion, Pd as NextPursuitVersionInput, Qd as PursuitNodePlatform, Qm as CoordinationHttpAudit, Rd as SettledPursuitVersion, Sf as WorkerSlots, Ub as DownMessageAuthorizationInput, Ud as SupervisePursuitError, Vd as assertPursuitVersions, Wd as SupervisePursuitOptions, Wp as DeadlineCheckIn, Xd as PursuitCostProvenance, Xm as CoordinationTransportOptions, Yb as MapOnSettleRoute, Yd as PursuitObserverDelivery, Ym as CoordinationReadAccess, Yp as readRunParking, Zd as PursuitNodeCost, _S as readRunState, _p as SelectSeat, af as PursuitStatus, cf as ObserverJournal, dS as SpawnJournalReadOptions, df as observerRecordDigest, dr as readRootStream, ef as PursuitNodeTiming, fS as SpawnJournalReadRecord, ff as PursuitFork, fr as readRootStreamReceipt, gS as RunState, gb as WorkerWatchOptions, gm as ResolveDriveHarness, hp as SeatSelectionInput, if as PursuitRunTotals, lf as ObserverRecord, mS as readSpawnJournal, mm as DriveHarnessOwnerContext, mp as SeatSelection, nf as PursuitProjection, o_ as ToolLoopCompactionOptions, of as projectPursuit, ow as LoopTokenUsage, pS as SpawnJournalReadResult, pf as RUN_FORK_CORRELATION_KEYS, q as RetainedPendingCause, qd as supervisePursuit, qp as RunParkingPolicy, rf as PursuitRunProjection, sf as FileObserverJournal, tf as PursuitNodeUsage, uS as SpawnJournalCursor, uf as ObserverRecordKind, ur as RootStreamRecord, vf as AuthorizedSpawn, wm as ManagerWakePolicy, yf as AuthorizedSpawnContext, zd as VersionJudge, zx as AnalyzeOnSettleRoute } from "./types-Pi5uCS88.js";
1
+ import { $d as PursuitNodeUsage, $m as CoordinationHttpAudit, Ad as JudgedPursuitVersion, Bd as SuperviseGraphPursuitOptions, Bx as AnalyzeOnSettleRoute, F as NodeId, Fd as PursuitVersions, Gd as supervisePursuit, Gp as RunParkingPolicy, Hd as SupervisePursuitOptions, Hp as DeadlineCheckIn, Id as SettledPursuitVersion, Jd as PursuitCostProvenance, Kd as RunReopen, Km as CoordinationAuthentication, Kp as RunParkingRecord, Ld as VersionJudge, Md as NextPursuitVersionInput, Nd as PursuitVersionChain, Ob as EscalateQuestion, Pd as PursuitVersionStop, Qd as PursuitNodeTiming, Rd as VersionVerdict, Ta as SupervisedResult, Tm as ManagerWakePolicy, Ub as ContinuityMode, Ud as SupervisedPursuitResult, Up as ParkedRun, Vb as AuthorizedDownMessage, Vd as SupervisePursuitError, Wb as DownMessageAuthorizationInput, Wd as superviseGraphPursuit, Wp as RunParkedError, Xb as MapOnSettleRoute, Xd as PursuitNodePlatform, Xm as CoordinationReadAccess, Yd as PursuitNodeCost, Ym as CoordinationPublicAddress, Zd as PursuitNodeProjection, Zm as CoordinationTransportOptions, _S as RunState, _b as WorkerWatchOptions, _f as AuthorizedSpawnContext, _m as ResolveDriveHarness, af as FileObserverJournal, bf as WorkerSlots, cf as ObserverRecordKind, cm as readRootStreamReceipt, dS as SpawnJournalCursor, df as RUN_FORK_CORRELATION_KEYS, ef as PursuitProjection, eh as CoordinationRejectReason, fS as SpawnJournalReadOptions, fp as SeatSelection, gf as AuthorizedSpawn, hS as readSpawnJournal, hm as DriveHarnessOwnerContext, hp as SelectSeat, if as projectPursuit, jb as QuestionEscalationOutcome, jd as NextPursuitVersion, lf as observerRecordDigest, mS as SpawnJournalReadResult, nf as PursuitRunTotals, of as ObserverJournal, om as RootStreamRecord, pS as SpawnJournalReadRecord, pp as SeatSelectionInput, q as RetainedPendingCause, qd as PursuitObserverDelivery, qp as readRunParking, rf as PursuitStatus, s_ as ToolLoopCompactionOptions, sf as ObserverRecord, sm as readRootStream, sw as LoopTokenUsage, tf as PursuitRunProjection, uf as PursuitFork, vS as readRunState, wa as RootStreamReceipt, zd as assertPursuitVersions } from "./types-CMSBna4M.js";
2
2
  import { n as RuntimeDecisionKind, r as RuntimeDecisionPoint, t as RuntimeDecisionEvidenceRef } from "./runtime-hooks-DPghSHV7.js";
3
3
  import { a as ChatTurnProducer, c as handleChatTurn, i as ChatTurnIdentity, n as ChatStreamEvent, o as ChatTurnResult, r as ChatTurnHooks, s as RunChatTurnInput, t as deriveExecutionId } from "./execution-handle-CujvqgCn.js";
4
4
  import { AgentProfile } from "@tangle-network/agent-interface";
package/dist/durable.js CHANGED
@@ -1,22 +1,22 @@
1
- import { Fn as FileObserverJournal, In as createFileObserverHooks, Ln as observerRecordDigest, T as supervisorRunDir, X as FileSpawnJournal, Xr as authoredProfileDigest, l as readRootStream, ln as loadSpawnForest, u as readRootStreamReceipt } from "./supervisor-accounting-DlDUl58C.js";
2
- import { c as readRunParking, r as RunParkedError } from "./supervisor-DL4hO7UW.js";
1
+ import { In as FileObserverJournal, Ln as createFileObserverHooks, Rn as observerRecordDigest, T as supervisorRunDir, X as FileSpawnJournal, Zr as authoredProfileDigest, l as readRootStream, u as readRootStreamReceipt, un as loadSpawnForest } from "./supervisor-accounting-B0ofgTZX.js";
2
+ import { c as readRunParking, r as RunParkedError } from "./supervisor-C2KuUDnF.js";
3
3
  import { n as handleChatTurn, t as deriveExecutionId } from "./execution-handle-Bd2_nUB6.js";
4
- import { n as projectPursuit, t as discoverDurableSupervisionRun } from "./supervision-discovery-DKxqbnHf.js";
4
+ import { n as projectPursuit, t as discoverDurableSupervisionRun } from "./supervision-discovery-8XnVtdOD.js";
5
5
  import { a as applyExactAgentProfileDiff } from "./profile-Cxl_Ajl2.js";
6
6
  import { f as RuntimeRunStateError, m as ValidationError } from "./errors-DG8yufqX.js";
7
7
  import { _ as failedItems, t as isNoEntError, v as isFiniteNumber } from "./jsonl-file-B2ESMrTh.js";
8
8
  import { c as errorMessage, o as cloneTokenUsage } from "./util-qsH5cC9S.js";
9
- import { a as readFailureRecord, c as writeFailureRecord, i as parseSettleRecord, l as writeSettleRecord, n as SETTLE_RECORD_FILE, o as readSettleRecord, r as SettledRunDirectoryError, t as FAILURE_RECORD_FILE } from "./settle-record-BlIw2MU1.js";
10
- import { c as ASSISTANT_REASONING_SPAN, d as runToolSpans, t as supervise, u as rootStreamToolSpans, y as superviseRootProfile } from "./supervise-037R-zl1.js";
11
- import { R as contentAddress, i as runtimeFailureCause } from "./tool-server-n4XYpCok.js";
9
+ import { a as readFailureRecord, c as writeFailureRecord, i as parseSettleRecord, l as writeSettleRecord, n as SETTLE_RECORD_FILE, o as readSettleRecord, r as SettledRunDirectoryError, t as FAILURE_RECORD_FILE } from "./settle-record-DWae7fwV.js";
10
+ import { c as ASSISTANT_REASONING_SPAN, d as runToolSpans, t as supervise, u as rootStreamToolSpans, y as superviseRootProfile } from "./supervise-DEHDPDDb.js";
11
+ import { R as contentAddress, i as runtimeFailureCause } from "./tool-server-I63dnHZC.js";
12
12
  import { a as readRunDirectoryLock, n as RunDirectoryLockedError, r as acquireRunDirectoryLock, s as runDirectoryHolderIsLive, t as RUN_DIRECTORY_LOCK_FILE } from "./run-lock-Dcr79Wql.js";
13
13
  import { a as errMessage, f as defaultRedactor, i as causeChain, u as providerTraceId } from "./snapshot-BKLziJ5K.js";
14
- import { t as FileResultBlobStore } from "./result-blob-store-CJjp44Mz.js";
15
- import { n as readSpawnJournal, t as readRunState } from "./run-state-Bko0BF0_.js";
16
- import { s as rootCoordinationOwner, u as FileCoordinationLog } from "./supervise-identity-CtxWEk1I.js";
17
- import { i as superviseAgentGraph, s as graphExecutionOptions } from "./graph-B3pBmvnf.js";
14
+ import { t as FileResultBlobStore } from "./result-blob-store-BZwRmrFF.js";
15
+ import { n as readSpawnJournal, t as readRunState } from "./run-state-DXePNDvP.js";
16
+ import { s as rootCoordinationOwner, u as FileCoordinationLog } from "./supervise-identity-DLPzZTp3.js";
17
+ import { i as superviseAgentGraph, s as graphExecutionOptions } from "./graph-DP8O_w3P.js";
18
18
  import { a as withPursuitContext, t as composeRuntimeHooks } from "./runtime-hooks-CsW2pfFk.js";
19
- import { i as reopenSettledRun, t as assertRunReopen } from "./run-reopen-Cr2SHmYa.js";
19
+ import { i as reopenSettledRun, t as assertRunReopen } from "./run-reopen-YJwUAmv6.js";
20
20
  import { agentProfileSchema, canonicalAgentProfileDigest, canonicalCandidateDigest, sha256Bytes } from "@tangle-network/agent-interface";
21
21
  import { basename, dirname, isAbsolute, join, relative, resolve, sep } from "node:path";
22
22
  import { access, readFile, realpath } from "node:fs/promises";
@@ -1398,7 +1398,8 @@ var SupervisePursuitError = class extends Error {
1398
1398
  * Each `runDir` owns its lock and journals; Intelligence joins directories by `pursuitId`.
1399
1399
  * Agents never receive the observer path or projection.
1400
1400
  *
1401
- * `result.json` seals a segment and refuses re-entry before compute; `failure.json` records
1401
+ * `result.json` seals a segment and refuses re-entry before compute unless an explicit `reopen`
1402
+ * continues it from the workspace settlement kept; `failure.json` records
1402
1403
  * the latest throw and permits a corrected retry. Both pursuit entrypoints use the same
1403
1404
  * directory lifecycle below. A competing process is refused with the lock holder's identity;
1404
1405
  * an abandoned `supervise.lock.guard` requires confirmation of inactivity before removal.
@@ -1446,7 +1447,7 @@ async function superviseGraphPursuit(graph, opts) {
1446
1447
  /** The pursuit identity and run directory both durable entries require. */
1447
1448
  function assertPursuitDirectory(opts, entry) {
1448
1449
  for (const field of ["pursuitId", "runDir"]) if (opts[field].trim().length === 0) throw new TypeError(`${entry}: ${field} must be non-empty`);
1449
- if (opts.retainedAtSettlement === "keep") throw new TypeError(`${entry}: retainedAtSettlement 'keep' cannot hold, because a settled pursuit is never re-entered`);
1450
+ if (opts.retainedAtSettlement === "keep") throw new TypeError(`${entry}: retainedAtSettlement 'keep' cannot hold, because a reopen continues the root owner alone; retainRestorePoint keeps its workspace`);
1450
1451
  }
1451
1452
  /** Own the directory lock, terminal records and observer lifecycle for both pursuit entries. */
1452
1453
  async function runDurablePursuit(opts, execute, settled, budget) {