@desplega.ai/agent-swarm 2.10.0 → 2.11.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.
- package/dist/acp-adapter-weaaxey3.js +16 -0
- package/dist/{acp-targets-arrwv4f0.js → acp-targets-5wyy2b9m.js} +9 -9
- package/dist/{actions-y0d2n1c2.js → actions-4nxq386s.js} +24 -23
- package/dist/{agent-fs-provision-tpj7sktd.js → agent-fs-provision-v6enh76w.js} +4 -4
- package/dist/{amp-adapter-vmmnmw8d.js → amp-adapter-ze3x22qn.js} +3 -3
- package/dist/{anthropic-messages-zdca3gv1.js → anthropic-messages-88b7s3n9.js} +177 -25
- package/dist/{app-wb7w45dq.js → app-kyqt8ehw.js} +7 -6
- package/dist/{approval-notifications-7mqr6vbd.js → approval-notifications-a0db0esw.js} +7 -6
- package/dist/{assistant-gf60454p.js → assistant-9g5jzq25.js} +26 -25
- package/dist/{azure-openai-responses-b3y7fz36.js → azure-openai-responses-jeaas6x0.js} +10 -10
- package/dist/{boot-args-schema-qxmd59sr.js → boot-args-schema-d7fme4q1.js} +1 -1
- package/dist/{boot-reembed-wb44vc3s.js → boot-reembed-6wpazmpw.js} +1 -1
- package/dist/{boot-reembed-5tmeskj2.js → boot-reembed-jrwxeye2.js} +1 -1
- package/dist/{boot-scrub-sweep-25bxhnw4.js → boot-scrub-sweep-52h7yntp.js} +2 -2
- package/dist/{boot-seeds-nj9za0vk.js → boot-seeds-kb3dxjex.js} +4 -4
- package/dist/{boxd-wn235q80.js → boxd-jrrmkv3w.js} +2 -2
- package/dist/{claude-adapter-d3krpdyb.js → claude-adapter-0c0y8fqp.js} +8 -8
- package/dist/{claude-managed-adapter-t8nfgcgz.js → claude-managed-adapter-w2es07qq.js} +4 -4
- package/dist/{claude-managed-setup-7y4pwd81.js → claude-managed-setup-9ssb7ct4.js} +4 -4
- package/dist/{claude-sdk-session-d138zy0e.js → claude-sdk-session-p6t0gyse.js} +10941 -10412
- package/dist/{cli-p0n7b5rz.js → cli-075ccjh6.js} +344 -130
- package/dist/{cli-3caf7pmg.js → cli-0bgj4rh5.js} +3 -3
- package/dist/{cli-7r162fxe.js → cli-14xdms9a.js} +23 -17
- package/dist/{cli-rqx70rcz.js → cli-17qzb39j.js} +5 -2
- package/dist/{cli-y4ccxtz5.js → cli-1h4njv9y.js} +144 -6
- package/dist/{cli-6ym4jhzp.js → cli-27fat7st.js} +7 -7
- package/dist/{cli-k3q2va86.js → cli-2aacfdcn.js} +5 -5
- package/dist/{cli-vq2eg24x.js → cli-2gvdvsxj.js} +3 -3
- package/dist/{cli-sb4426be.js → cli-2jtfm8kh.js} +5 -5
- package/dist/{cli-6ehs4mta.js → cli-2z2c4k6q.js} +18 -4
- package/dist/{cli-6237rnyr.js → cli-3bpr3wks.js} +1 -1
- package/dist/{cli-5qhfv9rw.js → cli-453497a0.js} +44 -17
- package/dist/{cli-2rnd5j3t.js → cli-4aswccje.js} +2 -2
- package/dist/{cli-4ymxrwg5.js → cli-4dyzzkfb.js} +2 -2
- package/dist/{cli-p0c3vtch.js → cli-4g323fjh.js} +772 -515
- package/dist/{cli-3kd08rej.js → cli-4jjrhy48.js} +1 -1
- package/dist/{cli-fcfbct2j.js → cli-4kzp7r0q.js} +5 -5
- package/dist/{cli-kxn3747f.js → cli-4se3x6qm.js} +1 -26
- package/dist/{cli-zeh2mhkg.js → cli-5ptj757f.js} +1 -1
- package/dist/{cli-539h29es.js → cli-6a3j25xd.js} +224 -189
- package/dist/{cli-hnamkvnc.js → cli-6c9ve77f.js} +2 -2
- package/dist/{cli-3et6fmfe.js → cli-6n7y5ypy.js} +1 -1
- package/dist/{cli-8y43jx2r.js → cli-6p8p2e6r.js} +16 -9
- package/dist/{cli-zk7v5s89.js → cli-6tvh1fwq.js} +3 -3
- package/dist/{cli-p74md7t8.js → cli-7b7rxz22.js} +13 -15
- package/dist/{cli-5a6pqy45.js → cli-7e8sxqv5.js} +1 -1
- package/dist/{cli-6037prsx.js → cli-892y3vfp.js} +13 -13
- package/dist/cli-8mfdbdhe.js +43 -0
- package/dist/{cli-s1zqk1aj.js → cli-8zmpwe79.js} +15 -9
- package/dist/{cli-zcfpsfzf.js → cli-96234j5w.js} +3 -3
- package/dist/{cli-1z4qggfe.js → cli-9fvk9mv8.js} +30 -21
- package/dist/{cli-7mv4h3sn.js → cli-9g12h1aq.js} +2 -2
- package/dist/{cli-aw83sr40.js → cli-9knhkkgr.js} +3 -3
- package/dist/{cli-5mpy301f.js → cli-9t7syepg.js} +1 -1
- package/dist/{cli-qj39vrc6.js → cli-9yjhshah.js} +1 -1
- package/dist/{cli-6cwr32fe.js → cli-a02habn6.js} +422 -140
- package/dist/{cli-7evph51z.js → cli-a49frv85.js} +2 -2
- package/dist/{cli-3f8zbtqa.js → cli-a6q6x15h.js} +9 -8
- package/dist/{cli-j6te8keb.js → cli-atm0hkes.js} +8 -8
- package/dist/{cli-9fjr27ez.js → cli-b82a13ga.js} +13 -13
- package/dist/{cli-7zm3b3f5.js → cli-bf0t77nf.js} +1 -1
- package/dist/{cli-2xv18ywz.js → cli-bmqp0ser.js} +2 -2
- package/dist/{cli-mk7c5ac4.js → cli-bq97k63w.js} +2 -2
- package/dist/{cli-vfqvrd82.js → cli-cstggwq7.js} +2 -2
- package/dist/{cli-md50mj0r.js → cli-czvvnfr9.js} +3 -3
- package/dist/{cli-b6px1k1q.js → cli-dd2k2mcd.js} +1 -1
- package/dist/{cli-fq2rr3jb.js → cli-djt6wmrc.js} +6 -6
- package/dist/{cli-tsa40663.js → cli-ebqx630g.js} +3 -3
- package/dist/{cli-z0m452jr.js → cli-f7dhm7hh.js} +1 -1
- package/dist/{cli-mys27d03.js → cli-f8yhybxr.js} +3 -3
- package/dist/{cli-5gpqgs8b.js → cli-fwjwkw66.js} +2 -2
- package/dist/{cli-gabsjg8x.js → cli-g56fxddf.js} +1 -1
- package/dist/{cli-y8p78ekx.js → cli-h2qtafm4.js} +18 -18
- package/dist/{cli-psffsanb.js → cli-ha4ek2nb.js} +6 -1
- package/dist/{cli-th1dkc2v.js → cli-hnh8erra.js} +2 -2
- package/dist/{cli-w16kwbzw.js → cli-htymm48w.js} +1 -1
- package/dist/{cli-124ntmf0.js → cli-j2r1apqm.js} +138 -59
- package/dist/{cli-43ms35q9.js → cli-k3c13za2.js} +3 -3
- package/dist/{cli-54vrpgm0.js → cli-k3facve0.js} +8 -5
- package/dist/{cli-v8z0yga9.js → cli-k4r5sfaj.js} +4 -4
- package/dist/{cli-91pkxres.js → cli-kbm659dk.js} +2 -2
- package/dist/{cli-q5srsxq2.js → cli-m00c47q6.js} +110 -27
- package/dist/{cli-3aaeb78m.js → cli-mhrr4d5b.js} +95 -10
- package/dist/{cli-xqdz5cqm.js → cli-mz7ycqn8.js} +1 -0
- package/dist/{cli-qrta34nb.js → cli-n6ygvrrm.js} +4 -4
- package/dist/{cli-k5yewqgd.js → cli-nbakg5xh.js} +3 -3
- package/dist/{cli-nstkanmx.js → cli-nc39ym5q.js} +8 -8
- package/dist/{cli-01k6wpr9.js → cli-p1a4khta.js} +7 -7
- package/dist/{cli-t9ga4qmb.js → cli-p8zqbbt1.js} +40 -33
- package/dist/{cli-v46zsvqk.js → cli-ph95yejc.js} +2 -2
- package/dist/{cli-k6nejceb.js → cli-q4z9s6zs.js} +2 -2
- package/dist/{cli-kbtzfrxj.js → cli-q71g5q39.js} +3 -3
- package/dist/{cli-vs9vdpy0.js → cli-qncx2r0s.js} +1 -1
- package/dist/{cli-hg42n3hx.js → cli-qrzq3hvg.js} +8 -8
- package/dist/{cli-x40a0w9j.js → cli-r813c7rb.js} +1 -1
- package/dist/{cli-kpgcm7xy.js → cli-ramn8jae.js} +1 -1
- package/dist/{cli-cc93xzes.js → cli-raqw9fw9.js} +28 -17
- package/dist/cli-rhsc2zyx.js +68 -0
- package/dist/{cli-8st34zhr.js → cli-rpmw4fsv.js} +57 -19
- package/dist/{cli-had1p04a.js → cli-rwgwen5v.js} +4 -4
- package/dist/{cli-tr27kwyg.js → cli-rytq7dm2.js} +261 -6
- package/dist/{cli-s1khw52h.js → cli-s9twe4x0.js} +66 -17
- package/dist/{cli-2v2zdm0a.js → cli-t2s7j5cy.js} +2 -2
- package/dist/{cli-nv4xsvmk.js → cli-tb4j757d.js} +7 -7
- package/dist/{cli-q2d3e1k1.js → cli-thd3005a.js} +1 -1
- package/dist/cli-tsfkcd4v.js +30 -0
- package/dist/{cli-jrbq4djp.js → cli-v3zcnr8g.js} +1 -1
- package/dist/{cli-zfqg6fzn.js → cli-vbppqvte.js} +3 -3
- package/dist/{cli-qx4f057j.js → cli-vy3fn0mz.js} +4 -4
- package/dist/{cli-7sf9sb0w.js → cli-w5dar1bk.js} +1 -1
- package/dist/{cli-w1q68d8x.js → cli-wz4e5am2.js} +9 -9
- package/dist/{cli-m9cvf7vs.js → cli-xqbqwpxr.js} +14 -14
- package/dist/{cli-2spnz7ye.js → cli-ynph3b70.js} +11137 -8332
- package/dist/{cli-43evxwj4.js → cli-yvzxbztc.js} +9 -4
- package/dist/{cli-vsw91x06.js → cli-yzxqwcvq.js} +3 -6
- package/dist/{cli-wafmk3fn.js → cli-zb1hff00.js} +12 -12
- package/dist/{cli-yab6sh8p.js → cli-zcghfsdg.js} +23 -4
- package/dist/{cli-wwp1bd3n.js → cli-zhn4r1rz.js} +519 -75
- package/dist/{cli-tvgqesec.js → cli-zqq57pgx.js} +4 -4
- package/dist/cli.js +28 -27
- package/dist/{cloudflare-workers-ai-system-one-4aysy6rh.js → cloudflare-workers-ai-system-one-w3m0fbf8.js} +2 -2
- package/dist/{codex-adapter-exfdbj73.js → codex-adapter-ssahg4h4.js} +8 -8
- package/dist/{codex-hook-59atdwd8.js → codex-hook-aqtj17yr.js} +1 -1
- package/dist/{codex-login-a239g1ah.js → codex-login-9c7aggxe.js} +1 -1
- package/dist/{codex-session-runner-xhznc4g3.js → codex-session-runner-xn63q3h7.js} +9 -9
- package/dist/{commands-d8g349v4.js → commands-ctey7tr5.js} +3 -3
- package/dist/{controller-mwgdmb8y.js → controller-rqhbppg9.js} +4 -4
- package/dist/{controllers-connect-5v7qx04j.js → controllers-connect-w3qbpbt1.js} +22 -21
- package/dist/{core-sxy4epp2.js → core-df1n049h.js} +19 -18
- package/dist/{cursor-adapter-p2q5h35d.js → cursor-adapter-r819hf1a.js} +2 -2
- package/dist/{db-wcw0b2j8.js → db-2ah39cyx.js} +2 -2
- package/dist/{db-qpganbeb.js → db-p5drc1d1.js} +3 -3
- package/dist/{devin-adapter-zp4tqq53.js → devin-adapter-bc6g0x29.js} +1 -1
- package/dist/{dispatcher-8d8s49yz.js → dispatcher-x6w14pde.js} +19 -18
- package/dist/{docker-09tkkg0n.js → docker-6c4reetq.js} +51 -14
- package/dist/{dsh-adapter-me0twn13.js → dsh-adapter-h8qn14n4.js} +2 -2
- package/dist/{e2b-sm28k0k3.js → e2b-jg7kyyef.js} +6 -6
- package/dist/{e2b-3v1e745x.js → e2b-z4ec0qve.js} +3 -3
- package/dist/{easter-egg-3d-wv7w5ty6.js → easter-egg-3d-1y6r9gxy.js} +1 -1
- package/dist/{embedding-space-e48xchqa.js → embedding-space-z6ptw3jk.js} +6 -6
- package/dist/{embeddings-tgq2afbq.js → embeddings-0sxb1d2h.js} +1 -1
- package/dist/{event-bus-xr83x566.js → event-bus-swr88jg5.js} +1 -1
- package/dist/{execute-8rhwrk7f.js → execute-6m1ex8ce.js} +8 -4
- package/dist/{external-channel-8bt3j2pm.js → external-channel-ezer7pk0.js} +2 -2
- package/dist/fx-adapter-zwmps9re.js +19 -0
- package/dist/{google-generative-ai-bh0djqjp.js → google-generative-ai-sw77egmr.js} +9 -9
- package/dist/{google-vertex-prjbw8dj.js → google-vertex-rrw93g8h.js} +9 -9
- package/dist/grok-adapter-q0avf919.js +19 -0
- package/dist/handlers-g5jq0e4q.js +36 -0
- package/dist/{heartbeat-x0056ra5.js → heartbeat-6c4fr49t.js} +22 -21
- package/dist/{hook-mrd2ayxv.js → hook-02rt5tvq.js} +8 -8
- package/dist/{hook-a7vmn2st.js → hook-t1c5avbv.js} +5 -5
- package/dist/{http-ym9c5svp.js → http-qa3h32a1.js} +2049 -148
- package/dist/index-1f6m47mq.js +37 -0
- package/dist/index-1p1mpqda.js +36 -0
- package/dist/{index-p46tvwtx.js → index-akbgsdhh.js} +25 -24
- package/dist/{index-ny60jcat.js → index-e42j998x.js} +16 -13
- package/dist/{index-b5wgnm78.js → index-kdmkfjt7.js} +4 -4
- package/dist/{index-01ns1pkw.js → index-kqv9ebfj.js} +1 -1
- package/dist/{index-9myfj74s.js → index-kzdqn3dd.js} +3 -3
- package/dist/{index-4a0670yh.js → index-p2f5xg64.js} +6 -6
- package/dist/{index-x6azjwm8.js → index-qpjk2hxk.js} +1 -1
- package/dist/index-tnkd410q.js +41 -0
- package/dist/{k8s-m56sw868.js → k8s-7jrh5va2.js} +73 -14
- package/dist/{keepalive-7yxg8z4c.js → keepalive-jmf6pn8c.js} +4 -4
- package/dist/lead-m5e7xt93.js +75 -0
- package/dist/{llama-cpp-classify-nfgswa1m.js → llama-cpp-classify-yvb8vh7w.js} +2 -2
- package/dist/{maintenance-6tefxmk1.js → maintenance-g7v15tj1.js} +1 -1
- package/dist/{mistral-conversations-tm2vd4gc.js → mistral-conversations-w4bncwbt.js} +7 -7
- package/dist/{node-7qsx5kvm.js → node-z67yjre7.js} +19 -13
- package/dist/{oauth-refresh-sweep-70cavc3a.js → oauth-refresh-sweep-ywgf8tbr.js} +3 -3
- package/dist/{onboard-fja65z08.js → onboard-m3fedypq.js} +3 -3
- package/dist/{openai-codex-responses-sxjv60xx.js → openai-codex-responses-70g39cgz.js} +20 -14
- package/dist/{openai-completions-0c7qnhsx.js → openai-completions-cv3hp4h5.js} +18 -11
- package/dist/{openai-decisions-ytp6w6xh.js → openai-decisions-fyq1p9f9.js} +2 -2
- package/dist/{openai-responses-a7h29chp.js → openai-responses-trsvnks6.js} +13 -11
- package/dist/{opencode-adapter-hakkm7yh.js → opencode-adapter-19ktcbb9.js} +7 -7
- package/dist/{openrouter-images-xr9gme9x.js → openrouter-images-0jj12a2q.js} +6 -6
- package/dist/{otel-impl-7zhnt6gj.js → otel-impl-3ehm1hgc.js} +2 -2
- package/dist/{pending-h01yzpx4.js → pending-fwj2fatd.js} +20 -19
- package/dist/{pi-messages-2j0fpqwq.js → pi-messages-zk3g4esn.js} +1 -1
- package/dist/{pi-mono-adapter-f52hz743.js → pi-mono-adapter-xdeesvc4.js} +18 -17
- package/dist/{pricing-refresh-fzxvk2zf.js → pricing-refresh-4j8dzvxg.js} +2 -2
- package/dist/{rbac-roles-9v6vhgbs.js → rbac-roles-8msjr07m.js} +3 -3
- package/dist/{rbac-roles-hfgh8sba.js → rbac-roles-n7t2acv8.js} +2 -2
- package/dist/{render-v2-1rgspxzf.js → render-v2-j7qggj8h.js} +7 -6
- package/dist/{resume-tqy61x24.js → resume-hj1mn65y.js} +9 -8
- package/dist/{runtime-exkxyx5f.js → runtime-z31mdsgv.js} +2 -2
- package/dist/{session-access-3act7vt4.js → session-access-w38fh09a.js} +4 -4
- package/dist/{session-source-backfill-82qe7fqq.js → session-source-backfill-ax6qxv20.js} +3 -3
- package/dist/{setup-ry1vfdef.js → setup-dsqmpfcr.js} +1 -1
- package/dist/thread-buffer-nf55vwx3.js +39 -0
- package/dist/tree-visibility-6vqmnr71.js +24 -0
- package/dist/{typesafe-system-one-vcfj2ak8.js → typesafe-system-one-qkvkgrcz.js} +2 -2
- package/dist/{user-merge-jobs-bx6bf7db.js → user-merge-jobs-mvheb3ed.js} +3 -3
- package/dist/{virtual-modules-s0rjzcqq.js → virtual-modules-w2qk2wew.js} +32 -10
- package/dist/{work-objects-z2e5tv03.js → work-objects-4ahy5es5.js} +22 -21
- package/dist/worker-ews1nyhw.js +75 -0
- package/dist/{worker-follow-up-y3xeg89w.js → worker-follow-up-1gs4aw7y.js} +19 -18
- package/dist/{x-wg164ss9.js → x-3wr8c5sh.js} +2 -2
- package/openapi.json +995 -49
- package/package.json +9 -8
- package/src/be/db/request-composition.ts +190 -0
- package/src/be/db/runtime.ts +15 -0
- package/src/be/db/slack-trees.ts +220 -10
- package/src/be/db/tasks/human-free.ts +3 -2
- package/src/be/db/workflow-run-retention.ts +101 -0
- package/src/be/db-client.ts +23 -1
- package/src/be/db-retention-defaults.ts +46 -0
- package/src/be/db-retention.ts +55 -6
- package/src/be/mcp-events/catalog.ts +108 -0
- package/src/be/mcp-events/dispatcher.ts +202 -0
- package/src/be/mcp-events/protocol.ts +296 -0
- package/src/be/mcp-events/store.ts +231 -0
- package/src/be/mcp-events/webhook.ts +226 -0
- package/src/be/memory/providers/sqlite-store.ts +110 -24
- package/src/be/memory/review-recall-filter.ts +22 -0
- package/src/be/memory/search-candidates.ts +5 -7
- package/src/be/memory/types.ts +5 -0
- package/src/be/migrations/322_runtime_pool_workspace.sql +8 -0
- package/src/be/migrations/323_slack_task_tree_visibility.sql +9 -0
- package/src/be/migrations/326_slack_reconcile_pages.sql +13 -0
- package/src/be/migrations/327_mcp_event_subscriptions.sql +57 -0
- package/src/be/migrations/329_workflow_run_retention.sql +9 -0
- package/src/be/migrations/330_request_composition.sql +22 -0
- package/src/be/model-profile-check.ts +1 -1
- package/src/be/multi-runtime.ts +32 -4
- package/src/be/runtime-pools/controllers.ts +18 -3
- package/src/be/runtime-pools/db.ts +15 -4
- package/src/be/runtime-pools/supervisor.ts +42 -2
- package/src/be/swarm-config-guard.ts +10 -2
- package/src/commands/context-preamble.ts +11 -4
- package/src/commands/credential-outcome-report.ts +33 -9
- package/src/commands/e2b-stack-wizard.tsx +12 -6
- package/src/commands/runner.ts +116 -12
- package/src/extensions/catalog.generated.json +1 -1
- package/src/github/app.ts +59 -14
- package/src/http/all-routes.ts +2 -0
- package/src/http/config.ts +2 -1
- package/src/http/core.ts +2 -0
- package/src/http/github-token.ts +66 -0
- package/src/http/index.ts +21 -0
- package/src/http/mcp-user.ts +11 -8
- package/src/http/mcp.ts +58 -42
- package/src/http/prompt-templates.ts +1 -0
- package/src/http/request-composition.ts +310 -0
- package/src/http/tasks.ts +6 -1
- package/src/http/tool-schema-estimate.ts +95 -0
- package/src/http/workflows.ts +29 -11
- package/src/integrations/chat-sdk/inbound.ts +2 -2
- package/src/prompts/base-prompt.ts +133 -7
- package/src/prompts/resolver.ts +41 -2
- package/src/providers/amp-adapter.ts +1 -1
- package/src/providers/opencode-adapter.ts +72 -1
- package/src/providers/opencode-swarm-plugin.ts +22 -3
- package/src/providers/pi-mono-adapter.ts +1 -0
- package/src/providers/pi-mono-extension.ts +71 -0
- package/src/providers/pricing-sources.md +4 -0
- package/src/providers/request-composition-hook.ts +312 -0
- package/src/providers/types.ts +5 -0
- package/src/runtime-providers/controller-protocol.ts +7 -0
- package/src/runtime-providers/docker.ts +80 -12
- package/src/runtime-providers/k8s.ts +111 -6
- package/src/runtime-providers/types.ts +17 -0
- package/src/scheduler/scheduler.ts +1 -1
- package/src/server-user.ts +16 -1
- package/src/slack/ack.ts +10 -5
- package/src/slack/actions.ts +3 -3
- package/src/slack/app.ts +2 -0
- package/src/slack/assistant.ts +4 -4
- package/src/slack/blocks.ts +3 -3
- package/src/slack/handlers.ts +3 -3
- package/src/slack/reaction-shortcode.ts +23 -2
- package/src/slack/render-v2.ts +297 -200
- package/src/slack/responses.ts +7 -5
- package/src/slack/thread-buffer.ts +3 -3
- package/src/slack/tree-visibility.ts +64 -0
- package/src/tasks/worker-follow-up.ts +127 -17
- package/src/tests/azure-devops-outbound.test.ts +47 -14
- package/src/tests/base-prompt.test.ts +149 -1
- package/src/tests/check-playwright-version.test.ts +33 -0
- package/src/tests/context-preamble-budget.test.ts +65 -0
- package/src/tests/credential-outcome-report.test.ts +81 -1
- package/src/tests/db-client.test.ts +22 -0
- package/src/tests/db-retention-defaults.test.ts +244 -0
- package/src/tests/db-retention.test.ts +2 -1
- package/src/tests/db-runtime.test.ts +2 -1
- package/src/tests/deploy-release-dispatch.test.ts +332 -0
- package/src/tests/e2b-stack-wizard.test.tsx +156 -0
- package/src/tests/entrypoint-chown-no-follow.test.ts +69 -0
- package/src/tests/entrypoint-repo-clone-target.test.ts +112 -0
- package/src/tests/env-flag.test.ts +4 -2
- package/src/tests/event-loop-lag.test.ts +12 -18
- package/src/tests/extensions-example-slack-reply-gate.test.ts +15 -0
- package/src/tests/fixtures/base-prompt-baseline-cases.ts +78 -0
- package/src/tests/fixtures/base-prompt-baseline.json +18 -0
- package/src/tests/github-app-worker-auth-helper.test.ts +325 -0
- package/src/tests/github-installation-token-route.test.ts +199 -0
- package/src/tests/mcp-user-events.test.ts +708 -0
- package/src/tests/memory-key-paths.test.ts +4 -1
- package/src/tests/memory-search-stall.test.ts +421 -0
- package/src/tests/migration-322-runtime-pool-workspace.test.ts +116 -0
- package/src/tests/migration-329-workflow-run-retention.test.ts +32 -0
- package/src/tests/model-profile-fallbacks.test.ts +236 -2
- package/src/tests/opencode-adapter.test.ts +86 -0
- package/src/tests/pi-mono-extension.test.ts +168 -0
- package/src/tests/preload-env.test.ts +61 -1
- package/src/tests/preload.ts +22 -0
- package/src/tests/prompt-template-resolver.test.ts +85 -0
- package/src/tests/reload-config.test.ts +45 -0
- package/src/tests/request-composition.test.ts +447 -0
- package/src/tests/runner-max-concurrent.test.ts +86 -0
- package/src/tests/runtime-pools-db.test.ts +80 -0
- package/src/tests/runtime-provider-registration.test.ts +8 -0
- package/src/tests/runtime-providers-docker.test.ts +192 -1
- package/src/tests/runtime-providers-k8s.test.ts +127 -0
- package/src/tests/runtime-remote-controller.test.ts +64 -1
- package/src/tests/runtime-supervisor.test.ts +101 -0
- package/src/tests/script-connections.test.ts +8 -0
- package/src/tests/slack-blocks.test.ts +18 -0
- package/src/tests/slack-empty-icon-config.test.ts +113 -0
- package/src/tests/slack-reaction-config.test.ts +38 -2
- package/src/tests/slack-render-v2-query-plans.test.ts +100 -1
- package/src/tests/slack-render-v2-reconcile.test.ts +75 -4
- package/src/tests/slack-render-v2.test.ts +683 -11
- package/src/tests/swarm-config-reserved-keys.test.ts +1 -0
- package/src/tests/task-session-prompts.test.ts +37 -0
- package/src/tests/user-delete-perf.test.ts +36 -9
- package/src/tests/webhook-filter.test.ts +327 -0
- package/src/tests/workflow-async-v2.test.ts +19 -16
- package/src/tests/workflow-definition-telemetry.test.ts +15 -5
- package/src/tests/workflow-e2e.test.ts +1 -9
- package/src/tests/workflow-finalization-races.test.ts +553 -0
- package/src/tests/workflow-foreach.test.ts +2 -0
- package/src/tests/workflow-hitl-routing.test.ts +26 -20
- package/src/tests/workflow-http-v2.test.ts +105 -2
- package/src/tests/workflow-idempotency.test.ts +41 -0
- package/src/tests/workflow-mcp-webhook-filter.test.ts +214 -0
- package/src/tests/workflow-parallel-park.test.ts +297 -0
- package/src/tests/workflow-retry-v2.test.ts +57 -21
- package/src/tests/workflow-retry-validation.test.ts +13 -13
- package/src/tests/workflow-runs-retention.test.ts +533 -0
- package/src/tests/workflow-script-principal.test.ts +7 -2
- package/src/tests/workflow-tla-races.test.ts +7 -2
- package/src/tests/workflow-triggers-v2.test.ts +201 -0
- package/src/tests/workflow-wait-builtin-events.test.ts +3 -1
- package/src/tests/workflow-wait-event.test.ts +28 -2
- package/src/tests/workflow-wait-poller.test.ts +94 -0
- package/src/tests/workflow-wait-time.test.ts +7 -3
- package/src/tests/workflow-wait.test.ts +26 -0
- package/src/tests/workflow-wait.ts +44 -0
- package/src/tools/workflows/create-workflow.ts +7 -3
- package/src/tools/workflows/update-workflow.ts +7 -3
- package/src/types.ts +200 -2
- package/src/utils/credentials.ts +7 -0
- package/src/workflows/checkpoint.ts +18 -0
- package/src/workflows/engine.ts +38 -10
- package/src/workflows/foreach-driver.ts +42 -4
- package/src/workflows/recovery.ts +6 -1
- package/src/workflows/resume.ts +11 -3
- package/src/workflows/retry-poller.ts +17 -4
- package/src/workflows/successor-routing.ts +108 -0
- package/src/workflows/task-step-routing.ts +5 -2
- package/src/workflows/triggers.ts +21 -36
- package/src/workflows/wait-poller.ts +6 -2
- package/src/workflows/webhook-filter.ts +203 -0
- package/templates/extensions/slack-reply-gate/hooks.ts +8 -4
- package/templates/skills/swarm-docs/content.md +2 -0
- package/dist/acp-adapter-bht22g3k.js +0 -16
- package/dist/fx-adapter-adtdb3jb.js +0 -19
- package/dist/grok-adapter-accnn9km.js +0 -19
- package/dist/handlers-1x77561e.js +0 -35
- package/dist/index-48qzcqzj.js +0 -35
- package/dist/index-rkvaambe.js +0 -36
- package/dist/index-xj1mq27m.js +0 -40
- package/dist/lead-enzn86bz.js +0 -74
- package/dist/thread-buffer-3x93yexa.js +0 -38
- package/dist/worker-zfcv2wbf.js +0 -74
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
scrubSecrets,
|
|
3
3
|
init_secret_scrubber
|
|
4
|
-
} from "./cli-
|
|
4
|
+
} from "./cli-7e8sxqv5.js";
|
|
5
5
|
|
|
6
6
|
// src/providers/runtime-dependencies.ts
|
|
7
7
|
init_secret_scrubber();
|
|
@@ -51,7 +51,7 @@ async function validateProviderDependencies(provider, config, dependencies = pro
|
|
|
51
51
|
};
|
|
52
52
|
switch (provider) {
|
|
53
53
|
case "claude": {
|
|
54
|
-
const { resolveClaudeBinaryArgv, withClaudeRouteEnv } = await import("./claude-adapter-
|
|
54
|
+
const { resolveClaudeBinaryArgv, withClaudeRouteEnv } = await import("./claude-adapter-0c0y8fqp.js");
|
|
55
55
|
const sourceEnv = withClaudeRouteEnv(env);
|
|
56
56
|
const { argv, useClaudeBridge } = resolveClaudeBinaryArgv(sourceEnv);
|
|
57
57
|
requireExecutable(argv[0], useClaudeBridge ? "Use worker-full or install @desplega.ai/claude-bridge during image provisioning." : "Install Claude Code or set CLAUDE_BINARY to a trusted executable on the worker.", sourceEnv);
|
|
@@ -69,7 +69,7 @@ async function validateProviderDependencies(provider, config, dependencies = pro
|
|
|
69
69
|
case "grok":
|
|
70
70
|
case "fx":
|
|
71
71
|
case "acp": {
|
|
72
|
-
const { resolveAcpTarget, grokTargetProfile, fxTargetProfile } = await import("./acp-targets-
|
|
72
|
+
const { resolveAcpTarget, grokTargetProfile, fxTargetProfile } = await import("./acp-targets-5wyy2b9m.js");
|
|
73
73
|
const target = provider === "grok" ? grokTargetProfile : provider === "fx" ? fxTargetProfile : resolveAcpTarget(config);
|
|
74
74
|
const hint = provider === "grok" ? "Use worker-full, install @xai-official/grok@1.0.77, or set GROK_BINARY to a trusted executable." : provider === "fx" ? "Use worker-full, install the pinned fx release (Dockerfile.worker FX_VERSION), or set FX_BINARY." : `ACP_TARGET='${target.target}'. ${acpInstallHints[target.target]}`;
|
|
75
75
|
requireExecutable(target.command(config)[0], hint, target.env(config));
|
|
@@ -35,15 +35,15 @@ import {
|
|
|
35
35
|
getPendingWaitsByEvent2,
|
|
36
36
|
resolveWaitState2,
|
|
37
37
|
init_db4
|
|
38
|
-
} from "./cli-
|
|
38
|
+
} from "./cli-zhn4r1rz.js";
|
|
39
39
|
import {
|
|
40
40
|
workflowEventBus2,
|
|
41
41
|
init_event_bus
|
|
42
|
-
} from "./cli-
|
|
42
|
+
} from "./cli-thd3005a.js";
|
|
43
43
|
import {
|
|
44
44
|
postApprovalCancellationUpdates2,
|
|
45
45
|
init_approval_notifications
|
|
46
|
-
} from "./cli-
|
|
46
|
+
} from "./cli-raqw9fw9.js";
|
|
47
47
|
import {
|
|
48
48
|
BaseExecutor,
|
|
49
49
|
init_base,
|
|
@@ -61,6 +61,9 @@ import {
|
|
|
61
61
|
findWorkflowReadinessProblems,
|
|
62
62
|
formatReadinessProblems,
|
|
63
63
|
init_readiness,
|
|
64
|
+
hasOwedSuccessors,
|
|
65
|
+
claimAndOweWalk,
|
|
66
|
+
init_successor_routing,
|
|
64
67
|
startWorkflowExecution2,
|
|
65
68
|
ParentStepNotCurrentError,
|
|
66
69
|
failRunOnUnreadableReplay,
|
|
@@ -82,15 +85,15 @@ import {
|
|
|
82
85
|
getNextTargets,
|
|
83
86
|
getSuccessors,
|
|
84
87
|
init_definition2
|
|
85
|
-
} from "./cli-
|
|
88
|
+
} from "./cli-m00c47q6.js";
|
|
86
89
|
import {
|
|
87
90
|
RetryPolicySchema,
|
|
88
91
|
SUPERSEDED_WORKFLOW_TASK_REASON,
|
|
89
92
|
init_types5
|
|
90
|
-
} from "./cli-
|
|
93
|
+
} from "./cli-1h4njv9y.js";
|
|
91
94
|
import {
|
|
92
95
|
init_zod
|
|
93
|
-
} from "./cli-
|
|
96
|
+
} from "./cli-96234j5w.js";
|
|
94
97
|
import {
|
|
95
98
|
string2,
|
|
96
99
|
number2,
|
|
@@ -101,11 +104,11 @@ import {
|
|
|
101
104
|
record2,
|
|
102
105
|
_enum2,
|
|
103
106
|
literal2
|
|
104
|
-
} from "./cli-
|
|
107
|
+
} from "./cli-qrzq3hvg.js";
|
|
105
108
|
import {
|
|
106
109
|
scrubSecrets,
|
|
107
110
|
init_secret_scrubber
|
|
108
|
-
} from "./cli-
|
|
111
|
+
} from "./cli-7e8sxqv5.js";
|
|
109
112
|
import {
|
|
110
113
|
__esm
|
|
111
114
|
} from "./cli-242037k3.js";
|
|
@@ -573,7 +576,7 @@ function toRoutingResult(settle) {
|
|
|
573
576
|
};
|
|
574
577
|
}
|
|
575
578
|
async function checkpointPortStepAndResolveSuccessors(def, runId, stepId, nodeId, output, nextPort, ctx, registry) {
|
|
576
|
-
return await
|
|
579
|
+
return await claimAndOweWalk(runId, async () => {
|
|
577
580
|
const current = await getWorkflowRunStep2(stepId);
|
|
578
581
|
if (!current || current.status !== "waiting")
|
|
579
582
|
return UNCLAIMED;
|
|
@@ -644,7 +647,7 @@ async function isSupersedeCut(taskId, reason) {
|
|
|
644
647
|
return task?.failureReason === SUPERSEDED_WORKFLOW_TASK_REASON;
|
|
645
648
|
}
|
|
646
649
|
async function completeTaskStepAndResolveSuccessors(def, runId, step, output, ctx, failureReason, ownerTaskId, registry) {
|
|
647
|
-
return await
|
|
650
|
+
return await claimAndOweWalk(runId, async () => {
|
|
648
651
|
const current = await getWorkflowRunStep2(step.id);
|
|
649
652
|
if (!current || current.status !== "waiting")
|
|
650
653
|
return UNCLAIMED;
|
|
@@ -686,6 +689,7 @@ var init_task_step_routing = __esm(() => {
|
|
|
686
689
|
init_definition2();
|
|
687
690
|
init_foreach_body();
|
|
688
691
|
init_foreach_join();
|
|
692
|
+
init_successor_routing();
|
|
689
693
|
UNCLAIMED = {
|
|
690
694
|
claimed: false,
|
|
691
695
|
foreachChild: false,
|
|
@@ -827,7 +831,7 @@ async function resumeFromTaskCompletionUnguarded(event, registry) {
|
|
|
827
831
|
const successors = routing.successors;
|
|
828
832
|
if (successors.length > 0) {
|
|
829
833
|
const secretKeys = getSecretInputKeys(workflow.input);
|
|
830
|
-
await walkGraph(workflow.definition, run.id, ctx, successors, registry, workflow.id, secretKeys);
|
|
834
|
+
await walkGraph(workflow.definition, run.id, ctx, successors, registry, workflow.id, secretKeys, { successorDebt: routing.successorDebt });
|
|
831
835
|
} else {
|
|
832
836
|
await finalizeOrWait2(run.id);
|
|
833
837
|
}
|
|
@@ -840,7 +844,7 @@ async function finalizeOrWait2(runId) {
|
|
|
840
844
|
if (await getRunLineageBlock(runId))
|
|
841
845
|
return;
|
|
842
846
|
const steps = await getWorkflowRunStepsByRunId2(runId);
|
|
843
|
-
if (hasRunningStep(steps)) {
|
|
847
|
+
if (hasRunningStep(steps) || hasOwedSuccessors(runId)) {
|
|
844
848
|
if (status === "waiting")
|
|
845
849
|
await updateWorkflowRun2(runId, { status: "running" });
|
|
846
850
|
return;
|
|
@@ -903,7 +907,7 @@ async function handleTaskFailureUnguarded(event, reason, registry, options) {
|
|
|
903
907
|
const successors = routing.successors;
|
|
904
908
|
if (successors.length > 0) {
|
|
905
909
|
const secretKeys = getSecretInputKeys(workflow.input);
|
|
906
|
-
await walkGraph(workflow.definition, run.id, ctx, successors, registry, workflow.id, secretKeys);
|
|
910
|
+
await walkGraph(workflow.definition, run.id, ctx, successors, registry, workflow.id, secretKeys, { successorDebt: routing.successorDebt });
|
|
907
911
|
} else {
|
|
908
912
|
await finalizeOrWait2(run.id);
|
|
909
913
|
}
|
|
@@ -1135,7 +1139,7 @@ async function resumeFromApprovalResolutionUnguarded(event, registry) {
|
|
|
1135
1139
|
const successors = routing.successors;
|
|
1136
1140
|
if (successors.length > 0) {
|
|
1137
1141
|
const secretKeys = getSecretInputKeys(workflow.input);
|
|
1138
|
-
await walkGraph(workflow.definition, run.id, ctx, successors, registry, workflow.id, secretKeys);
|
|
1142
|
+
await walkGraph(workflow.definition, run.id, ctx, successors, registry, workflow.id, secretKeys, { successorDebt: routing.successorDebt });
|
|
1139
1143
|
} else {
|
|
1140
1144
|
await finalizeOrWait2(run.id);
|
|
1141
1145
|
}
|
|
@@ -1184,7 +1188,7 @@ async function resumeClaimedWait(waitRow, status, cappedPayload, registry) {
|
|
|
1184
1188
|
const successors = routing.successors;
|
|
1185
1189
|
if (successors.length > 0) {
|
|
1186
1190
|
const secretKeys = getSecretInputKeys(workflow.input);
|
|
1187
|
-
await walkGraph(workflow.definition, run.id, ctx, successors, registry, workflow.id, secretKeys);
|
|
1191
|
+
await walkGraph(workflow.definition, run.id, ctx, successors, registry, workflow.id, secretKeys, { successorDebt: routing.successorDebt });
|
|
1188
1192
|
} else {
|
|
1189
1193
|
await finalizeOrWait2(run.id);
|
|
1190
1194
|
}
|
|
@@ -1235,7 +1239,7 @@ async function resumeFromChildRun2(parentStepId, registry) {
|
|
|
1235
1239
|
claimed = true;
|
|
1236
1240
|
if (routing.successors.length > 0) {
|
|
1237
1241
|
const secretKeys = getSecretInputKeys(workflow.input);
|
|
1238
|
-
await walkGraph(workflow.definition, run.id, ctx, routing.successors, registry, workflow.id, secretKeys);
|
|
1242
|
+
await walkGraph(workflow.definition, run.id, ctx, routing.successors, registry, workflow.id, secretKeys, { successorDebt: routing.successorDebt });
|
|
1239
1243
|
} else {
|
|
1240
1244
|
await finalizeOrWait2(run.id);
|
|
1241
1245
|
}
|
|
@@ -1379,6 +1383,7 @@ var init_resume = __esm(() => {
|
|
|
1379
1383
|
init_input();
|
|
1380
1384
|
init_limits();
|
|
1381
1385
|
init_readiness();
|
|
1386
|
+
init_successor_routing();
|
|
1382
1387
|
init_task_step_routing();
|
|
1383
1388
|
init_wait_filter();
|
|
1384
1389
|
TERMINAL_RUN_STATUSES = new Set(["completed", "failed", "cancelled", "skipped"]);
|
|
@@ -1386,7 +1391,8 @@ var init_resume = __esm(() => {
|
|
|
1386
1391
|
CHILD_RETRY_SCHEDULED = {
|
|
1387
1392
|
claimed: true,
|
|
1388
1393
|
runFailed: false,
|
|
1389
|
-
successors: []
|
|
1394
|
+
successors: [],
|
|
1395
|
+
successorDebt: undefined
|
|
1390
1396
|
};
|
|
1391
1397
|
FIRED_PAYLOAD_BYTE_CAP = 64 * 1024;
|
|
1392
1398
|
waitsByEvent = new Map;
|
|
@@ -6,7 +6,10 @@ import {
|
|
|
6
6
|
function poolCacheKey(poolId, generation) {
|
|
7
7
|
return `swarm-cache-${poolId}${generation ? `-${generation}` : ""}`;
|
|
8
8
|
}
|
|
9
|
-
|
|
9
|
+
function workspaceVolumeKey(agentId, slot) {
|
|
10
|
+
return `swarm-ws-${agentId.toLowerCase()}-${slot}`;
|
|
11
|
+
}
|
|
12
|
+
var WORKSPACE_MOUNT_PATH = "/workspace/personal", RUNTIME_LABELS, WORKSPACE_LABEL = "swarm.workspace";
|
|
10
13
|
var init_types4 = __esm(() => {
|
|
11
14
|
RUNTIME_LABELS = {
|
|
12
15
|
owner: "swarm.owner",
|
|
@@ -16,4 +19,4 @@ var init_types4 = __esm(() => {
|
|
|
16
19
|
};
|
|
17
20
|
});
|
|
18
21
|
|
|
19
|
-
export { poolCacheKey, RUNTIME_LABELS, init_types4 };
|
|
22
|
+
export { poolCacheKey, WORKSPACE_MOUNT_PATH, workspaceVolumeKey, RUNTIME_LABELS, WORKSPACE_LABEL, init_types4 };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
exports_zod,
|
|
3
3
|
init_zod
|
|
4
|
-
} from "./cli-
|
|
4
|
+
} from "./cli-96234j5w.js";
|
|
5
5
|
import {
|
|
6
6
|
string2,
|
|
7
7
|
uuid,
|
|
@@ -21,7 +21,7 @@ import {
|
|
|
21
21
|
lazy,
|
|
22
22
|
ZodIssueCode,
|
|
23
23
|
exports_iso
|
|
24
|
-
} from "./cli-
|
|
24
|
+
} from "./cli-qrzq3hvg.js";
|
|
25
25
|
import {
|
|
26
26
|
MAX_PROFILE_FILE_LENGTH,
|
|
27
27
|
init_constants3
|
|
@@ -2158,6 +2158,33 @@ function resolveTaskModelSelection(opts) {
|
|
|
2158
2158
|
function isTerminalTaskStatus(status) {
|
|
2159
2159
|
return TERMINAL_TASK_STATUSES.includes(status);
|
|
2160
2160
|
}
|
|
2161
|
+
function hasControlCharacter(value) {
|
|
2162
|
+
for (let i = 0;i < value.length; i++) {
|
|
2163
|
+
const code = value.charCodeAt(i);
|
|
2164
|
+
if (code <= 31 || code === 127)
|
|
2165
|
+
return true;
|
|
2166
|
+
}
|
|
2167
|
+
return false;
|
|
2168
|
+
}
|
|
2169
|
+
function webhookBodyPathIssue(path) {
|
|
2170
|
+
if (path.length > WEBHOOK_FILTER_MAX_PATH) {
|
|
2171
|
+
return `body path is longer than ${WEBHOOK_FILTER_MAX_PATH} characters`;
|
|
2172
|
+
}
|
|
2173
|
+
const segments = path.split(".");
|
|
2174
|
+
if (segments.length > WEBHOOK_FILTER_MAX_SEGMENTS) {
|
|
2175
|
+
return `body path has more than ${WEBHOOK_FILTER_MAX_SEGMENTS} segments`;
|
|
2176
|
+
}
|
|
2177
|
+
for (const segment of segments) {
|
|
2178
|
+
if (segment.length === 0)
|
|
2179
|
+
return "body path has an empty segment";
|
|
2180
|
+
if (segment.length > WEBHOOK_FILTER_MAX_SEGMENT) {
|
|
2181
|
+
return `body path segment is longer than ${WEBHOOK_FILTER_MAX_SEGMENT} characters`;
|
|
2182
|
+
}
|
|
2183
|
+
if (hasControlCharacter(segment))
|
|
2184
|
+
return "body path segment has a control character";
|
|
2185
|
+
}
|
|
2186
|
+
return null;
|
|
2187
|
+
}
|
|
2161
2188
|
function checkExtensionInstallSource(body, ctx) {
|
|
2162
2189
|
const inline = body.manifest !== undefined || body.files !== undefined;
|
|
2163
2190
|
if (body.template !== undefined && inline) {
|
|
@@ -2177,7 +2204,7 @@ function checkExtensionInstallSource(body, ctx) {
|
|
|
2177
2204
|
ctx.addIssue({ code: "custom", path: ["files"], message: "files is required with manifest" });
|
|
2178
2205
|
}
|
|
2179
2206
|
}
|
|
2180
|
-
var AssetKeySchema, AssetEntityTypeSchema, AssetProviderRefSchema, AssetKeyMappingSchema, AssetSummarySchema, ModelTierSchema, MODEL_TIERS, ReasoningEffortSchema, LEGACY_MODEL_TO_TIER, DEFAULT_MODEL_TIER_MAP, AgentTaskStatusSchema, TERMINAL_TASK_STATUSES, OPEN_TASK_STATUSES, InboxMessageStatusSchema, InboxMessageSchema, AgentTaskSourceSchema, RoutingReasonSchema, RoutingSourceSchema, ProviderNameSchema, ModelProfileNameSchema, ModelProfileCredentialsSchema, ModelProfileSchema, ModelGroupSchema, ProviderErrorClassSchema, FallbackHopSchema, ProfileCheckStateSchema, ProfileCheckRowSchema, ProfileCheckResultSchema, SessionShareAccessSchema, SessionAccessSchema, SessionOwnerSchema, SessionSharesSchema, SessionSharesUpdateSchema, SteerModeSchema, SteeringStatusSchema, SteeringSourceSchema, SteeringMessageSchema, SteerOutcomeSchema, OnUnsupportedSchema, SteerResultSchema, PROVIDER_STEER_CAPABILITIES, FollowUpConfigSchema, RoutingAffinitySchema, SlackParticipantTrustSchema, TaskSlackParticipantSchema, TaskSlackParticipantsSchema, AgentTaskSchema, CreateTaskOptionsSchema, TaskAttachmentKindSchema, SERVER_GENERATED_ATTACHMENT_CAPABILITY = "_agentSwarmGeneratedBy", attachmentCapabilitiesSchema, attachmentCommonFields, AttachmentInputSchema, TaskAttachmentSchema, UserSchema, UserMergeJobStatusSchema, UserMergeJobSchema, RbacRoleSchema, UserRbacRolesSchema, UserCommsPrefsSchema, IdentityEventTypeSchema, InboxItemTypeSchema, InboxItemStatusSchema, InboxItemStateSchema, ChecklistItemSchema, FavoriteItemTypeSchema, UserFavoriteSchema, TaskTemplateKindSchema, TaskTemplateSchema, AgentStatusSchema, HttpsImageUrlSchema, LucideIconSchema, UrlIconSchema, AgentFsIconSchema, MediaIconSchema, AgentAvatarSchema, AppIconSchema, AgentSlackIconSchema, AgentSchema, AgentCredStatusKeyResultSchema, AgentCredStatusLiveTestSchema, AgentLatestModelSchema, AgentBedrockStatusSchema, AgentOpencodeGoStatusSchema, AcpSessionConfigSelectValueSchema, AcpSessionConfigSelectGroupSchema, AcpSessionConfigOptionSchema, AgentAcpStatusSchema, AgentCredStatusSchema, AgentWithTasksSchema, ChangeSourceSchema, VersionableFieldSchema, ContextVersionSchema, ChannelTypeSchema, ChannelSchema, ChannelMessageSchema, ServiceStatusSchema, ServiceSchema, AgentLogEventTypeSchema, ResumeReasonSchema, AgentLogSchema, SessionLogSchema, SessionCostSourceSchema, SessionCostKindSchema, SessionCostModelBreakdownSchema, SessionCostSchema, EventCategorySchema, EventStatusSchema, EventSourceSchema, EventNameSchema, SwarmEventSchema, AutomationIntegrationIdSchema, ScheduledTaskTargetTypeSchema, ScheduledTaskSchema, SwarmConfigScopeSchema, SwarmConfigSchema, RepoGuidelinesSchema, REPO_GUIDELINES_MAX_ENTRIES = 50, RepoGuidelinesInputSchema, RepoHooksSchema, SwarmRepoSchema, AgentMemoryScopeSchema, AgentMemorySourceSchema, AgentMemorySchema, ActiveSessionSchema, WorkerNudgeSchema, RuntimeInstanceStatusSchema, RuntimeProviderKindSchema, DeliveryModeSchema, PoolLifecycleSchema, RuntimeResourcesSchema, RuntimeControllerCreateSchema, RuntimeControllerUpdateSchema, RuntimeControllerSchema, RuntimePoolCacheSchema, RuntimePoolCreateSchema, RuntimePoolUpdateSchema, RuntimePoolSchema, RuntimePoolCreateAgentSchema, RuntimeInstanceSchema, RetryPolicySchema, SUPERSEDED_WORKFLOW_TASK_REASON = "superseded_workflow_task", ExecutorMetaSchema, ValidationResultSchema, StepValidationConfigSchema, SwarmScriptNodeConfigSchema, WorkflowNodeSchema, WorkflowEdgeSchema, WorkflowDefinitionSchema, WorkflowNodePatchSchema, WorkflowPatchSchema, WebhookVerificationSchema, TriggerConfigSchema, CooldownConfigSchema, InputValueSchema, WorkflowTemplateSchema, WorkflowSnapshotSchema, WorkflowSchema, WorkflowVersionSchema, PageContentTypeSchema, PageAuthModeSchema, PageThemeTokensSchema, PageThemeTokensInputSchema, PageSnapshotSchema, PageSchema, PageVersionSchema, MetricParamSchema, MetricVariableTypeSchema, MetricFormatSchema, MetricVisualizationSchema, MetricQuerySchema, MetricVariableSchema, MetricVizConfigSchema, MetricWidgetSchema, MetricDefinitionSchema, MetricSnapshotSchema, MetricSchema, MetricVersionSchema, WorkflowRunStatusSchema, WorkflowRunSchema, WorkflowRunParentSchema, WorkflowRunSummarySchema, ScriptRunStatusSchema, TERMINAL_SCRIPT_RUN_STATUSES, ScriptRunKindSchema, ScriptRunSchema, ScriptRunListItemSchema, ScriptRunJournalEntrySchema, WorkflowRunStepStatusSchema, WorkflowRunStepSchema, WorkflowRunStepSlimSchema, WaitModeSchema, WaitStateStatusSchema, WaitStateRowSchema, PromptTemplateScopeSchema, PromptTemplateStateSchema, PromptTemplateSchema, PromptTemplateHistorySchema, ScriptScopeSchema, ScriptFsModeSchema, ScriptExecutorNameSchema, ScriptRecordSchema, ScriptVersionRecordSchema, ExtensionNameSchema, SemverSchema, ExtensionBundlePathSchema, ExtensionAssetNameSchema, ExtensionScriptAssetSchema, ExtensionScheduleAssetSchema, ExtensionWorkflowAssetSchema, ExtensionSkillAssetSchema, ExtensionWorkflowFileSchema, ExtensionManifestSchema, ExtensionStatusSchema, ExtensionSchema, ExtensionFileSchema, ExtensionVersionSchema, ExtensionRunSchema, ExtensionInstallBodySchema, ScriptApiAuthModeSchema, ScriptApiRecordSchema, SkillTypeSchema, SkillScopeSchema, SkillSchema, AgentSkillSchema, SkillWithInstallInfoSchema, SkillFileSchema, McpServerTransportSchema, McpServerScopeSchema, McpAuthMethodSchema, McpServerSchema, AgentMcpServerSchema, McpServerWithInstallInfoSchema, ContextSnapshotEventTypeSchema, ContextFormulaSchema, ContextSnapshotSchema, BudgetScopeSchema, BudgetSchema, PricingProviderSchema, PricingTokenClassSchema, PricingRowSchema, BudgetRefusalCauseSchema, BudgetRefusalNotificationSchema, BudgetRefusedTriggerSchema, KvValueTypeSchema, KV_NAME_REGEX, KvNamespaceSchema, KvKeySchema, KvEntrySchema;
|
|
2207
|
+
var AssetKeySchema, AssetEntityTypeSchema, AssetProviderRefSchema, AssetKeyMappingSchema, AssetSummarySchema, ModelTierSchema, MODEL_TIERS, ReasoningEffortSchema, LEGACY_MODEL_TO_TIER, DEFAULT_MODEL_TIER_MAP, AgentTaskStatusSchema, TERMINAL_TASK_STATUSES, OPEN_TASK_STATUSES, InboxMessageStatusSchema, InboxMessageSchema, AgentTaskSourceSchema, RoutingReasonSchema, RoutingSourceSchema, ProviderNameSchema, ModelProfileNameSchema, ModelProfileCredentialsSchema, ModelProfileSchema, ModelGroupSchema, ProviderErrorClassSchema, FallbackHopSchema, ProfileCheckStateSchema, ProfileCheckRowSchema, ProfileCheckResultSchema, SessionShareAccessSchema, SessionAccessSchema, SessionOwnerSchema, SessionSharesSchema, SessionSharesUpdateSchema, SteerModeSchema, SteeringStatusSchema, SteeringSourceSchema, SteeringMessageSchema, SteerOutcomeSchema, OnUnsupportedSchema, SteerResultSchema, PROVIDER_STEER_CAPABILITIES, FollowUpConfigSchema, RoutingAffinitySchema, SlackParticipantTrustSchema, TaskSlackParticipantSchema, TaskSlackParticipantsSchema, AgentTaskSchema, CreateTaskOptionsSchema, TaskAttachmentKindSchema, SERVER_GENERATED_ATTACHMENT_CAPABILITY = "_agentSwarmGeneratedBy", attachmentCapabilitiesSchema, attachmentCommonFields, AttachmentInputSchema, TaskAttachmentSchema, UserSchema, UserMergeJobStatusSchema, UserMergeJobSchema, RbacRoleSchema, UserRbacRolesSchema, UserCommsPrefsSchema, IdentityEventTypeSchema, InboxItemTypeSchema, InboxItemStatusSchema, InboxItemStateSchema, ChecklistItemSchema, FavoriteItemTypeSchema, UserFavoriteSchema, TaskTemplateKindSchema, TaskTemplateSchema, AgentStatusSchema, HttpsImageUrlSchema, LucideIconSchema, UrlIconSchema, AgentFsIconSchema, MediaIconSchema, AgentAvatarSchema, AppIconSchema, AgentSlackIconSchema, AgentSchema, AgentCredStatusKeyResultSchema, AgentCredStatusLiveTestSchema, AgentLatestModelSchema, AgentBedrockStatusSchema, AgentOpencodeGoStatusSchema, AcpSessionConfigSelectValueSchema, AcpSessionConfigSelectGroupSchema, AcpSessionConfigOptionSchema, AgentAcpStatusSchema, AgentCredStatusSchema, AgentWithTasksSchema, ChangeSourceSchema, VersionableFieldSchema, ContextVersionSchema, ChannelTypeSchema, ChannelSchema, ChannelMessageSchema, ServiceStatusSchema, ServiceSchema, AgentLogEventTypeSchema, ResumeReasonSchema, AgentLogSchema, SessionLogSchema, SessionCostSourceSchema, SessionCostKindSchema, SessionCostModelBreakdownSchema, SessionCostSchema, EventCategorySchema, EventStatusSchema, EventSourceSchema, EventNameSchema, SwarmEventSchema, AutomationIntegrationIdSchema, ScheduledTaskTargetTypeSchema, ScheduledTaskSchema, SwarmConfigScopeSchema, SwarmConfigSchema, RepoGuidelinesSchema, REPO_GUIDELINES_MAX_ENTRIES = 50, RepoGuidelinesInputSchema, RepoHooksSchema, SwarmRepoSchema, AgentMemoryScopeSchema, AgentMemorySourceSchema, AgentMemorySchema, ActiveSessionSchema, WorkerNudgeSchema, RuntimeInstanceStatusSchema, RuntimeProviderKindSchema, DeliveryModeSchema, PoolLifecycleSchema, RuntimeResourcesSchema, RuntimeControllerCreateSchema, RuntimeControllerUpdateSchema, RuntimeControllerSchema, RuntimePoolCacheSchema, RuntimePoolWorkspaceSchema, RuntimePoolCreateSchema, RuntimePoolUpdateSchema, RuntimePoolSchema, RuntimePoolCreateAgentSchema, RuntimeInstanceSchema, RetryPolicySchema, SUPERSEDED_WORKFLOW_TASK_REASON = "superseded_workflow_task", ExecutorMetaSchema, ValidationResultSchema, StepValidationConfigSchema, SwarmScriptNodeConfigSchema, WorkflowNodeSchema, WorkflowEdgeSchema, WorkflowDefinitionSchema, WorkflowNodePatchSchema, WorkflowPatchSchema, WebhookVerificationSchema, WEBHOOK_FILTER_MAX_FIELDS = 32, WEBHOOK_FILTER_MAX_VALUES = 64, WEBHOOK_FILTER_MAX_STRING = 512, WEBHOOK_FILTER_MAX_HEADER_NAME = 128, WEBHOOK_FILTER_MAX_PATH = 256, WEBHOOK_FILTER_MAX_SEGMENTS = 12, WEBHOOK_FILTER_MAX_SEGMENT = 128, WEBHOOK_FILTER_HEADER_NAME, WEBHOOK_FILTER_PRESETS, WebhookFilterPresetSchema, webhookFilterHeaderValueSchema, webhookFilterBodyScalarSchema, webhookFilterBodyValueSchema, WebhookDeliveryFilterSchema, TriggerConfigSchema, CooldownConfigSchema, InputValueSchema, WorkflowTemplateSchema, WorkflowSnapshotSchema, WorkflowSchema, WorkflowVersionSchema, PageContentTypeSchema, PageAuthModeSchema, PageThemeTokensSchema, PageThemeTokensInputSchema, PageSnapshotSchema, PageSchema, PageVersionSchema, MetricParamSchema, MetricVariableTypeSchema, MetricFormatSchema, MetricVisualizationSchema, MetricQuerySchema, MetricVariableSchema, MetricVizConfigSchema, MetricWidgetSchema, MetricDefinitionSchema, MetricSnapshotSchema, MetricSchema, MetricVersionSchema, WorkflowRunStatusSchema, WorkflowRunSchema, WorkflowRunParentSchema, WorkflowRunSummarySchema, ScriptRunStatusSchema, TERMINAL_SCRIPT_RUN_STATUSES, ScriptRunKindSchema, ScriptRunSchema, ScriptRunListItemSchema, ScriptRunJournalEntrySchema, WorkflowRunStepStatusSchema, WorkflowRunStepSchema, WorkflowRunStepSlimSchema, WaitModeSchema, WaitStateStatusSchema, WaitStateRowSchema, PromptTemplateScopeSchema, PromptTemplateStateSchema, PromptTemplateSchema, PromptTemplateHistorySchema, ScriptScopeSchema, ScriptFsModeSchema, ScriptExecutorNameSchema, ScriptRecordSchema, ScriptVersionRecordSchema, ExtensionNameSchema, SemverSchema, ExtensionBundlePathSchema, ExtensionAssetNameSchema, ExtensionScriptAssetSchema, ExtensionScheduleAssetSchema, ExtensionWorkflowAssetSchema, ExtensionSkillAssetSchema, ExtensionWorkflowFileSchema, ExtensionManifestSchema, ExtensionStatusSchema, ExtensionSchema, ExtensionFileSchema, ExtensionVersionSchema, ExtensionRunSchema, ExtensionInstallBodySchema, ScriptApiAuthModeSchema, ScriptApiRecordSchema, SkillTypeSchema, SkillScopeSchema, SkillSchema, AgentSkillSchema, SkillWithInstallInfoSchema, SkillFileSchema, McpServerTransportSchema, McpServerScopeSchema, McpAuthMethodSchema, McpServerSchema, AgentMcpServerSchema, McpServerWithInstallInfoSchema, ContextSnapshotEventTypeSchema, ContextFormulaSchema, ContextSnapshotSchema, RequestCompositionPartKindSchema, RequestCompositionFidelitySchema, RequestCompositionPartInputSchema, RequestCompositionPartSchema, RequestCompositionToolLoadingSchema, RequestCompositionSchema, BudgetScopeSchema, BudgetSchema, PricingProviderSchema, PricingTokenClassSchema, PricingRowSchema, BudgetRefusalCauseSchema, BudgetRefusalNotificationSchema, BudgetRefusedTriggerSchema, KvValueTypeSchema, KV_NAME_REGEX, KvNamespaceSchema, KvKeySchema, KvEntrySchema;
|
|
2181
2208
|
var init_types5 = __esm(() => {
|
|
2182
2209
|
init_key();
|
|
2183
2210
|
init_bundle_path();
|
|
@@ -3481,6 +3508,7 @@ var init_types5 = __esm(() => {
|
|
|
3481
3508
|
return path.startsWith("/") && parts.length > 0 && !path.includes("\x00") && !parts.some((part) => part === "." || part === "..") && !protectedPaths.some((protectedPath) => protectedPath === normalized || protectedPath.startsWith(`${normalized}/`) || normalized.startsWith(`${protectedPath}/`));
|
|
3482
3509
|
}, "Cache mountPath must be absolute, without . or .., and must not cover worker homes, workspaces or credential directories")
|
|
3483
3510
|
}).strict();
|
|
3511
|
+
RuntimePoolWorkspaceSchema = object2({ sizeGb: number2().int().min(1).max(1024).optional() }).strict();
|
|
3484
3512
|
RuntimePoolCreateSchema = object2({
|
|
3485
3513
|
name: string2().min(1).max(200),
|
|
3486
3514
|
kind: RuntimeProviderKindSchema,
|
|
@@ -3495,6 +3523,7 @@ var init_types5 = __esm(() => {
|
|
|
3495
3523
|
env: record2(string2(), string2()).default({}),
|
|
3496
3524
|
resources: RuntimeResourcesSchema.nullable().default(null),
|
|
3497
3525
|
cache: RuntimePoolCacheSchema.nullable().default(null),
|
|
3526
|
+
workspace: RuntimePoolWorkspaceSchema.nullable().default(null),
|
|
3498
3527
|
ttlSec: number2().int().positive().nullable().default(null),
|
|
3499
3528
|
enabled: boolean().default(true)
|
|
3500
3529
|
}).strict();
|
|
@@ -3508,6 +3537,7 @@ var init_types5 = __esm(() => {
|
|
|
3508
3537
|
env: record2(string2(), string2()).optional(),
|
|
3509
3538
|
resources: RuntimeResourcesSchema.nullable().optional(),
|
|
3510
3539
|
cache: RuntimePoolCacheSchema.nullable().optional(),
|
|
3540
|
+
workspace: RuntimePoolWorkspaceSchema.nullable().optional(),
|
|
3511
3541
|
ttlSec: number2().int().positive().nullable().optional(),
|
|
3512
3542
|
enabled: boolean().optional()
|
|
3513
3543
|
});
|
|
@@ -3544,6 +3574,7 @@ var init_types5 = __esm(() => {
|
|
|
3544
3574
|
idleSince: string2().nullable().optional(),
|
|
3545
3575
|
leaseExpiresAt: string2().nullable().optional(),
|
|
3546
3576
|
taskId: string2().nullable().optional(),
|
|
3577
|
+
workspaceSlot: number2().int().nullable().optional(),
|
|
3547
3578
|
reportedSlots: number2().int(),
|
|
3548
3579
|
credentialReady: boolean().nullable().optional(),
|
|
3549
3580
|
metadata: record2(string2(), unknown()).nullable(),
|
|
@@ -3642,14 +3673,85 @@ var init_types5 = __esm(() => {
|
|
|
3642
3673
|
toleranceSeconds: number2().int().positive().default(300).describe("Maximum allowed clock skew, in seconds, for the webhook-timestamp header")
|
|
3643
3674
|
})
|
|
3644
3675
|
]);
|
|
3676
|
+
WEBHOOK_FILTER_HEADER_NAME = /^[!#$%&'*+.^_`|~0-9A-Za-z-]+$/;
|
|
3677
|
+
WEBHOOK_FILTER_PRESETS = ["github", "gitlab", "standard-webhooks"];
|
|
3678
|
+
WebhookFilterPresetSchema = _enum2(WEBHOOK_FILTER_PRESETS);
|
|
3679
|
+
webhookFilterHeaderValueSchema = union3([
|
|
3680
|
+
string2().min(1).max(WEBHOOK_FILTER_MAX_STRING),
|
|
3681
|
+
array2(string2().min(1).max(WEBHOOK_FILTER_MAX_STRING)).min(1).max(WEBHOOK_FILTER_MAX_VALUES)
|
|
3682
|
+
]);
|
|
3683
|
+
webhookFilterBodyScalarSchema = union3([
|
|
3684
|
+
string2().max(WEBHOOK_FILTER_MAX_STRING),
|
|
3685
|
+
number2().finite(),
|
|
3686
|
+
boolean(),
|
|
3687
|
+
_null()
|
|
3688
|
+
]);
|
|
3689
|
+
webhookFilterBodyValueSchema = union3([
|
|
3690
|
+
webhookFilterBodyScalarSchema,
|
|
3691
|
+
array2(webhookFilterBodyScalarSchema).min(1).max(WEBHOOK_FILTER_MAX_VALUES)
|
|
3692
|
+
]);
|
|
3693
|
+
WebhookDeliveryFilterSchema = strictObject2({
|
|
3694
|
+
headers: record2(string2().min(1).max(WEBHOOK_FILTER_MAX_HEADER_NAME), webhookFilterHeaderValueSchema).optional().describe("Header name to one exact value, or a list of exact values. Names are matched case-insensitively. Every entry must match."),
|
|
3695
|
+
body: record2(string2().min(1).max(WEBHOOK_FILTER_MAX_PATH), webhookFilterBodyValueSchema).optional().describe("Dot path into the JSON body, to one exact scalar or a list of scalars. A numeric segment indexes an array (commits.0.id). No type coercion. Every entry must match.")
|
|
3696
|
+
}).superRefine((filter, ctx) => {
|
|
3697
|
+
const headerNames = filter.headers ? Object.keys(filter.headers) : [];
|
|
3698
|
+
const bodyPaths = filter.body ? Object.keys(filter.body) : [];
|
|
3699
|
+
if (headerNames.length + bodyPaths.length === 0) {
|
|
3700
|
+
ctx.addIssue({
|
|
3701
|
+
code: "custom",
|
|
3702
|
+
message: "filter needs at least one header or body field"
|
|
3703
|
+
});
|
|
3704
|
+
}
|
|
3705
|
+
if (headerNames.length > WEBHOOK_FILTER_MAX_FIELDS) {
|
|
3706
|
+
ctx.addIssue({
|
|
3707
|
+
code: "custom",
|
|
3708
|
+
message: `filter has more than ${WEBHOOK_FILTER_MAX_FIELDS} headers`,
|
|
3709
|
+
path: ["headers"]
|
|
3710
|
+
});
|
|
3711
|
+
}
|
|
3712
|
+
if (bodyPaths.length > WEBHOOK_FILTER_MAX_FIELDS) {
|
|
3713
|
+
ctx.addIssue({
|
|
3714
|
+
code: "custom",
|
|
3715
|
+
message: `filter has more than ${WEBHOOK_FILTER_MAX_FIELDS} body fields`,
|
|
3716
|
+
path: ["body"]
|
|
3717
|
+
});
|
|
3718
|
+
}
|
|
3719
|
+
const seenHeaders = new Set;
|
|
3720
|
+
for (const name of headerNames) {
|
|
3721
|
+
if (!WEBHOOK_FILTER_HEADER_NAME.test(name)) {
|
|
3722
|
+
ctx.addIssue({
|
|
3723
|
+
code: "custom",
|
|
3724
|
+
message: "header name must be an HTTP token",
|
|
3725
|
+
path: ["headers", name]
|
|
3726
|
+
});
|
|
3727
|
+
}
|
|
3728
|
+
const folded = name.toLowerCase();
|
|
3729
|
+
if (seenHeaders.has(folded)) {
|
|
3730
|
+
ctx.addIssue({
|
|
3731
|
+
code: "custom",
|
|
3732
|
+
message: "duplicate header name",
|
|
3733
|
+
path: ["headers", name]
|
|
3734
|
+
});
|
|
3735
|
+
}
|
|
3736
|
+
seenHeaders.add(folded);
|
|
3737
|
+
}
|
|
3738
|
+
for (const path of bodyPaths) {
|
|
3739
|
+
const issue = webhookBodyPathIssue(path);
|
|
3740
|
+
if (issue) {
|
|
3741
|
+
ctx.addIssue({ code: "custom", message: issue, path: ["body", path] });
|
|
3742
|
+
}
|
|
3743
|
+
}
|
|
3744
|
+
}).describe("AND of header and JSON body allowlists. A delivery that misses is acknowledged with 200 and creates no run.");
|
|
3645
3745
|
TriggerConfigSchema = discriminatedUnion("type", [
|
|
3646
3746
|
object2({
|
|
3647
3747
|
type: literal2("webhook"),
|
|
3648
3748
|
hmacSecret: string2().optional(),
|
|
3649
3749
|
hmacHeader: string2().default("X-Hub-Signature-256").describe("Legacy HMAC header for webhook verification. Prefer verification.header for new workflows."),
|
|
3650
3750
|
verification: WebhookVerificationSchema.optional().describe("Optional webhook verification format. Omit to keep legacy HMAC-SHA256 behavior with fallback header scanning."),
|
|
3651
|
-
events: array2(string2().min(1)).optional().describe("
|
|
3652
|
-
eventHeader: string2().min(1).optional().describe("
|
|
3751
|
+
events: array2(string2().min(1)).optional().describe("Deprecated alias of one delivery-filter clause, AND-ed with filter. Matched exactly against eventHeader, or against the preset event field when eventHeader is omitted: X-GitHub-Event (github, and the default), X-Gitlab-Event (gitlab), or JSON body type (standard-webhooks). A miss returns 200 skipped with reason event-not-allowed and creates no run. Omit or leave empty to add no event clause."),
|
|
3752
|
+
eventHeader: string2().min(1).optional().describe("Deprecated. Header read for events. The name lookup is case-insensitive and the value is exact. Overrides preset. Defaults to X-GitHub-Event when preset is omitted."),
|
|
3753
|
+
preset: WebhookFilterPresetSchema.optional().describe("Optional sender preset for the events allowlist. github reads X-GitHub-Event, gitlab reads X-Gitlab-Event, and standard-webhooks reads the JSON body field type. A preset alone does not filter. Ignored when eventHeader is set."),
|
|
3754
|
+
filter: WebhookDeliveryFilterSchema.optional().describe("Header and JSON body allowlists, AND-ed with events. Evaluated after signature verification and before a run is saved. A miss returns 200 skipped with reason filter-not-matched and creates no run.")
|
|
3653
3755
|
}),
|
|
3654
3756
|
object2({
|
|
3655
3757
|
type: literal2("schedule"),
|
|
@@ -4346,6 +4448,42 @@ var init_types5 = __esm(() => {
|
|
|
4346
4448
|
contextFormula: ContextFormulaSchema.optional(),
|
|
4347
4449
|
createdAt: exports_iso.datetime()
|
|
4348
4450
|
}).openapi("ContextSnapshot");
|
|
4451
|
+
RequestCompositionPartKindSchema = _enum2([
|
|
4452
|
+
"system_section",
|
|
4453
|
+
"persona",
|
|
4454
|
+
"claude_md",
|
|
4455
|
+
"operator_prompt",
|
|
4456
|
+
"tool_schemas",
|
|
4457
|
+
"skills_listing",
|
|
4458
|
+
"task_prompt",
|
|
4459
|
+
"memories"
|
|
4460
|
+
]);
|
|
4461
|
+
RequestCompositionFidelitySchema = _enum2(["exact", "estimate"]);
|
|
4462
|
+
RequestCompositionPartInputSchema = object2({
|
|
4463
|
+
kind: RequestCompositionPartKindSchema,
|
|
4464
|
+
id: string2().min(1).max(200),
|
|
4465
|
+
label: string2().min(1).max(200),
|
|
4466
|
+
chars: number2().int().min(0),
|
|
4467
|
+
fidelity: RequestCompositionFidelitySchema.default("exact")
|
|
4468
|
+
});
|
|
4469
|
+
RequestCompositionPartSchema = RequestCompositionPartInputSchema.extend({
|
|
4470
|
+
estTokens: number2().int().min(0)
|
|
4471
|
+
}).openapi("RequestCompositionPart");
|
|
4472
|
+
RequestCompositionToolLoadingSchema = _enum2(["all", "core", "preloaded", "none"]);
|
|
4473
|
+
RequestCompositionSchema = object2({
|
|
4474
|
+
id: uuid(),
|
|
4475
|
+
taskId: string2(),
|
|
4476
|
+
agentId: string2(),
|
|
4477
|
+
sessionId: string2(),
|
|
4478
|
+
seq: number2().int().min(0),
|
|
4479
|
+
provider: string2(),
|
|
4480
|
+
model: string2().nullable(),
|
|
4481
|
+
source: _enum2(["worker", "harness-hook"]),
|
|
4482
|
+
parts: array2(RequestCompositionPartSchema),
|
|
4483
|
+
staticEstTokens: number2().int().min(0),
|
|
4484
|
+
tokenRatio: number2(),
|
|
4485
|
+
createdAt: exports_iso.datetime()
|
|
4486
|
+
}).openapi("RequestComposition");
|
|
4349
4487
|
BudgetScopeSchema = _enum2(["global", "agent", "user"]);
|
|
4350
4488
|
BudgetSchema = object2({
|
|
4351
4489
|
scope: BudgetScopeSchema,
|
|
@@ -4430,4 +4568,4 @@ var init_types5 = __esm(() => {
|
|
|
4430
4568
|
}).openapi("KvEntry");
|
|
4431
4569
|
});
|
|
4432
4570
|
|
|
4433
|
-
export { ASSET_KEY_MAX_LENGTH, AssetKeyError, normalizeAssetKey, defaultAssetKey, keyPrefixRange, SESSION_RESOURCE_KINDS, SESSION_LEAF_KINDS, NO_GROUP_LEAF_KINDS, isGroupKey, isResourceGroupPrefix, RESOURCE_GROUPS_READ_ONLY, sessionResourceGroupOf, sessionGroupKey, parseAssetKey, isCanonicalAssetKey, canWriteAssetKey, init_key, isSafeBundlePath, init_bundle_path, PAGE_THEME_COLOR_TOKENS, PAGE_THEME_SHARED_TOKENS, PAGE_THEME_TOKENS, HIVE_PAGE_TOKENS, init_tokens2, ThemeImportError, importThemeTokens, init_import, $OpenAPIRegistry, $OpenApiGeneratorV31, init_dist9, init_zod_openapi, AssetKeySchema, AssetEntityTypeSchema, AssetKeyMappingSchema, AssetSummarySchema, ModelTierSchema, MODEL_TIERS, ReasoningEffortSchema, DEFAULT_MODEL_TIER_MAP, parseModelTier, splitLegacyModelAlias, parseWorkerModelTierOverrides, resolveTaskModelSelection, AgentTaskStatusSchema, TERMINAL_TASK_STATUSES, isTerminalTaskStatus, OPEN_TASK_STATUSES, AgentTaskSourceSchema, RoutingReasonSchema, ProviderNameSchema, ModelProfileNameSchema, ModelProfileCredentialsSchema, ModelProfileSchema, ModelGroupSchema, ProviderErrorClassSchema, FallbackHopSchema, ProfileCheckResultSchema, SessionAccessSchema, SessionOwnerSchema, SessionSharesSchema, SessionSharesUpdateSchema, SteerModeSchema, SteeringSourceSchema, SteeringMessageSchema, SteerOutcomeSchema, OnUnsupportedSchema, SteerResultSchema, PROVIDER_STEER_CAPABILITIES, FollowUpConfigSchema, RoutingAffinitySchema, SlackParticipantTrustSchema, TaskSlackParticipantsSchema, AgentTaskSchema, CreateTaskOptionsSchema, SERVER_GENERATED_ATTACHMENT_CAPABILITY, AttachmentInputSchema, TaskAttachmentSchema, UserSchema, UserMergeJobStatusSchema, UserMergeJobSchema, RbacRoleSchema, UserRbacRolesSchema, UserCommsPrefsSchema, InboxItemTypeSchema, InboxItemStatusSchema, InboxItemStateSchema, ChecklistItemSchema, FavoriteItemTypeSchema, UserFavoriteSchema, TaskTemplateKindSchema, TaskTemplateSchema, AgentStatusSchema, AgentAvatarSchema, AppIconSchema, AgentSlackIconSchema, AgentSchema, AgentLatestModelSchema, AgentAcpStatusSchema, AgentCredStatusSchema, AgentWithTasksSchema, VersionableFieldSchema, ChannelTypeSchema, ResumeReasonSchema, AgentLogSchema, SessionLogSchema, SessionCostModelBreakdownSchema, SessionCostSchema, EventCategorySchema, EventStatusSchema, EventSourceSchema, EventNameSchema, SwarmEventSchema, AutomationIntegrationIdSchema, ScheduledTaskTargetTypeSchema, ScheduledTaskSchema, SwarmConfigScopeSchema, SwarmConfigSchema, RepoGuidelinesInputSchema, RepoHooksSchema, SwarmRepoSchema, AgentMemoryScopeSchema, AgentMemorySourceSchema, AgentMemorySchema, ActiveSessionSchema, WorkerNudgeSchema, RuntimeProviderKindSchema, DeliveryModeSchema, RuntimeControllerCreateSchema, RuntimeControllerUpdateSchema, RuntimeControllerSchema, RuntimePoolCacheSchema, RuntimePoolCreateSchema, RuntimePoolUpdateSchema, RuntimePoolSchema, RuntimePoolCreateAgentSchema, RuntimeInstanceSchema, RetryPolicySchema, SUPERSEDED_WORKFLOW_TASK_REASON, WorkflowEdgeSchema, WorkflowDefinitionSchema, WorkflowNodePatchSchema, WorkflowPatchSchema, TriggerConfigSchema, CooldownConfigSchema, InputValueSchema, WorkflowSchema, WorkflowVersionSchema, PageContentTypeSchema, PageAuthModeSchema, PageThemeTokensSchema, PageThemeTokensInputSchema, PageSchema, PageVersionSchema, MetricWidgetSchema, MetricDefinitionSchema, MetricSchema, MetricVersionSchema, WorkflowRunStatusSchema, WorkflowRunSchema, WorkflowRunParentSchema, WorkflowRunSummarySchema, ScriptRunStatusSchema, TERMINAL_SCRIPT_RUN_STATUSES, ScriptRunSchema, ScriptRunListItemSchema, ScriptRunJournalEntrySchema, WorkflowRunStepSchema, WorkflowRunStepSlimSchema, PromptTemplateScopeSchema, PromptTemplateStateSchema, PromptTemplateSchema, PromptTemplateHistorySchema, ScriptScopeSchema, ScriptFsModeSchema, ScriptExecutorNameSchema, ScriptRecordSchema, ScriptVersionRecordSchema, ExtensionWorkflowFileSchema, ExtensionManifestSchema, ExtensionSchema, ExtensionVersionSchema, ExtensionRunSchema, checkExtensionInstallSource, ExtensionInstallBodySchema, ScriptApiAuthModeSchema, ScriptApiRecordSchema, SkillSchema, AgentSkillSchema, SkillWithInstallInfoSchema, SkillFileSchema, McpAuthMethodSchema, McpServerSchema, AgentMcpServerSchema, McpServerWithInstallInfoSchema, ContextSnapshotEventTypeSchema, ContextFormulaSchema, ContextSnapshotSchema, BudgetScopeSchema, BudgetSchema, PricingProviderSchema, PricingTokenClassSchema, PricingRowSchema, BudgetRefusalCauseSchema, BudgetRefusalNotificationSchema, BudgetRefusedTriggerSchema, KvValueTypeSchema, KvNamespaceSchema, KvKeySchema, KvEntrySchema, init_types5 };
|
|
4571
|
+
export { ASSET_KEY_MAX_LENGTH, AssetKeyError, normalizeAssetKey, defaultAssetKey, keyPrefixRange, SESSION_RESOURCE_KINDS, SESSION_LEAF_KINDS, NO_GROUP_LEAF_KINDS, isGroupKey, isResourceGroupPrefix, RESOURCE_GROUPS_READ_ONLY, sessionResourceGroupOf, sessionGroupKey, parseAssetKey, isCanonicalAssetKey, canWriteAssetKey, init_key, isSafeBundlePath, init_bundle_path, PAGE_THEME_COLOR_TOKENS, PAGE_THEME_SHARED_TOKENS, PAGE_THEME_TOKENS, HIVE_PAGE_TOKENS, init_tokens2, ThemeImportError, importThemeTokens, init_import, $OpenAPIRegistry, $OpenApiGeneratorV31, init_dist9, init_zod_openapi, AssetKeySchema, AssetEntityTypeSchema, AssetKeyMappingSchema, AssetSummarySchema, ModelTierSchema, MODEL_TIERS, ReasoningEffortSchema, DEFAULT_MODEL_TIER_MAP, parseModelTier, splitLegacyModelAlias, parseWorkerModelTierOverrides, resolveTaskModelSelection, AgentTaskStatusSchema, TERMINAL_TASK_STATUSES, isTerminalTaskStatus, OPEN_TASK_STATUSES, AgentTaskSourceSchema, RoutingReasonSchema, ProviderNameSchema, ModelProfileNameSchema, ModelProfileCredentialsSchema, ModelProfileSchema, ModelGroupSchema, ProviderErrorClassSchema, FallbackHopSchema, ProfileCheckResultSchema, SessionAccessSchema, SessionOwnerSchema, SessionSharesSchema, SessionSharesUpdateSchema, SteerModeSchema, SteeringSourceSchema, SteeringMessageSchema, SteerOutcomeSchema, OnUnsupportedSchema, SteerResultSchema, PROVIDER_STEER_CAPABILITIES, FollowUpConfigSchema, RoutingAffinitySchema, SlackParticipantTrustSchema, TaskSlackParticipantsSchema, AgentTaskSchema, CreateTaskOptionsSchema, SERVER_GENERATED_ATTACHMENT_CAPABILITY, AttachmentInputSchema, TaskAttachmentSchema, UserSchema, UserMergeJobStatusSchema, UserMergeJobSchema, RbacRoleSchema, UserRbacRolesSchema, UserCommsPrefsSchema, InboxItemTypeSchema, InboxItemStatusSchema, InboxItemStateSchema, ChecklistItemSchema, FavoriteItemTypeSchema, UserFavoriteSchema, TaskTemplateKindSchema, TaskTemplateSchema, AgentStatusSchema, AgentAvatarSchema, AppIconSchema, AgentSlackIconSchema, AgentSchema, AgentLatestModelSchema, AgentAcpStatusSchema, AgentCredStatusSchema, AgentWithTasksSchema, VersionableFieldSchema, ChannelTypeSchema, ResumeReasonSchema, AgentLogSchema, SessionLogSchema, SessionCostModelBreakdownSchema, SessionCostSchema, EventCategorySchema, EventStatusSchema, EventSourceSchema, EventNameSchema, SwarmEventSchema, AutomationIntegrationIdSchema, ScheduledTaskTargetTypeSchema, ScheduledTaskSchema, SwarmConfigScopeSchema, SwarmConfigSchema, RepoGuidelinesInputSchema, RepoHooksSchema, SwarmRepoSchema, AgentMemoryScopeSchema, AgentMemorySourceSchema, AgentMemorySchema, ActiveSessionSchema, WorkerNudgeSchema, RuntimeProviderKindSchema, DeliveryModeSchema, RuntimeControllerCreateSchema, RuntimeControllerUpdateSchema, RuntimeControllerSchema, RuntimePoolCacheSchema, RuntimePoolCreateSchema, RuntimePoolUpdateSchema, RuntimePoolSchema, RuntimePoolCreateAgentSchema, RuntimeInstanceSchema, RetryPolicySchema, SUPERSEDED_WORKFLOW_TASK_REASON, WorkflowEdgeSchema, WorkflowDefinitionSchema, WorkflowNodePatchSchema, WorkflowPatchSchema, WEBHOOK_FILTER_PRESETS, WebhookDeliveryFilterSchema, TriggerConfigSchema, CooldownConfigSchema, InputValueSchema, WorkflowSchema, WorkflowVersionSchema, PageContentTypeSchema, PageAuthModeSchema, PageThemeTokensSchema, PageThemeTokensInputSchema, PageSchema, PageVersionSchema, MetricWidgetSchema, MetricDefinitionSchema, MetricSchema, MetricVersionSchema, WorkflowRunStatusSchema, WorkflowRunSchema, WorkflowRunParentSchema, WorkflowRunSummarySchema, ScriptRunStatusSchema, TERMINAL_SCRIPT_RUN_STATUSES, ScriptRunSchema, ScriptRunListItemSchema, ScriptRunJournalEntrySchema, WorkflowRunStepSchema, WorkflowRunStepSlimSchema, PromptTemplateScopeSchema, PromptTemplateStateSchema, PromptTemplateSchema, PromptTemplateHistorySchema, ScriptScopeSchema, ScriptFsModeSchema, ScriptExecutorNameSchema, ScriptRecordSchema, ScriptVersionRecordSchema, ExtensionWorkflowFileSchema, ExtensionManifestSchema, ExtensionSchema, ExtensionVersionSchema, ExtensionRunSchema, checkExtensionInstallSource, ExtensionInstallBodySchema, ScriptApiAuthModeSchema, ScriptApiRecordSchema, SkillSchema, AgentSkillSchema, SkillWithInstallInfoSchema, SkillFileSchema, McpAuthMethodSchema, McpServerSchema, AgentMcpServerSchema, McpServerWithInstallInfoSchema, ContextSnapshotEventTypeSchema, ContextFormulaSchema, ContextSnapshotSchema, RequestCompositionPartInputSchema, RequestCompositionToolLoadingSchema, RequestCompositionSchema, BudgetScopeSchema, BudgetSchema, PricingProviderSchema, PricingTokenClassSchema, PricingRowSchema, BudgetRefusalCauseSchema, BudgetRefusalNotificationSchema, BudgetRefusedTriggerSchema, KvValueTypeSchema, KvNamespaceSchema, KvKeySchema, KvEntrySchema, init_types5 };
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import {
|
|
2
2
|
Anthropic
|
|
3
|
-
} from "./cli-
|
|
3
|
+
} from "./cli-p8zqbbt1.js";
|
|
4
4
|
import {
|
|
5
5
|
contextBoundNoteThreshold,
|
|
6
6
|
createContextBoundNote
|
|
7
|
-
} from "./cli-
|
|
7
|
+
} from "./cli-9g12h1aq.js";
|
|
8
8
|
import {
|
|
9
9
|
checkToolLoop
|
|
10
10
|
} from "./cli-0726awxw.js";
|
|
11
11
|
import {
|
|
12
12
|
createSwarmEventHandler
|
|
13
|
-
} from "./cli-
|
|
13
|
+
} from "./cli-qncx2r0s.js";
|
|
14
14
|
import {
|
|
15
15
|
readPkgVersion
|
|
16
16
|
} from "./cli-kr5tjjtz.js";
|
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
computeContextUsedUnified,
|
|
21
21
|
clampContextPercent,
|
|
22
22
|
init_context_window
|
|
23
|
-
} from "./cli-
|
|
23
|
+
} from "./cli-6c9ve77f.js";
|
|
24
24
|
import {
|
|
25
25
|
isGitHubEnterprise,
|
|
26
26
|
init_github_host
|
|
@@ -28,16 +28,16 @@ import {
|
|
|
28
28
|
import {
|
|
29
29
|
selectCredential,
|
|
30
30
|
init_credentials2
|
|
31
|
-
} from "./cli-
|
|
31
|
+
} from "./cli-ha4ek2nb.js";
|
|
32
32
|
import {
|
|
33
33
|
runtimeCatalogModel,
|
|
34
34
|
init_runtime_model_catalog
|
|
35
|
-
} from "./cli-
|
|
35
|
+
} from "./cli-9yjhshah.js";
|
|
36
36
|
import {
|
|
37
37
|
init_src2,
|
|
38
38
|
scrubSecrets,
|
|
39
39
|
init_secret_scrubber
|
|
40
|
-
} from "./cli-
|
|
40
|
+
} from "./cli-7e8sxqv5.js";
|
|
41
41
|
|
|
42
42
|
// src/providers/claude-managed-adapter.ts
|
|
43
43
|
init_context_window();
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
resolveAcpTarget2
|
|
3
|
-
} from "./cli-
|
|
3
|
+
} from "./cli-p1a4khta.js";
|
|
4
4
|
import {
|
|
5
5
|
fetchInstalledMcpServers
|
|
6
6
|
} from "./cli-5y2fvw4z.js";
|
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
} from "./cli-7bw948kk.js";
|
|
13
13
|
import {
|
|
14
14
|
init_v4
|
|
15
|
-
} from "./cli-
|
|
15
|
+
} from "./cli-4jjrhy48.js";
|
|
16
16
|
import {
|
|
17
17
|
NEVER,
|
|
18
18
|
string2,
|
|
@@ -30,15 +30,15 @@ import {
|
|
|
30
30
|
record2,
|
|
31
31
|
literal2,
|
|
32
32
|
preprocess
|
|
33
|
-
} from "./cli-
|
|
33
|
+
} from "./cli-qrzq3hvg.js";
|
|
34
34
|
import {
|
|
35
35
|
init_package,
|
|
36
36
|
package_default
|
|
37
|
-
} from "./cli-
|
|
37
|
+
} from "./cli-a6q6x15h.js";
|
|
38
38
|
import {
|
|
39
39
|
scrubSecrets,
|
|
40
40
|
init_secret_scrubber
|
|
41
|
-
} from "./cli-
|
|
41
|
+
} from "./cli-7e8sxqv5.js";
|
|
42
42
|
|
|
43
43
|
// node_modules/@agentclientprotocol/sdk/dist/v1/unstable/schema/index.js
|
|
44
44
|
var AGENT_METHODS = {
|
|
@@ -6,15 +6,15 @@ import {
|
|
|
6
6
|
getResolvedConfig2,
|
|
7
7
|
getAllUsers2,
|
|
8
8
|
init_db4
|
|
9
|
-
} from "./cli-
|
|
9
|
+
} from "./cli-zhn4r1rz.js";
|
|
10
10
|
import {
|
|
11
11
|
getUserGrant2,
|
|
12
12
|
init_rbac_roles
|
|
13
|
-
} from "./cli-
|
|
13
|
+
} from "./cli-cstggwq7.js";
|
|
14
14
|
import {
|
|
15
15
|
scrubSecrets,
|
|
16
16
|
init_secret_scrubber
|
|
17
|
-
} from "./cli-
|
|
17
|
+
} from "./cli-7e8sxqv5.js";
|
|
18
18
|
|
|
19
19
|
// src/be/seed/agent-fs-provision.ts
|
|
20
20
|
init_secret_scrubber();
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getMemoryRaterNames,
|
|
3
3
|
init_memory_raters
|
|
4
|
-
} from "./cli-
|
|
4
|
+
} from "./cli-bmqp0ser.js";
|
|
5
5
|
import {
|
|
6
6
|
publicEndpointSsrfOptions,
|
|
7
7
|
init_mcp_wrapper
|
|
8
|
-
} from "./cli-
|
|
8
|
+
} from "./cli-t2s7j5cy.js";
|
|
9
9
|
import {
|
|
10
10
|
assertUrlSafe,
|
|
11
11
|
normalizeOrgWebsite,
|
|
12
12
|
init_org_website
|
|
13
|
-
} from "./cli-
|
|
13
|
+
} from "./cli-zhn4r1rz.js";
|
|
14
14
|
import {
|
|
15
15
|
getRouteProvider,
|
|
16
16
|
createScopedFetch,
|
|
17
17
|
deriveDefaultRoute,
|
|
18
18
|
init_src
|
|
19
|
-
} from "./cli-
|
|
19
|
+
} from "./cli-ha4ek2nb.js";
|
|
20
20
|
import {
|
|
21
21
|
getOpenRouterBaseUrl,
|
|
22
22
|
getOpenRouterAttributionHeaders,
|
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
init_src2,
|
|
29
29
|
scrubSecrets,
|
|
30
30
|
init_secret_scrubber
|
|
31
|
-
} from "./cli-
|
|
31
|
+
} from "./cli-7e8sxqv5.js";
|
|
32
32
|
|
|
33
33
|
// src/utils/lead-monitor-channels.ts
|
|
34
34
|
function isLeadChannelMonitoringEnabled(env = process.env) {
|
|
@@ -171,7 +171,8 @@ function resolveTemplateViaDb(eventType, variables, options) {
|
|
|
171
171
|
} else {
|
|
172
172
|
body = defaultBody;
|
|
173
173
|
}
|
|
174
|
-
|
|
174
|
+
const expandedRefs = [];
|
|
175
|
+
body = expandTemplateRefs(body, variables, options, new Set, 0, expandedRefs);
|
|
175
176
|
const composed = header ? `${header}
|
|
176
177
|
|
|
177
178
|
${body}` : body;
|
|
@@ -181,10 +182,21 @@ ${body}` : body;
|
|
|
181
182
|
templateId,
|
|
182
183
|
scope,
|
|
183
184
|
skipped: false,
|
|
184
|
-
unresolved
|
|
185
|
+
unresolved,
|
|
186
|
+
...expandedRefs.length > 0 && {
|
|
187
|
+
segments: measureSegments(eventType, text, expandedRefs, variables)
|
|
188
|
+
}
|
|
185
189
|
};
|
|
186
190
|
}
|
|
187
|
-
function
|
|
191
|
+
function measureSegments(eventType, text, refs, variables) {
|
|
192
|
+
const children = refs.map((ref) => ({
|
|
193
|
+
templateId: ref.templateId,
|
|
194
|
+
chars: interpolate(ref.body, variables).result.length
|
|
195
|
+
}));
|
|
196
|
+
const childChars = children.reduce((sum, segment) => sum + segment.chars, 0);
|
|
197
|
+
return [{ templateId: eventType, chars: Math.max(0, text.length - childChars) }, ...children];
|
|
198
|
+
}
|
|
199
|
+
function expandTemplateRefs(text, variables, options, visited, depth, expandedRefs) {
|
|
188
200
|
if (depth > MAX_TEMPLATE_REF_DEPTH) {
|
|
189
201
|
return text;
|
|
190
202
|
}
|
|
@@ -209,7 +221,9 @@ function expandTemplateRefs(text, variables, options, visited, depth) {
|
|
|
209
221
|
}
|
|
210
222
|
const newVisited = new Set(visited);
|
|
211
223
|
newVisited.add(referencedId);
|
|
212
|
-
|
|
224
|
+
const expanded = expandTemplateRefs(refBody, variables, options, newVisited, depth + 1);
|
|
225
|
+
expandedRefs?.push({ templateId: referencedId, body: expanded });
|
|
226
|
+
return expanded;
|
|
213
227
|
});
|
|
214
228
|
}
|
|
215
229
|
var dbResolverFn = null, httpResolverConfig = null, MAX_TEMPLATE_REF_DEPTH = 3, TEMPLATE_REF_REGEX;
|