agency-lang 0.7.0 → 0.7.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (150) hide show
  1. package/dist/lib/agents/agency-agent/agent.agency +122 -27
  2. package/dist/lib/agents/agency-agent/agent.js +474 -147
  3. package/dist/lib/agents/agency-agent/lib/attachments.js +2 -2
  4. package/dist/lib/agents/agency-agent/lib/config.agency +5 -0
  5. package/dist/lib/agents/agency-agent/lib/config.js +11 -0
  6. package/dist/lib/agents/agency-agent/lib/defaultPolicy.agency +106 -0
  7. package/dist/lib/agents/agency-agent/lib/defaultPolicy.js +764 -3
  8. package/dist/lib/agents/agency-agent/lib/modelFilters.js +1 -1
  9. package/dist/lib/agents/agency-agent/lib/resolution.js +4 -4
  10. package/dist/lib/agents/agency-agent/lib/search.js +3 -3
  11. package/dist/lib/agents/agency-agent/lib/settings.js +1 -1
  12. package/dist/lib/agents/agency-agent/lib/utils.js +1 -1
  13. package/dist/lib/agents/agency-agent/shared.js +2 -2
  14. package/dist/lib/agents/agency-agent/subagents/code.js +1 -1
  15. package/dist/lib/agents/agency-agent/subagents/explorer.js +1 -1
  16. package/dist/lib/agents/agency-agent/subagents/oracle.js +1 -1
  17. package/dist/lib/agents/agency-agent/subagents/research.js +1 -1
  18. package/dist/lib/agents/agency-agent/subagents/review.js +4 -4
  19. package/dist/lib/agents/agency-agent/tests/agentTurn.js +1 -1
  20. package/dist/lib/agents/agency-agent/tests/attachments.js +1 -1
  21. package/dist/lib/agents/agency-agent/tests/attachmentsTurn.js +2 -2
  22. package/dist/lib/agents/agency-agent/tests/gitPolicy.js +3 -3
  23. package/dist/lib/agents/review/agent.js +3 -3
  24. package/dist/lib/ir/prettyPrint.js +25 -4
  25. package/dist/lib/runtime/runner.d.ts +2 -2
  26. package/dist/lib/runtime/runner.js +26 -7
  27. package/dist/lib/stdlib/version.d.ts +1 -1
  28. package/dist/lib/stdlib/version.js +1 -1
  29. package/package.json +1 -1
  30. package/stdlib/agency/eval.js +1 -1
  31. package/stdlib/agency.js +1 -1
  32. package/stdlib/agent.agency +9 -9
  33. package/stdlib/agent.js +5 -5
  34. package/stdlib/data/tech/hackernews.js +1 -1
  35. package/stdlib/index.js +15 -15
  36. package/stdlib/llm.js +1 -1
  37. package/stdlib/markdown.js +1 -1
  38. package/stdlib/memory.js +2 -2
  39. package/stdlib/object.js +5 -5
  40. package/stdlib/policy.agency +21 -7
  41. package/stdlib/policy.js +45 -16
  42. package/stdlib/skills.js +1 -1
  43. package/stdlib/strategy.js +3 -3
  44. package/stdlib/thread.js +3 -3
  45. package/stdlib/ui/chart.js +2 -2
  46. package/stdlib/ui/cli.agency +1 -1
  47. package/stdlib/ui/cli.js +1 -1
  48. package/stdlib/ui/layout.js +3 -3
  49. package/stdlib/ui/table.js +2 -2
  50. package/stdlib/ui.js +3 -3
  51. package/dist/lib/agents/docs/cli/cli/agent.md +0 -16
  52. package/dist/lib/agents/docs/cli/cli/compile.md +0 -21
  53. package/dist/lib/agents/docs/cli/cli/coverage.md +0 -112
  54. package/dist/lib/agents/docs/cli/cli/debug.md +0 -41
  55. package/dist/lib/agents/docs/cli/cli/doc.md +0 -98
  56. package/dist/lib/agents/docs/cli/cli/editor-integration.md +0 -44
  57. package/dist/lib/agents/docs/cli/cli/eval-judge.md +0 -72
  58. package/dist/lib/agents/docs/cli/cli/eval.md +0 -194
  59. package/dist/lib/agents/docs/cli/cli/format.md +0 -23
  60. package/dist/lib/agents/docs/cli/cli/index.md +0 -7
  61. package/dist/lib/agents/docs/cli/cli/local.md +0 -92
  62. package/dist/lib/agents/docs/cli/cli/models.md +0 -63
  63. package/dist/lib/agents/docs/cli/cli/optimize.md +0 -338
  64. package/dist/lib/agents/docs/cli/cli/pack.md +0 -56
  65. package/dist/lib/agents/docs/cli/cli/policy.md +0 -23
  66. package/dist/lib/agents/docs/cli/cli/preprocess-and-ast.md +0 -21
  67. package/dist/lib/agents/docs/cli/cli/review.md +0 -16
  68. package/dist/lib/agents/docs/cli/cli/run.md +0 -79
  69. package/dist/lib/agents/docs/cli/cli/schedule.md +0 -89
  70. package/dist/lib/agents/docs/cli/cli/serve.md +0 -52
  71. package/dist/lib/agents/docs/cli/cli/test.md +0 -44
  72. package/dist/lib/agents/docs/cli/cli/trace-and-bundle.md +0 -75
  73. package/dist/lib/agents/docs/cli/cli/typecheck.md +0 -19
  74. package/dist/lib/agents/docs/guide/guide/advanced-types.md +0 -26
  75. package/dist/lib/agents/docs/guide/guide/agency-config-file.md +0 -212
  76. package/dist/lib/agents/docs/guide/guide/agency-packages.md +0 -54
  77. package/dist/lib/agents/docs/guide/guide/agency-stdlib.md +0 -14
  78. package/dist/lib/agents/docs/guide/guide/agency-vs-typescript.md +0 -33
  79. package/dist/lib/agents/docs/guide/guide/attachments.md +0 -56
  80. package/dist/lib/agents/docs/guide/guide/basic-syntax.md +0 -350
  81. package/dist/lib/agents/docs/guide/guide/blocks.md +0 -134
  82. package/dist/lib/agents/docs/guide/guide/build-integration.md +0 -99
  83. package/dist/lib/agents/docs/guide/guide/builtins.md +0 -84
  84. package/dist/lib/agents/docs/guide/guide/callbacks.md +0 -169
  85. package/dist/lib/agents/docs/guide/guide/checkpointing.md +0 -101
  86. package/dist/lib/agents/docs/guide/guide/cli-args.md +0 -190
  87. package/dist/lib/agents/docs/guide/guide/common-functions.md +0 -36
  88. package/dist/lib/agents/docs/guide/guide/compiling-and-running.md +0 -62
  89. package/dist/lib/agents/docs/guide/guide/concurrency.md +0 -108
  90. package/dist/lib/agents/docs/guide/guide/cross-thread-context.md +0 -226
  91. package/dist/lib/agents/docs/guide/guide/custom-providers.md +0 -195
  92. package/dist/lib/agents/docs/guide/guide/debugging.md +0 -67
  93. package/dist/lib/agents/docs/guide/guide/developer-tools.md +0 -90
  94. package/dist/lib/agents/docs/guide/guide/effects-and-raises.md +0 -137
  95. package/dist/lib/agents/docs/guide/guide/effects.md +0 -100
  96. package/dist/lib/agents/docs/guide/guide/error-handling.md +0 -161
  97. package/dist/lib/agents/docs/guide/guide/exercise-1.md +0 -32
  98. package/dist/lib/agents/docs/guide/guide/functions.md +0 -94
  99. package/dist/lib/agents/docs/guide/guide/getting-started.md +0 -35
  100. package/dist/lib/agents/docs/guide/guide/global-var-initialization.md +0 -70
  101. package/dist/lib/agents/docs/guide/guide/global-vs-static.md +0 -76
  102. package/dist/lib/agents/docs/guide/guide/guards.md +0 -134
  103. package/dist/lib/agents/docs/guide/guide/handlers.md +0 -196
  104. package/dist/lib/agents/docs/guide/guide/image-generation.md +0 -113
  105. package/dist/lib/agents/docs/guide/guide/imports-and-packages.md +0 -100
  106. package/dist/lib/agents/docs/guide/guide/interrupts-from-typescript.md +0 -84
  107. package/dist/lib/agents/docs/guide/guide/interrupts-part-2.md +0 -54
  108. package/dist/lib/agents/docs/guide/guide/interrupts.md +0 -139
  109. package/dist/lib/agents/docs/guide/guide/llm-part-2.md +0 -111
  110. package/dist/lib/agents/docs/guide/guide/llm.md +0 -109
  111. package/dist/lib/agents/docs/guide/guide/mcp.md +0 -295
  112. package/dist/lib/agents/docs/guide/guide/memory.md +0 -401
  113. package/dist/lib/agents/docs/guide/guide/message-threads.md +0 -111
  114. package/dist/lib/agents/docs/guide/guide/nodes.md +0 -50
  115. package/dist/lib/agents/docs/guide/guide/observability.md +0 -99
  116. package/dist/lib/agents/docs/guide/guide/partial-application.md +0 -96
  117. package/dist/lib/agents/docs/guide/guide/pattern-matching.md +0 -366
  118. package/dist/lib/agents/docs/guide/guide/policies.md +0 -67
  119. package/dist/lib/agents/docs/guide/guide/schema-parameter-injection.md +0 -101
  120. package/dist/lib/agents/docs/guide/guide/schemas.md +0 -99
  121. package/dist/lib/agents/docs/guide/guide/serving.md +0 -165
  122. package/dist/lib/agents/docs/guide/guide/state-isolation.md +0 -139
  123. package/dist/lib/agents/docs/guide/guide/streaming.md +0 -28
  124. package/dist/lib/agents/docs/guide/guide/tags.md +0 -72
  125. package/dist/lib/agents/docs/guide/guide/testing.md +0 -187
  126. package/dist/lib/agents/docs/guide/guide/troubleshooting.md +0 -86
  127. package/dist/lib/agents/docs/guide/guide/ts-helpers.md +0 -559
  128. package/dist/lib/agents/docs/guide/guide/ts-interop.md +0 -72
  129. package/dist/lib/agents/docs/guide/guide/type-validation.md +0 -187
  130. package/dist/lib/agents/docs/guide/guide/types.md +0 -181
  131. package/dist/lib/agents/docs/guide/guide/unused.md +0 -178
  132. package/dist/lib/agents/docs/guide/guide/unused2.md +0 -258
  133. package/dist/lib/agents/docs/guide/guide/value-parameterized-types.md +0 -186
  134. package/dist/lib/agents/docs/guide/guide/vscode-extension.md +0 -33
  135. package/dist/lib/agents/docs/guide/guide/why-agency.md +0 -323
  136. package/stdlib/browser.js +0 -421
  137. package/stdlib/chart.js +0 -983
  138. package/stdlib/cli.js +0 -1116
  139. package/stdlib/email.js +0 -1104
  140. package/stdlib/imessage.js +0 -377
  141. package/stdlib/keyring.js +0 -803
  142. package/stdlib/layout.js +0 -3657
  143. package/stdlib/oauth.js +0 -862
  144. package/stdlib/schemas.js +0 -223
  145. package/stdlib/search.js +0 -629
  146. package/stdlib/sms.js +0 -419
  147. package/stdlib/table.js +0 -1419
  148. package/stdlib/threads.js +0 -1041
  149. package/stdlib/types.js +0 -222
  150. package/stdlib/validators.js +0 -1606
@@ -3,15 +3,13 @@ import { getVersion } from "agency-lang/stdlib/agency.js";
3
3
  import { printLocalCatalog, localModelsSupported, listModelNames } from "agency-lang/stdlib/agency/local.js";
4
4
  import { parseArgs } from "agency-lang/stdlib/args.js";
5
5
  import { map } from "agency-lang/stdlib/array.js";
6
- import { clearMessages, pushMessage, repl, clearScreen, clearHistory } from "agency-lang/stdlib/ui/cli.js";
7
6
  import { today } from "agency-lang/stdlib/date.js";
8
7
  import { generateImage } from "agency-lang/stdlib/image.js";
9
8
  import { applyAgentCwd, setAgentCwd } from "agency-lang/stdlib/index.js";
10
- import { keys } from "agency-lang/stdlib/object.js";
11
- import { basename, dirname } from "agency-lang/stdlib/path.js";
12
- import { box, render } from "agency-lang/stdlib/ui/layout.js";
13
9
  import { listHostedModels, hostedModelInfo } from "agency-lang/stdlib/llm.js";
14
10
  import { setMemoryId, disableMemory } from "agency-lang/stdlib/memory.js";
