@tangle-network/agent-runtime 0.109.2 → 0.110.0

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 (72) hide show
  1. package/dist/{activation-CM-L6TtL.js → activation-CsuHCZVN.js} +3 -3
  2. package/dist/{activation-CM-L6TtL.js.map → activation-CsuHCZVN.js.map} +1 -1
  3. package/dist/agent.d.ts +4 -4
  4. package/dist/agent.js +2 -2
  5. package/dist/agent.js.map +1 -1
  6. package/dist/{analyst-loop-C8cGThTW.js → analyst-loop-BoNIG2hA.js} +30 -9
  7. package/dist/analyst-loop-BoNIG2hA.js.map +1 -0
  8. package/dist/analyst-loop.d.ts +1 -1
  9. package/dist/analyst-loop.js +1 -1
  10. package/dist/candidate-execution/index.js +4 -4
  11. package/dist/{candidate-execution-nYMa-bc-.js → candidate-execution-Co3sRC_7.js} +4 -4
  12. package/dist/{candidate-execution-nYMa-bc-.js.map → candidate-execution-Co3sRC_7.js.map} +1 -1
  13. package/dist/{environment-provider-CfLUmKmf.js → environment-provider-BsHpW4Dp.js} +52 -5
  14. package/dist/environment-provider-BsHpW4Dp.js.map +1 -0
  15. package/dist/{environment-provider-CMqSAp-O.d.ts → environment-provider-CTEMEP9u.d.ts} +9 -1
  16. package/dist/environment-provider.d.ts +1 -1
  17. package/dist/environment-provider.js +1 -1
  18. package/dist/{improvement-adapter-BaAdfJKT.d.ts → improvement-adapter-D5gwwoXQ.d.ts} +2 -2
  19. package/dist/{improvement-cycle-9O4iVFOA.js → improvement-cycle-ryAyCLKN.js} +5 -5
  20. package/dist/{improvement-cycle-9O4iVFOA.js.map → improvement-cycle-ryAyCLKN.js.map} +1 -1
  21. package/dist/{index-BwY61sh3.d.ts → index-C-Zn0VrN.d.ts} +3 -3
  22. package/dist/{index-CFJ_1m1U.d.ts → index-D_OdNLe0.d.ts} +285 -92
  23. package/dist/{index-HsQm1Rrr.d.ts → index-WODlt7iz.d.ts} +6 -6
  24. package/dist/index.d.ts +5 -5
  25. package/dist/index.js +11 -11
  26. package/dist/intelligence.d.ts +2 -2
  27. package/dist/intelligence.js +39 -9
  28. package/dist/intelligence.js.map +1 -1
  29. package/dist/kernel.d.ts +3 -3
  30. package/dist/kernel.js +7 -7
  31. package/dist/{knowledge-1a38bcUT.js → knowledge-DBNAteaC.js} +5 -5
  32. package/dist/{knowledge-1a38bcUT.js.map → knowledge-DBNAteaC.js.map} +1 -1
  33. package/dist/knowledge.d.ts +1 -1
  34. package/dist/knowledge.js +1 -1
  35. package/dist/{loop-runner-bin-DUQF0bYz.d.ts → loop-runner-bin-BUm83y1g.d.ts} +4 -4
  36. package/dist/{loop-runner-bin-C35m19w0.js → loop-runner-bin-zE7DyGop.js} +4 -4
  37. package/dist/{loop-runner-bin-C35m19w0.js.map → loop-runner-bin-zE7DyGop.js.map} +1 -1
  38. package/dist/loop-runner-bin.d.ts +1 -1
  39. package/dist/loop-runner-bin.js +1 -1
  40. package/dist/mcp/bin.js +1 -1
  41. package/dist/mcp/index.d.ts +1 -1
  42. package/dist/mcp/index.js +5 -5
  43. package/dist/{openai-tools-DT9FH2_t.js → openai-tools-st-hERvA.js} +2 -2
  44. package/dist/{openai-tools-DT9FH2_t.js.map → openai-tools-st-hERvA.js.map} +1 -1
  45. package/dist/{prepare-Pr19X93k.js → prepare-BKVdOn0w.js} +15 -14
  46. package/dist/prepare-BKVdOn0w.js.map +1 -0
  47. package/dist/primeintellect/index.d.ts +1 -1
  48. package/dist/{protected-model-port-uthtDNqu.js → protected-model-port-BtldAE9j.js} +2 -2
  49. package/dist/{protected-model-port-uthtDNqu.js.map → protected-model-port-BtldAE9j.js.map} +1 -1
  50. package/dist/{runtime-dpJZmZtt.js → runtime-DSkMJb_X.js} +404 -15
  51. package/dist/runtime-DSkMJb_X.js.map +1 -0
  52. package/dist/{spawn-journal-CwPvKUTa.js → spawn-journal-DLhnom3e.js} +2 -2
  53. package/dist/{spawn-journal-CwPvKUTa.js.map → spawn-journal-DLhnom3e.js.map} +1 -1
  54. package/dist/{structural-rollout-ASQLr4-v.js → structural-rollout-CgnNy7_4.js} +3 -3
  55. package/dist/{structural-rollout-ASQLr4-v.js.map → structural-rollout-CgnNy7_4.js.map} +1 -1
  56. package/dist/{supervise-DyPmmhJ6.js → supervise-CeZtA1wu.js} +223 -107
  57. package/dist/supervise-CeZtA1wu.js.map +1 -0
  58. package/dist/{supervisor-sTJC9psT.js → supervisor-ByCPHcp9.js} +82 -24
  59. package/dist/supervisor-ByCPHcp9.js.map +1 -0
  60. package/dist/testing.js +9 -9
  61. package/dist/{types-CfGKhIuj.d.ts → types-zWfqDjeL.d.ts} +10 -1
  62. package/dist/{util-MVgdwuIS.js → util-Cc9g9Y-o.js} +2 -2
  63. package/dist/{util-MVgdwuIS.js.map → util-Cc9g9Y-o.js.map} +1 -1
  64. package/dist/{workspace-archive-C9w_rxt6.js → workspace-archive-CYYxZyA7.js} +2 -2
  65. package/dist/{workspace-archive-C9w_rxt6.js.map → workspace-archive-CYYxZyA7.js.map} +1 -1
  66. package/package.json +7 -7
  67. package/dist/analyst-loop-C8cGThTW.js.map +0 -1
  68. package/dist/environment-provider-CfLUmKmf.js.map +0 -1
  69. package/dist/prepare-Pr19X93k.js.map +0 -1
  70. package/dist/runtime-dpJZmZtt.js.map +0 -1
  71. package/dist/supervise-DyPmmhJ6.js.map +0 -1
  72. package/dist/supervisor-sTJC9psT.js.map +0 -1
