@theokit/sdk 5.12.1 → 5.14.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 (193) hide show
  1. package/CHANGELOG.md +74 -0
  2. package/dist/{agent-Cn0sphpA.d.cts → agent-DExqjqYy.d.cts} +18 -3
  3. package/dist/{agent-CVzDy_Oj.d.ts → agent-Dfw3VsIX.d.ts} +18 -3
  4. package/dist/{agent-IG7BP6GN.js → agent-T34LCGQM.js} +11 -11
  5. package/dist/{agent-IG7BP6GN.js.map → agent-T34LCGQM.js.map} +1 -1
  6. package/dist/{agent-BVKIUP7F.cjs → agent-TL4K7BTG.cjs} +12 -12
  7. package/dist/{agent-BVKIUP7F.cjs.map → agent-TL4K7BTG.cjs.map} +1 -1
  8. package/dist/auth/index.cjs +17 -16
  9. package/dist/auth/index.cjs.map +1 -1
  10. package/dist/auth/index.js +5 -4
  11. package/dist/auth/index.js.map +1 -1
  12. package/dist/{chunk-NHOEXFZT.js → chunk-2HXTNVLM.js} +5 -2
  13. package/dist/chunk-2HXTNVLM.js.map +1 -0
  14. package/dist/{chunk-Q6WT5535.cjs → chunk-2WY2OFSC.cjs} +259 -79
  15. package/dist/chunk-2WY2OFSC.cjs.map +1 -0
  16. package/dist/{chunk-HN4IKB6X.cjs → chunk-2XWAYCFM.cjs} +15 -13
  17. package/dist/chunk-2XWAYCFM.cjs.map +1 -0
  18. package/dist/{chunk-3FSBE4PS.js → chunk-3GTN4HOO.js} +10 -6
  19. package/dist/chunk-3GTN4HOO.js.map +1 -0
  20. package/dist/{chunk-VVGFZQZC.js → chunk-3LMVJTNJ.js} +9 -5
  21. package/dist/chunk-3LMVJTNJ.js.map +1 -0
  22. package/dist/{chunk-4GUFNDZR.js → chunk-3ONIVO2I.js} +3 -3
  23. package/dist/{chunk-4GUFNDZR.js.map → chunk-3ONIVO2I.js.map} +1 -1
  24. package/dist/{chunk-7WARNHWW.cjs → chunk-3UMPP553.cjs} +5 -2
  25. package/dist/chunk-3UMPP553.cjs.map +1 -0
  26. package/dist/{chunk-NWWTYBD3.cjs → chunk-4KBI37F3.cjs} +5 -5
  27. package/dist/{chunk-NWWTYBD3.cjs.map → chunk-4KBI37F3.cjs.map} +1 -1
  28. package/dist/{chunk-S46WJTDL.cjs → chunk-4TEGFMSP.cjs} +6 -6
  29. package/dist/{chunk-S46WJTDL.cjs.map → chunk-4TEGFMSP.cjs.map} +1 -1
  30. package/dist/{chunk-QISSETTG.cjs → chunk-5645PMVU.cjs} +6 -4
  31. package/dist/chunk-5645PMVU.cjs.map +1 -0
  32. package/dist/{chunk-ZLFFDPXC.js → chunk-73IITAF7.js} +36 -14
  33. package/dist/chunk-73IITAF7.js.map +1 -0
  34. package/dist/{chunk-5A4UFBHW.cjs → chunk-A77UMVMD.cjs} +15 -11
  35. package/dist/chunk-A77UMVMD.cjs.map +1 -0
  36. package/dist/{chunk-IO4RI5ZJ.cjs → chunk-BZK5QL3N.cjs} +4 -4
  37. package/dist/{chunk-IO4RI5ZJ.cjs.map → chunk-BZK5QL3N.cjs.map} +1 -1
  38. package/dist/{chunk-5HSMH2ZZ.js → chunk-CJN5CEI3.js} +4 -4
  39. package/dist/{chunk-5HSMH2ZZ.js.map → chunk-CJN5CEI3.js.map} +1 -1
  40. package/dist/{chunk-XRPMZ7TO.js → chunk-CYWOJA6B.js} +6 -4
  41. package/dist/chunk-CYWOJA6B.js.map +1 -0
  42. package/dist/{chunk-AQW54OWQ.js → chunk-DFBWYETS.js} +5 -3
  43. package/dist/chunk-DFBWYETS.js.map +1 -0
  44. package/dist/{chunk-EPANMGH7.cjs → chunk-FLDHYF5C.cjs} +11 -2
  45. package/dist/chunk-FLDHYF5C.cjs.map +1 -0
  46. package/dist/{chunk-BJ7BPLQK.js → chunk-GARVAUCU.js} +209 -29
  47. package/dist/chunk-GARVAUCU.js.map +1 -0
  48. package/dist/{chunk-YOVZMN4P.cjs → chunk-LXG6VL6R.cjs} +3 -3
  49. package/dist/{chunk-YOVZMN4P.cjs.map → chunk-LXG6VL6R.cjs.map} +1 -1
  50. package/dist/{chunk-NJBJ3CUG.js → chunk-NAVUTK6X.js} +3 -3
  51. package/dist/{chunk-NJBJ3CUG.js.map → chunk-NAVUTK6X.js.map} +1 -1
  52. package/dist/{chunk-2SFLLOMN.js → chunk-NVQSBRG6.js} +3 -3
  53. package/dist/{chunk-2SFLLOMN.js.map → chunk-NVQSBRG6.js.map} +1 -1
  54. package/dist/{chunk-FEAWEBWN.cjs → chunk-PDOXYXWX.cjs} +6 -4
  55. package/dist/chunk-PDOXYXWX.cjs.map +1 -0
  56. package/dist/{chunk-MS3TQSXU.js → chunk-QD6B6W6I.js} +6 -4
  57. package/dist/chunk-QD6B6W6I.js.map +1 -0
  58. package/dist/{chunk-NBNRQN6T.js → chunk-QGDPMM3C.js} +11 -2
  59. package/dist/chunk-QGDPMM3C.js.map +1 -0
  60. package/dist/{chunk-ZWLFHSON.cjs → chunk-R35ZJAYT.cjs} +38 -15
  61. package/dist/chunk-R35ZJAYT.cjs.map +1 -0
  62. package/dist/{chunk-4YD2WI57.cjs → chunk-R427EOZE.cjs} +19 -15
  63. package/dist/chunk-R427EOZE.cjs.map +1 -0
  64. package/dist/chunk-R5UQL2R5.cjs +18 -0
  65. package/dist/{chunk-LO6LIUZ6.cjs.map → chunk-R5UQL2R5.cjs.map} +1 -1
  66. package/dist/{chunk-TLVI2OQK.cjs → chunk-SETHRLQS.cjs} +18 -2
  67. package/dist/chunk-SETHRLQS.cjs.map +1 -0
  68. package/dist/{chunk-LSWHDOCL.cjs → chunk-SNVYOX46.cjs} +88 -72
  69. package/dist/chunk-SNVYOX46.cjs.map +1 -0
  70. package/dist/{chunk-BO3PV3OP.js → chunk-TDED5XES.js} +18 -3
  71. package/dist/chunk-TDED5XES.js.map +1 -0
  72. package/dist/{chunk-NKQVLWDF.js → chunk-ULEK4OM4.js} +3 -3
  73. package/dist/{chunk-NKQVLWDF.js.map → chunk-ULEK4OM4.js.map} +1 -1
  74. package/dist/{chunk-XJ4C4NFX.js → chunk-ZOL3L4EH.js} +63 -49
  75. package/dist/chunk-ZOL3L4EH.js.map +1 -0
  76. package/dist/{compact-session-NM56BREJ.cjs → compact-session-D2MQDB6G.cjs} +15 -15
  77. package/dist/{compact-session-NM56BREJ.cjs.map → compact-session-D2MQDB6G.cjs.map} +1 -1
  78. package/dist/{compact-session-3U2JYTVG.js → compact-session-N2PPHQO6.js} +6 -6
  79. package/dist/{compact-session-3U2JYTVG.js.map → compact-session-N2PPHQO6.js.map} +1 -1
  80. package/dist/{cron-CHn-F0fC.d.ts → cron-BubDpFJG.d.ts} +2 -2
  81. package/dist/{cron-BWDYetbq.d.cts → cron-CK2v0VWA.d.cts} +2 -2
  82. package/dist/cron.cjs +11 -11
  83. package/dist/cron.d.cts +3 -3
  84. package/dist/cron.d.ts +3 -3
  85. package/dist/cron.js +10 -10
  86. package/dist/eval.cjs +15 -15
  87. package/dist/eval.js +10 -10
  88. package/dist/{executor-HKHT4CWS.cjs → executor-5QL5AXIZ.cjs} +18 -15
  89. package/dist/executor-5QL5AXIZ.cjs.map +1 -0
  90. package/dist/{executor-3D2UDJHW.js → executor-THUXNAFR.js} +6 -3
  91. package/dist/executor-THUXNAFR.js.map +1 -0
  92. package/dist/generate-object-A5F576IT.cjs +20 -0
  93. package/dist/{generate-object-XBWD2PU7.cjs.map → generate-object-A5F576IT.cjs.map} +1 -1
  94. package/dist/{generate-object-S7MNVF2V.js → generate-object-TBDOBBYW.js} +4 -4
  95. package/dist/{generate-object-S7MNVF2V.js.map → generate-object-TBDOBBYW.js.map} +1 -1
  96. package/dist/generate-object.d.ts +14 -1
  97. package/dist/index.cjs +81 -65
  98. package/dist/index.cjs.map +1 -1
  99. package/dist/index.d.cts +36 -7
  100. package/dist/index.d.ts +36 -7
  101. package/dist/index.js +44 -28
  102. package/dist/index.js.map +1 -1
  103. package/dist/{inject-session-JVTZNQF6.cjs → inject-session-3ICZIJ2N.cjs} +4 -4
  104. package/dist/{inject-session-JVTZNQF6.cjs.map → inject-session-3ICZIJ2N.cjs.map} +1 -1
  105. package/dist/{inject-session-THABTKJY.js → inject-session-J26SHHIO.js} +3 -3
  106. package/dist/{inject-session-THABTKJY.js.map → inject-session-J26SHHIO.js.map} +1 -1
  107. package/dist/internal/agent-loop/prune-tool-results.d.ts +37 -0
  108. package/dist/internal/auth/credential-store.d.ts +1 -1
  109. package/dist/internal/auth/types.d.ts +4 -0
  110. package/dist/internal/providers/discovery.d.ts +2 -2
  111. package/dist/internal/providers/trust-gate.d.ts +35 -0
  112. package/dist/internal/runtime/plugin-loader/manifest-entry-import.d.ts +17 -0
  113. package/dist/internal/runtime/plugin-loader/workspace-plugin-trust.d.ts +16 -0
  114. package/dist/internal/runtime/skills/binary-on-path.d.ts +1 -0
  115. package/dist/internal/runtime/skills/discover-skills.d.ts +2 -0
  116. package/dist/internal/structured-output-helpers.d.ts +5 -2
  117. package/dist/mcp-auth.cjs +2 -2
  118. package/dist/mcp-auth.js +1 -1
  119. package/dist/models.cjs +11 -11
  120. package/dist/models.js +4 -4
  121. package/dist/providers.cjs +6 -6
  122. package/dist/providers.js +4 -4
  123. package/dist/sandbox/bwrap.d.cts +10 -8
  124. package/dist/sandbox/bwrap.d.ts +10 -8
  125. package/dist/sandbox/deny-read.d.cts +24 -0
  126. package/dist/sandbox/deny-read.d.ts +24 -0
  127. package/dist/sandbox/index.cjs +114 -35
  128. package/dist/sandbox/index.cjs.map +1 -1
  129. package/dist/sandbox/index.d.cts +2 -1
  130. package/dist/sandbox/index.d.ts +2 -1
  131. package/dist/sandbox/index.js +96 -21
  132. package/dist/sandbox/index.js.map +1 -1
  133. package/dist/sandbox/linux-sandbox.d.cts +16 -1
  134. package/dist/sandbox/linux-sandbox.d.ts +16 -1
  135. package/dist/sandbox/local-sandbox.d.cts +3 -1
  136. package/dist/sandbox/local-sandbox.d.ts +3 -1
  137. package/dist/sandbox/seccomp-delivery.d.cts +3 -0
  138. package/dist/sandbox/seccomp-delivery.d.ts +3 -0
  139. package/dist/sandbox/shell-escape.d.cts +14 -2
  140. package/dist/sandbox/shell-escape.d.ts +14 -2
  141. package/dist/sandbox/types.d.cts +45 -0
  142. package/dist/sandbox/types.d.ts +45 -0
  143. package/dist/{sdk-agent-4-dXI2GS.d.cts → sdk-agent-DwzHcuxy.d.cts} +28 -3
  144. package/dist/{sdk-agent-CTOJlWA_.d.ts → sdk-agent-a3fW1xUK.d.ts} +28 -3
  145. package/dist/skills.cjs +4 -4
  146. package/dist/skills.js +1 -1
  147. package/dist/stream-object-AS4YYM4B.cjs +20 -0
  148. package/dist/{stream-object-TEEK3CAX.cjs.map → stream-object-AS4YYM4B.cjs.map} +1 -1
  149. package/dist/stream-object-EKM4WGTI.js +7 -0
  150. package/dist/{stream-object-R6SMYV4R.js.map → stream-object-EKM4WGTI.js.map} +1 -1
  151. package/dist/stream-object.d.ts +14 -1
  152. package/dist/subagents-loader.d.cts +2 -2
  153. package/dist/subagents-loader.d.ts +2 -2
  154. package/dist/types/agent.d.ts +14 -1
  155. package/dist/types/run.d.ts +27 -2
  156. package/dist/workflow-as-tool.d.ts +39 -5
  157. package/dist/workflow-errors.d.ts +16 -0
  158. package/dist/workflow.cjs +31 -23
  159. package/dist/workflow.d.cts +55 -5
  160. package/dist/workflow.d.ts +55 -5
  161. package/dist/workflow.js +2 -2
  162. package/docs/adr/mutation-testing-scope.md +56 -0
  163. package/docs/error-codes.md +23 -18
  164. package/docs/harness-capability-map.md +78 -4
  165. package/package.json +1 -1
  166. package/dist/chunk-3FSBE4PS.js.map +0 -1
  167. package/dist/chunk-4YD2WI57.cjs.map +0 -1
  168. package/dist/chunk-5A4UFBHW.cjs.map +0 -1
  169. package/dist/chunk-7WARNHWW.cjs.map +0 -1
  170. package/dist/chunk-AQW54OWQ.js.map +0 -1
  171. package/dist/chunk-BJ7BPLQK.js.map +0 -1
  172. package/dist/chunk-BO3PV3OP.js.map +0 -1
  173. package/dist/chunk-EPANMGH7.cjs.map +0 -1
  174. package/dist/chunk-FEAWEBWN.cjs.map +0 -1
  175. package/dist/chunk-HN4IKB6X.cjs.map +0 -1
  176. package/dist/chunk-LO6LIUZ6.cjs +0 -18
  177. package/dist/chunk-LSWHDOCL.cjs.map +0 -1
  178. package/dist/chunk-MS3TQSXU.js.map +0 -1
  179. package/dist/chunk-NBNRQN6T.js.map +0 -1
  180. package/dist/chunk-NHOEXFZT.js.map +0 -1
  181. package/dist/chunk-Q6WT5535.cjs.map +0 -1
  182. package/dist/chunk-QISSETTG.cjs.map +0 -1
  183. package/dist/chunk-TLVI2OQK.cjs.map +0 -1
  184. package/dist/chunk-VVGFZQZC.js.map +0 -1
  185. package/dist/chunk-XJ4C4NFX.js.map +0 -1
  186. package/dist/chunk-XRPMZ7TO.js.map +0 -1
  187. package/dist/chunk-ZLFFDPXC.js.map +0 -1
  188. package/dist/chunk-ZWLFHSON.cjs.map +0 -1
  189. package/dist/executor-3D2UDJHW.js.map +0 -1
  190. package/dist/executor-HKHT4CWS.cjs.map +0 -1
  191. package/dist/generate-object-XBWD2PU7.cjs +0 -20
  192. package/dist/stream-object-R6SMYV4R.js +0 -7
  193. package/dist/stream-object-TEEK3CAX.cjs +0 -20