11
+ import { keys } from "agency-lang/stdlib/object.js";
12
+ import { basename, dirname } from "agency-lang/stdlib/path.js";
15
13
  import { cliPolicyHandler, parsePolicyFile, setPolicy, ScopedRuleFields } from "agency-lang/stdlib/policy.js";
16
14
  import { exists } from "agency-lang/stdlib/shell.js";
17
15
  import { commandsDir, expandSlash } from "agency-lang/stdlib/skills.js";
@@ -19,10 +17,12 @@ import { highlight } from "agency-lang/stdlib/syntax.js";
19
17
  import { cwd, env, isTTY, readStdin, setTitle } from "agency-lang/stdlib/system.js";
20
18
  import { attachToReply, getCost, getModelCosts, image, systemMessage, Attachment } from "agency-lang/stdlib/thread.js";
21
19
  import { chooseOption, ChoiceItem } from "agency-lang/stdlib/ui.js";
20
+ import { clearMessages, pushMessage, repl, clearScreen, clearHistory } from "agency-lang/stdlib/ui/cli.js";
21
+ import { box, render } from "agency-lang/stdlib/ui/layout.js";
22
22
  import { figs, title } from "./images/images.js";
23
23
  import { detectAttachments, modalityFilter } from "./lib/attachments.js";
24
- import { POLICY_PATH, HISTORY_PATH, ALWAYS_FIELDS } from "./lib/config.js";
25
- import { minimalAutoApprovePolicy, recommendedAutoApprovePolicy } from "./lib/defaultPolicy.js";
24
+ import { POLICY_PATH, SESSION_POLICY_PATH, HISTORY_PATH, ALWAYS_FIELDS } from "./lib/config.js";
25
+ import { builtinPolicy, builtinPolicyNames, minimalAutoApprovePolicy, recommendedAutoApprovePolicy, BUILTIN_POLICIES } from "./lib/defaultPolicy.js";
26
26
  import { filterHostedModels, ModelFilters } from "./lib/modelFilters.js";
27
27
  import { parseModelFlag, knownProviders, Resolved } from "./lib/models.js";
28
28
  import { buildLayers, resolveAll, diffResolved, Ctx, SlotChange } from "./lib/resolution.js";
@@ -210,24 +210,17 @@ __registerTool(localModelsSupported);
210
210
  __registerTool(listModelNames);
211
211
  __registerTool(parseArgs);
212
212
  __registerTool(map);
213
- __registerTool(clearMessages);
214
- __registerTool(pushMessage);
215
- __registerTool(repl);
216
- __registerTool(clearScreen);
217
- __registerTool(clearHistory);
218
213
  __registerTool(today);
219
214
  __registerTool(generateImage);
220
215
  __registerTool(applyAgentCwd);
221
216
  __registerTool(setAgentCwd);
222
- __registerTool(keys);
223
- __registerTool(basename);
224
- __registerTool(dirname);
225
- __registerTool(box);
226
- __registerTool(render);
227
217
  __registerTool(listHostedModels);
228
218
  __registerTool(hostedModelInfo);
229
219
  __registerTool(setMemoryId);
230
220
  __registerTool(disableMemory);
221
+ __registerTool(keys);
222
+ __registerTool(basename);
223
+ __registerTool(dirname);
231
224
  __registerTool(cliPolicyHandler);
232
225
  __registerTool(parsePolicyFile);
233
226
  __registerTool(setPolicy);
@@ -249,15 +242,26 @@ __registerTool(systemMessage);
249
242
  __registerTool(Attachment);
250
243
  __registerTool(chooseOption);
251
244
  __registerTool(ChoiceItem);
245
+ __registerTool(clearMessages);
246
+ __registerTool(pushMessage);
247
+ __registerTool(repl);
248
+ __registerTool(clearScreen);
249
+ __registerTool(clearHistory);
250
+ __registerTool(box);
251
+ __registerTool(render);
252
252
  __registerTool(figs);
253
253
  __registerTool(title);
254
254
  __registerTool(detectAttachments);
255
255
  __registerTool(modalityFilter);
256
256
  __registerTool(POLICY_PATH);
257
+ __registerTool(SESSION_POLICY_PATH);
257
258
  __registerTool(HISTORY_PATH);
258
259
  __registerTool(ALWAYS_FIELDS);
260
+ __registerTool(builtinPolicy);
261
+ __registerTool(builtinPolicyNames);
259
262
  __registerTool(minimalAutoApprovePolicy);
260
263
  __registerTool(recommendedAutoApprovePolicy);
264
+ __registerTool(BUILTIN_POLICIES);
261
265
  __registerTool(filterHostedModels);
262
266
  __registerTool(ModelFilters);
263
267
  __registerTool(parseModelFlag);
@@ -537,6 +541,7 @@ async function __initializeGlobals(__ctx) {
537
541
  }), `1`));
538
542
  __ctx.globals.set("dist/lib/agents/agency-agent/agent.agency", "VERBOSE", false);
539
543
  __ctx.globals.set("dist/lib/agents/agency-agent/agent.agency", "_isInteractive", true);
544
+ __ctx.globals.set("dist/lib/agents/agency-agent/agent.agency", "_policyArg", ``);
540
545
  __ctx.globals.set("dist/lib/agents/agency-agent/agent.agency", "_context", ``);