@@ -1,5 +1,5 @@
1
1
  import { E as SandboxClient, h as LoopSandboxPlacement } from "../types-DnNGJ5Gz.js";
2
- import { $c as DetachedWinnerSelection, $l as DelegationStatus, $s as createDelegateHandler, Ac as DiffOptions, Al as SubmitInput, As as DEFAULT_AWAIT_EVENT_TIMEOUT_MS, Au as DELEGATION_TRACE_MAX_BYTES, Bc as JsonRpcMessage, Bl as DelegateResearchResult, Bs as SettledWorker, Bu as DelegationStateCorruptError, Cl as DelegationRecord, Dl as DelegationRunContext, Ds as CoordinationEvent, El as DelegationResumeTick, Es as AnalystRegistry, Fc as captureWorktreeDiff, Fl as DelegateCodeResult, Fs as QuestionLevel, Fu as buildDelegationTraceSpans, Gc as FeedbackStore, Gl as DelegationError, Gs as createInProcessTransport, Hc as McpToolDescriptor, Hl as DelegateUiAuditConfig, Hs as createCoordinationTools, Hu as FileDelegationStore, Ic as createWorktree, Il as DelegateFeedbackArgs, Is as QuestionOption, Iu as capDelegationTrace, Jc as CoderDelegate, Jl as DelegationHistoryEntry, Js as DELEGATE_INPUT_SCHEMA, Kc as InMemoryFeedbackStore, Kl as DelegationFeedbackSnapshot, Ks as createMcpServer, Lc as removeWorktree, Ll as DelegateFeedbackResult, Ls as QuestionPolicy, Lu as composeLoopTraceEmitters, Mc as GitRunner, Ml as hashIdempotencyInput, Ms as MakeWorkerAgent, Mu as DelegationTraceCaps, Nc as RemoveWorktreeOptions, Nl as DelegateCodeArgs, Ns as Question, Nu as DelegationTraceCollector, Ol as DelegationTaskQueue, Os as CoordinationTools, Pc as WorktreeHandle, Pl as DelegateCodeConfig, Ps as QuestionDecision, Pu as DelegationTraceSpan, Qc as DetachedSessionDelegateOptions, Ql as DelegationResultPayload, Qs as DelegateResult, Rl as DelegateResearchArgs, Rs as QuestionRecord, Ru as createDelegationTraceCollector, Sl as DelegationArgs, Tl as DelegationResumeDriver, Ts as AnalystFindingEvent, Uc as McpTransport, Ul as DelegateUiAuditResult, Us as McpServer, Uu as FileDelegationStoreOptions, Vc as JsonRpcResponse, Vl as DelegateUiAuditArgs, Vs as WorkerWatchOptions, Vu as DelegationStore, Wc as FeedbackEvent, Wl as DelegateUiAuditRoute, Ws as McpServerOptions, Wu as InMemoryDelegationStore, Xc as CoderReviewer, Xl as DelegationProfile, Xs as DelegateArgs, Yc as CoderReview, Yl as DelegationHistoryResult, Ys as DELEGATE_TOOL_NAME, Zc as DelegateRunCtx, Zl as DelegationProgress, Zs as DelegateHandlerOptions, _l as createDetachedTurnResumeDriver, al as DelegationExecutor, au as ResearchSource, bl as parseDetachedSessionRef, cl as SiblingSandboxExecutorOptions, cu as TraceContext, dl as DetachedSessionRefParts, du as traceContextToEnv, ec as validateDelegateArgs, ed as CoderOutput, el as SettleDetachedCoderTurnOptions, eu as DelegationStatusArgs, fl as DetachedTurn, gl as RunDetachedTurnOptions, hl as DriveTurnTick, il as settleDetachedCoderTurn, iu as ResearchOutputShape, jc as DiffResult, jl as SubmitOutput, js as DownMessageEvent, ju as DELEGATION_TRACE_MAX_SPANS, kc as CreateWorktreeOptions, kl as DelegationTaskQueueOptions, ks as CoordinationToolsOptions, ku as CappedDelegationTrace, ll as createFleetWorkspaceExecutor, lu as createPropagatingTraceEmitter, ml as DriveTurnCapableBox, nl as coderTaskFromArgs, nu as FeedbackRating, ol as FleetHandle, ou as UiAuditLensFilter, pl as DetachedTurnResumeDriverOptions, qc as eventToSnapshot, ql as DelegationHistoryArgs, qs as DELEGATE_DESCRIPTION, rl as detachedSessionDelegate, ru as FeedbackRefersTo, sl as FleetWorkspaceExecutorOptions, su as UiAuditorDelegationOutput, tl as UiAuditorDelegate, tu as DelegationStatusResult, ul as createSiblingSandboxExecutor, uu as readTraceContextFromEnv, vl as detachedTurnEvents, wl as DelegationResumeContext, xl as runDetachedTurn, yl as formatDetachedSessionRef, zl as DelegateResearchConfig, zs as QuestionUrgency, zu as DelegationPersistenceError } from "../index-CFJ_1m1U.js";
2
+ import { $c as RemoveWorktreeOptions, $l as DelegateCodeResult, $s as Question, $u as buildDelegationTraceSpans, Al as DetachedTurn, Bl as DelegationArgs, Cl as DelegationExecutor, Cu as ResearchSource, Dl as createFleetWorkspaceExecutor, Du as createPropagatingTraceEmitter, El as SiblingSandboxExecutorOptions, Eu as TraceContext, Fl as createDetachedTurnResumeDriver, Gl as DelegationRunContext, Gs as AnalystFindingEvent, Hl as DelegationResumeContext, Il as detachedTurnEvents, Jl as SubmitInput, Js as CoordinationTools, Ju as DELEGATION_TRACE_MAX_BYTES, Kl as DelegationTaskQueue, Ks as AnalystRegistry, Ll as formatDetachedSessionRef, Ml as DriveTurnCapableBox, Nl as DriveTurnTick, Ol as createSiblingSandboxExecutor, Ou as readTraceContextFromEnv, Pl as RunDetachedTurnOptions, Qc as GitRunner, Ql as DelegateCodeConfig, Qs as MakeWorkerAgent, Qu as DelegationTraceSpan, Rl as parseDetachedSessionRef, Sl as settleDetachedCoderTurn, Su as ResearchOutputShape, Tl as FleetWorkspaceExecutorOptions, Tu as UiAuditorDelegationOutput, Ul as DelegationResumeDriver, Vl as DelegationRecord, Wl as DelegationResumeTick, Xc as DiffOptions, Xl as hashIdempotencyInput, Xs as DEFAULT_AWAIT_EVENT_TIMEOUT_MS, Xu as DelegationTraceCaps, Yc as CreateWorktreeOptions, Yl as SubmitOutput, Ys as CoordinationToolsOptions, Yu as DELEGATION_TRACE_MAX_SPANS, Zc as DiffResult, Zl as DelegateCodeArgs, Zs as DownMessageEvent, Zu as DelegationTraceCollector, _c as DelegateHandlerOptions, _l as DetachedWinnerSelection, _u as DelegationStatus, ac as QuestionUrgency, ad as DelegationStore, al as JsonRpcResponse, au as DelegateUiAuditArgs, bc as validateDelegateArgs, bl as coderTaskFromArgs, bu as FeedbackRating, cc as createCoordinationTools, cd as InMemoryDelegationStore, cl as FeedbackEvent, cu as DelegateUiAuditRoute, dc as createInProcessTransport, dl as eventToSnapshot, du as DelegationHistoryArgs, ec as QuestionDecision, ed as capDelegationTrace, el as WorktreeHandle, eu as DelegateFeedbackArgs, fc as createMcpServer, fl as CoderDelegate, fu as DelegationHistoryEntry, gc as DelegateArgs, gl as DetachedSessionDelegateOptions, gu as DelegationResultPayload, hc as DELEGATE_TOOL_NAME, hl as DelegateRunCtx, hu as DelegationProgress, ic as QuestionRecord, id as DelegationStateCorruptError, il as JsonRpcMessage, iu as DelegateResearchResult, jl as DetachedTurnResumeDriverOptions, kl as DetachedSessionRefParts, ku as traceContextToEnv, lc as McpServer, ll as FeedbackStore, lu as DelegationError, mc as DELEGATE_INPUT_SCHEMA, ml as CoderReviewer, mu as DelegationProfile, nc as QuestionOption, nd as createDelegationTraceCollector, nl as createWorktree, nu as DelegateResearchArgs, oc as SettledWorker, od as FileDelegationStore, ol as McpToolDescriptor, ou as DelegateUiAuditConfig, pc as DELEGATE_DESCRIPTION, pl as CoderReview, pu as DelegationHistoryResult, ql as DelegationTaskQueueOptions, qs as CoordinationEvent, qu as CappedDelegationTrace, rc as QuestionPolicy, rd as DelegationPersistenceError, rl as removeWorktree, ru as DelegateResearchConfig, sc as WorkerWatchOptions, sd as FileDelegationStoreOptions, sl as McpTransport, su as DelegateUiAuditResult, tc as QuestionLevel, td as composeLoopTraceEmitters, tl as captureWorktreeDiff, tu as DelegateFeedbackResult, uc as McpServerOptions, ul as InMemoryFeedbackStore, uu as DelegationFeedbackSnapshot, vc as DelegateResult, vd as CoderOutput, vl as SettleDetachedCoderTurnOptions, vu as DelegationStatusArgs, wl as FleetHandle, wu as UiAuditLensFilter, xl as detachedSessionDelegate, xu as FeedbackRefersTo, yc as createDelegateHandler, yl as UiAuditorDelegate, yu as DelegationStatusResult, zl as runDetachedTurn } from "../index-D_OdNLe0.js";
3
3
  import { o as UiLens } from "../substrate-BcnuSHXm.js";