package/dist/index.d.cts CHANGED
@@ -1,16 +1,17 @@
1
+ import { TokenUsage } from "./index.js";
1
2
  import { T as TheokitAgentError, E as ErrorMetadata } from './errors-base-B5g01neU.cjs';
2
3
  export { a as ErrorCode } from './errors-base-B5g01neU.cjs';
3
- import { A as AgentOptions, L as LocalOptions, S as SystemPromptResolver, C as CloudOptions, M as MemorySettings, a as AgentDefinition, b as SkillsSettings, c as ListAgentsOptions, d as ListResult, e as SDKAgentInfo, G as GetAgentOptions, f as ListRunsOptions, g as GetRunOptions, h as AgentOperationOptions, i as AgentDescription, P as Plugin$1, j as ProviderProfile, I as InlineSkill, k as Skill, B as BudgetTracker, l as MemoryProvider, m as PreToolCallDecision } from './agent-Cn0sphpA.cjs';
4
- export { n as ActiveMemoryPassArgs, o as ActiveMemoryPassResult, p as AgentSubagentDescription, q as AgentToolDescription, r as BudgetCheck, s as BudgetTotal, t as BudgetUsageEvent, u as BuiltinToolName, v as CloudEnv, w as CloudRepo, x as CompatSource, y as CompatSourceAdapter, z as CompatSurface, D as CreateSkillSpec, H as HookApprovalGate, E as HookApprovalRequest, F as HookName, J as LlmCallContext, K as MemoryProviderAgentRef, N as MemoryProviderFactory, O as MemoryProviderHandle, Q as MemoryProviderInitOptions, R as PluginContext, T as PluginHookDisposer, U as PostAssistantReplyContext, V as PostToolCallContext, W as PreToolCallContext, X as PreUserSendContext, Y as PreUserSendResult, Z as ProviderTransform, _ as ProviderTransformContext, $ as RecordSessionSummaryArgs, a0 as SessionLifecycleContext, a1 as SessionRecord, a2 as SessionStore, a3 as SettingSource, a4 as Skill, a5 as SkillsResolver, a6 as SkillsResolverContext, a7 as SystemPromptContext, a8 as SystemPromptMemoryFact, a9 as TelemetrySettings, aa as ToolCallSummary, ab as ToolContext, ac as ToolResultTransformContext, ad as TransformContext } from './agent-Cn0sphpA.cjs';
5
- import { ab as RunEvent, v as CostBreakdown, a_ as TokenUsage, R as RunResult, P as ProviderRoutingSettings, S as SDKAgent, M as McpServerConfig, C as ContextSettings, a as PluginsSettings, b as Run, c as Processor, J as JudgeResult, G as GoalOptions, d as GoalEvent, e as GoalResult, f as MemoryId, g as RunEventSink$1, h as SDKProvider, i as SDKMessage } from './sdk-agent-4-dXI2GS.cjs';
6
- export { A as AgentConversationTurn, j as AgentMemory, k as AgentOperation, l as AssistantMessage, m as CompletionCheck, n as CompletionCheckResult, o as ContextBudget, p as ContextManagerKind, q as ContextSnapshot, r as ContextSource, s as ContextSourceStatus, t as ConversationStep, u as ConversationTurn, v as CostBreakdown, w as CostSource, x as CostStatus, D as DoomLoopThresholds, E as EnvPolicy, F as ForkOptions, y as ForkResult, z as GenerateOptions, B as GenerateRunResult, I as InputProcessorContext, H as InteractionUpdate, K as InvalidateCacheOptions, L as McpAuthConfig, N as McpHttpServerConfig, O as McpOAuthConfig, Q as McpStdioServerConfig, T as MemoryAdapter, U as MemoryAdapterCapabilities, V as MemoryContext, W as MemoryFact, X as MemoryRevision, Y as MemoryToolSchema, Z as MemoryTurnMessage, _ as MessageOrigin, $ as OutputProcessorContext, a0 as PartialToolCallUpdate, a1 as PersonalityPreset, a2 as ProcessorControls, a3 as ProcessorTripwire, a4 as ProcessorViolation, a5 as ProviderCapability, a6 as ProviderRoute, a7 as ResolvedProviderRoute, a8 as RunCompactBoundaryEvent, a9 as RunCompletionCheckEvent, aa as RunErrorDetail, ab as RunEvent, ac as RunGitInfo, ad as RunMemoryDegradedEvent, ae as RunPermissionDeniedEvent, af as RunRateLimitEvent, ag as RunStatus, ah as RunTaskCompletedEvent, ai as RunTaskStartedEvent, aj as RunTaskUpdatedEvent, ak as RunTimelineEvent, al as RunToCompletionOptions, am as RunToCompletionResult, an as RunToolProgressEvent, ao as RunTripwireEvent, ap as RunUntilIterator, aq as SDKAgentPlugins, ar as SDKAgentSkillDetail, as as SDKAgentSkills, at as SDKArtifact, au as SDKAssistantMessage, av as SDKContextManager, aw as SDKImage, ax as SDKImageDimension, ay as SDKObjectDelta, az as SDKPluginMetadata, aA as SDKProvidersManager, aB as SDKRequestMessage, aC as SDKStatusMessage, aD as SDKSystemMessage, aE as SDKTaskMessage, aF as SDKThinkingMessage, aG as SDKToolUseMessage, aH as SDKUserMessage, aI as SDKUserMessageEvent, aJ as SendOptions, aK as ShellCommand, aL as ShellConversationTurn, aM as ShellOutput, aN as ShellOutputDeltaUpdate, aO as StepCompletedUpdate, aP as StepStartedUpdate, aQ as StreamToCompletionResult, aR as SummaryCompletedUpdate, aS as SummaryStartedUpdate, aT as SummaryUpdate, aU as SystemPromptSkillRef, aV as TextDeltaUpdate, aW as ThinkingCompletedUpdate, aX as ThinkingDeltaUpdate, aY as ThinkingMessage, aZ as TokenDeltaUpdate, a_ as TokenUsage, a$ as ToolCall, b0 as ToolCallCompletedUpdate, b1 as ToolCallStartedUpdate, b2 as ToolResult, b3 as ToolResultGuardOptions, b4 as ToolUseBlock, b5 as TurnEndedUpdate, b6 as UserMessage, b7 as UserMessageAppendedUpdate, b8 as Verdict } from './sdk-agent-4-dXI2GS.cjs';
4
+ import { A as AgentOptions, L as LocalOptions, B as BuiltinToolName, M as MemorySettings, S as SystemPromptResolver, C as CloudOptions, a as AgentDefinition, b as SkillsSettings, c as ListAgentsOptions, d as ListResult, e as SDKAgentInfo, G as GetAgentOptions, f as ListRunsOptions, g as GetRunOptions, h as AgentOperationOptions, i as AgentDescription, P as Plugin$1, j as ProviderProfile, I as InlineSkill, k as Skill, l as BudgetTracker, m as MemoryProvider, n as PreToolCallDecision } from './agent-DExqjqYy.cjs';
5
+ export { o as ActiveMemoryPassArgs, p as ActiveMemoryPassResult, q as AgentSubagentDescription, r as AgentToolDescription, s as BudgetCheck, t as BudgetTotal, u as BudgetUsageEvent, v as CloudEnv, w as CloudRepo, x as CompatSource, y as CompatSourceAdapter, z as CompatSurface, D as CreateSkillSpec, H as HookApprovalGate, E as HookApprovalRequest, F as HookName, J as LlmCallContext, K as MemoryProviderAgentRef, N as MemoryProviderFactory, O as MemoryProviderHandle, Q as MemoryProviderInitOptions, R as PluginContext, T as PluginHookDisposer, U as PostAssistantReplyContext, V as PostToolCallContext, W as PreToolCallContext, X as PreUserSendContext, Y as PreUserSendResult, Z as ProviderTransform, _ as ProviderTransformContext, $ as RecordSessionSummaryArgs, a0 as SessionLifecycleContext, a1 as SessionRecord, a2 as SessionStore, a3 as SettingSource, a4 as Skill, a5 as SkillsResolver, a6 as SkillsResolverContext, a7 as SystemPromptContext, a8 as SystemPromptMemoryFact, a9 as TelemetrySettings, aa as ToolCallSummary, ab as ToolContext, ac as ToolResultTransformContext, ad as TransformContext } from './agent-DExqjqYy.cjs';
6
+ import { ac as RunEvent, v as CostBreakdown, R as RunResult, P as ProviderRoutingSettings, S as SDKAgent, M as McpServerConfig, C as ContextSettings, a as PluginsSettings, b as Run, c as Processor, J as JudgeResult, G as GoalOptions, d as GoalEvent, e as GoalResult, f as MemoryId, g as RunEventSink$1, h as SDKProvider, i as SDKMessage } from './sdk-agent-DwzHcuxy.cjs';
7
+ export { A as AgentConversationTurn, j as AgentMemory, k as AgentOperation, l as AssistantMessage, m as CompletionCheck, n as CompletionCheckResult, o as ContextBudget, p as ContextManagerKind, q as ContextSnapshot, r as ContextSource, s as ContextSourceStatus, t as ConversationStep, u as ConversationTurn, v as CostBreakdown, w as CostSource, x as CostStatus, D as DoomLoopThresholds, E as EnvPolicy, F as ForkOptions, y as ForkResult, z as GenerateOptions, B as GenerateRunResult, I as InputProcessorContext, H as InteractionUpdate, K as InvalidateCacheOptions, L as McpAuthConfig, N as McpHttpServerConfig, O as McpOAuthConfig, Q as McpStdioServerConfig, T as MemoryAdapter, U as MemoryAdapterCapabilities, V as MemoryContext, W as MemoryFact, X as MemoryRevision, Y as MemoryToolSchema, Z as MemoryTurnMessage, _ as MessageOrigin, $ as OutputProcessorContext, a0 as PartialToolCallUpdate, a1 as PersonalityPreset, a2 as ProcessorControls, a3 as ProcessorTripwire, a4 as ProcessorViolation, a5 as ProviderCapability, a6 as ProviderRoute, a7 as PruneToolResultsOptions, a8 as ResolvedProviderRoute, a9 as RunCompactBoundaryEvent, aa as RunCompletionCheckEvent, ab as RunErrorDetail, ac as RunEvent, ad as RunGitInfo, ae as RunMemoryDegradedEvent, af as RunPermissionDeniedEvent, ag as RunRateLimitEvent, ah as RunStatus, ai as RunTaskCompletedEvent, aj as RunTaskStartedEvent, ak as RunTaskUpdatedEvent, al as RunTimelineEvent, am as RunToCompletionOptions, an as RunToCompletionResult, ao as RunToolProgressEvent, ap as RunTripwireEvent, aq as RunUntilIterator, ar as SDKAgentPlugins, as as SDKAgentSkillDetail, at as SDKAgentSkills, au as SDKArtifact, av as SDKAssistantMessage, aw as SDKContextManager, ax as SDKImage, ay as SDKImageDimension, az as SDKObjectDelta, aA as SDKPluginMetadata, aB as SDKProvidersManager, aC as SDKRequestMessage, aD as SDKStatusMessage, aE as SDKSystemMessage, aF as SDKTaskMessage, aG as SDKThinkingMessage, aH as SDKToolUseMessage, aI as SDKUserMessage, aJ as SDKUserMessageEvent, aK as SendOptions, aL as ShellCommand, aM as ShellConversationTurn, aN as ShellOutput, aO as ShellOutputDeltaUpdate, aP as StepCompletedUpdate, aQ as StepStartedUpdate, aR as StreamToCompletionResult, aS as SummaryCompletedUpdate, aT as SummaryStartedUpdate, aU as SummaryUpdate, aV as SystemPromptSkillRef, aW as TextDeltaUpdate, aX as ThinkingCompletedUpdate, aY as ThinkingDeltaUpdate, aZ as ThinkingMessage, a_ as TokenDeltaUpdate, a$ as TokenUsage, b0 as ToolCall, b1 as ToolCallCompletedUpdate, b2 as ToolCallStartedUpdate, b3 as ToolResult, b4 as ToolResultGuardOptions, b5 as ToolUseBlock, b6 as TurnEndedUpdate, b7 as UserMessage, b8 as UserMessageAppendedUpdate, b9 as Verdict } from './sdk-agent-DwzHcuxy.cjs';
7
8
  import * as zod from 'zod';