541
546
  __ctx.globals.set("dist/lib/agents/agency-agent/agent.agency", "_session", {
542
547
  "pin": ``,
@@ -1854,7 +1859,7 @@ async function __renderLLMCallResponse_impl(data) {
1854
1859
  {
1855
1860
  condition: async () => __stack.args.data.toolCalls.length > 0,
1856
1861
  body: async (runner2) => {
1857
- await runner2.loop(0, __stack.args.data.toolCalls, async (toolCall, _, runner3) => {
1862
+ await runner2.loop(0, async () => __stack.args.data.toolCalls, async (toolCall, _, runner3) => {
1858
1863
  await runner3.step(0, async (runner4) => {
1859
1864
  __self.__retryable = false;
1860
1865
  await __callMethod(__stack.locals.response, "push", {
@@ -2269,7 +2274,7 @@ async function __mergedPalette_impl() {
2269
2274
  await runner.step(1, async (runner2) => {
2270
2275
  __stack.locals.out = {};
2271
2276
  });
2272
- await runner.loop(2, __readStatic(projectCommands, "projectCommands", "dist/lib/agents/agency-agent/agent.agency"), async (cmd, _, runner2) => {
2277
+ await runner.loop(2, async () => __readStatic(projectCommands, "projectCommands", "dist/lib/agents/agency-agent/agent.agency"), async (cmd, _, runner2) => {
2273
2278
  await runner2.step(0, async (runner3) => {
2274
2279
  __stack.locals.label = cmd.description;
2275
2280
  });
@@ -2298,7 +2303,7 @@ async function __mergedPalette_impl() {
2298
2303
  return;
2299
2304
  }
2300
2305
  });
2301
- await runner.loop(4, __stack.locals.builtins, async (key, _, runner2) => {
2306
+ await runner.loop(4, async () => __stack.locals.builtins, async (key, _, runner2) => {
2302
2307
  await runner2.step(0, async (runner3) => {
2303
2308
  __stack.locals.out[key] = __stack.locals.builtins[key];
2304
2309
  });
@@ -2435,7 +2440,7 @@ async function __switchModel_impl(prior, spec, ctx, before) {
2435
2440
  await runner.step(1, async (runner2) => {
2436
2441
  __stack.locals.nextSlots = {};
2437
2442
  });
2438
- await runner.loop(2, await __callMethod(Object, "keys", {
2443
+ await runner.loop(2, async () => await __callMethod(Object, "keys", {
2439
2444
  type: "positional",
2440
2445
  args: [__stack.args.prior.slots]
2441
2446
  }), async (key, _, runner2) => {
@@ -2922,7 +2927,7 @@ async function __modelChoiceItems_impl(filters) {
2922
2927
  await runner.step(1, async (runner2) => {
2923
2928
  __stack.locals.items = [];
2924
2929
  });
2925
- await runner.loop(2, await __call(filterHostedModels, {
2930
+ await runner.loop(2, async () => await __call(filterHostedModels, {
2926
2931
  type: "positional",
2927
2932
  args: [await __call(listHostedModels, {
2928
2933
  type: "positional",
@@ -3442,7 +3447,7 @@ async function ___runTurn_impl(msg) {
3442
3447
  await runner2.step(3, async (runner3) => {
3443
3448
  __stack.locals.totalTokens = 0;
3444
3449
  });
3445
- await runner2.loop(4, __stack.locals.byModel, async (m, _, runner3) => {
3450
+ await runner2.loop(4, async () => __stack.locals.byModel, async (m, _, runner3) => {
3446
3451
  await runner3.step(0, async (runner4) => {
3447
3452
  __stack.locals.totalCost = __stack.locals.totalCost + m.cost;
3448
3453
  });
@@ -3505,7 +3510,7 @@ async function ___runTurn_impl(msg) {
3505
3510
  return;
3506
3511
  }
3507
3512
  });
3508
- await runner3.loop(2, __stack.locals.byModel, async (m, _, runner4) => {
3513
+ await runner3.loop(2, async () => __stack.locals.byModel, async (m, _, runner4) => {
3509
3514
  await runner4.step(0, async (runner5) => {
3510
3515
  __self.__retryable = false;
3511
3516
  const __funcResult = await __call(pushMessage, {
@@ -3596,7 +3601,7 @@ async function ___runTurn_impl(msg) {
3596
3601
  return;
3597
3602
  }
3598
3603
  });
3599
- await runner3.loop(2, await __callMethod(Object, "keys", {
3604
+ await runner3.loop(2, async () => await __callMethod(Object, "keys", {
3600
3605
  type: "positional",
3601
3606
  args: [__stack.locals.current]
3602
3607
  }), async (slot, _, runner4) => {
@@ -3705,7 +3710,7 @@ async function ___runTurn_impl(msg) {
3705
3710
  await runner2.step(6, async (runner3) => {
3706
3711
  __globals().set("dist/lib/agents/agency-agent/agent.agency", "_session", __stack.locals.out.session);
3707
3712
  });
3708
- await runner2.loop(7, __stack.locals.out.changes, async (change, _, runner3) => {
3713
+ await runner2.loop(7, async () => __stack.locals.out.changes, async (change, _, runner3) => {
3709
3714
  await runner3.step(0, async (runner4) => {
3710
3715
  const __funcResult = await __call(reactToSlotChange, {
3711
3716
  type: "positional",
@@ -3730,7 +3735,7 @@ async function ___runTurn_impl(msg) {
3730
3735
  return;
3731
3736
  }
3732
3737
  });
3733
- await runner2.loop(9, await __callMethod(Object, "keys", {
3738
+ await runner2.loop(9, async () => await __callMethod(Object, "keys", {
3734
3739
  type: "positional",
3735
3740
  args: [__stack.locals.out.resolved]
3736
3741
  }), async (slot, _, runner3) => {
@@ -3837,7 +3842,7 @@ async function ___runTurn_impl(msg) {
3837
3842
  await runner2.step(3, async (runner3) => {
3838
3843
  __self.__retryable = false;
3839
3844
  });
3840
- await runner2.loop(4, __stack.locals.models, async (model, _, runner3) => {
3845
+ await runner2.loop(4, async () => __stack.locals.models, async (model, _, runner3) => {
3841
3846
  await runner3.step(0, async (runner4) => {
3842
3847
  __self.__retryable = false;
3843
3848
  const __funcResult = await __call(pushMessage, {
@@ -3905,7 +3910,7 @@ async function ___runTurn_impl(msg) {
3905
3910
  await runner2.step(2, async (runner3) => {
3906
3911
  __stack.locals.items = [];
3907
3912
  });
3908
- await runner2.loop(3, await __call(listModelNames, {
3913
+ await runner2.loop(3, async () => await __call(listModelNames, {
3909
3914
  type: "positional",
3910
3915
  args: []
3911
3916
  }), async (modelName, _, runner3) => {
@@ -3986,7 +3991,7 @@ async function ___runTurn_impl(msg) {
3986
3991
  return;
3987
3992
  }
3988
3993
  });
3989
- await runner2.loop(10, await __call(diffResolved, {
3994
+ await runner2.loop(10, async () => await __call(diffResolved, {
3990
3995
  type: "positional",
3991
3996
  args: [__stack.locals.before, await __call(getResolvedSlots, {
3992
3997
  type: "positional",
@@ -4662,7 +4667,7 @@ async function __mainAgent_impl(prompt) {
4662
4667
  }
4663
4668
  });
4664
4669
  });
4665
- await runner.thread(1, "create", { label: `main`, summarize: true, session: `main` }, async (runner2) => {
4670
+ await runner.thread(1, "create", async () => ({ label: `main`, summarize: true, session: `main` }), async (runner2) => {
4666
4671
  await runner2.step(0, async (runner3) => {
4667
4672
  __self.__retryable = false;
4668
4673
  const __funcResult = await __call(setMemoryId, {
@@ -4969,7 +4974,7 @@ async function __agentReplyVia_impl(target, userMsg) {
4969
4974
  return;
4970
4975
  }
4971
4976
  });
4972
- await runner.loop(13, __stack.locals.detected.skipped, async (skippedFile, _, runner2) => {
4977
+ await runner.loop(13, async () => __stack.locals.detected.skipped, async (skippedFile, _, runner2) => {
4973
4978
  await runner2.step(0, async (runner3) => {
4974
4979
  __self.__retryable = false;
4975
4980
  const __funcResult = await __call(pushMessage, {
@@ -5006,7 +5011,7 @@ async function __agentReplyVia_impl(target, userMsg) {
5006
5011
  }
5007
5012
  }
5008
5013
  ]);
5009
- await runner.loop(16, __stack.locals.detected.attached, async (item, _, runner2) => {
5014
+ await runner.loop(16, async () => __stack.locals.detected.attached, async (item, _, runner2) => {
5010
5015
  await runner2.step(0, async (runner3) => {
5011
5016
  __self.__retryable = false;
5012
5017
  const __funcResult = await __call(pushMessage, {
@@ -5889,6 +5894,181 @@ const printHeader = __AgencyFunction.create({
5889
5894
  safe: false,
5890
5895
  exported: false
5891
5896
  }, __toolRegistry);
5897
+ async function __printPolicyHelp_impl() {
5898
+ const __setupData = setupFunction();
5899
+ const __stack = __setupData.stack;
5900
+ const __step = __setupData.step;
5901
+ const __self = __setupData.self;
5902
+ const __ctx = getRuntimeContext().ctx;
5903
+ let __forked;
5904
+ let __functionCompleted = false;
5905
+ if (!__globals().isInitialized("dist/lib/agents/agency-agent/agent.agency")) {
5906
+ await __initializeGlobals(__ctx);
5907
+ }
5908
+ let __funcStartTime = performance.now();
5909
+ __self.__retryable = __self.__retryable ?? true;
5910
+ const runner = new Runner(__ctx, __stack, { state: __stack, moduleId: "dist/lib/agents/agency-agent/agent.agency", scopeName: "printPolicyHelp", threads: __setupData.threads });
5911
+ let __resultCheckpointId = -1;
5912
+ if (__ctx._pendingArgOverrides) {
5913
+ const __overrides = __ctx._pendingArgOverrides;
5914
+ __ctx._pendingArgOverrides = void 0;
5915
+ }
5916
+ try {
5917
+ await agencyStore.run({
5918
+ ...getRuntimeContext(),
5919
+ ctx: __ctx,
5920
+ stack: __setupData.stateStack,
5921
+ threads: __setupData.threads
5922
+ }, async () => {
5923
+ await runner.hook(0, async () => {
5924
+ await callHook({
5925
+ name: "onFunctionStart",
5926
+ data: {
5927
+ functionName: "printPolicyHelp",
5928
+ args: {},
5929
+ moduleId: "dist/lib/agents/agency-agent/agent.agency"
5930
+ }
5931
+ });
5932
+ });
5933
+ await runner.step(1, async (runner2) => {
5934
+ const __funcResult = await __call(print, {
5935
+ type: "positional",
5936
+ args: [await __callMethod(color, "bold", {
5937
+ type: "positional",
5938
+ args: [`Usage: agency agent --policy <name | path>`]
5939
+ })]
5940
+ });
5941
+ if (hasInterrupts(__funcResult)) {
5942
+ await getRuntimeContext().ctx.pendingPromises.awaitAll();
5943
+ runner2.halt(__funcResult);
5944
+ return;
5945
+ }
5946
+ });
5947
+ await runner.step(2, async (runner2) => {
5948
+ const __funcResult = await __call(print, {
5949
+ type: "positional",
5950
+ args: [`Select the approval policy for this run: a built-in name below, or a path to a policy JSON file.`]
5951
+ });
5952
+ if (hasInterrupts(__funcResult)) {
5953
+ await getRuntimeContext().ctx.pendingPromises.awaitAll();
5954
+ runner2.halt(__funcResult);
5955
+ return;
5956
+ }
5957
+ });
5958
+ await runner.step(3, async (runner2) => {
5959
+ const __funcResult = await __call(print, {
5960
+ type: "positional",
5961
+ args: [``]
5962
+ });
5963
+ if (hasInterrupts(__funcResult)) {
5964
+ await getRuntimeContext().ctx.pendingPromises.awaitAll();
5965
+ runner2.halt(__funcResult);
5966
+ return;
5967
+ }
5968
+ });
5969
+ await runner.step(4, async (runner2) => {
5970
+ const __funcResult = await __call(print, {
5971
+ type: "positional",
5972
+ args: [await __callMethod(color, "bold", {
5973
+ type: "positional",
5974
+ args: [`Built-in policies:`]
5975
+ })]
5976
+ });
5977
+ if (hasInterrupts(__funcResult)) {
5978
+ await getRuntimeContext().ctx.pendingPromises.awaitAll();
5979
+ runner2.halt(__funcResult);
5980
+ return;
5981
+ }
5982
+ });
5983
+ await runner.loop(5, async () => __readStatic(BUILTIN_POLICIES, "BUILTIN_POLICIES", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/defaultPolicy.agency"), async (p, _, runner2) => {
5984
+ await runner2.step(0, async (runner3) => {
5985
+ const __funcResult = await __call(print, {
5986
+ type: "positional",
5987
+ args: [` ${await __callMethod(color, "cyan", {
5988
+ type: "positional",
5989
+ args: [p.name]
5990
+ })}`]
5991
+ });
5992
+ if (hasInterrupts(__funcResult)) {
5993
+ await getRuntimeContext().ctx.pendingPromises.awaitAll();
5994
+ runner3.halt(__funcResult);
5995
+ return;
5996
+ }
5997
+ });
5998
+ await runner2.step(1, async (runner3) => {
5999
+ const __funcResult = await __call(print, {
6000
+ type: "positional",
6001
+ args: [` ${p.description}`]
6002
+ });
6003
+ if (hasInterrupts(__funcResult)) {
6004
+ await getRuntimeContext().ctx.pendingPromises.awaitAll();
6005
+ runner3.halt(__funcResult);
6006
+ return;
6007
+ }
6008
+ });
6009
+ });
6010
+ });
6011
+ if (runner.halted) {
6012
+ if (isFailure(runner.haltResult)) {
6013
+ runner.haltResult.retryable = runner.haltResult.retryable && __self.__retryable;
6014
+ }
6015
+ return runner.haltResult;
6016
+ }
6017
+ } catch (__error) {
6018
+ if (__error instanceof RestoreSignal) {
6019
+ throw __error;
6020
+ }
6021
+ if (__error instanceof AgencyAbort) {
6022
+ throw __error;
6023
+ }
6024
+ {
6025
+ const __errMsg = __error instanceof Error ? __error.message : String(__error);
6026
+ const __errStack = __error instanceof Error && __error.stack ? __error.stack : "";
6027
+ const __log = __createLogger(__ctx.logLevel);
6028
+ __log.error("Function printPolicyHelp threw an exception (converted to Failure): " + __errMsg);
6029
+ if (__errStack) __log.error(__errStack);
6030
+ __ctx.statelogClient?.error?.({
6031
+ errorType: "runtimeError",
6032
+ message: __errMsg,
6033
+ functionName: "printPolicyHelp",
6034
+ retryable: __self.__retryable
6035
+ });
6036
+ }
6037
+ return failure(
6038
+ __error instanceof Error ? __error.message : String(__error),
6039
+ {
6040
+ checkpoint: getRuntimeContext().ctx.getResultCheckpoint(),
6041
+ retryable: __self.__retryable,
6042
+ functionName: "printPolicyHelp",
6043
+ args: __stack.args
6044
+ }
6045
+ );
6046
+ } finally {
6047
+ __stateStack()?.pop();
6048
+ if (__functionCompleted) {
6049
+ await callHook({
6050
+ name: "onFunctionEnd",
6051
+ data: {
6052
+ functionName: "printPolicyHelp",
6053
+ timeTaken: performance.now() - __funcStartTime
6054
+ }
6055
+ });
6056
+ }
6057
+ }
6058
+ }
6059
+ const printPolicyHelp = __AgencyFunction.create({
6060
+ name: "printPolicyHelp",
6061
+ module: "dist/lib/agents/agency-agent/agent.agency",
6062
+ fn: __printPolicyHelp_impl,
6063
+ params: [],
6064
+ toolDefinition: {
6065
+ name: "printPolicyHelp",
6066
+ description: "No description provided.",
6067
+ schema: z.object({})
6068
+ },
6069
+ safe: false,
6070
+ exported: false
6071
+ }, __toolRegistry);
5892
6072
  async function __givePolicyChoice_impl() {
5893
6073
  const __setupData = setupFunction();
5894
6074
  const __stack = __setupData.stack;
@@ -6136,138 +6316,249 @@ Current working directory: ${await __call(cwd, {
6136
6316
  })}${__stack.locals.projectContext}`);
6137
6317
  });
6138
6318
  await runner.step(5, async (runner2) => {
6139
- __self.__retryable = false;
6140
- __stack.locals.policy = await __call(parsePolicyFile, {
6141
- type: "positional",
6142
- args: [__readStatic(POLICY_PATH, "POLICY_PATH", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency")]
6143
- });
6144
- if (hasInterrupts(__stack.locals.policy)) {
6145
- await getRuntimeContext().ctx.pendingPromises.awaitAll();
6146
- runner2.halt(__stack.locals.policy);
6147
- return;
6148
- }
6319
+ __stack.locals.policyFile = __readStatic(POLICY_PATH, "POLICY_PATH", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency");
6149
6320
  });
6150
- await runner.ifElse(6, [
6321
+ await runner.step(6, async (runner2) => {
6322
+ __stack.locals.sessionPolicy = null;
6323
+ });
6324
+ await runner.ifElse(7, [
6151
6325
  {
6152
- condition: async () => await isFailure(__stack.locals.policy),
6326
+ condition: async () => !__eq(__globals().get("dist/lib/agents/agency-agent/agent.agency", "_policyArg"), ``),
6153
6327
  body: async (runner2) => {
6154
6328
  await runner2.step(0, async (runner3) => {
6155
- __stack.locals.f = __stack.locals.policy.error;
6156
6329
  });
6157
- await runner2.ifElse(1, [
6330
+ await runner2.step(1, async (runner3) => {
6331
+ __self.__retryable = false;
6332
+ __stack.locals.builtin = await __call(builtinPolicy, {
6333
+ type: "positional",
6334
+ args: [__globals().get("dist/lib/agents/agency-agent/agent.agency", "_policyArg"), await __call(cwd, {
6335
+ type: "positional",
6336
+ args: []
6337
+ })]
6338
+ });
6339
+ if (hasInterrupts(__stack.locals.builtin)) {
6340
+ await getRuntimeContext().ctx.pendingPromises.awaitAll();
6341
+ runner3.halt(__stack.locals.builtin);
6342
+ return;
6343
+ }
6344
+ });
6345
+ await runner2.ifElse(2, [
6158
6346
  {
6159
- condition: async () => __eq(__stack.locals.f.status, `doesnt-exist`),
6347
+ condition: async () => !__eq(__stack.locals.builtin, null),
6160
6348
  body: async (runner3) => {
6161
- await runner3.ifElse(0, [
6162
- {
6163
- condition: async () => __stack.args.interactive,
6164
- body: async (runner4) => {
6165
- await runner4.step(0, async (runner5) => {
6166
- const __funcResult = await __call(print, {
6167
- type: "positional",
6168
- args: [await __callMethod(color, "yellow", {
6169
- type: "positional",
6170
- args: [`No existing policy found at ${__readStatic(POLICY_PATH, "POLICY_PATH", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency")}.`]
6171
- })]
6172
- });
6173
- if (hasInterrupts(__funcResult)) {
6174
- await getRuntimeContext().ctx.pendingPromises.awaitAll();
6175
- runner5.halt(__funcResult);
6176
- return;
6177
- }
6178
- });
6179
- await runner4.step(1, async (runner5) => {
6180
- __self.__retryable = false;
6181
- const __funcResult = await __call(setPolicy, {
6182
- type: "positional",
6183
- args: [__readStatic(POLICY_PATH, "POLICY_PATH", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency"), await __call(givePolicyChoice, {
6184
- type: "positional",
6185
- args: []
6186
- })]
6187
- });
6188
- if (hasInterrupts(__funcResult)) {
6189
- await getRuntimeContext().ctx.pendingPromises.awaitAll();
6190
- runner5.halt(__funcResult);
6191
- return;
6192
- }
6193
- });
6194
- }
6195
- }
6196
- ], async (runner4) => {
6197
- await runner4.step(2, async (runner5) => {
6198
- __self.__retryable = false;
6199
- const __funcResult = await __call(setPolicy, {
6200
- type: "positional",
6201
- args: [__readStatic(POLICY_PATH, "POLICY_PATH", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency"), __readStatic(recommendedAutoApprovePolicy, "recommendedAutoApprovePolicy", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/defaultPolicy.agency")]
6202
- });
6203
- if (hasInterrupts(__funcResult)) {
6204
- await getRuntimeContext().ctx.pendingPromises.awaitAll();
6205
- runner5.halt(__funcResult);
6206
- return;
6207
- }
6208
- });
6349
+ await runner3.step(0, async (runner4) => {
6209
6350
  });
6210
6351
  await runner3.step(1, async (runner4) => {
6211
- __self.__retryable = false;
6352
+ __stack.locals.policyFile = __readStatic(SESSION_POLICY_PATH, "SESSION_POLICY_PATH", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency");
6353
+ });
6354
+ await runner3.step(2, async (runner4) => {
6355
+ __stack.locals.sessionPolicy = __stack.locals.builtin;
6212
6356
  });
6213
6357
  }
6214
6358
  }
6215
6359
  ], async (runner3) => {
6216
- await runner3.step(2, async (runner4) => {
6217
- const __funcResult = await __call(print, {
6360
+ await runner3.step(3, async (runner4) => {
6361
+ });
6362
+ await runner3.step(4, async (runner4) => {
6363
+ __self.__retryable = false;
6364
+ __stack.locals.loaded = await __call(parsePolicyFile, {
6218
6365
  type: "positional",
6219
- args: [await __callMethod(color, "red", {
6220
- type: "positional",
6221
- args: [`Failed to load policy: ${await __callMethod(JSON, "stringify", {
6222
- type: "positional",
6223
- args: [__stack.locals.f.error]
6224
- })}`]
6225
- })]
6366
+ args: [__globals().get("dist/lib/agents/agency-agent/agent.agency", "_policyArg")]
6226
6367
  });
6227
- if (hasInterrupts(__funcResult)) {
6368
+ if (hasInterrupts(__stack.locals.loaded)) {
6228
6369
  await getRuntimeContext().ctx.pendingPromises.awaitAll();
6229
- runner4.halt(__funcResult);
6370
+ runner4.halt(__stack.locals.loaded);
6230
6371
  return;
6231
6372
  }
6232
6373
  });
6233
- await runner3.step(3, async (runner4) => {
6234
- await __callMethod(process, "exit", {
6235
- type: "positional",
6236
- args: [1]
6237
- });
6374
+ await runner3.ifElse(5, [
6375
+ {
6376
+ condition: async () => await isFailure(__stack.locals.loaded),
6377
+ body: async (runner4) => {
6378
+ await runner4.step(0, async (runner5) => {
6379
+ __stack.locals.f = __stack.locals.loaded.error;
6380
+ });
6381
+ await runner4.step(1, async (runner5) => {
6382
+ __self.__retryable = false;
6383
+ const __funcResult = await __call(print, {
6384
+ type: "positional",
6385
+ args: [await __callMethod(color, "red", {
6386
+ type: "positional",
6387
+ args: [`--policy '${__globals().get("dist/lib/agents/agency-agent/agent.agency", "_policyArg")}' is neither a built-in policy (${await __callMethod(await await __call(builtinPolicyNames, {
6388
+ type: "positional",
6389
+ args: []
6390
+ }), "join", {
6391
+ type: "positional",
6392
+ args: [`, `]
6393
+ })}) nor a readable policy file (${__stack.locals.f.status}).`]
6394
+ })]
6395
+ });
6396
+ if (hasInterrupts(__funcResult)) {
6397
+ await getRuntimeContext().ctx.pendingPromises.awaitAll();
6398
+ runner5.halt(__funcResult);
6399
+ return;
6400
+ }
6401
+ });
6402
+ await runner4.step(2, async (runner5) => {
6403
+ await __callMethod(process, "exit", {
6404
+ type: "positional",
6405
+ args: [1]
6406
+ });
6407
+ });
6408
+ }
6409
+ }
6410
+ ]);
6411
+ await runner3.step(6, async (runner4) => {
6412
+ __self.__retryable = false;
6413
+ });
6414
+ await runner3.step(7, async (runner4) => {
6415
+ __stack.locals.policyFile = __globals().get("dist/lib/agents/agency-agent/agent.agency", "_policyArg");
6238
6416
  });
6239
6417
  });
6240
- await runner2.step(2, async (runner3) => {
6418
+ await runner2.step(3, async (runner3) => {
6241
6419
  __self.__retryable = false;
6242
6420
  });
6243
6421
  }
6244
6422
  }
6245
6423
  ], async (runner2) => {
6246
- await runner2.step(3, async (runner3) => {
6424
+ await runner2.step(4, async (runner3) => {
6247
6425
  __self.__retryable = false;
6248
- const __funcResult = await __call(setPolicy, {
6426
+ __stack.locals.policy = await __call(parsePolicyFile, {
6249
6427
  type: "positional",
6250
- args: [__readStatic(POLICY_PATH, "POLICY_PATH", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency"), __stack.locals.policy.value]
6428
+ args: [__readStatic(POLICY_PATH, "POLICY_PATH", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency")]
6251
6429
  });
6252
- if (hasInterrupts(__funcResult)) {
6430
+ if (hasInterrupts(__stack.locals.policy)) {
6253
6431
  await getRuntimeContext().ctx.pendingPromises.awaitAll();
6254
- runner3.halt(__funcResult);
6432
+ runner3.halt(__stack.locals.policy);
6255
6433
  return;
6256
6434
  }
6257
6435
  });
6436
+ await runner2.ifElse(5, [
6437
+ {
6438
+ condition: async () => await isFailure(__stack.locals.policy),
6439
+ body: async (runner3) => {
6440
+ await runner3.step(0, async (runner4) => {
6441
+ __stack.locals.f = __stack.locals.policy.error;
6442
+ });
6443
+ await runner3.ifElse(1, [
6444
+ {
6445
+ condition: async () => __eq(__stack.locals.f.status, `doesnt-exist`),
6446
+ body: async (runner4) => {
6447
+ await runner4.ifElse(0, [
6448
+ {
6449
+ condition: async () => __stack.args.interactive,
6450
+ body: async (runner5) => {
6451
+ await runner5.step(0, async (runner6) => {
6452
+ const __funcResult = await __call(print, {
6453
+ type: "positional",
6454
+ args: [await __callMethod(color, "yellow", {
6455
+ type: "positional",
6456
+ args: [`No existing policy found at ${__readStatic(POLICY_PATH, "POLICY_PATH", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency")}.`]
6457
+ })]
6458
+ });
6459
+ if (hasInterrupts(__funcResult)) {
6460
+ await getRuntimeContext().ctx.pendingPromises.awaitAll();
6461
+ runner6.halt(__funcResult);
6462
+ return;
6463
+ }
6464
+ });
6465
+ await runner5.step(1, async (runner6) => {
6466
+ __self.__retryable = false;
6467
+ const __funcResult = await __call(setPolicy, {
6468
+ type: "positional",
6469
+ args: [__readStatic(POLICY_PATH, "POLICY_PATH", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency"), await __call(givePolicyChoice, {
6470
+ type: "positional",
6471
+ args: []
6472
+ })]
6473
+ });
6474
+ if (hasInterrupts(__funcResult)) {
6475
+ await getRuntimeContext().ctx.pendingPromises.awaitAll();
6476
+ runner6.halt(__funcResult);
6477
+ return;
6478
+ }
6479
+ });
6480
+ }
6481
+ }
6482
+ ], async (runner5) => {
6483
+ await runner5.step(2, async (runner6) => {
6484
+ __self.__retryable = false;
6485
+ const __funcResult = await __call(setPolicy, {
6486
+ type: "positional",
6487
+ args: [__readStatic(POLICY_PATH, "POLICY_PATH", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency"), __readStatic(recommendedAutoApprovePolicy, "recommendedAutoApprovePolicy", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/defaultPolicy.agency")]
6488
+ });
6489
+ if (hasInterrupts(__funcResult)) {
6490
+ await getRuntimeContext().ctx.pendingPromises.awaitAll();
6491
+ runner6.halt(__funcResult);
6492
+ return;
6493
+ }
6494
+ });
6495
+ });
6496
+ await runner4.step(1, async (runner5) => {
6497
+ __self.__retryable = false;
6498
+ });
6499
+ }
6500
+ }
6501
+ ], async (runner4) => {
6502
+ await runner4.step(2, async (runner5) => {
6503
+ const __funcResult = await __call(print, {
6504
+ type: "positional",
6505
+ args: [await __callMethod(color, "red", {
6506
+ type: "positional",
6507
+ args: [`Failed to load policy: ${await __callMethod(JSON, "stringify", {
6508
+ type: "positional",
6509
+ args: [__stack.locals.f.error]
6510
+ })}`]
6511
+ })]
6512
+ });
6513
+ if (hasInterrupts(__funcResult)) {
6514
+ await getRuntimeContext().ctx.pendingPromises.awaitAll();
6515
+ runner5.halt(__funcResult);
6516
+ return;
6517
+ }
6518
+ });
6519
+ await runner4.step(3, async (runner5) => {
6520
+ await __callMethod(process, "exit", {
6521
+ type: "positional",
6522
+ args: [1]
6523
+ });
6524
+ });
6525
+ });
6526
+ await runner3.step(2, async (runner4) => {
6527
+ __self.__retryable = false;
6528
+ });
6529
+ }
6530
+ }
6531
+ ], async (runner3) => {
6532
+ await runner3.step(3, async (runner4) => {
6533
+ __self.__retryable = false;
6534
+ const __funcResult = await __call(setPolicy, {
6535
+ type: "positional",
6536
+ args: [__readStatic(POLICY_PATH, "POLICY_PATH", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency"), __stack.locals.policy.value]
6537
+ });
6538
+ if (hasInterrupts(__funcResult)) {
6539
+ await getRuntimeContext().ctx.pendingPromises.awaitAll();
6540
+ runner4.halt(__funcResult);
6541
+ return;
6542
+ }
6543
+ });
6544
+ });
6545
+ await runner2.step(6, async (runner3) => {
6546
+ __self.__retryable = false;
6547
+ });
6258
6548
  });
6259
- await runner.step(7, async (runner2) => {
6549
+ await runner.step(8, async (runner2) => {
6260
6550
  __self.__retryable = false;
6261
6551
  });
6262
- await runner.step(8, async (runner2) => {
6552
+ await runner.step(9, async (runner2) => {
6263
6553
  __self.__retryable = false;
6264
6554
  __functionCompleted = true;
6265
6555
  runner2.halt(await __call(cliPolicyHandler, {
6266
6556
  type: "named",
6267
6557
  positionalArgs: [],
6268
6558
  namedArgs: {
6269
- file: __readStatic(POLICY_PATH, "POLICY_PATH", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency"),
6270
- fields: __readStatic(ALWAYS_FIELDS, "ALWAYS_FIELDS", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency")
6559
+ file: __stack.locals.policyFile,
6560
+ fields: __readStatic(ALWAYS_FIELDS, "ALWAYS_FIELDS", "/Users/adityabhargava/agency-lang/packages/agency-lang/dist/lib/agents/agency-agent/lib/config.agency"),
6561
+ policy: __stack.locals.sessionPolicy
6271
6562
  }
6272
6563
  }));
6273
6564
  return;
@@ -7057,6 +7348,11 @@ graph.node("main", async (__state) => {
7057
7348
  "type": `string`,
7058
7349
  "description": `Route the starting prompt to a named subagent: code, research, oracle, explorer, review (default: coordinator)`
7059
7350
  },
7351
+ "policy": {
7352
+ "type": `string`,
7353
+ "optional": true,
7354
+ "description": `Approval policy for this run: a built-in name (minimal, recommended, with-writes, with-bash) or a path to a policy JSON file. with-writes/with-bash auto-approve writes (and, for with-bash, shell) scoped to the current directory and its children. Overrides the saved policy without persisting it. Pass --policy with no value to list the built-in policies.`
7355
+ },
7060
7356
  "local": {
7061
7357
  "type": `string`,
7062
7358
  "optional": true,
@@ -7101,16 +7397,46 @@ graph.node("main", async (__state) => {
7101
7397
  ]);
7102
7398
  await runner.step(5, async (runner2) => {
7103
7399
  });
7104
- await runner.step(6, async (runner2) => {
7400
+ await runner.ifElse(6, [
7401
+ {
7402
+ condition: async () => __eq(__stack.locals.args.flags.policy, ``),
7403
+ body: async (runner2) => {
7404
+ await runner2.step(0, async (runner3) => {
7405
+ const __funcResult = await __call(printPolicyHelp, {
7406
+ type: "positional",
7407
+ args: []
7408
+ });
7409
+ if (hasInterrupts(__funcResult)) {
7410
+ await getRuntimeContext().ctx.pendingPromises.awaitAll();
7411
+ runner3.halt({
7412
+ ...__state,
7413
+ data: __funcResult
7414
+ });
7415
+ return;
7416
+ }
7417
+ });
7418
+ await runner2.step(1, async (runner3) => {
7419
+ await __callMethod(process, "exit", {
7420
+ type: "positional",
7421
+ args: [0]
7422
+ });
7423
+ });
7424
+ }
7425
+ }
7426
+ ]);
7427
+ await runner.step(7, async (runner2) => {
7428
+ __globals().set("dist/lib/agents/agency-agent/agent.agency", "_policyArg", __stack.locals.args.flags.policy ?? ``);
7429
+ });
7430
+ await runner.step(8, async (runner2) => {
7105
7431
  __stack.locals.localVal = __stack.locals.args.flags[`local`] ?? __stack.locals.args.flags[`local-model`];
7106
7432
  });
7107
- await runner.step(7, async (runner2) => {
7433
+ await runner.step(9, async (runner2) => {
7108
7434
  __stack.locals.modelArg = __stack.locals.args.flags.model ?? ``;
7109
7435
  });
7110
- await runner.step(8, async (runner2) => {
7436
+ await runner.step(10, async (runner2) => {
7111
7437
  __stack.locals.hasModelFlags = !__eq(__stack.locals.modelArg, ``) || !__eq(__stack.locals.args.flags.fastmodel ?? ``, ``) || !__eq(__stack.locals.args.flags.slowmodel ?? ``, ``);
7112
7438
  });
7113
- await runner.ifElse(9, [
7439
+ await runner.ifElse(11, [
7114
7440
  {
7115
7441
  condition: async () => !__eq(__stack.locals.localVal, null) && __stack.locals.hasModelFlags,
7116
7442
  body: async (runner2) => {
@@ -7140,7 +7466,7 @@ graph.node("main", async (__state) => {
7140
7466
  }
7141
7467
  }
7142
7468
  ]);
7143
- await runner.ifElse(10, [
7469
+ await runner.ifElse(12, [
7144
7470
  {
7145
7471
  condition: async () => __eq(__stack.locals.localVal, ``),
7146
7472
  body: async (runner2) => {
@@ -7233,7 +7559,7 @@ graph.node("main", async (__state) => {
7233
7559
  await runner2.step(5, async (runner3) => {
7234
7560
  __stack.locals.items = [];
7235
7561
  });
7236
- await runner2.loop(6, await __call(listModelNames, {
7562
+ await runner2.loop(6, async () => await __call(listModelNames, {
7237
7563
  type: "positional",
7238
7564
  args: []
7239
7565
  }), async (modelName, _, runner3) => {
@@ -7505,25 +7831,25 @@ graph.node("main", async (__state) => {
7505
7831
  }
7506
7832
  });
7507
7833
  });
7508
- await runner.step(11, async (runner2) => {
7834
+ await runner.step(13, async (runner2) => {
7509
7835
  __self.__retryable = false;
7510
7836
  });
7511
- await runner.step(12, async (runner2) => {
7837
+ await runner.step(14, async (runner2) => {
7512
7838
  __stack.locals.positionalQuery = await __callMethod(__stack.locals.args.positionals, "join", {
7513
7839
  type: "positional",
7514
7840
  args: [` `]
7515
7841
  });
7516
7842
  });
7517
- await runner.step(13, async (runner2) => {
7843
+ await runner.step(15, async (runner2) => {
7518
7844
  __stack.locals.hasQuery = !__eq(__stack.locals.positionalQuery, ``);
7519
7845
  });
7520
- await runner.step(14, async (runner2) => {
7846
+ await runner.step(16, async (runner2) => {
7521
7847
  __stack.locals.startAgent = __stack.locals.args.flags.agent ?? ``;
7522
7848
  });
7523
- await runner.step(15, async (runner2) => {
7849
+ await runner.step(17, async (runner2) => {
7524
7850
  __stack.locals.wantInteractive = __stack.locals.args.flags.interactive;
7525
7851
  });
7526
- await runner.ifElse(16, [
7852
+ await runner.ifElse(18, [
7527
7853
  {
7528
7854
  condition: async () => !__eq(__stack.locals.startAgent, ``) && !await __callMethod(__readStatic(START_AGENTS, "START_AGENTS", "dist/lib/agents/agency-agent/agent.agency"), "includes", {
7529
7855
  type: "positional",
@@ -7559,9 +7885,9 @@ graph.node("main", async (__state) => {
7559
7885
  }
7560
7886
  }
7561
7887
  ]);
7562
- await runner.step(17, async (runner2) => {
7888
+ await runner.step(19, async (runner2) => {
7563
7889
  });
7564
- await runner.ifElse(18, [
7890
+ await runner.ifElse(20, [
7565
7891
  {
7566
7892
  condition: async () => __stack.locals.wantInteractive && __stack.locals.hasQuery && await __call(isTTY, {
7567
7893
  type: "positional",
@@ -7649,13 +7975,13 @@ graph.node("main", async (__state) => {
7649
7975
  }
7650
7976
  }
7651
7977
  ]);
7652
- await runner.step(19, async (runner2) => {
7978
+ await runner.step(21, async (runner2) => {
7653
7979
  __self.__retryable = false;
7654
7980
  });
7655
- await runner.step(20, async (runner2) => {
7981
+ await runner.step(22, async (runner2) => {
7656
7982
  __stack.locals.forceOneShot = __stack.locals.args.flags.print || __stack.locals.hasQuery;
7657
7983
  });
7658
- await runner.ifElse(21, [
7984
+ await runner.ifElse(23, [
7659
7985
  {
7660
7986
  condition: async () => __stack.locals.forceOneShot || !await __call(isTTY, {
7661
7987
  type: "positional",
@@ -7728,9 +8054,9 @@ graph.node("main", async (__state) => {
7728
8054
  }
7729
8055
  }
7730
8056
  ]);
7731
- await runner.step(22, async (runner2) => {
8057
+ await runner.step(24, async (runner2) => {
7732
8058
  });
7733
- await runner.step(23, async (runner2) => {
8059
+ await runner.step(25, async (runner2) => {
7734
8060
  __self.__retryable = false;
7735
8061
  const __funcResult = await __call(setTitle, {
7736
8062
  type: "positional",
@@ -7745,7 +8071,7 @@ graph.node("main", async (__state) => {
7745
8071
  return;
7746
8072
  }
7747
8073
  });
7748
- await runner.step(24, async (runner2) => {
8074
+ await runner.step(26, async (runner2) => {
7749
8075
  __self.__retryable = false;
7750
8076
  const __funcResult = await __call(clearScreen, {
7751
8077
  type: "positional",
@@ -7760,7 +8086,7 @@ graph.node("main", async (__state) => {
7760
8086
  return;
7761
8087
  }
7762
8088
  });
7763
- await runner.step(25, async (runner2) => {
8089
+ await runner.step(27, async (runner2) => {
7764
8090
  const __funcResult = await __call(printHeader, {
7765
8091
  type: "positional",
7766
8092
  args: []
@@ -7774,7 +8100,7 @@ graph.node("main", async (__state) => {
7774
8100
  return;
7775
8101
  }
7776
8102
  });
7777
- await runner.step(26, async (runner2) => {
8103
+ await runner.step(28, async (runner2) => {
7778
8104
  __stack.locals.handler = await __call(setupSession, {
7779
8105
  type: "positional",
7780
8106
  args: [true]
@@ -7788,7 +8114,7 @@ graph.node("main", async (__state) => {
7788
8114
  return;
7789
8115
  }
7790
8116
  });
7791
- await runner.step(27, async (runner2) => {
8117
+ await runner.step(29, async (runner2) => {
7792
8118
  const __funcResult = await __call(startInteractive, {
7793
8119
  type: "positional",
7794
8120
  args: [__stack.locals.handler, ``, ``]
@@ -7804,7 +8130,7 @@ graph.node("main", async (__state) => {
7804
8130
  });
7805
8131
  });
7806
8132
  if (runner.halted) return runner.haltResult;
7807
- await runner.hook(28, async () => {
8133
+ await runner.hook(30, async () => {
7808
8134
  await callHook({
7809
8135
  name: "onNodeEnd",
7810
8136
  data: {
@@ -7870,7 +8196,7 @@ Agent crashed: ${__error.message}`);
7870
8196
  }
7871
8197
  }
7872
8198
  var stdin_default = graph;
7873
- const __sourceMap = { "dist/lib/agents/agency-agent/agent.agency:__cb_top_0": { "1": { "line": 138, "col": 2 }, "1.0": { "line": 139, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:__cb_top_1": { "1": { "line": 144, "col": 2 }, "1.0.0": { "line": 145, "col": 4 }, "1.0.1": { "line": 146, "col": 6 }, "1.0.2": { "line": 147, "col": 11 }, "1.0.3": { "line": 148, "col": 6 }, "1.0.4": { "line": 150, "col": 6 }, "1.0": { "line": 145, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:__cb_top_2": { "1": { "line": 156, "col": 2 }, "1.0": { "line": 157, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:__cb_top_3": { "1": { "line": 162, "col": 2 }, "1.0": { "line": 163, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:__cb_top_4": { "1": { "line": 203, "col": 2 }, "1.0": { "line": 204, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:_showTraces": { "1": { "line": 134, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:retryReasonLabel": { "1": { "line": 174, "col": 2 }, "2": { "line": 177, "col": 2 }, "3": { "line": 180, "col": 2 }, "4": { "line": 183, "col": 2 }, "5": { "line": 186, "col": 2 }, "6": { "line": 189, "col": 2 }, "7": { "line": 192, "col": 2 }, "1.0": { "line": 175, "col": 4 }, "2.0": { "line": 178, "col": 4 }, "3.0": { "line": 181, "col": 4 }, "4.0": { "line": 184, "col": 4 }, "5.0": { "line": 187, "col": 4 }, "6.0": { "line": 190, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:formatTurnFailure": { "1": { "line": 219, "col": 2 }, "2": { "line": 222, "col": 2 }, "3": { "line": 225, "col": 2 }, "4": { "line": 228, "col": 2 }, "1.0": { "line": 220, "col": 4 }, "2.0": { "line": 223, "col": 4 }, "3.0": { "line": 226, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:renderLLMCallResponse": { "1": { "line": 245, "col": 2 }, "2": { "line": 246, "col": 2 }, "3": { "line": 249, "col": 2 }, "5": { "line": 254, "col": 2 }, "2.0": { "line": 247, "col": 4 }, "3.0.0": { "line": 251, "col": 6 }, "3.0": { "line": 250, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:loadAgentsMd": { "1": { "line": 265, "col": 2 }, "2": { "line": 268, "col": 2 }, "3": { "line": 269, "col": 2 }, "4": { "line": 272, "col": 2 }, "1.0": { "line": 266, "col": 4 }, "2.0": { "line": 268, "col": 2 }, "3.0": { "line": 270, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:builtinPalette": { "1": { "line": 286, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:mergedPalette": { "1": { "line": 303, "col": 2 }, "2": { "line": 304, "col": 2 }, "3": { "line": 311, "col": 2 }, "4": { "line": 312, "col": 2 }, "5": { "line": 315, "col": 2 }, "2.0": { "line": 305, "col": 4 }, "2.1.0": { "line": 307, "col": 6 }, "2.1": { "line": 306, "col": 4 }, "2.2": { "line": 309, "col": 4 }, "4.0": { "line": 313, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:switchModel": { "1": { "line": 342, "col": 2 }, "2": { "line": 343, "col": 2 }, "3": { "line": 346, "col": 2 }, "4": { "line": 350, "col": 2 }, "5": { "line": 351, "col": 2 }, "7": { "line": 361, "col": 2 }, "9": { "line": 369, "col": 2 }, "10": { "line": 370, "col": 2 }, "11": { "line": 371, "col": 2 }, "12": { "line": 380, "col": 2 }, "13": { "line": 381, "col": 2 }, "15": { "line": 389, "col": 2 }, "16": { "line": 390, "col": 2 }, "17": { "line": 391, "col": 2 }, "2.0": { "line": 344, "col": 4 }, "5.0": { "line": 352, "col": 4 }, "5.1": { "line": 355, "col": 4 }, "7.0": { "line": 362, "col": 4 }, "7.1": { "line": 364, "col": 4 }, "13.0": { "line": 382, "col": 4 }, "13.1": { "line": 383, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:reactToSlotChange": { "1": { "line": 403, "col": 2 }, "3": { "line": 414, "col": 2 }, "1.0": { "line": 404, "col": 4 }, "1.1": { "line": 411, "col": 4 }, "1.3": { "line": 412, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:modelChoiceItems": { "1": { "line": 420, "col": 2 }, "2": { "line": 421, "col": 2 }, "4": { "line": 428, "col": 2 }, "2.0": { "line": 422, "col": 4 }, "2.1": { "line": 423, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:parseModelsFilters": { "1": { "line": 435, "col": 2 }, "2": { "line": 436, "col": 2 }, "3": { "line": 439, "col": 2 }, "4": { "line": 440, "col": 2 }, "5": { "line": 443, "col": 2 }, "2.0": { "line": 437, "col": 4 }, "4.0": { "line": 441, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:_runTurn": { "2": { "line": 456, "col": 2 }, "3": { "line": 457, "col": 2 }, "4": { "line": 460, "col": 2 }, "5": { "line": 463, "col": 2 }, "7": { "line": 467, "col": 2 }, "9": { "line": 472, "col": 2 }, "11": { "line": 478, "col": 2 }, "13": { "line": 493, "col": 2 }, "15": { "line": 521, "col": 2 }, "17": { "line": 566, "col": 2 }, "19": { "line": 580, "col": 2 }, "21": { "line": 622, "col": 2 }, "22": { "line": 623, "col": 2 }, "24": { "line": 632, "col": 2 }, "3.0": { "line": 458, "col": 4 }, "4.0": { "line": 461, "col": 4 }, "5.0": { "line": 464, "col": 4 }, "5.1": { "line": 465, "col": 4 }, "7.0": { "line": 468, "col": 4 }, "7.1": { "line": 469, "col": 4 }, "7.2": { "line": 470, "col": 4 }, "9.0": { "line": 473, "col": 4 }, "9.1": { "line": 476, "col": 4 }, "11.0": { "line": 479, "col": 4 }, "11.1": { "line": 480, "col": 4 }, "11.2.0": { "line": 488, "col": 6 }, "11.2.1": { "line": 489, "col": 6 }, "11.2": { "line": 487, "col": 4 }, "11.4": { "line": 491, "col": 4 }, "13.1": { "line": 501, "col": 4 }, "13.2": { "line": 502, "col": 4 }, "13.3": { "line": 503, "col": 4 }, "13.4.0": { "line": 505, "col": 6 }, "13.4.1": { "line": 506, "col": 6 }, "13.4": { "line": 504, "col": 4 }, "13.5": { "line": 508, "col": 4 }, "13.6": { "line": 509, "col": 4 }, "13.7.0": { "line": 511, "col": 6 }, "13.7.1": { "line": 512, "col": 6 }, "13.7.2.0": { "line": 514, "col": 8 }, "13.7.2": { "line": 513, "col": 6 }, "13.7": { "line": 510, "col": 4 }, "13.9": { "line": 519, "col": 4 }, "15.0": { "line": 522, "col": 4 }, "15.1.0": { "line": 524, "col": 6 }, "15.1": { "line": 523, "col": 4 }, "15.2.0": { "line": 527, "col": 6 }, "15.2.1": { "line": 528, "col": 6 }, "15.2.2.0": { "line": 530, "col": 8 }, "15.2.2.1.0": { "line": 532, "col": 10 }, "15.2.2.1": { "line": 531, "col": 8 }, "15.2.2": { "line": 529, "col": 6 }, "15.2.4": { "line": 535, "col": 6 }, "15.2.5": { "line": 536, "col": 6 }, "15.2.6.0": { "line": 544, "col": 8 }, "15.2.6": { "line": 543, "col": 6 }, "15.2.7": { "line": 546, "col": 6 }, "15.2": { "line": 526, "col": 4 }, "15.4": { "line": 548, "col": 4 }, "15.5": { "line": 552, "col": 4 }, "15.6": { "line": 553, "col": 4 }, "15.7.0": { "line": 555, "col": 6 }, "15.7": { "line": 554, "col": 4 }, "15.8": { "line": 557, "col": 4 }, "15.9.0": { "line": 559, "col": 6 }, "15.9.1.0": { "line": 561, "col": 8 }, "15.9.1": { "line": 560, "col": 6 }, "15.9": { "line": 558, "col": 4 }, "15.11": { "line": 564, "col": 4 }, "17.0": { "line": 567, "col": 4 }, "17.1": { "line": 568, "col": 4 }, "17.2.0": { "line": 570, "col": 6 }, "17.2.1": { "line": 571, "col": 6 }, "17.2": { "line": 569, "col": 4 }, "17.4.0": { "line": 574, "col": 6 }, "17.4": { "line": 573, "col": 4 }, "17.6": { "line": 578, "col": 4 }, "19.0.0": { "line": 582, "col": 6 }, "19.0.1": { "line": 587, "col": 6 }, "19.0": { "line": 581, "col": 4 }, "19.2": { "line": 589, "col": 4 }, "19.3.0": { "line": 591, "col": 6 }, "19.3": { "line": 590, "col": 4 }, "19.5": { "line": 596, "col": 4 }, "19.6.0": { "line": 604, "col": 6 }, "19.6": { "line": 603, "col": 4 }, "19.7": { "line": 606, "col": 4 }, "19.8": { "line": 607, "col": 4 }, "19.9": { "line": 608, "col": 4 }, "19.10.0": { "line": 610, "col": 6 }, "19.10": { "line": 609, "col": 4 }, "19.12": { "line": 612, "col": 4 }, "19.13": { "line": 613, "col": 4 }, "22.0": { "line": 623, "col": 2 }, "22.1.0": { "line": 625, "col": 6 }, "22.1.1": { "line": 627, "col": 6 }, "22.1": { "line": 624, "col": 4 }, "22.3": { "line": 629, "col": 9 }, "22.4": { "line": 630, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:resolveEditInputs": { "1": { "line": 818, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:__block_0": { "1.0.0": { "line": 820, "col": 6 }, "1.0": { "line": 819, "col": 4 }, "1.1": { "line": 822, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:generateImageFile": { "2": { "line": 850, "col": 2 }, "3": { "line": 851, "col": 2 }, "4": { "line": 852, "col": 2 }, "6": { "line": 858, "col": 2 }, "7": { "line": 859, "col": 2 }, "9": { "line": 865, "col": 2 }, "10": { "line": 866, "col": 2 }, "4.0": { "line": 853, "col": 4 }, "7.0": { "line": 860, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:mainAgent": { "1": { "line": 879, "col": 2 }, "3": { "line": 893, "col": 2 }, "1.0": { "line": 880, "col": 4 }, "1.1.1": { "line": 885, "col": 6 }, "1.1.2": { "line": 886, "col": 6 }, "1.1": { "line": 881, "col": 4 }, "1.3": { "line": 888, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:agentReplyVia": { "1": { "line": 902, "col": 2 }, "2": { "line": 903, "col": 2 }, "4": { "line": 906, "col": 2 }, "6": { "line": 909, "col": 2 }, "8": { "line": 912, "col": 2 }, "10": { "line": 915, "col": 2 }, "12": { "line": 921, "col": 2 }, "13": { "line": 922, "col": 2 }, "15": { "line": 925, "col": 2 }, "16": { "line": 932, "col": 2 }, "18": { "line": 935, "col": 2 }, "19": { "line": 938, "col": 2 }, "20": { "line": 939, "col": 2 }, "2.0": { "line": 904, "col": 4 }, "4.0": { "line": 907, "col": 4 }, "6.0": { "line": 910, "col": 4 }, "8.0": { "line": 913, "col": 4 }, "10.0": { "line": 916, "col": 4 }, "13.0": { "line": 923, "col": 4 }, "15.1": { "line": 930, "col": 4 }, "16.0": { "line": 933, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:__block_1": { "18.0": { "line": 936, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:agentReply": { "1": { "line": 949, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:roundedCost": { "1": { "line": 953, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:_buildStatus": { "1": { "line": 957, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:sample": { "1": { "line": 965, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:printHeader": { "1": { "line": 969, "col": 2 }, "2": { "line": 970, "col": 2 }, "3": { "line": 992, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:__block_2": { "2.0": { "line": 977, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:__block_3": { "2.0.0": { "line": 978, "col": 6 }, "2.0.1": { "line": 986, "col": 6 }, "2.0.2": { "line": 987, "col": 6 } }, "dist/lib/agents/agency-agent/agent.agency:__block_4": { "2.0.0.0": { "line": 979, "col": 8 }, "2.0.0.1": { "line": 980, "col": 8 }, "2.0.0.2": { "line": 981, "col": 8 }, "2.0.0.3": { "line": 982, "col": 8 }, "2.0.0.4": { "line": 983, "col": 8 }, "2.0.0.5": { "line": 984, "col": 8 } }, "dist/lib/agents/agency-agent/agent.agency:__block_5": { "2.0.2.0": { "line": 988, "col": 8 } }, "dist/lib/agents/agency-agent/agent.agency:givePolicyChoice": { "1": { "line": 996, "col": 2 }, "2": { "line": 997, "col": 2 }, "3": { "line": 998, "col": 2 }, "4": { "line": 1009, "col": 2 }, "5": { "line": 1010, "col": 9 }, "6": { "line": 1010, "col": 2 }, "5.0": { "line": 1011, "col": 17 }, "5.1": { "line": 1011, "col": 17 }, "5.2": { "line": 1012, "col": 21 }, "5.3": { "line": 1012, "col": 21 } }, "dist/lib/agents/agency-agent/agent.agency:setupSession": { "2": { "line": 1028, "col": 2 }, "3": { "line": 1033, "col": 2 }, "4": { "line": 1034, "col": 2 }, "5": { "line": 1036, "col": 2 }, "6": { "line": 1037, "col": 2 }, "8": { "line": 1054, "col": 2 }, "3.0": { "line": 1033, "col": 2 }, "6.0": { "line": 1037, "col": 2 }, "6.1.0.0": { "line": 1040, "col": 8 }, "6.1.0.1": { "line": 1041, "col": 8 }, "6.1.0.2": { "line": 1043, "col": 8 }, "6.1.0": { "line": 1039, "col": 6 }, "6.1.2": { "line": 1046, "col": 6 }, "6.1.3": { "line": 1047, "col": 6 }, "6.1": { "line": 1038, "col": 4 }, "6.3": { "line": 1050, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:oneShotAgent": { "1": { "line": 1064, "col": 2 }, "2": { "line": 1065, "col": 2 }, "3": { "line": 1066, "col": 2 }, "4": { "line": 1067, "col": 2 }, "5": { "line": 1080, "col": 2 }, "4.1": { "line": 1071, "col": 4 }, "4.2.0": { "line": 1072, "col": 4 }, "4.2.1": { "line": 1073, "col": 6 }, "4.2.2": { "line": 1074, "col": 11 }, "4.2.3": { "line": 1075, "col": 6 }, "4.2": { "line": 1072, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:_runSeedTurn": { "1": { "line": 1087, "col": 2 }, "2": { "line": 1088, "col": 2 }, "3": { "line": 1089, "col": 2 }, "3.0": { "line": 1089, "col": 2 }, "3.1.0": { "line": 1091, "col": 6 }, "3.1.1": { "line": 1093, "col": 6 }, "3.1": { "line": 1090, "col": 4 }, "3.3": { "line": 1095, "col": 9 }, "3.4": { "line": 1096, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:startInteractive": { "1": { "line": 1107, "col": 2 }, "3": { "line": 1122, "col": 2 }, "1.0.0": { "line": 1109, "col": 6 }, "1.0": { "line": 1108, "col": 4 }, "1.1": { "line": 1111, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:main": { "2": { "line": 1128, "col": 2 }, "3": { "line": 1186, "col": 2 }, "4": { "line": 1189, "col": 2 }, "6": { "line": 1198, "col": 2 }, "7": { "line": 1199, "col": 2 }, "8": { "line": 1200, "col": 2 }, "9": { "line": 1201, "col": 2 }, "10": { "line": 1207, "col": 2 }, "12": { "line": 1289, "col": 2 }, "13": { "line": 1290, "col": 2 }, "14": { "line": 1291, "col": 2 }, "15": { "line": 1292, "col": 2 }, "16": { "line": 1295, "col": 2 }, "18": { "line": 1310, "col": 2 }, "20": { "line": 1329, "col": 2 }, "21": { "line": 1330, "col": 2 }, "23": { "line": 1348, "col": 2 }, "24": { "line": 1349, "col": 2 }, "25": { "line": 1350, "col": 2 }, "26": { "line": 1351, "col": 2 }, "27": { "line": 1352, "col": 2 }, "3.0": { "line": 1187, "col": 4 }, "4.0": { "line": 1190, "col": 4 }, "9.0": { "line": 1202, "col": 4 }, "9.1": { "line": 1205, "col": 4 }, "10.1.0": { "line": 1211, "col": 6 }, "10.1.1": { "line": 1212, "col": 6 }, "10.1": { "line": 1210, "col": 4 }, "10.3.0": { "line": 1215, "col": 6 }, "10.3.1": { "line": 1216, "col": 6 }, "10.3.2": { "line": 1217, "col": 6 }, "10.3": { "line": 1214, "col": 4 }, "10.5": { "line": 1219, "col": 4 }, "10.6.0": { "line": 1221, "col": 6 }, "10.6": { "line": 1220, "col": 4 }, "10.8": { "line": 1226, "col": 4 }, "10.9.0": { "line": 1234, "col": 6 }, "10.9": { "line": 1233, "col": 4 }, "10.10": { "line": 1236, "col": 4 }, "10.11": { "line": 1237, "col": 4 }, "10.12": { "line": 1240, "col": 4 }, "10.13": { "line": 1244, "col": 4 }, "10.15": { "line": 1248, "col": 4 }, "10.16": { "line": 1249, "col": 4 }, "10.17": { "line": 1250, "col": 4 }, "10.18": { "line": 1251, "col": 4 }, "10.19.0.0": { "line": 1254, "col": 8 }, "10.19.0.1": { "line": 1256, "col": 8 }, "10.19.0.2": { "line": 1258, "col": 8 }, "10.19.0.3": { "line": 1260, "col": 8 }, "10.19.0.4": { "line": 1265, "col": 8 }, "10.19.0": { "line": 1253, "col": 6 }, "10.19": { "line": 1252, "col": 4 }, "10.20": { "line": 1268, "col": 4 }, "10.21": { "line": 1269, "col": 4 }, "10.22.0": { "line": 1271, "col": 6 }, "10.22": { "line": 1270, "col": 4 }, "10.23.0": { "line": 1274, "col": 6 }, "10.23": { "line": 1273, "col": 4 }, "10.24": { "line": 1276, "col": 4 }, "10.25": { "line": 1282, "col": 4 }, "10.26": { "line": 1283, "col": 4 }, "16.0": { "line": 1296, "col": 4 }, "16.1": { "line": 1301, "col": 4 }, "18.0": { "line": 1311, "col": 4 }, "18.1": { "line": 1312, "col": 4 }, "18.2": { "line": 1313, "col": 4 }, "18.3": { "line": 1314, "col": 4 }, "18.4": { "line": 1315, "col": 4 }, "18.5": { "line": 1316, "col": 4 }, "21.0": { "line": 1331, "col": 4 }, "21.1.0": { "line": 1333, "col": 6 }, "21.1.1.0": { "line": 1335, "col": 8 }, "21.1.1": { "line": 1334, "col": 6 }, "21.1.2": { "line": 1337, "col": 6 }, "21.1": { "line": 1332, "col": 4 }, "21.2": { "line": 1339, "col": 4 }, "21.3": { "line": 1340, "col": 4 } } };
8199
+ const __sourceMap = { "dist/lib/agents/agency-agent/agent.agency:__cb_top_0": { "1": { "line": 158, "col": 2 }, "1.0": { "line": 159, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:__cb_top_1": { "1": { "line": 164, "col": 2 }, "1.0.0": { "line": 165, "col": 4 }, "1.0.1": { "line": 166, "col": 6 }, "1.0.2": { "line": 167, "col": 11 }, "1.0.3": { "line": 168, "col": 6 }, "1.0.4": { "line": 170, "col": 6 }, "1.0": { "line": 165, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:__cb_top_2": { "1": { "line": 176, "col": 2 }, "1.0": { "line": 177, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:__cb_top_3": { "1": { "line": 182, "col": 2 }, "1.0": { "line": 183, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:__cb_top_4": { "1": { "line": 223, "col": 2 }, "1.0": { "line": 224, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:_showTraces": { "1": { "line": 154, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:retryReasonLabel": { "1": { "line": 194, "col": 2 }, "2": { "line": 197, "col": 2 }, "3": { "line": 200, "col": 2 }, "4": { "line": 203, "col": 2 }, "5": { "line": 206, "col": 2 }, "6": { "line": 209, "col": 2 }, "7": { "line": 212, "col": 2 }, "1.0": { "line": 195, "col": 4 }, "2.0": { "line": 198, "col": 4 }, "3.0": { "line": 201, "col": 4 }, "4.0": { "line": 204, "col": 4 }, "5.0": { "line": 207, "col": 4 }, "6.0": { "line": 210, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:formatTurnFailure": { "1": { "line": 239, "col": 2 }, "2": { "line": 242, "col": 2 }, "3": { "line": 245, "col": 2 }, "4": { "line": 248, "col": 2 }, "1.0": { "line": 240, "col": 4 }, "2.0": { "line": 243, "col": 4 }, "3.0": { "line": 246, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:renderLLMCallResponse": { "1": { "line": 265, "col": 2 }, "2": { "line": 266, "col": 2 }, "3": { "line": 269, "col": 2 }, "5": { "line": 274, "col": 2 }, "2.0": { "line": 267, "col": 4 }, "3.0.0": { "line": 271, "col": 6 }, "3.0": { "line": 270, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:loadAgentsMd": { "1": { "line": 285, "col": 2 }, "2": { "line": 288, "col": 2 }, "3": { "line": 289, "col": 2 }, "4": { "line": 292, "col": 2 }, "1.0": { "line": 286, "col": 4 }, "2.0": { "line": 288, "col": 2 }, "3.0": { "line": 290, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:builtinPalette": { "1": { "line": 306, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:mergedPalette": { "1": { "line": 323, "col": 2 }, "2": { "line": 324, "col": 2 }, "3": { "line": 331, "col": 2 }, "4": { "line": 332, "col": 2 }, "5": { "line": 335, "col": 2 }, "2.0": { "line": 325, "col": 4 }, "2.1.0": { "line": 327, "col": 6 }, "2.1": { "line": 326, "col": 4 }, "2.2": { "line": 329, "col": 4 }, "4.0": { "line": 333, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:switchModel": { "1": { "line": 362, "col": 2 }, "2": { "line": 363, "col": 2 }, "3": { "line": 366, "col": 2 }, "4": { "line": 370, "col": 2 }, "5": { "line": 371, "col": 2 }, "7": { "line": 381, "col": 2 }, "9": { "line": 389, "col": 2 }, "10": { "line": 390, "col": 2 }, "11": { "line": 391, "col": 2 }, "12": { "line": 400, "col": 2 }, "13": { "line": 401, "col": 2 }, "15": { "line": 409, "col": 2 }, "16": { "line": 410, "col": 2 }, "17": { "line": 411, "col": 2 }, "2.0": { "line": 364, "col": 4 }, "5.0": { "line": 372, "col": 4 }, "5.1": { "line": 375, "col": 4 }, "7.0": { "line": 382, "col": 4 }, "7.1": { "line": 384, "col": 4 }, "13.0": { "line": 402, "col": 4 }, "13.1": { "line": 403, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:reactToSlotChange": { "1": { "line": 423, "col": 2 }, "3": { "line": 434, "col": 2 }, "1.0": { "line": 424, "col": 4 }, "1.1": { "line": 431, "col": 4 }, "1.3": { "line": 432, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:modelChoiceItems": { "1": { "line": 440, "col": 2 }, "2": { "line": 441, "col": 2 }, "4": { "line": 448, "col": 2 }, "2.0": { "line": 442, "col": 4 }, "2.1": { "line": 443, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:parseModelsFilters": { "1": { "line": 455, "col": 2 }, "2": { "line": 456, "col": 2 }, "3": { "line": 459, "col": 2 }, "4": { "line": 460, "col": 2 }, "5": { "line": 463, "col": 2 }, "2.0": { "line": 457, "col": 4 }, "4.0": { "line": 461, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:_runTurn": { "2": { "line": 476, "col": 2 }, "3": { "line": 477, "col": 2 }, "4": { "line": 480, "col": 2 }, "5": { "line": 483, "col": 2 }, "7": { "line": 487, "col": 2 }, "9": { "line": 492, "col": 2 }, "11": { "line": 498, "col": 2 }, "13": { "line": 513, "col": 2 }, "15": { "line": 541, "col": 2 }, "17": { "line": 586, "col": 2 }, "19": { "line": 600, "col": 2 }, "21": { "line": 642, "col": 2 }, "22": { "line": 643, "col": 2 }, "24": { "line": 652, "col": 2 }, "3.0": { "line": 478, "col": 4 }, "4.0": { "line": 481, "col": 4 }, "5.0": { "line": 484, "col": 4 }, "5.1": { "line": 485, "col": 4 }, "7.0": { "line": 488, "col": 4 }, "7.1": { "line": 489, "col": 4 }, "7.2": { "line": 490, "col": 4 }, "9.0": { "line": 493, "col": 4 }, "9.1": { "line": 496, "col": 4 }, "11.0": { "line": 499, "col": 4 }, "11.1": { "line": 500, "col": 4 }, "11.2.0": { "line": 508, "col": 6 }, "11.2.1": { "line": 509, "col": 6 }, "11.2": { "line": 507, "col": 4 }, "11.4": { "line": 511, "col": 4 }, "13.1": { "line": 521, "col": 4 }, "13.2": { "line": 522, "col": 4 }, "13.3": { "line": 523, "col": 4 }, "13.4.0": { "line": 525, "col": 6 }, "13.4.1": { "line": 526, "col": 6 }, "13.4": { "line": 524, "col": 4 }, "13.5": { "line": 528, "col": 4 }, "13.6": { "line": 529, "col": 4 }, "13.7.0": { "line": 531, "col": 6 }, "13.7.1": { "line": 532, "col": 6 }, "13.7.2.0": { "line": 534, "col": 8 }, "13.7.2": { "line": 533, "col": 6 }, "13.7": { "line": 530, "col": 4 }, "13.9": { "line": 539, "col": 4 }, "15.0": { "line": 542, "col": 4 }, "15.1.0": { "line": 544, "col": 6 }, "15.1": { "line": 543, "col": 4 }, "15.2.0": { "line": 547, "col": 6 }, "15.2.1": { "line": 548, "col": 6 }, "15.2.2.0": { "line": 550, "col": 8 }, "15.2.2.1.0": { "line": 552, "col": 10 }, "15.2.2.1": { "line": 551, "col": 8 }, "15.2.2": { "line": 549, "col": 6 }, "15.2.4": { "line": 555, "col": 6 }, "15.2.5": { "line": 556, "col": 6 }, "15.2.6.0": { "line": 564, "col": 8 }, "15.2.6": { "line": 563, "col": 6 }, "15.2.7": { "line": 566, "col": 6 }, "15.2": { "line": 546, "col": 4 }, "15.4": { "line": 568, "col": 4 }, "15.5": { "line": 572, "col": 4 }, "15.6": { "line": 573, "col": 4 }, "15.7.0": { "line": 575, "col": 6 }, "15.7": { "line": 574, "col": 4 }, "15.8": { "line": 577, "col": 4 }, "15.9.0": { "line": 579, "col": 6 }, "15.9.1.0": { "line": 581, "col": 8 }, "15.9.1": { "line": 580, "col": 6 }, "15.9": { "line": 578, "col": 4 }, "15.11": { "line": 584, "col": 4 }, "17.0": { "line": 587, "col": 4 }, "17.1": { "line": 588, "col": 4 }, "17.2.0": { "line": 590, "col": 6 }, "17.2.1": { "line": 591, "col": 6 }, "17.2": { "line": 589, "col": 4 }, "17.4.0": { "line": 594, "col": 6 }, "17.4": { "line": 593, "col": 4 }, "17.6": { "line": 598, "col": 4 }, "19.0.0": { "line": 602, "col": 6 }, "19.0.1": { "line": 607, "col": 6 }, "19.0": { "line": 601, "col": 4 }, "19.2": { "line": 609, "col": 4 }, "19.3.0": { "line": 611, "col": 6 }, "19.3": { "line": 610, "col": 4 }, "19.5": { "line": 616, "col": 4 }, "19.6.0": { "line": 624, "col": 6 }, "19.6": { "line": 623, "col": 4 }, "19.7": { "line": 626, "col": 4 }, "19.8": { "line": 627, "col": 4 }, "19.9": { "line": 628, "col": 4 }, "19.10.0": { "line": 630, "col": 6 }, "19.10": { "line": 629, "col": 4 }, "19.12": { "line": 632, "col": 4 }, "19.13": { "line": 633, "col": 4 }, "22.0": { "line": 643, "col": 2 }, "22.1.0": { "line": 645, "col": 6 }, "22.1.1": { "line": 647, "col": 6 }, "22.1": { "line": 644, "col": 4 }, "22.3": { "line": 649, "col": 9 }, "22.4": { "line": 650, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:resolveEditInputs": { "1": { "line": 838, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:__block_0": { "1.0.0": { "line": 840, "col": 6 }, "1.0": { "line": 839, "col": 4 }, "1.1": { "line": 842, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:generateImageFile": { "2": { "line": 870, "col": 2 }, "3": { "line": 871, "col": 2 }, "4": { "line": 872, "col": 2 }, "6": { "line": 878, "col": 2 }, "7": { "line": 884, "col": 2 }, "9": { "line": 890, "col": 2 }, "10": { "line": 891, "col": 2 }, "4.0": { "line": 873, "col": 4 }, "7.0": { "line": 885, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:mainAgent": { "1": { "line": 904, "col": 2 }, "3": { "line": 918, "col": 2 }, "1.0": { "line": 905, "col": 4 }, "1.1.1": { "line": 910, "col": 6 }, "1.1.2": { "line": 911, "col": 6 }, "1.1": { "line": 906, "col": 4 }, "1.3": { "line": 913, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:agentReplyVia": { "1": { "line": 927, "col": 2 }, "2": { "line": 928, "col": 2 }, "4": { "line": 931, "col": 2 }, "6": { "line": 934, "col": 2 }, "8": { "line": 937, "col": 2 }, "10": { "line": 940, "col": 2 }, "12": { "line": 946, "col": 2 }, "13": { "line": 947, "col": 2 }, "15": { "line": 952, "col": 2 }, "16": { "line": 959, "col": 2 }, "18": { "line": 962, "col": 2 }, "19": { "line": 965, "col": 2 }, "20": { "line": 966, "col": 2 }, "2.0": { "line": 929, "col": 4 }, "4.0": { "line": 932, "col": 4 }, "6.0": { "line": 935, "col": 4 }, "8.0": { "line": 938, "col": 4 }, "10.0": { "line": 941, "col": 4 }, "13.0": { "line": 948, "col": 4 }, "15.1": { "line": 957, "col": 4 }, "16.0": { "line": 960, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:__block_1": { "18.0": { "line": 963, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:agentReply": { "1": { "line": 976, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:roundedCost": { "1": { "line": 980, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:_buildStatus": { "1": { "line": 984, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:sample": { "1": { "line": 992, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:printHeader": { "1": { "line": 996, "col": 2 }, "2": { "line": 997, "col": 2 }, "3": { "line": 1019, "col": 2 } }, "dist/lib/agents/agency-agent/agent.agency:__block_2": { "2.0": { "line": 1004, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:__block_3": { "2.0.0": { "line": 1005, "col": 6 }, "2.0.1": { "line": 1013, "col": 6 }, "2.0.2": { "line": 1014, "col": 6 } }, "dist/lib/agents/agency-agent/agent.agency:__block_4": { "2.0.0.0": { "line": 1006, "col": 8 }, "2.0.0.1": { "line": 1007, "col": 8 }, "2.0.0.2": { "line": 1008, "col": 8 }, "2.0.0.3": { "line": 1009, "col": 8 }, "2.0.0.4": { "line": 1010, "col": 8 }, "2.0.0.5": { "line": 1011, "col": 8 } }, "dist/lib/agents/agency-agent/agent.agency:__block_5": { "2.0.2.0": { "line": 1015, "col": 8 } }, "dist/lib/agents/agency-agent/agent.agency:printPolicyHelp": { "1": { "line": 1025, "col": 2 }, "2": { "line": 1026, "col": 2 }, "3": { "line": 1029, "col": 2 }, "4": { "line": 1030, "col": 2 }, "5": { "line": 1031, "col": 2 }, "5.0": { "line": 1032, "col": 4 }, "5.1": { "line": 1033, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:givePolicyChoice": { "1": { "line": 1038, "col": 2 }, "2": { "line": 1039, "col": 2 }, "3": { "line": 1040, "col": 2 }, "4": { "line": 1051, "col": 2 }, "5": { "line": 1052, "col": 9 }, "6": { "line": 1052, "col": 2 }, "5.0": { "line": 1053, "col": 17 }, "5.1": { "line": 1053, "col": 17 }, "5.2": { "line": 1054, "col": 21 }, "5.3": { "line": 1054, "col": 21 } }, "dist/lib/agents/agency-agent/agent.agency:setupSession": { "2": { "line": 1070, "col": 2 }, "3": { "line": 1075, "col": 2 }, "4": { "line": 1076, "col": 2 }, "5": { "line": 1082, "col": 2 }, "6": { "line": 1083, "col": 2 }, "7": { "line": 1085, "col": 2 }, "9": { "line": 1133, "col": 2 }, "3.0": { "line": 1075, "col": 2 }, "7.1": { "line": 1090, "col": 4 }, "7.2.1": { "line": 1096, "col": 6 }, "7.2.2": { "line": 1097, "col": 6 }, "7.2.4": { "line": 1102, "col": 6 }, "7.2.5.0": { "line": 1103, "col": 6 }, "7.2.5.1": { "line": 1104, "col": 8 }, "7.2.5.2": { "line": 1109, "col": 8 }, "7.2.5": { "line": 1103, "col": 6 }, "7.2.7": { "line": 1111, "col": 6 }, "7.2": { "line": 1091, "col": 4 }, "7.4": { "line": 1114, "col": 4 }, "7.5.0": { "line": 1115, "col": 4 }, "7.5.1.0.0": { "line": 1118, "col": 10 }, "7.5.1.0.1": { "line": 1119, "col": 10 }, "7.5.1.0.2": { "line": 1121, "col": 10 }, "7.5.1.0": { "line": 1117, "col": 8 }, "7.5.1.2": { "line": 1124, "col": 8 }, "7.5.1.3": { "line": 1125, "col": 8 }, "7.5.1": { "line": 1116, "col": 6 }, "7.5.3": { "line": 1128, "col": 6 }, "7.5": { "line": 1115, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:oneShotAgent": { "1": { "line": 1147, "col": 2 }, "2": { "line": 1148, "col": 2 }, "3": { "line": 1149, "col": 2 }, "4": { "line": 1150, "col": 2 }, "5": { "line": 1163, "col": 2 }, "4.1": { "line": 1154, "col": 4 }, "4.2.0": { "line": 1155, "col": 4 }, "4.2.1": { "line": 1156, "col": 6 }, "4.2.2": { "line": 1157, "col": 11 }, "4.2.3": { "line": 1158, "col": 6 }, "4.2": { "line": 1155, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:_runSeedTurn": { "1": { "line": 1170, "col": 2 }, "2": { "line": 1171, "col": 2 }, "3": { "line": 1172, "col": 2 }, "3.0": { "line": 1172, "col": 2 }, "3.1.0": { "line": 1174, "col": 6 }, "3.1.1": { "line": 1176, "col": 6 }, "3.1": { "line": 1173, "col": 4 }, "3.3": { "line": 1178, "col": 9 }, "3.4": { "line": 1179, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:startInteractive": { "1": { "line": 1190, "col": 2 }, "3": { "line": 1205, "col": 2 }, "1.0.0": { "line": 1192, "col": 6 }, "1.0": { "line": 1191, "col": 4 }, "1.1": { "line": 1194, "col": 4 } }, "dist/lib/agents/agency-agent/agent.agency:main": { "2": { "line": 1211, "col": 2 }, "3": { "line": 1274, "col": 2 }, "4": { "line": 1277, "col": 2 }, "6": { "line": 1283, "col": 2 }, "7": { "line": 1287, "col": 2 }, "8": { "line": 1294, "col": 2 }, "9": { "line": 1295, "col": 2 }, "10": { "line": 1296, "col": 2 }, "11": { "line": 1297, "col": 2 }, "12": { "line": 1303, "col": 2 }, "14": { "line": 1385, "col": 2 }, "15": { "line": 1386, "col": 2 }, "16": { "line": 1387, "col": 2 }, "17": { "line": 1388, "col": 2 }, "18": { "line": 1391, "col": 2 }, "20": { "line": 1406, "col": 2 }, "22": { "line": 1425, "col": 2 }, "23": { "line": 1426, "col": 2 }, "25": { "line": 1444, "col": 2 }, "26": { "line": 1445, "col": 2 }, "27": { "line": 1446, "col": 2 }, "28": { "line": 1447, "col": 2 }, "29": { "line": 1448, "col": 2 }, "3.0": { "line": 1275, "col": 4 }, "4.0": { "line": 1278, "col": 4 }, "6.0": { "line": 1284, "col": 4 }, "6.1": { "line": 1285, "col": 4 }, "11.0": { "line": 1298, "col": 4 }, "11.1": { "line": 1301, "col": 4 }, "12.1.0": { "line": 1307, "col": 6 }, "12.1.1": { "line": 1308, "col": 6 }, "12.1": { "line": 1306, "col": 4 }, "12.3.0": { "line": 1311, "col": 6 }, "12.3.1": { "line": 1312, "col": 6 }, "12.3.2": { "line": 1313, "col": 6 }, "12.3": { "line": 1310, "col": 4 }, "12.5": { "line": 1315, "col": 4 }, "12.6.0": { "line": 1317, "col": 6 }, "12.6": { "line": 1316, "col": 4 }, "12.8": { "line": 1322, "col": 4 }, "12.9.0": { "line": 1330, "col": 6 }, "12.9": { "line": 1329, "col": 4 }, "12.10": { "line": 1332, "col": 4 }, "12.11": { "line": 1333, "col": 4 }, "12.12": { "line": 1336, "col": 4 }, "12.13": { "line": 1340, "col": 4 }, "12.15": { "line": 1344, "col": 4 }, "12.16": { "line": 1345, "col": 4 }, "12.17": { "line": 1346, "col": 4 }, "12.18": { "line": 1347, "col": 4 }, "12.19.0.0": { "line": 1350, "col": 8 }, "12.19.0.1": { "line": 1352, "col": 8 }, "12.19.0.2": { "line": 1354, "col": 8 }, "12.19.0.3": { "line": 1356, "col": 8 }, "12.19.0.4": { "line": 1361, "col": 8 }, "12.19.0": { "line": 1349, "col": 6 }, "12.19": { "line": 1348, "col": 4 }, "12.20": { "line": 1364, "col": 4 }, "12.21": { "line": 1365, "col": 4 }, "12.22.0": { "line": 1367, "col": 6 }, "12.22": { "line": 1366, "col": 4 }, "12.23.0": { "line": 1370, "col": 6 }, "12.23": { "line": 1369, "col": 4 }, "12.24": { "line": 1372, "col": 4 }, "12.25": { "line": 1378, "col": 4 }, "12.26": { "line": 1379, "col": 4 }, "18.0": { "line": 1392, "col": 4 }, "18.1": { "line": 1397, "col": 4 }, "20.0": { "line": 1407, "col": 4 }, "20.1": { "line": 1408, "col": 4 }, "20.2": { "line": 1409, "col": 4 }, "20.3": { "line": 1410, "col": 4 }, "20.4": { "line": 1411, "col": 4 }, "20.5": { "line": 1412, "col": 4 }, "23.0": { "line": 1427, "col": 4 }, "23.1.0": { "line": 1429, "col": 6 }, "23.1.1.0": { "line": 1431, "col": 8 }, "23.1.1": { "line": 1430, "col": 6 }, "23.1.2": { "line": 1433, "col": 6 }, "23.1": { "line": 1428, "col": 4 }, "23.2": { "line": 1435, "col": 4 }, "23.3": { "line": 1436, "col": 4 } } };
7874
8200
  export {
7875
8201
  Session,
7876
8202
  __cb_top_0,
@@ -7910,6 +8236,7 @@ export {
7910
8236
  oneShotAgent,
7911
8237
  parseModelsFilters,
7912
8238
  printHeader,
8239
+ printPolicyHelp,
7913
8240
  reactToSlotChange,
7914
8241
  reject,
7915
8242
  renderLLMCallResponse,