4
4
  import { a as LocalHarnessResult, c as runLocalHarness, i as LocalHarness, n as CodexExecutionPolicy, o as RunLocalHarnessOptions, r as CodexTokenUsage, s as parseCodexTokenUsage, t as CodexExecutionEvidence } from "../local-harness-Dh8PJ0ot.js";
5
5
  import { a as KbGateResult, i as FactJudgeVerdict, n as FactCandidate, o as createKbGate, r as FactJudge, t as CreateKbGateOptions } from "../kb-gate-C8z2juK8.js";
package/dist/mcp/index.js CHANGED
@@ -1,11 +1,11 @@
1
1
  import { u as ValidationError } from "../errors-DEAvWQPy.js";
2
- import { l as throwAbort, n as deleteBoxSafe, s as sleep, u as throwIfAborted } from "../util-MVgdwuIS.js";
3
- import { A as createWorktree, F as CodexExecutionDiagnosticError, N as parseCodexTokenUsage, O as runWorktreeHarness, P as runLocalHarness, j as removeWorktree, k as captureWorktreeDiff } from "../supervisor-sTJC9psT.js";
4
- import { W as selectValidWinner, m as runCoderChecks, q as assertTraceDerivedFindings } from "../runtime-dpJZmZtt.js";
5
- import { $ as eventToSnapshot, A as createDelegateHandler, B as DelegationTaskQueue, Bt as runAgentRounds, C as DELEGATE_FEEDBACK_INPUT_SCHEMA, D as DELEGATE_DESCRIPTION, E as validateDelegateFeedbackArgs, G as capDelegationTrace, H as DELEGATION_TRACE_MAX_BYTES, J as DelegationPersistenceError, K as composeLoopTraceEmitters, O as DELEGATE_INPUT_SCHEMA, Q as InMemoryFeedbackStore, Rt as createSandboxForSpec, S as DELEGATE_FEEDBACK_DESCRIPTION, T as createDelegateFeedbackHandler, U as DELEGATION_TRACE_MAX_SPANS, V as hashIdempotencyInput, W as buildDelegationTraceSpans, X as FileDelegationStore, Y as DelegationStateCorruptError, Z as InMemoryDelegationStore, _ as DELEGATE_UI_AUDIT_DESCRIPTION, a as createInProcessTransport, b as createDelegateUiAuditHandler, c as DELEGATION_STATUS_INPUT_SCHEMA, d as validateDelegationStatusArgs, f as DELEGATION_HISTORY_DESCRIPTION, g as validateDelegationHistoryArgs, h as createDelegationHistoryHandler, ht as createCoordinationTools, j as validateDelegateArgs, k as DELEGATE_TOOL_NAME, l as DELEGATION_STATUS_TOOL_NAME, m as DELEGATION_HISTORY_TOOL_NAME, mt as DEFAULT_AWAIT_EVENT_TIMEOUT_MS, o as createMcpServer, p as DELEGATION_HISTORY_INPUT_SCHEMA, q as createDelegationTraceCollector, s as DELEGATION_STATUS_DESCRIPTION, u as createDelegationStatusHandler, v as DELEGATE_UI_AUDIT_INPUT_SCHEMA, w as DELEGATE_FEEDBACK_TOOL_NAME, x as validateDelegateUiAuditArgs, y as DELEGATE_UI_AUDIT_TOOL_NAME } from "../supervise-DyPmmhJ6.js";
2
+ import { c as sleep, d as throwIfAborted, r as deleteBoxSafe, u as throwAbort } from "../util-Cc9g9Y-o.js";
3
+ import { A as createWorktree, F as CodexExecutionDiagnosticError, N as parseCodexTokenUsage, O as runWorktreeHarness, P as runLocalHarness, j as removeWorktree, k as captureWorktreeDiff } from "../supervisor-ByCPHcp9.js";
4
+ import { O as runCoderChecks, it as selectValidWinner, st as assertTraceDerivedFindings } from "../runtime-DSkMJb_X.js";
5
+ import { $ as eventToSnapshot, A as createDelegateHandler, B as DelegationTaskQueue, Bt as runAgentRounds, C as DELEGATE_FEEDBACK_INPUT_SCHEMA, D as DELEGATE_DESCRIPTION, E as validateDelegateFeedbackArgs, G as capDelegationTrace, H as DELEGATION_TRACE_MAX_BYTES, J as DelegationPersistenceError, K as composeLoopTraceEmitters, O as DELEGATE_INPUT_SCHEMA, Q as InMemoryFeedbackStore, Rt as createSandboxForSpec, S as DELEGATE_FEEDBACK_DESCRIPTION, T as createDelegateFeedbackHandler, U as DELEGATION_TRACE_MAX_SPANS, V as hashIdempotencyInput, W as buildDelegationTraceSpans, X as FileDelegationStore, Y as DelegationStateCorruptError, Z as InMemoryDelegationStore, _ as DELEGATE_UI_AUDIT_DESCRIPTION, a as createInProcessTransport, b as createDelegateUiAuditHandler, c as DELEGATION_STATUS_INPUT_SCHEMA, d as validateDelegationStatusArgs, f as DELEGATION_HISTORY_DESCRIPTION, g as validateDelegationHistoryArgs, h as createDelegationHistoryHandler, ht as createCoordinationTools, j as validateDelegateArgs, k as DELEGATE_TOOL_NAME, l as DELEGATION_STATUS_TOOL_NAME, m as DELEGATION_HISTORY_TOOL_NAME, mt as DEFAULT_AWAIT_EVENT_TIMEOUT_MS, o as createMcpServer, p as DELEGATION_HISTORY_INPUT_SCHEMA, q as createDelegationTraceCollector, s as DELEGATION_STATUS_DESCRIPTION, u as createDelegationStatusHandler, v as DELEGATE_UI_AUDIT_INPUT_SCHEMA, w as DELEGATE_FEEDBACK_TOOL_NAME, x as validateDelegateUiAuditArgs, y as DELEGATE_UI_AUDIT_TOOL_NAME } from "../supervise-CeZtA1wu.js";
6
6
  import { t as createStdioToolServer } from "../tool-server-RcWgLIsL.js";