8
9
  import { ZodType, z } from 'zod';
9
10
  import { S as StructuredOutputError, B as BudgetOptions, a as BudgetHandle, b as BudgetSnapshot } from './errors-BiDQFWTG.cjs';
10
11
  export { A as AgentDisposedError, c as AgentRunError, d as AgentRunErrorCode, e as AuthenticationError, f as BudgetExceedEvent, g as BudgetExceededError, h as BudgetLimit, i as BudgetMode, j as BudgetScope, k as BudgetThresholdEvent, l as BudgetWindow, C as ConfigurationError, I as IntegrationNotConnectedError, m as InvalidTaskIdError, M as MemoryAdapterError, n as MemoryAdapterErrorCode, N as NetworkError, R as RateLimitError, T as TaskNotFoundError, U as UnknownAgentError, o as UnsupportedBudgetOperationError, p as UnsupportedRunOperationError, q as UnsupportedTaskOperationError, r as isTransientError } from './errors-BiDQFWTG.cjs';
11
12
  import { M as ModelSelection, C as CustomTool, T as ToolResultContentBlock, P as PermissionMode } from './agent-prims-CZyxfCmS.cjs';
12
13
  export { I as ImageBlock, a as ModelParameterValue, R as RunOperation, b as TextBlock, c as ToolContextMessage } from './agent-prims-CZyxfCmS.cjs';
13
- export { C as Cron, a as CronCreateOptions, b as CronGetOptions, c as CronJob, d as CronJobStatus, e as CronListOptions, f as CronOperationOptions, g as CronRunOptions, h as CronRuntime, i as CronSchedulerStatus, j as CronStartOptions } from './cron-BWDYetbq.cjs';
14
+ export { C as Cron, a as CronCreateOptions, b as CronGetOptions, c as CronJob, d as CronJobStatus, e as CronListOptions, f as CronOperationOptions, g as CronRunOptions, h as CronRuntime, i as CronSchedulerStatus, j as CronStartOptions } from './cron-CK2v0VWA.cjs';
14
15
  import { StepResult } from './workflow.cjs';
15
16
  export { Workflow, agentStep, fn } from './workflow.cjs';
16
17
 
@@ -242,6 +243,19 @@ interface StreamObjectOptions<T extends ZodType> {
242
243
  * when the right env key is set under a different provider name.
243
244
  */
244
245
  providers?: ProviderRoutingSettings;
246
+ /**
247
+ * Builtin tools removed from the transient agent's catalogue, forwarded to
248
+ * {@link AgentOptions.withheldBuiltinTools}. Absent ⇒ unchanged default: the agent holds
249
+ * `shell`. Pass `["shell"]` for a step that must only produce JSON. The `output` tool is
250
+ * never withheld.
251
+ */
252
+ withheldBuiltinTools?: readonly BuiltinToolName[];
253
+ /**
254
+ * Memory settings for the transient agent, forwarded to {@link AgentOptions.memory}.
255
+ * Absent ⇒ unchanged default (a session transcript is written). Pass `{ enabled: false }`
256
+ * for a step that must leave no transcript.
257
+ */
258
+ memory?: MemorySettings;
245
259
  }
246
260
  /**
247
261
  * Recursive partial — `T` where every nested field becomes optional.
@@ -340,6 +354,19 @@ interface GenerateObjectOptions<T extends ZodType> {
340
354
  * to raw.
341
355
  */
342
356
  errorStrategy?: "throw" | "return-partial" | "return-raw";
357
+ /**
358
+ * Builtin tools removed from every transient agent's catalogue (the reasoning-phase agent of
359
+ * `structuringModel` included), forwarded to {@link AgentOptions.withheldBuiltinTools}.
360
+ * Absent ⇒ unchanged default: the agent holds `shell`. Pass `["shell"]` for a step that must
361
+ * only produce JSON. The `output` tool is never withheld.
362
+ */
363
+ withheldBuiltinTools?: readonly BuiltinToolName[];
364
+ /**
365
+ * Memory settings for every transient agent of the call, forwarded to {@link AgentOptions.memory}.
366
+ * Absent ⇒ unchanged default (a session transcript is written). Pass `{ enabled: false }`
367
+ * for a step that must leave no transcript.
368
+ */
369
+ memory?: MemorySettings;
343
370
  }
344
371
  /**
345
372
  * Successful return from {@link Agent.generateObject}.
@@ -1652,13 +1679,15 @@ declare class Provider {
1652
1679
  * listed by name and description, with the instructions under the frontmatter unable to arrive.
1653
1680
  */
1654
1681
  type ReadableSkill = InlineSkill | Skill;
1682
+ /** A fixed list, or a function re-evaluated on every call so later-discovered skills are readable. */
1683
+ type SkillReadSource = ReadonlyArray<ReadableSkill> | (() => ReadonlyArray<ReadableSkill> | Promise<ReadonlyArray<ReadableSkill>>);
1655
1684
  /** SE36 — `SkillReadTool.create` replaces `defineSkillReadTool` (ADR 0015). @public *
1656
1685
  * `SkillReadTool.create` returns a **`CustomTool`** — a skill-reading tool, not a
1657
1686
  * `SkillReadTool` instance.
1658
1687
  */
1659
1688
  declare class SkillReadTool {
1660
1689
  private constructor();
1661
- static create(skills: ReadonlyArray<ReadableSkill>): CustomTool;
1690
+ static create(skills: SkillReadSource): CustomTool;
1662
1691
  }
1663
1692
 
1664
1693
  /**
@@ -4492,4 +4521,4 @@ interface WiringRecordInput<K extends string> {
4492
4521
  */
4493
4522
  declare function recordWiring<K extends string>(input: WiringRecordInput<K>): Readonly<Record<K, WiredEntity>>;
4494
4523
 
4495
- export { Agent, AgentBuilder, type AgentBuilderDeps, AgentDefinition, type AgentDescription, AgentFactory, AgentOperationOptions, AgentOptions, type AgentPromptResult, type AgentRegistryOptions, type ApprovalDecision, type ApprovalInput, type ApprovalMode, type ApprovalOutcome, type ApprovalReason, type BatchItem, type BatchOptions, type BatchProgress, type BatchResult, type BlastRadiusDecision, type BlastRadiusInput, type BlastRadiusOutcome, type BlastRadiusReason, Budget, BudgetHandle, BudgetOptions, BudgetSnapshot, type BudgetTracker, CloudOptions, ContextSettings, type CounterBudgetTrackerOptions, type CredentialInput, type CredentialReport, type CustomTool, type DeclaredAction, type DeclaredLayer, type DeepPartial, type DefineProviderOptions, type DefineToolSpec, type DiagnosticsSink, type DreamingSweepOptions, type DreamingSweepResult, type EffectiveToolCatalog, type EnvOptOut, type EnvReachabilityAudit, type EnvReachabilityInput, ErrorMetadata, EventBus, type EvictReason, GOAL_CONTINUATION_MARKER, GenerateObjectError, type GenerateObjectOptions, type GenerateObjectResult, GetAgentOptions, GetRunOptions, GoalEvent, type GoalLoopAgent, GoalOptions, GoalResult, InlineSkill, JobQueue, type JobQueueOptions, JudgeCredentialError, type JudgeResult, type KeepReason, type KeptArtifact, LayerOrderError, type LayerValues, ListAgentsOptions, ListResult, ListRunsOptions, type LiveAgentRegistry, LiveSessionError, type LiveSessionReason, LocalOptions, type ManagedSettings, McpServerConfig, Memory, MemoryId, type MemoryProvider, MemorySettings, type MigrateOptions, type MigrateResult, type ModelListItem, type ModelParameterDefinition, ModelSelection, type ModelVariant, NoopMemoryProvider, type NormalizedJsonSchema, type OTelSpan, type PermissionAction, PermissionEngine, type PermissionEngineOptions, type PermissionFloorContext, type PermissionGate, type PermissionGateContext, type PermissionGateDecision, PermissionMode, PermissionPlugin, type PermissionPluginOptions, type PermissionRule, type PermissionRuleSet, Plugin, PluginsSettings, PreToolCallDecision, type Processor, Provider, type ProviderProfile, ProviderRoutingSettings, type ReadSessionMessagesOptions, type ReapPlan, type ReapPlanInput, type ReapableArtifact, type RetentionPolicy, RetentionPolicyError, Run, RunEventSink$1 as RunEventSink, RunResult, type SDKAgent, SDKAgentInfo, SDKMessage, type SDKModel, SDKProvider, type SDKRepository, type SDKUser, SOVEREIGN_ENV_KEYS, Security, type SecurityFloorInput, type SessionMessage, type SessionMessagePart, type SessionScope, type ShareGptMessage, type ShareGptTrajectory, SkillReadTool, SkillsSettings, type SovereignEnvKey, Squad, type SquadOptions, type SquadRun, StreamObjectError, type StreamObjectEvent, type StreamObjectOptions, SystemPromptResolver, TASK_RESERVED_PREFIXES, Task, type TaskCancelResult, type TaskConfigureOptions, type TaskEvent, type TaskFilter, type TaskHandle, type TaskKind, type TaskState, type TaskStoreOptions, type TaskSubmitOptions, type TaskWorkContext, type TaskWorkFn, type TelemetryHandle, Theokit, TheokitAgentError, type TheokitRequestOptions, TokenLimiter, type TokenLimiterOptions, Tool, ToolError, type ToolResultContentBlock, type TrustLevel, type TrustPosture, type TrustPostureInput, type TrustSource, UngatedCapabilityError, UnicodeNormalizer, type UnicodeNormalizerOptions, type UnresolvedToolSource, UsageAccumulator, type WiredEntity, type WiringRecordInput, type WithBlastRadius, applyMode, applySecurityFloor, auditEnvReachability, chargeAndCheckThresholds, computeCost, createCounterBudgetTracker, createTokenLimiter, createUnicodeNormalizer, decideApproval, describeAction, describeCredential, effectiveToolNames, emitRunEvent, estimateTokens, evaluateBlastRadius, extractRawId, foldLayers, getPricingEntry, guardSessionDestruction, inferApiMode, isInside, isValidTaskId, loadProjectEnv, managedSettingsPathFor, migrateSqliteToLance, mkMemoryId, normalizeSchema, normalizeUsage, parsePermissionRules, permissionFloorReason, planReaping, preflightCheck, readManagedSettings, readSessionMessages, recordWiring, resolveTrustPosture, runGoalLoop, scopedConversationId, sessionScopePrefix, setDiagnosticsSink, toShareGptTrajectory, verifyLayerOrdering, withBlastRadius, withCwdMutex };
4524
+ export { Agent, AgentBuilder, type AgentBuilderDeps, AgentDefinition, type AgentDescription, AgentFactory, AgentOperationOptions, AgentOptions, type AgentPromptResult, type AgentRegistryOptions, type ApprovalDecision, type ApprovalInput, type ApprovalMode, type ApprovalOutcome, type ApprovalReason, type BatchItem, type BatchOptions, type BatchProgress, type BatchResult, type BlastRadiusDecision, type BlastRadiusInput, type BlastRadiusOutcome, type BlastRadiusReason, Budget, BudgetHandle, BudgetOptions, BudgetSnapshot, type BudgetTracker, BuiltinToolName, CloudOptions, ContextSettings, type CounterBudgetTrackerOptions, type CredentialInput, type CredentialReport, type CustomTool, type DeclaredAction, type DeclaredLayer, type DeepPartial, type DefineProviderOptions, type DefineToolSpec, type DiagnosticsSink, type DreamingSweepOptions, type DreamingSweepResult, type EffectiveToolCatalog, type EnvOptOut, type EnvReachabilityAudit, type EnvReachabilityInput, ErrorMetadata, EventBus, type EvictReason, GOAL_CONTINUATION_MARKER, GenerateObjectError, type GenerateObjectOptions, type GenerateObjectResult, GetAgentOptions, GetRunOptions, GoalEvent, type GoalLoopAgent, GoalOptions, GoalResult, InlineSkill, JobQueue, type JobQueueOptions, JudgeCredentialError, type JudgeResult, type KeepReason, type KeptArtifact, LayerOrderError, type LayerValues, ListAgentsOptions, ListResult, ListRunsOptions, type LiveAgentRegistry, LiveSessionError, type LiveSessionReason, LocalOptions, type ManagedSettings, McpServerConfig, Memory, MemoryId, type MemoryProvider, MemorySettings, type MigrateOptions, type MigrateResult, type ModelListItem, type ModelParameterDefinition, ModelSelection, type ModelVariant, NoopMemoryProvider, type NormalizedJsonSchema, type OTelSpan, type PermissionAction, PermissionEngine, type PermissionEngineOptions, type PermissionFloorContext, type PermissionGate, type PermissionGateContext, type PermissionGateDecision, PermissionMode, PermissionPlugin, type PermissionPluginOptions, type PermissionRule, type PermissionRuleSet, Plugin, PluginsSettings, PreToolCallDecision, type Processor, Provider, type ProviderProfile, ProviderRoutingSettings, type ReadSessionMessagesOptions, type ReapPlan, type ReapPlanInput, type ReapableArtifact, type RetentionPolicy, RetentionPolicyError, Run, RunEventSink$1 as RunEventSink, RunResult, type SDKAgent, SDKAgentInfo, SDKMessage, type SDKModel, SDKProvider, type SDKRepository, type SDKUser, SOVEREIGN_ENV_KEYS, Security, type SecurityFloorInput, type SessionMessage, type SessionMessagePart, type SessionScope, type ShareGptMessage, type ShareGptTrajectory, SkillReadTool, SkillsSettings, type SovereignEnvKey, Squad, type SquadOptions, type SquadRun, StreamObjectError, type StreamObjectEvent, type StreamObjectOptions, SystemPromptResolver, TASK_RESERVED_PREFIXES, Task, type TaskCancelResult, type TaskConfigureOptions, type TaskEvent, type TaskFilter, type TaskHandle, type TaskKind, type TaskState, type TaskStoreOptions, type TaskSubmitOptions, type TaskWorkContext, type TaskWorkFn, type TelemetryHandle, Theokit, TheokitAgentError, type TheokitRequestOptions, TokenLimiter, type TokenLimiterOptions, Tool, ToolError, type ToolResultContentBlock, type TrustLevel, type TrustPosture, type TrustPostureInput, type TrustSource, UngatedCapabilityError, UnicodeNormalizer, type UnicodeNormalizerOptions, type UnresolvedToolSource, UsageAccumulator, type WiredEntity, type WiringRecordInput, type WithBlastRadius, applyMode, applySecurityFloor, auditEnvReachability, chargeAndCheckThresholds, computeCost, createCounterBudgetTracker, createTokenLimiter, createUnicodeNormalizer, decideApproval, describeAction, describeCredential, effectiveToolNames, emitRunEvent, estimateTokens, evaluateBlastRadius, extractRawId, foldLayers, getPricingEntry, guardSessionDestruction, inferApiMode, isInside, isValidTaskId, loadProjectEnv, managedSettingsPathFor, migrateSqliteToLance, mkMemoryId, normalizeSchema, normalizeUsage, parsePermissionRules, permissionFloorReason, planReaping, preflightCheck, readManagedSettings, readSessionMessages, recordWiring, resolveTrustPosture, runGoalLoop, scopedConversationId, sessionScopePrefix, setDiagnosticsSink, toShareGptTrajectory, verifyLayerOrdering, withBlastRadius, withCwdMutex };
package/dist/index.d.ts CHANGED
@@ -1,16 +1,17 @@
1
+ import { TokenUsage } from "./types/index.js";
1
2
  import { T as TheokitAgentError, E as ErrorMetadata } from './errors-base-B5g01neU.js';