7
7
  import { t as createKbGate } from "../kb-gate-DpaSwXVx.js";
8
- import { n as mcpToolsForRuntimeMcpSubset, t as mcpToolsForRuntimeMcp } from "../openai-tools-DT9FH2_t.js";
8
+ import { n as mcpToolsForRuntimeMcpSubset, t as mcpToolsForRuntimeMcp } from "../openai-tools-st-hERvA.js";
9
9
  import { t as coderTaskToPrompt } from "../coder-yhVWbdWc.js";
10
10
  import { a as createMemoryToolServer, c as resolveMemoryFromEnv, i as MEMORY_NAME_ENV, n as MEMORY_ITEMS_ENV, o as parseMemoryItems, r as MEMORY_LOG_ENV, s as readMemoryItemsFile, t as MEMORY_FILE_ENV } from "../memory-server-DL6cE2Ag.js";
11
11
  import { n as readTraceContextFromEnv, r as traceContextToEnv, t as createPropagatingTraceEmitter } from "../trace-propagation-CJJC7SVB.js";
@@ -1,4 +1,4 @@
1
- import { C as DELEGATE_FEEDBACK_INPUT_SCHEMA, S as DELEGATE_FEEDBACK_DESCRIPTION, c as DELEGATION_STATUS_INPUT_SCHEMA, f as DELEGATION_HISTORY_DESCRIPTION, l as DELEGATION_STATUS_TOOL_NAME, m as DELEGATION_HISTORY_TOOL_NAME, p as DELEGATION_HISTORY_INPUT_SCHEMA, s as DELEGATION_STATUS_DESCRIPTION, w as DELEGATE_FEEDBACK_TOOL_NAME } from "./supervise-DyPmmhJ6.js";
1
+ import { C as DELEGATE_FEEDBACK_INPUT_SCHEMA, S as DELEGATE_FEEDBACK_DESCRIPTION, c as DELEGATION_STATUS_INPUT_SCHEMA, f as DELEGATION_HISTORY_DESCRIPTION, l as DELEGATION_STATUS_TOOL_NAME, m as DELEGATION_HISTORY_TOOL_NAME, p as DELEGATION_HISTORY_INPUT_SCHEMA, s as DELEGATION_STATUS_DESCRIPTION, w as DELEGATE_FEEDBACK_TOOL_NAME } from "./supervise-CeZtA1wu.js";
2
2
  //#region src/mcp/openai-tools.ts