2
3
  export { a as ErrorCode } from './errors-base-B5g01neU.js';
3
- import { A as AgentOptions, L as LocalOptions, S as SystemPromptResolver, C as CloudOptions, M as MemorySettings, a as AgentDefinition, b as SkillsSettings, c as ListAgentsOptions, d as ListResult, e as SDKAgentInfo, G as GetAgentOptions, f as ListRunsOptions, g as GetRunOptions, h as AgentOperationOptions, i as AgentDescription, P as Plugin$1, j as ProviderProfile, I as InlineSkill, k as Skill, B as BudgetTracker, l as MemoryProvider, m as PreToolCallDecision } from './agent-CVzDy_Oj.js';
4
- export { n as ActiveMemoryPassArgs, o as ActiveMemoryPassResult, p as AgentSubagentDescription, q as AgentToolDescription, r as BudgetCheck, s as BudgetTotal, t as BudgetUsageEvent, u as BuiltinToolName, v as CloudEnv, w as CloudRepo, x as CompatSource, y as CompatSourceAdapter, z as CompatSurface, D as CreateSkillSpec, H as HookApprovalGate, E as HookApprovalRequest, F as HookName, J as LlmCallContext, K as MemoryProviderAgentRef, N as MemoryProviderFactory, O as MemoryProviderHandle, Q as MemoryProviderInitOptions, R as PluginContext, T as PluginHookDisposer, U as PostAssistantReplyContext, V as PostToolCallContext, W as PreToolCallContext, X as PreUserSendContext, Y as PreUserSendResult, Z as ProviderTransform, _ as ProviderTransformContext, $ as RecordSessionSummaryArgs, a0 as SessionLifecycleContext, a1 as SessionRecord, a2 as SessionStore, a3 as SettingSource, a4 as Skill, a5 as SkillsResolver, a6 as SkillsResolverContext, a7 as SystemPromptContext, a8 as SystemPromptMemoryFact, a9 as TelemetrySettings, aa as ToolCallSummary, ab as ToolContext, ac as ToolResultTransformContext, ad as TransformContext } from './agent-CVzDy_Oj.js';
5
- import { ab as RunEvent, v as CostBreakdown, a_ as TokenUsage, R as RunResult, P as ProviderRoutingSettings, S as SDKAgent, M as McpServerConfig, C as ContextSettings, a as PluginsSettings, b as Run, c as Processor, J as JudgeResult, G as GoalOptions, d as GoalEvent, e as GoalResult, f as MemoryId, g as RunEventSink$1, h as SDKProvider, i as SDKMessage } from './sdk-agent-CTOJlWA_.js';
6
- export { A as AgentConversationTurn, j as AgentMemory, k as AgentOperation, l as AssistantMessage, m as CompletionCheck, n as CompletionCheckResult, o as ContextBudget, p as ContextManagerKind, q as ContextSnapshot, r as ContextSource, s as ContextSourceStatus, t as ConversationStep, u as ConversationTurn, v as CostBreakdown, w as CostSource, x as CostStatus, D as DoomLoopThresholds, E as EnvPolicy, F as ForkOptions, y as ForkResult, z as GenerateOptions, B as GenerateRunResult, I as InputProcessorContext, H as InteractionUpdate, K as InvalidateCacheOptions, L as McpAuthConfig, N as McpHttpServerConfig, O as McpOAuthConfig, Q as McpStdioServerConfig, T as MemoryAdapter, U as MemoryAdapterCapabilities, V as MemoryContext, W as MemoryFact, X as MemoryRevision, Y as MemoryToolSchema, Z as MemoryTurnMessage, _ as MessageOrigin, $ as OutputProcessorContext, a0 as PartialToolCallUpdate, a1 as PersonalityPreset, a2 as ProcessorControls, a3 as ProcessorTripwire, a4 as ProcessorViolation, a5 as ProviderCapability, a6 as ProviderRoute, a7 as ResolvedProviderRoute, a8 as RunCompactBoundaryEvent, a9 as RunCompletionCheckEvent, aa as RunErrorDetail, ab as RunEvent, ac as RunGitInfo, ad as RunMemoryDegradedEvent, ae as RunPermissionDeniedEvent, af as RunRateLimitEvent, ag as RunStatus, ah as RunTaskCompletedEvent, ai as RunTaskStartedEvent, aj as RunTaskUpdatedEvent, ak as RunTimelineEvent, al as RunToCompletionOptions, am as RunToCompletionResult, an as RunToolProgressEvent, ao as RunTripwireEvent, ap as RunUntilIterator, aq as SDKAgentPlugins, ar as SDKAgentSkillDetail, as as SDKAgentSkills, at as SDKArtifact, au as SDKAssistantMessage, av as SDKContextManager, aw as SDKImage, ax as SDKImageDimension, ay as SDKObjectDelta, az as SDKPluginMetadata, aA as SDKProvidersManager, aB as SDKRequestMessage, aC as SDKStatusMessage, aD as SDKSystemMessage, aE as SDKTaskMessage, aF as SDKThinkingMessage, aG as SDKToolUseMessage, aH as SDKUserMessage, aI as SDKUserMessageEvent, aJ as SendOptions, aK as ShellCommand, aL as ShellConversationTurn, aM as ShellOutput, aN as ShellOutputDeltaUpdate, aO as StepCompletedUpdate, aP as StepStartedUpdate, aQ as StreamToCompletionResult, aR as SummaryCompletedUpdate, aS as SummaryStartedUpdate, aT as SummaryUpdate, aU as SystemPromptSkillRef, aV as TextDeltaUpdate, aW as ThinkingCompletedUpdate, aX as ThinkingDeltaUpdate, aY as ThinkingMessage, aZ as TokenDeltaUpdate, a_ as TokenUsage, a$ as ToolCall, b0 as ToolCallCompletedUpdate, b1 as ToolCallStartedUpdate, b2 as ToolResult, b3 as ToolResultGuardOptions, b4 as ToolUseBlock, b5 as TurnEndedUpdate, b6 as UserMessage, b7 as UserMessageAppendedUpdate, b8 as Verdict } from './sdk-agent-CTOJlWA_.js';
4
+ import { A as AgentOptions, L as LocalOptions, B as BuiltinToolName, M as MemorySettings, S as SystemPromptResolver, C as CloudOptions, a as AgentDefinition, b as SkillsSettings, c as ListAgentsOptions, d as ListResult, e as SDKAgentInfo, G as GetAgentOptions, f as ListRunsOptions, g as GetRunOptions, h as AgentOperationOptions, i as AgentDescription, P as Plugin$1, j as ProviderProfile, I as InlineSkill, k as Skill, l as BudgetTracker, m as MemoryProvider, n as PreToolCallDecision } from './agent-Dfw3VsIX.js';
5
+ export { o as ActiveMemoryPassArgs, p as ActiveMemoryPassResult, q as AgentSubagentDescription, r as AgentToolDescription, s as BudgetCheck, t as BudgetTotal, u as BudgetUsageEvent, v as CloudEnv, w as CloudRepo, x as CompatSource, y as CompatSourceAdapter, z as CompatSurface, D as CreateSkillSpec, H as HookApprovalGate, E as HookApprovalRequest, F as HookName, J as LlmCallContext, K as MemoryProviderAgentRef, N as MemoryProviderFactory, O as MemoryProviderHandle, Q as MemoryProviderInitOptions, R as PluginContext, T as PluginHookDisposer, U as PostAssistantReplyContext, V as PostToolCallContext, W as PreToolCallContext, X as PreUserSendContext, Y as PreUserSendResult, Z as ProviderTransform, _ as ProviderTransformContext, $ as RecordSessionSummaryArgs, a0 as SessionLifecycleContext, a1 as SessionRecord, a2 as SessionStore, a3 as SettingSource, a4 as Skill, a5 as SkillsResolver, a6 as SkillsResolverContext, a7 as SystemPromptContext, a8 as SystemPromptMemoryFact, a9 as TelemetrySettings, aa as ToolCallSummary, ab as ToolContext, ac as ToolResultTransformContext, ad as TransformContext } from './agent-Dfw3VsIX.js';
6
+ import { ac as RunEvent, v as CostBreakdown, R as RunResult, P as ProviderRoutingSettings, S as SDKAgent, M as McpServerConfig, C as ContextSettings, a as PluginsSettings, b as Run, c as Processor, J as JudgeResult, G as GoalOptions, d as GoalEvent, e as GoalResult, f as MemoryId, g as RunEventSink$1, h as SDKProvider, i as SDKMessage } from './sdk-agent-a3fW1xUK.js';
7
+ export { A as AgentConversationTurn, j as AgentMemory, k as AgentOperation, l as AssistantMessage, m as CompletionCheck, n as CompletionCheckResult, o as ContextBudget, p as ContextManagerKind, q as ContextSnapshot, r as ContextSource, s as ContextSourceStatus, t as ConversationStep, u as ConversationTurn, v as CostBreakdown, w as CostSource, x as CostStatus, D as DoomLoopThresholds, E as EnvPolicy, F as ForkOptions, y as ForkResult, z as GenerateOptions, B as GenerateRunResult, I as InputProcessorContext, H as InteractionUpdate, K as InvalidateCacheOptions, L as McpAuthConfig, N as McpHttpServerConfig, O as McpOAuthConfig, Q as McpStdioServerConfig, T as MemoryAdapter, U as MemoryAdapterCapabilities, V as MemoryContext, W as MemoryFact, X as MemoryRevision, Y as MemoryToolSchema, Z as MemoryTurnMessage, _ as MessageOrigin, $ as OutputProcessorContext, a0 as PartialToolCallUpdate, a1 as PersonalityPreset, a2 as ProcessorControls, a3 as ProcessorTripwire, a4 as ProcessorViolation, a5 as ProviderCapability, a6 as ProviderRoute, a7 as PruneToolResultsOptions, a8 as ResolvedProviderRoute, a9 as RunCompactBoundaryEvent, aa as RunCompletionCheckEvent, ab as RunErrorDetail, ac as RunEvent, ad as RunGitInfo, ae as RunMemoryDegradedEvent, af as RunPermissionDeniedEvent, ag as RunRateLimitEvent, ah as RunStatus, ai as RunTaskCompletedEvent, aj as RunTaskStartedEvent, ak as RunTaskUpdatedEvent, al as RunTimelineEvent, am as RunToCompletionOptions, an as RunToCompletionResult, ao as RunToolProgressEvent, ap as RunTripwireEvent, aq as RunUntilIterator, ar as SDKAgentPlugins, as as SDKAgentSkillDetail, at as SDKAgentSkills, au as SDKArtifact, av as SDKAssistantMessage, aw as SDKContextManager, ax as SDKImage, ay as SDKImageDimension, az as SDKObjectDelta, aA as SDKPluginMetadata, aB as SDKProvidersManager, aC as SDKRequestMessage, aD as SDKStatusMessage, aE as SDKSystemMessage, aF as SDKTaskMessage, aG as SDKThinkingMessage, aH as SDKToolUseMessage, aI as SDKUserMessage, aJ as SDKUserMessageEvent, aK as SendOptions, aL as ShellCommand, aM as ShellConversationTurn, aN as ShellOutput, aO as ShellOutputDeltaUpdate, aP as StepCompletedUpdate, aQ as StepStartedUpdate, aR as StreamToCompletionResult, aS as SummaryCompletedUpdate, aT as SummaryStartedUpdate, aU as SummaryUpdate, aV as SystemPromptSkillRef, aW as TextDeltaUpdate, aX as ThinkingCompletedUpdate, aY as ThinkingDeltaUpdate, aZ as ThinkingMessage, a_ as TokenDeltaUpdate, a$ as TokenUsage, b0 as ToolCall, b1 as ToolCallCompletedUpdate, b2 as ToolCallStartedUpdate, b3 as ToolResult, b4 as ToolResultGuardOptions, b5 as ToolUseBlock, b6 as TurnEndedUpdate, b7 as UserMessage, b8 as UserMessageAppendedUpdate, b9 as Verdict } from './sdk-agent-a3fW1xUK.js';
7
8
  import * as zod from 'zod';
8
9
  import { ZodType, z } from 'zod';
9
10
  import { S as StructuredOutputError, B as BudgetOptions, a as BudgetHandle, b as BudgetSnapshot } from './errors-Pf22PJJ-.js';
10
11
  export { A as AgentDisposedError, c as AgentRunError, d as AgentRunErrorCode, e as AuthenticationError, f as BudgetExceedEvent, g as BudgetExceededError, h as BudgetLimit, i as BudgetMode, j as BudgetScope, k as BudgetThresholdEvent, l as BudgetWindow, C as ConfigurationError, I as IntegrationNotConnectedError, m as InvalidTaskIdError, M as MemoryAdapterError, n as MemoryAdapterErrorCode, N as NetworkError, R as RateLimitError, T as TaskNotFoundError, U as UnknownAgentError, o as UnsupportedBudgetOperationError, p as UnsupportedRunOperationError, q as UnsupportedTaskOperationError, r as isTransientError } from './errors-Pf22PJJ-.js';
11
12
  import { M as ModelSelection, C as CustomTool, T as ToolResultContentBlock, P as PermissionMode } from './agent-prims-CZyxfCmS.js';
12
13
  export { I as ImageBlock, a as ModelParameterValue, R as RunOperation, b as TextBlock, c as ToolContextMessage } from './agent-prims-CZyxfCmS.js';
13
- export { C as Cron, a as CronCreateOptions, b as CronGetOptions, c as CronJob, d as CronJobStatus, e as CronListOptions, f as CronOperationOptions, g as CronRunOptions, h as CronRuntime, i as CronSchedulerStatus, j as CronStartOptions } from './cron-CHn-F0fC.js';
14
+ export { C as Cron, a as CronCreateOptions, b as CronGetOptions, c as CronJob, d as CronJobStatus, e as CronListOptions, f as CronOperationOptions, g as CronRunOptions, h as CronRuntime, i as CronSchedulerStatus, j as CronStartOptions } from './cron-BubDpFJG.js';
14
15
  import { StepResult } from './workflow.js';
15
16
  export { Workflow, agentStep, fn } from './workflow.js';
16
17
 
@@ -242,6 +243,19 @@ interface StreamObjectOptions<T extends ZodType> {
242
243
  * when the right env key is set under a different provider name.
243
244
  */
244
245
  providers?: ProviderRoutingSettings;
246
+ /**
247
+ * Builtin tools removed from the transient agent's catalogue, forwarded to
248
+ * {@link AgentOptions.withheldBuiltinTools}. Absent ⇒ unchanged default: the agent holds
249
+ * `shell`. Pass `["shell"]` for a step that must only produce JSON. The `output` tool is
250
+ * never withheld.
251
+ */
252
+ withheldBuiltinTools?: readonly BuiltinToolName[];
253
+ /**
254
+ * Memory settings for the transient agent, forwarded to {@link AgentOptions.memory}.
255
+ * Absent ⇒ unchanged default (a session transcript is written). Pass `{ enabled: false }`
256
+ * for a step that must leave no transcript.
257
+ */
258
+ memory?: MemorySettings;
245
259
  }
246
260
  /**
247
261
  * Recursive partial — `T` where every nested field becomes optional.
@@ -340,6 +354,19 @@ interface GenerateObjectOptions<T extends ZodType> {
340
354
  * to raw.
341
355
  */
342
356
  errorStrategy?: "throw" | "return-partial" | "return-raw";
357
+ /**
358
+ * Builtin tools removed from every transient agent's catalogue (the reasoning-phase agent of
359
+ * `structuringModel` included), forwarded to {@link AgentOptions.withheldBuiltinTools}.
360
+ * Absent ⇒ unchanged default: the agent holds `shell`. Pass `["shell"]` for a step that must
361
+ * only produce JSON. The `output` tool is never withheld.
362
+ */
363
+ withheldBuiltinTools?: readonly BuiltinToolName[];
364
+ /**
365
+ * Memory settings for every transient agent of the call, forwarded to {@link AgentOptions.memory}.
366
+ * Absent ⇒ unchanged default (a session transcript is written). Pass `{ enabled: false }`
367
+ * for a step that must leave no transcript.
368
+ */
369
+ memory?: MemorySettings;
343
370
  }
344
371
  /**
345
372
  * Successful return from {@link Agent.generateObject}.
@@ -1652,13 +1679,15 @@ declare class Provider {
1652
1679
  * listed by name and description, with the instructions under the frontmatter unable to arrive.
1653
1680
  */
1654
1681
  type ReadableSkill = InlineSkill | Skill;