3
3
  function buildTool(name, description, parameters) {
4
4
  return {
@@ -41,4 +41,4 @@ function mcpToolsForRuntimeMcpSubset(names) {
41
41
  //#endregion
42
42
  export { mcpToolsForRuntimeMcpSubset as n, mcpToolsForRuntimeMcp as t };
43
43
 
44
- //# sourceMappingURL=openai-tools-DT9FH2_t.js.map
44
+ //# sourceMappingURL=openai-tools-st-hERvA.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"openai-tools-DT9FH2_t.js","names":[],"sources":["../src/mcp/openai-tools.ts"],"sourcesContent":["/**\n *\n * OpenAI Chat Completions `tools[]` projection of the queue-bound agent-runtime\n * MCP delegation tools.\n *\n * Use when configuring `createOpenAICompatibleBackend({ tools: ... })` so the\n * model can call `delegate_feedback`, `delegation_status`, and\n * `delegation_history` through the OpenAI-compat transport (tcloud, OpenRouter,\n * OpenAI direct, cli-bridge). The runtime surfaces tool calls as `tool_call`\n * stream events — execution is the caller's responsibility (typically the\n * parent sandbox runtime's MCP mount).\n *\n * Sandbox-SDK callers do NOT need this helper: the sandbox runtime mounts\n * MCP servers natively and the in-sandbox harness discovers tools via the\n * runtime, not via an OpenAI tools array.\n *\n * Tool name + description + JSON-schema are pulled from the canonical\n * `DELEGATE_*` constants exported by `./tools/*` so the projection cannot\n * drift from the server's own validators.\n *\n * @experimental\n */\n\nimport type { OpenAIChatTool } from '../types'\nimport {\n DELEGATE_FEEDBACK_DESCRIPTION,\n DELEGATE_FEEDBACK_INPUT_SCHEMA,\n DELEGATE_FEEDBACK_TOOL_NAME,\n} from './tools/delegate-feedback'\nimport {\n DELEGATION_HISTORY_DESCRIPTION,\n DELEGATION_HISTORY_INPUT_SCHEMA,\n DELEGATION_HISTORY_TOOL_NAME,\n} from './tools/delegation-history'\nimport {\n DELEGATION_STATUS_DESCRIPTION,\n DELEGATION_STATUS_INPUT_SCHEMA,\n DELEGATION_STATUS_TOOL_NAME,\n} from './tools/delegation-status'\n\nfunction buildTool(\n name: string,\n description: string,\n parameters: Readonly<Record<string, unknown>>,\n): OpenAIChatTool {\n // `parameters` arrives as a deeply-readonly `as const` literal. The\n // OpenAI-compat backend JSON-serializes the body so a shallow copy\n // into a plain object is sufficient — and shields callers that mutate\n // the returned descriptor from corrupting the source constant.\n return {\n type: 'function',\n function: { name, description, parameters: { ...parameters } },\n }\n}\n\n/**\n *\n * Returns the queue-bound delegation tools projected into OpenAI Chat\n * Completions `tools[]` shape. The order is stable: `delegate_feedback`,\n * `delegation_status`, `delegation_history`.\n *\n * @experimental\n */\nexport function mcpToolsForRuntimeMcp(): OpenAIChatTool[] {\n return [\n buildTool(\n DELEGATE_FEEDBACK_TOOL_NAME,\n DELEGATE_FEEDBACK_DESCRIPTION,\n DELEGATE_FEEDBACK_INPUT_SCHEMA as Readonly<Record<string, unknown>>,\n ),\n buildTool(\n DELEGATION_STATUS_TOOL_NAME,\n DELEGATION_STATUS_DESCRIPTION,\n DELEGATION_STATUS_INPUT_SCHEMA as Readonly<Record<string, unknown>>,\n ),\n buildTool(\n DELEGATION_HISTORY_TOOL_NAME,\n DELEGATION_HISTORY_DESCRIPTION,\n DELEGATION_HISTORY_INPUT_SCHEMA as Readonly<Record<string, unknown>>,\n ),\n ]\n}\n\n/**\n *\n * Subset filter — return only the projected tools whose `function.name`\n * appears in `names`. Useful for curated mounts (e.g. only the queue-bound\n * delegation tools, omitting `delegate_feedback`). Unknown names are\n * silently ignored; pass an empty array to get an empty result.\n *\n * @experimental\n */\nexport function mcpToolsForRuntimeMcpSubset(names: ReadonlyArray<string>): OpenAIChatTool[] {\n const allowed = new Set(names)\n return mcpToolsForRuntimeMcp().filter((tool) => allowed.has(tool.function.name))\n}\n"],"mappings":";;AAwCA,SAAS,UACP,MACA,aACA,YACgB;CAKhB,OAAO;EACL,MAAM;EACN,UAAU;GAAE;GAAM;GAAa,YAAY,EAAE,GAAG,WAAW;EAAE;CAC/D;AACF;;;;;;;;;AAUA,SAAgB,wBAA0C;CACxD,OAAO;EACL,UACE,6BACA,+BACA,8BACF;EACA,UACE,6BACA,+BACA,8BACF;EACA,UACE,8BACA,gCACA,+BACF;CACF;AACF;;;;;;;;;;AAWA,SAAgB,4BAA4B,OAAgD;CAC1F,MAAM,UAAU,IAAI,IAAI,KAAK;CAC7B,OAAO,sBAAsB,CAAC,CAAC,QAAQ,SAAS,QAAQ,IAAI,KAAK,SAAS,IAAI,CAAC;AACjF"}
1
+ {"version":3,"file":"openai-tools-st-hERvA.js","names":[],"sources":["../src/mcp/openai-tools.ts"],"sourcesContent":["/**\n *\n * OpenAI Chat Completions `tools[]` projection of the queue-bound agent-runtime\n * MCP delegation tools.\n *\n * Use when configuring `createOpenAICompatibleBackend({ tools: ... })` so the\n * model can call `delegate_feedback`, `delegation_status`, and\n * `delegation_history` through the OpenAI-compat transport (tcloud, OpenRouter,\n * OpenAI direct, cli-bridge). The runtime surfaces tool calls as `tool_call`\n * stream events — execution is the caller's responsibility (typically the\n * parent sandbox runtime's MCP mount).\n *\n * Sandbox-SDK callers do NOT need this helper: the sandbox runtime mounts\n * MCP servers natively and the in-sandbox harness discovers tools via the\n * runtime, not via an OpenAI tools array.\n *\n * Tool name + description + JSON-schema are pulled from the canonical\n * `DELEGATE_*` constants exported by `./tools/*` so the projection cannot\n * drift from the server's own validators.\n *\n * @experimental\n */\n\nimport type { OpenAIChatTool } from '../types'\nimport {\n DELEGATE_FEEDBACK_DESCRIPTION,\n DELEGATE_FEEDBACK_INPUT_SCHEMA,\n DELEGATE_FEEDBACK_TOOL_NAME,\n} from './tools/delegate-feedback'\nimport {\n DELEGATION_HISTORY_DESCRIPTION,\n DELEGATION_HISTORY_INPUT_SCHEMA,\n DELEGATION_HISTORY_TOOL_NAME,\n} from './tools/delegation-history'\nimport {\n DELEGATION_STATUS_DESCRIPTION,\n DELEGATION_STATUS_INPUT_SCHEMA,\n DELEGATION_STATUS_TOOL_NAME,\n} from './tools/delegation-status'\n\nfunction buildTool(\n name: string,\n description: string,\n parameters: Readonly<Record<string, unknown>>,\n): OpenAIChatTool {\n // `parameters` arrives as a deeply-readonly `as const` literal. The\n // OpenAI-compat backend JSON-serializes the body so a shallow copy\n // into a plain object is sufficient — and shields callers that mutate\n // the returned descriptor from corrupting the source constant.\n return {\n type: 'function',\n function: { name, description, parameters: { ...parameters } },\n }\n}\n\n/**\n *\n * Returns the queue-bound delegation tools projected into OpenAI Chat\n * Completions `tools[]` shape. The order is stable: `delegate_feedback`,\n * `delegation_status`, `delegation_history`.\n *\n * @experimental\n */\nexport function mcpToolsForRuntimeMcp(): OpenAIChatTool[] {\n return [\n buildTool(\n DELEGATE_FEEDBACK_TOOL_NAME,\n DELEGATE_FEEDBACK_DESCRIPTION,\n DELEGATE_FEEDBACK_INPUT_SCHEMA as Readonly<Record<string, unknown>>,\n ),\n buildTool(\n DELEGATION_STATUS_TOOL_NAME,\n DELEGATION_STATUS_DESCRIPTION,\n DELEGATION_STATUS_INPUT_SCHEMA as Readonly<Record<string, unknown>>,\n ),\n buildTool(\n DELEGATION_HISTORY_TOOL_NAME,\n DELEGATION_HISTORY_DESCRIPTION,\n DELEGATION_HISTORY_INPUT_SCHEMA as Readonly<Record<string, unknown>>,\n ),\n ]\n}\n\n/**\n *\n * Subset filter — return only the projected tools whose `function.name`\n * appears in `names`. Useful for curated mounts (e.g. only the queue-bound\n * delegation tools, omitting `delegate_feedback`). Unknown names are\n * silently ignored; pass an empty array to get an empty result.\n *\n * @experimental\n */\nexport function mcpToolsForRuntimeMcpSubset(names: ReadonlyArray<string>): OpenAIChatTool[] {\n const allowed = new Set(names)\n return mcpToolsForRuntimeMcp().filter((tool) => allowed.has(tool.function.name))\n}\n"],"mappings":";;AAwCA,SAAS,UACP,MACA,aACA,YACgB;CAKhB,OAAO;EACL,MAAM;EACN,UAAU;GAAE;GAAM;GAAa,YAAY,EAAE,GAAG,WAAW;EAAE;CAC/D;AACF;;;;;;;;;AAUA,SAAgB,wBAA0C;CACxD,OAAO;EACL,UACE,6BACA,+BACA,8BACF;EACA,UACE,6BACA,+BACA,8BACF;EACA,UACE,8BACA,gCACA,+BACF;CACF;AACF;;;;;;;;;;AAWA,SAAgB,4BAA4B,OAAgD;CAC1F,MAAM,UAAU,IAAI,IAAI,KAAK;CAC7B,OAAO,sBAAsB,CAAC,CAAC,QAAQ,SAAS,QAAQ,IAAI,KAAK,SAAS,IAAI,CAAC;AACjF"}
@@ -1,4 +1,4 @@
1
- import { a as contentAddress } from "./spawn-journal-CwPvKUTa.js";
1
+ import { a as contentAddress } from "./spawn-journal-DLhnom3e.js";
2
2
  import { i as redactProtectedValue, n as createProtectedRecordRedactor, r as redactProtectedReason, t as assertNoProtectedBytes } from "./protected-redaction--F3v1oo8.js";
3
3
  import { REDACTION_VERSION, canonicalJson, isLlmSpan } from "@tangle-network/agent-eval";
4
4
  import { agentCandidateArtifactRefSchema, agentCandidateBenchmarkResultEvidenceSchema, agentCandidateBenchmarkSuiteSchema, agentCandidateBenchmarkTaskSchema, agentCandidateBundleSchema, agentCandidateContainerSchema, agentCandidateExecutionLimitsSchema, agentCandidateExecutionPlanEvidenceSchema, agentCandidateExecutionPlanMaterialSchema, agentCandidateMaterializationReceiptSchema, agentCandidateModelAccessNetworkSchema, agentCandidateModelSettlementEvidenceSchema, agentCandidateProfileActivationSchema, agentCandidateProfilePlanEvidenceSchema, agentCandidateProfileSchema, agentCandidateResolvedModelSchema, agentCandidateRunCellSchema, agentCandidateRunReceiptSchema, agentCandidateTaskOutcomeEvidenceSchema, agentCandidateTaskOutcomeSpecSchema, agentCandidateTerminationSchema, agentCandidateWorkspaceManifestMaterialSchema, agentCandidateWorkspaceSnapshotEvidenceSchema, agentProfileDiffSchema, agentProfileSchema, applyAgentProfileDiff, sha256DigestSchema } from "@tangle-network/agent-interface";
@@ -198,15 +198,15 @@ function agentCandidateProfileAsAgentProfile(candidate) {
198
198
  if (candidate.model) output.model = { ...candidate.model };
199
199
  if (candidate.mcp) output.mcp = Object.fromEntries(Object.entries(candidate.mcp).map(([name, server]) => [name, {
200
200
  ...server,
201
- ...server.args ? { args: server.args.map(publicValue$1) } : {},
202
- ...server.env ? { env: mapPublicValues(server.env) } : {}
201
+ ...server.args ? { args: server.args.map((value) => ({ ...value })) } : {},
202
+ ...server.env ? { env: cloneRecord(server.env) } : {}
203
203
  }]));
204
204
  if (candidate.subagents) output.subagents = cloneRecord(candidate.subagents);
205
205
  if (candidate.modes) output.modes = cloneRecord(candidate.modes);
206
206
  if (candidate.hooks) output.hooks = Object.fromEntries(Object.entries(candidate.hooks).map(([event, hooks]) => [event, hooks.map(({ executable, args, env, ...hook }) => ({
207
207
  ...hook,
208
208
  command: [executable, ...(args ?? []).map(publicValue$1)].map(shellQuote).join(" "),
209
- ...env ? { env: mapPublicValues(env) } : {}
209
+ ...env ? { env: cloneRecord(env) } : {}
210
210
  }))]));
211
211
  if (candidate.resources) {
212
212
  if (candidate.resources.failOnError !== true) throw new Error("sealed candidate profile contains fields unsupported by generic profiles");
@@ -242,8 +242,8 @@ function freezeMcpServers(servers) {
242
242
  return [name, {
243
243
  ...server.transport ? { transport: server.transport } : {},
244
244
  ...server.command ? { command: server.command } : {},
245
- ...server.args ? { args: server.args.map(candidatePublicValue) } : {},
246
- ...server.env ? { env: mapCandidatePublicValues(server.env) } : {},
245
+ ...server.args ? { args: server.args.map((value, index) => candidatePublicValue(value, `mcp.${name}.args[${index}]`)) } : {},
246
+ ...server.env ? { env: mapCandidatePublicValues(server.env, `mcp.${name}.env`) } : {},
247
247
  ...server.cwd ? { cwd: server.cwd } : {},
248
248
  ...server.enabled === void 0 ? {} : { enabled: server.enabled }
249
249
  }];
@@ -293,21 +293,22 @@ function publicResource(resource) {
293
293
  ...resource.name ? { name: resource.name } : {}
294
294
  };
295
295
  }
296
- function candidatePublicValue(value) {
296
+ /** Freeze one profile config value into the candidate's PUBLIC-only config
297
+ * shape. A secret-ref has no candidate representation (AgentCandidateConfigValue
298
+ * is public-only), so it is rejected, never silently dropped or unwrapped. */
299
+ function candidatePublicValue(value, path) {
300
+ if (value.kind !== "public") unsupportedProfileField(`${path} (secret-ref '${value.key}')`);
297
301
  return {
298
302
  kind: "public",
299
- value
303
+ value: value.value
300
304
  };
301
305
  }
302
- function mapCandidatePublicValues(values) {
303
- return Object.fromEntries(Object.entries(values).map(([name, value]) => [name, candidatePublicValue(value)]));
306
+ function mapCandidatePublicValues(values, pathPrefix) {
307
+ return Object.fromEntries(Object.entries(values).map(([name, value]) => [name, candidatePublicValue(value, `${pathPrefix}.${name}`)]));
304
308
  }
305
309
  function publicValue$1(value) {
306
310
  return value.value;
307
311
  }
308
- function mapPublicValues(values) {
309
- return Object.fromEntries(Object.entries(values).map(([key, value]) => [key, publicValue$1(value)]));
310
- }
311
312
  function cloneRecord(values) {
312
313
  return Object.fromEntries(Object.entries(values).map(([key, value]) => [key, { ...value }]));
313
314
  }
@@ -4441,4 +4442,4 @@ function errorMessage(error) {
4441
4442
  //#endregion
4442
4443
  export { parseExactAgentProfile as $, verifyMaterializedWorkspace as A, rejectedStage as B, assertNoGitIndirection as C, captureMaterializedWorkspace as D, candidateWorkspaceManifest as E, assertTerminalAllowedInPhase as F, agentCandidateProfileAsAgentProfile as G, sealTerminalDigest as H, assertTerminalMatchesClaim as I, candidateMaterializerHarness as J, applyExactAgentProfileDiff as K, assertTerminalMatchesStaged as L, candidateCleanupTimeout as M, withinCandidateCleanupDeadline as N, readVerifiedArtifact as O, assertRecoveryMatchesStaged as P, parseAgentCandidateProfileActivation as Q, recoveredTerminalRecord as R, CANDIDATE_TRACE_TAGS as S, runCandidateGit as T, terminalRecord as U, requireStagedTerminal as V, assertExactObjectKeys as W, freezeGenericAgentCandidateProfile as X, createAgentCandidateProfileActivation as Y, omitUndefinedObjectFields as Z, candidateExecutionClaim as _, persistCandidateOutputArtifact as a, deepFreezeCandidate as at, consumePreparedCandidateExecution as b, CANDIDATE_KNOWLEDGE_ROOT_ENV as c, omitTopLevelDigest as ct, verifiedResourceTextByDigest as d, parseExactAgentProfileDiff as et, verifyAgentCandidateBundle as f, candidateClaimFileInternals as g, InMemoryAgentCandidateExecutionClaimStore as h, persistCandidateModelSettlementEvidence as i, canonicalCandidateDocument as it, candidateCleanupDeadline as j, verifyBytes as k, candidateKnowledgeExecutionPaths as l, sha256Bytes as lt, usdToNanos as m, executePreparedAgentCandidate as n, canonicalCandidateBytes as nt, sealAgentCandidateExecutorStopAcknowledgement as o, embeddedCandidateArtifact as ot, sealAgentCandidateModelSettlement as p, assertCandidateProfileBinding as q, RecoveryAgentCandidateTraceStore as r, canonicalCandidateDigest$1 as rt, CANDIDATE_KNOWLEDGE_RETRIEVAL_CONFIG_ENV as s, immutableCandidateValue as st, prepareAgentCandidateExecution as t, parseExactCandidateProfile as tt, AGENT_CANDIDATE_EXECUTION_SUPPORT as u, verifyCanonicalCandidateDocument as ut, assertPreparedCandidateIntegrity as v, readCandidateGitTreeFiles as w, CANDIDATE_TRACE_ENV as x, beginPreparedCandidateDisposal as y, rejectedFinish as z };
4443
4444
 
4444
- //# sourceMappingURL=prepare-Pr19X93k.js.map
4445
+ //# sourceMappingURL=prepare-BKVdOn0w.js.map