1682
+ /** A fixed list, or a function re-evaluated on every call so later-discovered skills are readable. */
1683
+ type SkillReadSource = ReadonlyArray<ReadableSkill> | (() => ReadonlyArray<ReadableSkill> | Promise<ReadonlyArray<ReadableSkill>>);
1655
1684
  /** SE36 — `SkillReadTool.create` replaces `defineSkillReadTool` (ADR 0015). @public *
1656
1685
  * `SkillReadTool.create` returns a **`CustomTool`** — a skill-reading tool, not a
1657
1686
  * `SkillReadTool` instance.
1658
1687
  */
1659
1688
  declare class SkillReadTool {
1660
1689
  private constructor();
1661
- static create(skills: ReadonlyArray<ReadableSkill>): CustomTool;
1690
+ static create(skills: SkillReadSource): CustomTool;
1662
1691
  }
1663
1692
 
1664
1693
  /**
@@ -4492,4 +4521,4 @@ interface WiringRecordInput<K extends string> {
4492
4521
  */
4493
4522
  declare function recordWiring<K extends string>(input: WiringRecordInput<K>): Readonly<Record<K, WiredEntity>>;
4494
4523
 
4495
- export { Agent, AgentBuilder, type AgentBuilderDeps, AgentDefinition, type AgentDescription, AgentFactory, AgentOperationOptions, AgentOptions, type AgentPromptResult, type AgentRegistryOptions, type ApprovalDecision, type ApprovalInput, type ApprovalMode, type ApprovalOutcome, type ApprovalReason, type BatchItem, type BatchOptions, type BatchProgress, type BatchResult, type BlastRadiusDecision, type BlastRadiusInput, type BlastRadiusOutcome, type BlastRadiusReason, Budget, BudgetHandle, BudgetOptions, BudgetSnapshot, type BudgetTracker, CloudOptions, ContextSettings, type CounterBudgetTrackerOptions, type CredentialInput, type CredentialReport, type CustomTool, type DeclaredAction, type DeclaredLayer, type DeepPartial, type DefineProviderOptions, type DefineToolSpec, type DiagnosticsSink, type DreamingSweepOptions, type DreamingSweepResult, type EffectiveToolCatalog, type EnvOptOut, type EnvReachabilityAudit, type EnvReachabilityInput, ErrorMetadata, EventBus, type EvictReason, GOAL_CONTINUATION_MARKER, GenerateObjectError, type GenerateObjectOptions, type GenerateObjectResult, GetAgentOptions, GetRunOptions, GoalEvent, type GoalLoopAgent, GoalOptions, GoalResult, InlineSkill, JobQueue, type JobQueueOptions, JudgeCredentialError, type JudgeResult, type KeepReason, type KeptArtifact, LayerOrderError, type LayerValues, ListAgentsOptions, ListResult, ListRunsOptions, type LiveAgentRegistry, LiveSessionError, type LiveSessionReason, LocalOptions, type ManagedSettings, McpServerConfig, Memory, MemoryId, type MemoryProvider, MemorySettings, type MigrateOptions, type MigrateResult, type ModelListItem, type ModelParameterDefinition, ModelSelection, type ModelVariant, NoopMemoryProvider, type NormalizedJsonSchema, type OTelSpan, type PermissionAction, PermissionEngine, type PermissionEngineOptions, type PermissionFloorContext, type PermissionGate, type PermissionGateContext, type PermissionGateDecision, PermissionMode, PermissionPlugin, type PermissionPluginOptions, type PermissionRule, type PermissionRuleSet, Plugin, PluginsSettings, PreToolCallDecision, type Processor, Provider, type ProviderProfile, ProviderRoutingSettings, type ReadSessionMessagesOptions, type ReapPlan, type ReapPlanInput, type ReapableArtifact, type RetentionPolicy, RetentionPolicyError, Run, RunEventSink$1 as RunEventSink, RunResult, type SDKAgent, SDKAgentInfo, SDKMessage, type SDKModel, SDKProvider, type SDKRepository, type SDKUser, SOVEREIGN_ENV_KEYS, Security, type SecurityFloorInput, type SessionMessage, type SessionMessagePart, type SessionScope, type ShareGptMessage, type ShareGptTrajectory, SkillReadTool, SkillsSettings, type SovereignEnvKey, Squad, type SquadOptions, type SquadRun, StreamObjectError, type StreamObjectEvent, type StreamObjectOptions, SystemPromptResolver, TASK_RESERVED_PREFIXES, Task, type TaskCancelResult, type TaskConfigureOptions, type TaskEvent, type TaskFilter, type TaskHandle, type TaskKind, type TaskState, type TaskStoreOptions, type TaskSubmitOptions, type TaskWorkContext, type TaskWorkFn, type TelemetryHandle, Theokit, TheokitAgentError, type TheokitRequestOptions, TokenLimiter, type TokenLimiterOptions, Tool, ToolError, type ToolResultContentBlock, type TrustLevel, type TrustPosture, type TrustPostureInput, type TrustSource, UngatedCapabilityError, UnicodeNormalizer, type UnicodeNormalizerOptions, type UnresolvedToolSource, UsageAccumulator, type WiredEntity, type WiringRecordInput, type WithBlastRadius, applyMode, applySecurityFloor, auditEnvReachability, chargeAndCheckThresholds, computeCost, createCounterBudgetTracker, createTokenLimiter, createUnicodeNormalizer, decideApproval, describeAction, describeCredential, effectiveToolNames, emitRunEvent, estimateTokens, evaluateBlastRadius, extractRawId, foldLayers, getPricingEntry, guardSessionDestruction, inferApiMode, isInside, isValidTaskId, loadProjectEnv, managedSettingsPathFor, migrateSqliteToLance, mkMemoryId, normalizeSchema, normalizeUsage, parsePermissionRules, permissionFloorReason, planReaping, preflightCheck, readManagedSettings, readSessionMessages, recordWiring, resolveTrustPosture, runGoalLoop, scopedConversationId, sessionScopePrefix, setDiagnosticsSink, toShareGptTrajectory, verifyLayerOrdering, withBlastRadius, withCwdMutex };
4524
+ export { Agent, AgentBuilder, type AgentBuilderDeps, AgentDefinition, type AgentDescription, AgentFactory, AgentOperationOptions, AgentOptions, type AgentPromptResult, type AgentRegistryOptions, type ApprovalDecision, type ApprovalInput, type ApprovalMode, type ApprovalOutcome, type ApprovalReason, type BatchItem, type BatchOptions, type BatchProgress, type BatchResult, type BlastRadiusDecision, type BlastRadiusInput, type BlastRadiusOutcome, type BlastRadiusReason, Budget, BudgetHandle, BudgetOptions, BudgetSnapshot, type BudgetTracker, BuiltinToolName, CloudOptions, ContextSettings, type CounterBudgetTrackerOptions, type CredentialInput, type CredentialReport, type CustomTool, type DeclaredAction, type DeclaredLayer, type DeepPartial, type DefineProviderOptions, type DefineToolSpec, type DiagnosticsSink, type DreamingSweepOptions, type DreamingSweepResult, type EffectiveToolCatalog, type EnvOptOut, type EnvReachabilityAudit, type EnvReachabilityInput, ErrorMetadata, EventBus, type EvictReason, GOAL_CONTINUATION_MARKER, GenerateObjectError, type GenerateObjectOptions, type GenerateObjectResult, GetAgentOptions, GetRunOptions, GoalEvent, type GoalLoopAgent, GoalOptions, GoalResult, InlineSkill, JobQueue, type JobQueueOptions, JudgeCredentialError, type JudgeResult, type KeepReason, type KeptArtifact, LayerOrderError, type LayerValues, ListAgentsOptions, ListResult, ListRunsOptions, type LiveAgentRegistry, LiveSessionError, type LiveSessionReason, LocalOptions, type ManagedSettings, McpServerConfig, Memory, MemoryId, type MemoryProvider, MemorySettings, type MigrateOptions, type MigrateResult, type ModelListItem, type ModelParameterDefinition, ModelSelection, type ModelVariant, NoopMemoryProvider, type NormalizedJsonSchema, type OTelSpan, type PermissionAction, PermissionEngine, type PermissionEngineOptions, type PermissionFloorContext, type PermissionGate, type PermissionGateContext, type PermissionGateDecision, PermissionMode, PermissionPlugin, type PermissionPluginOptions, type PermissionRule, type PermissionRuleSet, Plugin, PluginsSettings, PreToolCallDecision, type Processor, Provider, type ProviderProfile, ProviderRoutingSettings, type ReadSessionMessagesOptions, type ReapPlan, type ReapPlanInput, type ReapableArtifact, type RetentionPolicy, RetentionPolicyError, Run, RunEventSink$1 as RunEventSink, RunResult, type SDKAgent, SDKAgentInfo, SDKMessage, type SDKModel, SDKProvider, type SDKRepository, type SDKUser, SOVEREIGN_ENV_KEYS, Security, type SecurityFloorInput, type SessionMessage, type SessionMessagePart, type SessionScope, type ShareGptMessage, type ShareGptTrajectory, SkillReadTool, SkillsSettings, type SovereignEnvKey, Squad, type SquadOptions, type SquadRun, StreamObjectError, type StreamObjectEvent, type StreamObjectOptions, SystemPromptResolver, TASK_RESERVED_PREFIXES, Task, type TaskCancelResult, type TaskConfigureOptions, type TaskEvent, type TaskFilter, type TaskHandle, type TaskKind, type TaskState, type TaskStoreOptions, type TaskSubmitOptions, type TaskWorkContext, type TaskWorkFn, type TelemetryHandle, Theokit, TheokitAgentError, type TheokitRequestOptions, TokenLimiter, type TokenLimiterOptions, Tool, ToolError, type ToolResultContentBlock, type TrustLevel, type TrustPosture, type TrustPostureInput, type TrustSource, UngatedCapabilityError, UnicodeNormalizer, type UnicodeNormalizerOptions, type UnresolvedToolSource, UsageAccumulator, type WiredEntity, type WiringRecordInput, type WithBlastRadius, applyMode, applySecurityFloor, auditEnvReachability, chargeAndCheckThresholds, computeCost, createCounterBudgetTracker, createTokenLimiter, createUnicodeNormalizer, decideApproval, describeAction, describeCredential, effectiveToolNames, emitRunEvent, estimateTokens, evaluateBlastRadius, extractRawId, foldLayers, getPricingEntry, guardSessionDestruction, inferApiMode, isInside, isValidTaskId, loadProjectEnv, managedSettingsPathFor, migrateSqliteToLance, mkMemoryId, normalizeSchema, normalizeUsage, parsePermissionRules, permissionFloorReason, planReaping, preflightCheck, readManagedSettings, readSessionMessages, recordWiring, resolveTrustPosture, runGoalLoop, scopedConversationId, sessionScopePrefix, setDiagnosticsSink, toShareGptTrajectory, verifyLayerOrdering, withBlastRadius, withCwdMutex };
package/dist/index.js CHANGED
@@ -1,19 +1,19 @@
1
- export { StreamObjectError } from './chunk-XRPMZ7TO.js';
1
+ export { StreamObjectError } from './chunk-CYWOJA6B.js';
2
2
  export { GOAL_CONTINUATION_MARKER } from './chunk-PY2RQOA7.js';
3
3
  export { JudgeCredentialError } from './chunk-XZKIAENA.js';
4
4
  import { migrateSqliteToLance, appendDiaryEntry } from './chunk-MSEL5E5P.js';
5
- export { GenerateObjectError } from './chunk-VVGFZQZC.js';
6
- import './chunk-AQW54OWQ.js';
7
- import { Workflow, agentStep } from './chunk-ZLFFDPXC.js';
8
- export { Workflow, agentStep, fn } from './chunk-ZLFFDPXC.js';
9
- import './chunk-BO3PV3OP.js';
5
+ export { GenerateObjectError } from './chunk-3LMVJTNJ.js';
6
+ import './chunk-DFBWYETS.js';
7
+ import { Workflow, agentStep } from './chunk-73IITAF7.js';
8
+ export { Workflow, agentStep, fn } from './chunk-73IITAF7.js';
9
+ import './chunk-TDED5XES.js';
10
10
  import './chunk-HY66GLM6.js';
11
- export { Cron } from './chunk-NJBJ3CUG.js';
12
- import { MEMORY_EMBEDDING_ADAPTERS, resolveSessionDir, DEFAULT_AGENTIC_MODEL_ID, Agent } from './chunk-BJ7BPLQK.js';
13
- export { Agent, AgentBuilder, Tool, ToolError, UsageAccumulator, computeCost, getPricingEntry, managedSettingsPathFor, readManagedSettings } from './chunk-BJ7BPLQK.js';
11
+ export { Cron } from './chunk-NAVUTK6X.js';
12
+ import { MEMORY_EMBEDDING_ADAPTERS, resolveSessionDir, DEFAULT_AGENTIC_MODEL_ID, Agent } from './chunk-GARVAUCU.js';
13
+ export { Agent, AgentBuilder, Tool, ToolError, UsageAccumulator, computeCost, getPricingEntry, managedSettingsPathFor, readManagedSettings } from './chunk-GARVAUCU.js';
14
14
  import { configure, submit, list, get, cancel, subscribe } from './chunk-HWMGR3HA.js';
15
15
  export { emitRunEvent } from './chunk-HWMGR3HA.js';
16
- import './chunk-4GUFNDZR.js';
16
+ import './chunk-3ONIVO2I.js';
17
17
  import './chunk-K2BQQ445.js';
18
18
  import './chunk-2C24NSNV.js';
19
19
  import './chunk-HJ2LV464.js';
@@ -23,8 +23,8 @@ import './chunk-H73MEMQB.js';
23
23
  import './chunk-QK2ERTO3.js';
24
24
  import { resolveMemoryRoot, readFactsFromMarkdown } from './chunk-DF77RBF4.js';
25
25
  import { FsSessionStore } from './chunk-AB4OPJLD.js';
26
- import { discoverProviderPlugins, shouldUseFixtureMode, isFixtureApiKey, httpRequest, mapOllamaTransportError, readErrorResponseBody, mapOllamaHttpError } from './chunk-XJ4C4NFX.js';
27
- export { inferApiMode, normalizeUsage } from './chunk-XJ4C4NFX.js';
26
+ import { discoverProviderPlugins, shouldUseFixtureMode, isFixtureApiKey, httpRequest, mapOllamaTransportError, readErrorResponseBody, mapOllamaHttpError } from './chunk-ZOL3L4EH.js';
27
+ export { inferApiMode, normalizeUsage } from './chunk-ZOL3L4EH.js';
28
28
  import './chunk-5AR6O7GW.js';
29
29
  import './chunk-2XC6KDJM.js';
30
30
  import './chunk-ZJAYFSVI.js';
@@ -41,7 +41,7 @@ import './chunk-FJWQP6EE.js';
41
41
  import './chunk-NAF4L3T6.js';
42
42
  import './chunk-VZGE7NAI.js';
43
43
  import './chunk-6X6ID4MO.js';
44
- import { stripSkillFrontmatter } from './chunk-NHOEXFZT.js';
44
+ import { stripSkillFrontmatter } from './chunk-2HXTNVLM.js';
45
45
  import './chunk-4QCJAJAG.js';
46
46
  import './chunk-SAGRF4IB.js';
47
47
  import './chunk-PKRPV3R7.js';
@@ -63,13 +63,13 @@ import { CLAUDE_DIR_NAME, THEOKIT_DIR_LITERAL } from './chunk-YMVTUV5K.js';
63
63
  import './chunk-Q7UG242V.js';
64
64
  import { estimateTokens, CHARS_PER_TOKEN } from './chunk-SZQFCHU6.js';
65
65
  export { estimateTokens } from './chunk-SZQFCHU6.js';
66
- import './chunk-2SFLLOMN.js';
66
+ import './chunk-NVQSBRG6.js';
67
67
  import { parseModelId } from './chunk-R7WIIPUR.js';
68
- import './chunk-NKQVLWDF.js';
69
- import { registerBuiltins, listProviders, getCatalogCapabilities, getProviderProfile } from './chunk-5HSMH2ZZ.js';
68
+ import './chunk-ULEK4OM4.js';
69
+ import { registerBuiltins, listProviders, getCatalogCapabilities, getProviderProfile } from './chunk-CJN5CEI3.js';
70
70
  import './chunk-AGACYRJ2.js';
71
- import './chunk-3FSBE4PS.js';
72
- import './chunk-MS3TQSXU.js';
71
+ import './chunk-3GTN4HOO.js';
72
+ import './chunk-QD6B6W6I.js';
73
73
  import './chunk-5IUDICRK.js';
74
74
  import './chunk-Q7GYMXVC.js';
75
75
  import { BudgetExceededError, ConfigurationError, TheokitAgentError, MemoryAdapterError, AuthenticationError } from './chunk-TNFOU6SB.js';
@@ -77,8 +77,8 @@ export { AgentDisposedError, AgentRunError, AuthenticationError, BudgetExceededE
77
77
  import { diag, redactSecrets, addPattern, resolveApiKey } from './chunk-3OY6H3I7.js';
78
78
  export { setDiagnosticsSink } from './chunk-3OY6H3I7.js';
79
79
  import { createHash, randomUUID } from 'crypto';
80
- import { readFile, mkdir, readdir } from 'fs/promises';
81
- import { resolve, normalize, sep, isAbsolute, parse, relative, dirname, join } from 'path';
80
+ import { mkdir, readFile, readdir } from 'fs/promises';
81
+ import { resolve, normalize, sep, isAbsolute, parse, relative, join, dirname } from 'path';
82
82
  import { z } from 'zod';
83
83
  import { homedir } from 'os';
84
84
 
@@ -630,6 +630,14 @@ async function readReferences(skillDir) {
630
630
  }
631
631
  return Object.keys(refs).length > 0 ? refs : void 0;
632
632
  }
633
+ function readNamed(skills, name) {
634
+ const skill = skills.find((s) => s.name === name);
635
+ if (skill === void 0) {
636
+ const available = skills.map((s) => s.name).join(", ");
637
+ return `Skill "${name}" not found. Available skills: ${available.length > 0 ? available : "(none)"}.`;
638
+ }
639
+ return renderSkill(skill);
640
+ }
633
641
  var SkillReadInputSchema = z.object({
634
642
  name: z.string().min(1, "skill_read: `name` is required.")
635
643
  });
@@ -645,7 +653,9 @@ async function renderSkill(skill) {
645
653
  }
646
654
  return parts.join("\n");
647
655
  }
648
- function defineSkillReadTool(skills) {
656
+ function defineSkillReadTool(source) {
657
+ if (typeof source === "function") return lazySkillReadTool(source);
658
+ const skills = source;
649
659
  const seen = /* @__PURE__ */ new Set();
650
660
  for (const skill of skills) {
651
661
  if (seen.has(skill.name)) {
@@ -666,12 +676,18 @@ function defineSkillReadTool(skills) {
666
676
  // promise: parse and the not-found answer stay exactly as synchronous as they were.
667
677
  handler: (input) => {
668
678
  const { name } = SkillReadInputSchema.parse(input);
669
- const skill = skills.find((s) => s.name === name);
670
- if (skill === void 0) {
671
- const available = skills.map((s) => s.name).join(", ");
672
- return `Skill "${name}" not found. Available skills: ${available.length > 0 ? available : "(none)"}.`;
673
- }
674
- return renderSkill(skill);
679
+ return readNamed(skills, name);
680
+ }
681
+ };
682
+ }
683
+ function lazySkillReadTool(source) {
684
+ const fixed = defineSkillReadTool([]);
685
+ return {
686
+ ...fixed,
687
+ handler: async (input) => {
688
+ const { name } = SkillReadInputSchema.parse(input);
689
+ const skills = await source();
690
+ return readNamed(skills, name);
675
691
  }
676
692
  };
677
693
  }
@@ -1929,7 +1945,7 @@ function isBuiltAgent(m) {
1929
1945
  return typeof m.send === "function";
1930
1946
  }
1931
1947
  async function materialize(def, index) {
1932
- const { Agent: Agent2 } = await import('./agent-IG7BP6GN.js');
1948
+ const { Agent: Agent2 } = await import('./agent-T34LCGQM.js');
1933
1949
  return Agent2.create({
1934
1950
  // `AgentDefinition.model` admits the sentinel `'inherit'`, which is not a model id. Inheriting
1935
1951
  // here means "declare nothing and let the default apply" — forwarding the literal would create