@desplega.ai/agent-swarm 2.7.5 → 2.7.6
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-g3ads55s.js → acp-adapter-bp91d37f.js} +4 -4
- package/dist/{actions-zwfykqqk.js → actions-yj0eeaqh.js} +18 -17
- package/dist/{amp-adapter-z3s0ssdt.js → amp-adapter-4pg9h34q.js} +1 -1
- package/dist/{app-vmp4fgep.js → app-909e97cr.js} +3 -3
- package/dist/{assistant-vwde653f.js → assistant-qdyb5fyy.js} +24 -22
- package/dist/{boot-reembed-375t7tbk.js → boot-reembed-fk0s9z18.js} +1 -1
- package/dist/{boot-reembed-gq9rcpnj.js → boot-reembed-gs1rzrnh.js} +1 -1
- package/dist/{boot-scrub-sweep-nd938kyf.js → boot-scrub-sweep-4qfd4kfx.js} +2 -2
- package/dist/{boot-seeds-aykx51v3.js → boot-seeds-yr00k13d.js} +4 -4
- package/dist/{boxd-k1j26g3h.js → boxd-vdmfssd9.js} +4 -4
- package/dist/{claude-adapter-8j4hm099.js → claude-adapter-qta1f1xn.js} +3 -3
- package/dist/{claude-managed-setup-0wyynpn1.js → claude-managed-setup-sc6j4dm0.js} +1 -1
- package/dist/{claude-sdk-session-q6wj5hmy.js → claude-sdk-session-zgrz6yvc.js} +9169 -9070
- package/dist/{cli-gjr2y2xk.js → cli-0agcv1v5.js} +4 -1
- package/dist/{cli-vqypxzh4.js → cli-0at8w34w.js} +7 -7
- package/dist/{cli-7a42nfy0.js → cli-0qatpy8q.js} +3 -3
- package/dist/{cli-p599f1qm.js → cli-0yv5z2pg.js} +1 -1
- package/dist/{cli-0gey5fzy.js → cli-386tyxxg.js} +2 -2
- package/dist/{cli-5pag6rmn.js → cli-3ypk9vk1.js} +1 -1
- package/dist/{cli-qxnf8z2z.js → cli-436532ck.js} +2 -2
- package/dist/{cli-z8eh3ex8.js → cli-4necwtsv.js} +4 -4
- package/dist/{cli-zh3fp8v2.js → cli-54t00gt8.js} +1 -1
- package/dist/{cli-hf6zt5m6.js → cli-69szn7w7.js} +17 -1
- package/dist/{cli-nn4d8dne.js → cli-89knwags.js} +2 -2
- package/dist/{cli-spknvxbq.js → cli-8bc1w0tw.js} +10 -10
- package/dist/{cli-rqkxrmgw.js → cli-8snvgs5r.js} +38 -13
- package/dist/{cli-rhw40jgb.js → cli-bjb3z51z.js} +2 -2
- package/dist/{cli-xtjhfmpc.js → cli-c60vetmm.js} +1 -1
- package/dist/{cli-0731hvbw.js → cli-decfb6v8.js} +2 -2
- package/dist/{cli-bhjt02p8.js → cli-drr5v6av.js} +1 -1
- package/dist/{cli-fqzx7gwa.js → cli-dxae2yg7.js} +2 -2
- package/dist/{cli-tqgg40ek.js → cli-e3r2neck.js} +8 -7
- package/dist/{cli-zppwg9p9.js → cli-ekwks2vs.js} +1 -1
- package/dist/{cli-nzxr556s.js → cli-es6va8jk.js} +26 -26
- package/dist/{cli-a47xy8eq.js → cli-faxe6thg.js} +1 -1
- package/dist/cli-gdhpcbhf.js +55 -0
- package/dist/{cli-82jg7fp9.js → cli-he5nxaa8.js} +1 -1
- package/dist/{cli-8veytvbh.js → cli-he9wchme.js} +1 -1
- package/dist/{cli-pywf3eh5.js → cli-hgaazk69.js} +1 -1
- package/dist/{cli-0bxqnvq9.js → cli-hr2e2fft.js} +28 -6
- package/dist/{cli-1ayk1eas.js → cli-k2gzwsj2.js} +135 -26
- package/dist/{cli-xbkdm710.js → cli-kqdg1bsb.js} +3 -3
- package/dist/cli-m2z8jagn.js +12078 -0
- package/dist/{cli-g61qxmge.js → cli-m48g6p95.js} +3 -3
- package/dist/{cli-7wspm5gm.js → cli-nhrvpaj7.js} +20 -4
- package/dist/{cli-afrrppsw.js → cli-nwj0ee2w.js} +2 -2
- package/dist/{cli-3h4nhjn8.js → cli-p5gp8pcx.js} +9 -7
- package/dist/{cli-rm6hqj3z.js → cli-pd7vagab.js} +33 -139
- package/dist/{cli-mjzynrse.js → cli-q0k1w5zd.js} +1 -1
- package/dist/{cli-8hs41zy2.js → cli-rmmmrjkd.js} +1 -1
- package/dist/{cli-kg8hchyg.js → cli-sa02jsqt.js} +1 -1
- package/dist/{cli-1338796d.js → cli-shpbx5ee.js} +142 -98
- package/dist/{cli-82ae98pz.js → cli-svj5090z.js} +2 -2
- package/dist/{cli-bnz7a7qf.js → cli-vvpx3gsx.js} +1 -1
- package/dist/{cli-mmwm7zbf.js → cli-w6dt9ged.js} +1 -1
- package/dist/{cli-wvaawacd.js → cli-waqbxg08.js} +5230 -66
- package/dist/{cli-j3jvnpe8.js → cli-wp9sp1qb.js} +1 -1
- package/dist/{cli-nmbmy64z.js → cli-xbbndvjy.js} +3 -3
- package/dist/{cli-vbyfwh92.js → cli-xds5f77d.js} +2 -2
- package/dist/{cli-7wcyk2s5.js → cli-xnqgpshy.js} +1 -1
- package/dist/{cli-rpm2sgv0.js → cli-xnrwazav.js} +19 -2
- package/dist/{cli-gf5hbmdr.js → cli-yjdgea32.js} +3 -3
- package/dist/{cli-mry0qzym.js → cli-yn4kxs06.js} +123 -10
- package/dist/{cli-hn9hxmz9.js → cli-yx4kfngt.js} +1 -1
- package/dist/{cli-y24sc29k.js → cli-yy3rhsdw.js} +30 -8
- package/dist/{cli-6s7vdcta.js → cli-zbbwez0r.js} +4 -4
- package/dist/{cli-z6jkx23q.js → cli-zm72anhg.js} +9 -9
- package/dist/cli.js +22 -21
- package/dist/{codex-adapter-q6k3gnyg.js → codex-adapter-ayd1fb6h.js} +2 -2
- package/dist/{codex-session-runner-3mwmk3d9.js → codex-session-runner-jesa32xc.js} +2 -2
- package/dist/{commands-evrenjn9.js → commands-hanewgf2.js} +9 -3
- package/dist/{controller-xjp8vswh.js → controller-dt1n3c1q.js} +8 -3
- package/dist/{controllers-connect-pp5jnxvc.js → controllers-connect-xx8x64n5.js} +20 -19
- package/dist/{cursor-adapter-yf47w4t0.js → cursor-adapter-9s4dwwdw.js} +1 -1
- package/dist/{db-zxpw6aht.js → db-3vttcbv4.js} +3 -3
- package/dist/{db-rgfsh91f.js → db-9dv0g1ab.js} +11 -3
- package/dist/{devtools-82fzqra8.js → devtools-qxfgbsqz.js} +1 -1
- package/dist/{dispatcher-smasgws7.js → dispatcher-tx9hd1sv.js} +17 -16
- package/dist/{docker-rrjhaqt9.js → docker-c1a3gqmf.js} +89 -22
- package/dist/{dsh-adapter-ftyy8dnp.js → dsh-adapter-007y4ejs.js} +1 -1
- package/dist/{e2b-qcaj675y.js → e2b-a19d28rz.js} +2 -2
- package/dist/{e2b-w1p0bnpm.js → e2b-we6hs6q5.js} +4 -4
- package/dist/{easter-egg-3d-yyts7p16.js → easter-egg-3d-rgbrqb8s.js} +1 -1
- package/dist/{embedding-space-1z0mbg95.js → embedding-space-ny1e2940.js} +6 -6
- package/dist/{embeddings-ygeg7tm7.js → embeddings-2t386t13.js} +1 -1
- package/dist/{execute-14qhqp4d.js → execute-pksh0ceh.js} +1 -1
- package/dist/{external-channel-ttgrs3sx.js → external-channel-phgmhmd7.js} +2 -2
- package/dist/{fx-adapter-gt6pncj2.js → fx-adapter-fy8rr921.js} +5 -5
- package/dist/{google-generative-ai-yvmdxyxa.js → google-generative-ai-8y3m3k4b.js} +1 -1
- package/dist/{google-vertex-jrtdh9gs.js → google-vertex-w3v98n7b.js} +1 -1
- package/dist/{grok-adapter-sm4m5k4g.js → grok-adapter-q0abvpaj.js} +5 -5
- package/dist/handlers-by3sfxyx.js +32 -0
- package/dist/{heartbeat-qahz4p62.js → heartbeat-kadyek8p.js} +20 -19
- package/dist/{hook-kj3d398m.js → hook-5zs3msf6.js} +2 -2
- package/dist/{hook-4fd5wq5w.js → hook-9k551xnj.js} +2 -2
- package/dist/{http-1ted0j1k.js → http-mhz9vw1f.js} +213 -80
- package/dist/index-4f2pvxae.js +37 -0
- package/dist/index-98gz7tmp.js +30 -0
- package/dist/{index-5rk6rfzr.js → index-fvzke5kx.js} +1 -1
- package/dist/index-k08z2cak.js +33 -0
- package/dist/{index-yqhz88yy.js → index-pxn30mse.js} +8 -8
- package/dist/{index-6rq3r5zb.js → index-q361cg2f.js} +1 -1
- package/dist/{index-7v51awbn.js → index-rvr00sg7.js} +20 -13
- package/dist/{index-q4b917zs.js → index-vdygbq10.js} +1 -1
- package/dist/{keepalive-6cf311t5.js → keepalive-w56f32cg.js} +3 -3
- package/dist/{lead-fjy418cw.js → lead-enq35nqp.js} +31 -30
- package/dist/{maintenance-a4bm1bmt.js → maintenance-7mdgxcea.js} +1 -1
- package/dist/{oauth-refresh-sweep-3h0dfw1k.js → oauth-refresh-sweep-29txy9vk.js} +2 -2
- package/dist/{onboard-myn5hraa.js → onboard-kpsrkarj.js} +4 -4
- package/dist/{opencode-adapter-p2nkb5am.js → opencode-adapter-j25vm3rr.js} +3 -3
- package/dist/{otel-impl-a1a0ef6b.js → otel-impl-6kkct7a8.js} +1 -1
- package/dist/{pi-mono-adapter-rzmpb72a.js → pi-mono-adapter-exhkzhn2.js} +4 -4
- package/dist/{pricing-refresh-83drrnxj.js → pricing-refresh-n2x7jh6k.js} +3 -3
- package/dist/{rbac-roles-s8y6ecb5.js → rbac-roles-81ypx6es.js} +1 -1
- package/dist/{rbac-roles-0fb6e7pj.js → rbac-roles-b5htkjby.js} +2 -2
- package/dist/{render-v2-twmbgrz4.js → render-v2-qn6jmpk4.js} +3 -3
- package/dist/{resume-zfqc36xj.js → resume-wd30wx23.js} +6 -6
- package/dist/{runtime-qwggdpqr.js → runtime-4hsg7h60.js} +1 -1
- package/dist/{session-access-sc9pn9da.js → session-access-5qvfevhk.js} +4 -4
- package/dist/{session-source-backfill-qh07xr8g.js → session-source-backfill-n1czavbr.js} +2 -2
- package/dist/{setup-4fr0m7a1.js → setup-dnb56qy5.js} +3 -3
- package/dist/{virtual-modules-fh4ha15b.js → virtual-modules-76xxv9fs.js} +2 -2
- package/dist/{work-objects-0wr8zxct.js → work-objects-4n21tfkm.js} +20 -19
- package/dist/{worker-follow-up-ktyyazyp.js → worker-follow-up-77hvzxww.js} +17 -16
- package/dist/{worker-0c5tyzqe.js → worker-gg1576j3.js} +31 -30
- package/openapi.json +93 -1
- package/package.json +8 -7
- package/src/be/db/script-runs.ts +23 -0
- package/src/be/db/tasks/read.ts +122 -3
- package/src/be/db-client.ts +8 -5
- package/src/be/db.ts +15 -4
- package/src/be/memory/providers/sqlite-store.ts +49 -12
- package/src/be/migrations/260_runtime_pool_cache.sql +20 -0
- package/src/be/migrations/262_session_visibility_indexes.sql +18 -0
- package/src/be/migrations/263_task_list_filter_index.sql +11 -0
- package/src/be/migrations/264_slack_thread_cover_index.sql +9 -0
- package/src/be/migrations/266_script_runs_source_task.sql +11 -0
- package/src/be/runtime-pools/cache-cleanup.ts +109 -0
- package/src/be/runtime-pools/db.ts +65 -6
- package/src/be/runtime-pools/remote-controller.ts +5 -0
- package/src/be/runtime-pools/supervisor.ts +33 -2
- package/src/be/scripts/typecheck.ts +22 -0
- package/src/be/seed-scripts/catalog/task-failure-audit.ts +5 -1
- package/src/commands/controller.ts +4 -0
- package/src/commands/entrypoint-api-readiness.ts +74 -0
- package/src/http/index.ts +1 -1
- package/src/http/list-total-cache.ts +14 -7
- package/src/http/memory.ts +38 -9
- package/src/http/script-runs.ts +174 -5
- package/src/http/status.ts +10 -2
- package/src/http/tasks.ts +4 -2
- package/src/providers/amp-adapter.ts +1 -1
- package/src/providers/fx-adapter.ts +1 -1
- package/src/runtime-providers/controller-protocol.ts +14 -1
- package/src/runtime-providers/controller.ts +5 -0
- package/src/runtime-providers/docker.ts +108 -23
- package/src/runtime-providers/types.ts +16 -0
- package/src/script-workflows/workflow-ctx.ts +8 -0
- package/src/scripts-runtime/types/stdlib.d.ts +22 -0
- package/src/scripts-runtime/types/swarm-sdk.d.ts +22 -0
- package/src/server-user.ts +1 -0
- package/src/slack/commands.ts +5 -1
- package/src/slack/handlers.ts +37 -2
- package/src/slack/left-threads.ts +27 -4
- package/src/tasks/follow-up-redelegation-guard.ts +155 -0
- package/src/tests/claude-artifacts-read-script.test.ts +209 -0
- package/src/tests/db-client.test.ts +21 -0
- package/src/tests/db-task-read-contract.test.ts +8 -2
- package/src/tests/db-task-write-contract.test.ts +5 -1
- package/src/tests/entrypoint-api-readiness.test.ts +416 -210
- package/src/tests/explicit-model-validation.test.ts +14 -8
- package/src/tests/follow-up-redelivery-guard.test.ts +432 -202
- package/src/tests/list-total-cache.test.ts +27 -2
- package/src/tests/memory-fts-populate.test.ts +11 -9
- package/src/tests/memory-retrieval-purge.test.ts +80 -0
- package/src/tests/migration-260-runtime-pool-cache.test.ts +118 -0
- package/src/tests/query-audit-plans.test.ts +27 -0
- package/src/tests/runtime-cache-cleanup.test.ts +367 -0
- package/src/tests/runtime-e2b-pools.test.ts +41 -0
- package/src/tests/runtime-pools-db.test.ts +98 -0
- package/src/tests/runtime-pools-http.test.ts +29 -0
- package/src/tests/runtime-providers-docker.test.ts +253 -0
- package/src/tests/runtime-remote-controller.test.ts +66 -2
- package/src/tests/runtime-supervisor.test.ts +66 -2
- package/src/tests/script-connections.test.ts +11 -0
- package/src/tests/script-runs-http.test.ts +684 -2
- package/src/tests/seed-scripts.test.ts +26 -0
- package/src/tests/slack-leave-thread.test.ts +145 -5
- package/src/tests/slack-render-v2-query-plans.test.ts +24 -2
- package/src/tests/status.test.ts +11 -0
- package/src/tests/tasks-readable-row.test.ts +155 -0
- package/src/tools/send-task.ts +35 -47
- package/src/tools/slack-leave-thread.ts +1 -1
- package/src/tools/task-dedup.ts +45 -21
- package/src/types.ts +38 -0
- package/templates/skills/composio-google-docs/content.md +10 -0
- package/templates/skills/script-workflows/content.md +19 -1
- package/templates/skills/swarm-docs/content.md +1 -0
- package/templates/skills/swarm-scripts/SKILL.md +2 -0
- package/templates/skills/swarm-scripts/content.md +2 -0
- package/dist/cli-dznrgaep.js +0 -30
- package/dist/cli-w3hcrxht.js +0 -6985
- package/dist/handlers-vwmba1m2.js +0 -31
- package/dist/index-5r71rf98.js +0 -32
- package/dist/index-anmwxs87.js +0 -29
- package/dist/index-spp0ra5c.js +0 -36
|
@@ -91,7 +91,9 @@ import {
|
|
|
91
91
|
getAgentWorkingOnContextKey2,
|
|
92
92
|
getLatestActiveTaskByContextKey2,
|
|
93
93
|
getLatestLeadTaskByContextKey2,
|
|
94
|
-
|
|
94
|
+
findCompletedTasksInThread2,
|
|
95
|
+
findRecentFailedTaskInThread2,
|
|
96
|
+
countAgentDispatchesInThread2,
|
|
95
97
|
findRecentCancelledTaskInThread2,
|
|
96
98
|
init_read,
|
|
97
99
|
listModelProfiles,
|
|
@@ -349,17 +351,17 @@ import {
|
|
|
349
351
|
recordInlineScriptRun2,
|
|
350
352
|
exports_db,
|
|
351
353
|
init_db4
|
|
352
|
-
} from "./cli-
|
|
354
|
+
} from "./cli-k2gzwsj2.js";
|
|
353
355
|
import {
|
|
354
356
|
getUserGrant2,
|
|
355
357
|
init_rbac_roles
|
|
356
|
-
} from "./cli-
|
|
358
|
+
} from "./cli-rmmmrjkd.js";
|
|
357
359
|
import {
|
|
358
360
|
ensurePricingSeeded2,
|
|
359
361
|
ensureRbacSeeded2,
|
|
360
362
|
ensureModelProfilesSeeded2,
|
|
361
363
|
init_boot_seeds
|
|
362
|
-
} from "./cli-
|
|
364
|
+
} from "./cli-zbbwez0r.js";
|
|
363
365
|
import {
|
|
364
366
|
buildCatalogEntries,
|
|
365
367
|
listModelCatalog,
|
|
@@ -371,7 +373,7 @@ import {
|
|
|
371
373
|
requestModelCatalogRefresh2,
|
|
372
374
|
startPricingRefreshLoop2,
|
|
373
375
|
init_pricing_refresh
|
|
374
|
-
} from "./cli-
|
|
376
|
+
} from "./cli-89knwags.js";
|
|
375
377
|
import {
|
|
376
378
|
workflowEventBus2,
|
|
377
379
|
init_event_bus
|
|
@@ -384,7 +386,7 @@ import {
|
|
|
384
386
|
externalChannelToolError2,
|
|
385
387
|
getChannelBlockReason2,
|
|
386
388
|
init_external_channel
|
|
387
|
-
} from "./cli-
|
|
389
|
+
} from "./cli-w6dt9ged.js";
|
|
388
390
|
import {
|
|
389
391
|
noteSlackInboundSideEffect,
|
|
390
392
|
init_inbound_dispatch,
|
|
@@ -419,7 +421,7 @@ import {
|
|
|
419
421
|
startSlackApp2,
|
|
420
422
|
stopSlackApp2,
|
|
421
423
|
init_app3
|
|
422
|
-
} from "./cli-
|
|
424
|
+
} from "./cli-waqbxg08.js";
|
|
423
425
|
import {
|
|
424
426
|
shapeApprovalResolution,
|
|
425
427
|
init_approval_resolution,
|
|
@@ -443,7 +445,7 @@ import {
|
|
|
443
445
|
resumeFromChildRun2,
|
|
444
446
|
initWaitBusSubscriptions2,
|
|
445
447
|
init_resume
|
|
446
|
-
} from "./cli-
|
|
448
|
+
} from "./cli-m48g6p95.js";
|
|
447
449
|
import {
|
|
448
450
|
FilesError,
|
|
449
451
|
providerPath,
|
|
@@ -457,7 +459,7 @@ import {
|
|
|
457
459
|
import {
|
|
458
460
|
getRuntimePool2,
|
|
459
461
|
init_db2
|
|
460
|
-
} from "./cli-
|
|
462
|
+
} from "./cli-yn4kxs06.js";
|
|
461
463
|
import {
|
|
462
464
|
duplicateGuardedQueryKey,
|
|
463
465
|
parseQueryParams,
|
|
@@ -490,7 +492,7 @@ import {
|
|
|
490
492
|
findRoute,
|
|
491
493
|
route,
|
|
492
494
|
init_route_def
|
|
493
|
-
} from "./cli-
|
|
495
|
+
} from "./cli-4necwtsv.js";
|
|
494
496
|
import {
|
|
495
497
|
COMPOSIO_HTTP_METHODS,
|
|
496
498
|
executeComposioRequest,
|
|
@@ -502,7 +504,7 @@ import {
|
|
|
502
504
|
ampPinCatalogError,
|
|
503
505
|
ampModelError,
|
|
504
506
|
init_amp_models
|
|
505
|
-
} from "./cli-
|
|
507
|
+
} from "./cli-q0k1w5zd.js";
|
|
506
508
|
import {
|
|
507
509
|
object,
|
|
508
510
|
init_v4_mini
|
|
@@ -523,7 +525,7 @@ import {
|
|
|
523
525
|
import {
|
|
524
526
|
loadModelsDevCache,
|
|
525
527
|
init_modelsdev_cache
|
|
526
|
-
} from "./cli-
|
|
528
|
+
} from "./cli-c60vetmm.js";
|
|
527
529
|
import {
|
|
528
530
|
require_dist2,
|
|
529
531
|
ConnectionAuthInputSchema,
|
|
@@ -602,7 +604,7 @@ import {
|
|
|
602
604
|
init_typecheck,
|
|
603
605
|
parseSkillContent,
|
|
604
606
|
init_skill_parser
|
|
605
|
-
} from "./cli-
|
|
607
|
+
} from "./cli-hr2e2fft.js";
|
|
606
608
|
import {
|
|
607
609
|
detachedProcessGroup,
|
|
608
610
|
registerProcessGroup,
|
|
@@ -617,7 +619,7 @@ import {
|
|
|
617
619
|
ensureToken,
|
|
618
620
|
ensureTokenOrThrow,
|
|
619
621
|
init_ensure_token
|
|
620
|
-
} from "./cli-
|
|
622
|
+
} from "./cli-xnqgpshy.js";
|
|
621
623
|
import {
|
|
622
624
|
require_fast_deep_equal
|
|
623
625
|
} from "./cli-bhp11egn.js";
|
|
@@ -712,7 +714,7 @@ import {
|
|
|
712
714
|
validateDefinition,
|
|
713
715
|
applyDefinitionPatch,
|
|
714
716
|
init_definition2
|
|
715
|
-
} from "./cli-
|
|
717
|
+
} from "./cli-8bc1w0tw.js";
|
|
716
718
|
import {
|
|
717
719
|
isMultiRuntimeEnabled,
|
|
718
720
|
init_multi_runtime2
|
|
@@ -728,14 +730,20 @@ import {
|
|
|
728
730
|
import {
|
|
729
731
|
require_dist3
|
|
730
732
|
} from "./cli-k28wkapa.js";
|
|
733
|
+
import {
|
|
734
|
+
SLACK_LEAVE_THREAD_DISABLE,
|
|
735
|
+
isSlackLeaveThreadDisabled,
|
|
736
|
+
leaveSlackThread,
|
|
737
|
+
init_left_threads
|
|
738
|
+
} from "./cli-gdhpcbhf.js";
|
|
731
739
|
import {
|
|
732
740
|
publicEndpointSsrfOptions,
|
|
733
741
|
init_mcp_wrapper
|
|
734
|
-
} from "./cli-
|
|
742
|
+
} from "./cli-hgaazk69.js";
|
|
735
743
|
import {
|
|
736
744
|
canProvisionKind,
|
|
737
745
|
init_runtime_providers
|
|
738
|
-
} from "./cli-
|
|
746
|
+
} from "./cli-kqdg1bsb.js";
|
|
739
747
|
import {
|
|
740
748
|
findUserById,
|
|
741
749
|
findUserByExternalId,
|
|
@@ -750,7 +758,7 @@ import {
|
|
|
750
758
|
resolveSessionToken,
|
|
751
759
|
fingerprintApiKey,
|
|
752
760
|
init_users
|
|
753
|
-
} from "./cli-
|
|
761
|
+
} from "./cli-drr5v6av.js";
|
|
754
762
|
import {
|
|
755
763
|
isRbacEnabled,
|
|
756
764
|
decideAdmission,
|
|
@@ -821,7 +829,7 @@ import {
|
|
|
821
829
|
KvNamespaceSchema,
|
|
822
830
|
KvKeySchema,
|
|
823
831
|
init_types4
|
|
824
|
-
} from "./cli-
|
|
832
|
+
} from "./cli-nhrvpaj7.js";
|
|
825
833
|
import {
|
|
826
834
|
generateDefaultClaudeMd2,
|
|
827
835
|
generateDefaultSoulMd2,
|
|
@@ -893,7 +901,7 @@ import {
|
|
|
893
901
|
import {
|
|
894
902
|
init_package,
|
|
895
903
|
package_default
|
|
896
|
-
} from "./cli-
|
|
904
|
+
} from "./cli-e3r2neck.js";
|
|
897
905
|
import {
|
|
898
906
|
realtimeBus,
|
|
899
907
|
init_bus
|
|
@@ -20871,7 +20879,7 @@ function startRetryPoller(registry, intervalMs = 5000) {
|
|
|
20871
20879
|
if (!waiting)
|
|
20872
20880
|
continue;
|
|
20873
20881
|
if (result.waitFor === "workflow.child.finished") {
|
|
20874
|
-
const { resumeFromChildRun } = await import("./resume-
|
|
20882
|
+
const { resumeFromChildRun } = await import("./resume-wd30wx23.js");
|
|
20875
20883
|
await resumeFromChildRun(step.id, registry);
|
|
20876
20884
|
}
|
|
20877
20885
|
} else {
|
|
@@ -21584,7 +21592,7 @@ var init_notify = __esm(() => {
|
|
|
21584
21592
|
}
|
|
21585
21593
|
}
|
|
21586
21594
|
case "slack": {
|
|
21587
|
-
const { getSlackApp } = await import("./app-
|
|
21595
|
+
const { getSlackApp } = await import("./app-909e97cr.js");
|
|
21588
21596
|
const app = getSlackApp();
|
|
21589
21597
|
if (!app) {
|
|
21590
21598
|
return {
|
|
@@ -24908,7 +24916,7 @@ function setPreloadedTools(server, names) {
|
|
|
24908
24916
|
async function applyPreToolCall(name, args, requestInfo, inputSchema) {
|
|
24909
24917
|
if (requestInfo.callOrigin !== "mcp")
|
|
24910
24918
|
return { args };
|
|
24911
|
-
const dispatcher = await import("./dispatcher-
|
|
24919
|
+
const dispatcher = await import("./dispatcher-tx9hd1sv.js");
|
|
24912
24920
|
const result = await dispatcher.dispatchPre("pre.tool.call", { tool: name, args, requestInfo }, inputSchema ? {
|
|
24913
24921
|
validateModify: async (data) => {
|
|
24914
24922
|
const schema = normalizeObjectSchema(inputSchema) ?? inputSchema;
|
|
@@ -32386,7 +32394,7 @@ async function loadAdapter(name, config, logger) {
|
|
|
32386
32394
|
});
|
|
32387
32395
|
}
|
|
32388
32396
|
case "slack": {
|
|
32389
|
-
const { createSlackAdapter } = await import("./index-
|
|
32397
|
+
const { createSlackAdapter } = await import("./index-pxn30mse.js");
|
|
32390
32398
|
return createSlackAdapter({
|
|
32391
32399
|
...base,
|
|
32392
32400
|
signingSecret: config.signingSecret ?? "",
|
|
@@ -32405,7 +32413,7 @@ async function loadAdapter(name, config, logger) {
|
|
|
32405
32413
|
});
|
|
32406
32414
|
}
|
|
32407
32415
|
case "teams": {
|
|
32408
|
-
const { createTeamsAdapter } = await import("./index-
|
|
32416
|
+
const { createTeamsAdapter } = await import("./index-fvzke5kx.js");
|
|
32409
32417
|
const { teamsWebhookVerifier, teamsToken } = getChatSdkTestHooks();
|
|
32410
32418
|
return createTeamsAdapter({
|
|
32411
32419
|
...base,
|
|
@@ -35873,7 +35881,7 @@ async function notifySlack(text) {
|
|
|
35873
35881
|
return;
|
|
35874
35882
|
}
|
|
35875
35883
|
try {
|
|
35876
|
-
const { getSlackApp } = await import("./app-
|
|
35884
|
+
const { getSlackApp } = await import("./app-909e97cr.js");
|
|
35877
35885
|
const app = getSlackApp();
|
|
35878
35886
|
if (!app) {
|
|
35879
35887
|
console.warn("[Jira webhook keepalive] Slack not available, cannot send notification");
|
|
@@ -35944,7 +35952,7 @@ async function deleteJiraWebhook(webhookId) {
|
|
|
35944
35952
|
console.log(`[Jira webhook keepalive] Deleted webhook id=${webhookId}`);
|
|
35945
35953
|
}
|
|
35946
35954
|
async function overwriteWebhookIds(next) {
|
|
35947
|
-
const { getDbClient } = await import("./db-
|
|
35955
|
+
const { getDbClient } = await import("./db-9dv0g1ab.js");
|
|
35948
35956
|
await getDbClient().transaction(async (tx) => {
|
|
35949
35957
|
const row = await tx.get("SELECT metadata FROM oauth_apps WHERE provider = 'jira'");
|
|
35950
35958
|
if (!row) {
|
|
@@ -109417,7 +109425,7 @@ async function reloadGlobalConfigsAndIntegrations() {
|
|
|
109417
109425
|
return runWithoutRequestAuth(() => reloadGlobalConfigsAndIntegrationsInner());
|
|
109418
109426
|
}
|
|
109419
109427
|
async function reloadGlobalConfigsAndIntegrationsInner() {
|
|
109420
|
-
const { getEmbeddingProvider, resetEmbeddingProvider } = await import("./index-
|
|
109428
|
+
const { getEmbeddingProvider, resetEmbeddingProvider } = await import("./index-vdygbq10.js");
|
|
109421
109429
|
const wasEmbeddingsConfigured = getEmbeddingProvider().isConfigured();
|
|
109422
109430
|
const updated = await loadGlobalConfigsIntoEnv(true);
|
|
109423
109431
|
await syncTelemetryEnabled("settings").catch((err) => {
|
|
@@ -109433,7 +109441,7 @@ async function reloadGlobalConfigsAndIntegrationsInner() {
|
|
|
109433
109441
|
integrations.push("embeddings");
|
|
109434
109442
|
}
|
|
109435
109443
|
if (isEmbeddingsConfigured) {
|
|
109436
|
-
import("./embedding-space-
|
|
109444
|
+
import("./embedding-space-ny1e2940.js").then(({ runEmbeddingMaintenance }) => runEmbeddingMaintenance({ backfill: !wasEmbeddingsConfigured })).catch((err) => {
|
|
109437
109445
|
console.error("[config-reload] embedding maintenance failed (non-fatal):", err);
|
|
109438
109446
|
});
|
|
109439
109447
|
}
|
|
@@ -109879,42 +109887,6 @@ var init_mcp_limits = __esm(() => {
|
|
|
109879
109887
|
MCP_MAX_REQUEST_BODY_BYTES = 4 * 1024 * 1024;
|
|
109880
109888
|
});
|
|
109881
109889
|
|
|
109882
|
-
// src/slack/left-threads.ts
|
|
109883
|
-
function isSlackLeaveThreadDisabled() {
|
|
109884
|
-
return isEnvFlagEnabled(SLACK_LEAVE_THREAD_DISABLE, false);
|
|
109885
|
-
}
|
|
109886
|
-
function threadKey(channelId, threadTs) {
|
|
109887
|
-
return `${channelId}:${threadTs}`;
|
|
109888
|
-
}
|
|
109889
|
-
async function leaveSlackThread(channelId, threadTs, agentId) {
|
|
109890
|
-
await upsertKv2({
|
|
109891
|
-
namespace: SLACK_LEFT_THREAD_KV_NAMESPACE,
|
|
109892
|
-
key: threadKey(channelId, threadTs),
|
|
109893
|
-
value: { agentId, leftAt: new Date().toISOString() },
|
|
109894
|
-
valueType: "json"
|
|
109895
|
-
});
|
|
109896
|
-
}
|
|
109897
|
-
async function isSlackThreadLeft(channelId, threadTs) {
|
|
109898
|
-
return await getKv2(SLACK_LEFT_THREAD_KV_NAMESPACE, threadKey(channelId, threadTs)) !== null;
|
|
109899
|
-
}
|
|
109900
|
-
async function shouldSkipLeftSlackThread(channelId, threadTs, botMentioned) {
|
|
109901
|
-
if (!threadTs)
|
|
109902
|
-
return false;
|
|
109903
|
-
const key = threadKey(channelId, threadTs);
|
|
109904
|
-
if (botMentioned) {
|
|
109905
|
-
if (await deleteKv2(SLACK_LEFT_THREAD_KV_NAMESPACE, key)) {
|
|
109906
|
-
console.log(`[Slack] Rejoined left thread ${key}: bot mentioned`);
|
|
109907
|
-
}
|
|
109908
|
-
return false;
|
|
109909
|
-
}
|
|
109910
|
-
return isSlackThreadLeft(channelId, threadTs);
|
|
109911
|
-
}
|
|
109912
|
-
var SLACK_LEFT_THREAD_KV_NAMESPACE = "slack-left-thread", SLACK_LEAVE_THREAD_DISABLE = "SLACK_LEAVE_THREAD_DISABLE";
|
|
109913
|
-
var init_left_threads = __esm(() => {
|
|
109914
|
-
init_db4();
|
|
109915
|
-
init_env_flag();
|
|
109916
|
-
});
|
|
109917
|
-
|
|
109918
109890
|
// src/tools/task-tool-ctx.ts
|
|
109919
109891
|
function ownerCtx(info) {
|
|
109920
109892
|
return {
|
|
@@ -132767,10 +132739,27 @@ function jaccardSimilarity(a, b) {
|
|
|
132767
132739
|
const union = new Set([...wordsA, ...wordsB]).size;
|
|
132768
132740
|
return intersection / union;
|
|
132769
132741
|
}
|
|
132742
|
+
function matchSimilarTask(existing, opts) {
|
|
132743
|
+
const similarity = jaccardSimilarity(existing.task, opts.taskDescription);
|
|
132744
|
+
if (similarity > HIGH_SIMILARITY_THRESHOLD) {
|
|
132745
|
+
return {
|
|
132746
|
+
task: existing,
|
|
132747
|
+
reason: `similar task description (${(similarity * 100).toFixed(0)}% match)`
|
|
132748
|
+
};
|
|
132749
|
+
}
|
|
132750
|
+
if (opts.targetAgentId && existing.agentId === opts.targetAgentId && similarity > SAME_AGENT_SIMILARITY_THRESHOLD) {
|
|
132751
|
+
return {
|
|
132752
|
+
task: existing,
|
|
132753
|
+
reason: `similar task to same agent (${(similarity * 100).toFixed(0)}% match)`
|
|
132754
|
+
};
|
|
132755
|
+
}
|
|
132756
|
+
return null;
|
|
132757
|
+
}
|
|
132770
132758
|
async function findDuplicateTask(opts) {
|
|
132771
132759
|
const recentTasks = await findRecentSimilarTasks2({
|
|
132772
132760
|
creatorAgentId: opts.creatorAgentId,
|
|
132773
|
-
windowMinutes: opts.windowMinutes ?? 10
|
|
132761
|
+
windowMinutes: opts.windowMinutes ?? 10,
|
|
132762
|
+
limit: DEDUP_SCAN_LIMIT
|
|
132774
132763
|
});
|
|
132775
132764
|
for (const existing of recentTasks) {
|
|
132776
132765
|
if (opts.slackChannelId && opts.slackThreadTs && existing.slackChannelId === opts.slackChannelId && existing.slackThreadTs === opts.slackThreadTs) {
|
|
@@ -132779,25 +132768,77 @@ async function findDuplicateTask(opts) {
|
|
|
132779
132768
|
reason: `same Slack thread (${opts.slackChannelId}/${opts.slackThreadTs})`
|
|
132780
132769
|
};
|
|
132781
132770
|
}
|
|
132782
|
-
const
|
|
132783
|
-
if (
|
|
132784
|
-
return
|
|
132785
|
-
|
|
132786
|
-
|
|
132787
|
-
|
|
132788
|
-
|
|
132789
|
-
|
|
132771
|
+
const match = matchSimilarTask(existing, opts);
|
|
132772
|
+
if (match)
|
|
132773
|
+
return match;
|
|
132774
|
+
}
|
|
132775
|
+
return null;
|
|
132776
|
+
}
|
|
132777
|
+
var HIGH_SIMILARITY_THRESHOLD = 0.8, SAME_AGENT_SIMILARITY_THRESHOLD = 0.6, DEDUP_SCAN_LIMIT = 500;
|
|
132778
|
+
var init_task_dedup = __esm(() => {
|
|
132779
|
+
init_db4();
|
|
132780
|
+
});
|
|
132781
|
+
|
|
132782
|
+
// src/tasks/follow-up-redelegation-guard.ts
|
|
132783
|
+
async function followUpThreadForSourceTask(sourceTaskId) {
|
|
132784
|
+
if (!sourceTaskId)
|
|
132785
|
+
return null;
|
|
132786
|
+
const sourceTask = await getTaskById2(sourceTaskId);
|
|
132787
|
+
if (sourceTask?.taskType !== "follow-up" || !sourceTask.slackChannelId || !sourceTask.slackThreadTs) {
|
|
132788
|
+
return null;
|
|
132789
|
+
}
|
|
132790
|
+
return {
|
|
132791
|
+
channelId: sourceTask.slackChannelId,
|
|
132792
|
+
threadTs: sourceTask.slackThreadTs,
|
|
132793
|
+
userId: sourceTask.slackUserId
|
|
132794
|
+
};
|
|
132795
|
+
}
|
|
132796
|
+
async function findMatchingCompletedWork(args) {
|
|
132797
|
+
let before;
|
|
132798
|
+
for (;; ) {
|
|
132799
|
+
const page = await findCompletedTasksInThread2(args.channelId, args.threadTs, FOLLOW_UP_SAME_WORK_WINDOW_MINUTES, FOLLOW_UP_SAME_WORK_PAGE_SIZE, before);
|
|
132800
|
+
for (const existing of page) {
|
|
132801
|
+
const match = matchSimilarTask(existing, args);
|
|
132802
|
+
if (match)
|
|
132803
|
+
return match;
|
|
132804
|
+
}
|
|
132805
|
+
const last = page.at(-1);
|
|
132806
|
+
if (!last || page.length < FOLLOW_UP_SAME_WORK_PAGE_SIZE)
|
|
132807
|
+
return null;
|
|
132808
|
+
before = { lastUpdatedAt: last.lastUpdatedAt, id: last.id };
|
|
132809
|
+
}
|
|
132810
|
+
}
|
|
132811
|
+
async function evaluateFollowUpRedelegation(args) {
|
|
132812
|
+
const { channelId, threadTs } = args;
|
|
132813
|
+
const match = await findMatchingCompletedWork(args);
|
|
132814
|
+
if (match) {
|
|
132815
|
+
const existing = match.task;
|
|
132816
|
+
const [cancelled, failed] = await Promise.all([
|
|
132817
|
+
findRecentCancelledTaskInThread2(channelId, threadTs, FOLLOW_UP_SAME_WORK_WINDOW_MINUTES),
|
|
132818
|
+
findRecentFailedTaskInThread2(channelId, threadTs, FOLLOW_UP_SAME_WORK_WINDOW_MINUTES)
|
|
132819
|
+
]);
|
|
132820
|
+
const completedAt = new Date(existing.lastUpdatedAt).getTime();
|
|
132821
|
+
const interruptedLater = [cancelled, failed].some((t) => t && new Date(t.lastUpdatedAt).getTime() > completedAt);
|
|
132822
|
+
if (!interruptedLater) {
|
|
132790
132823
|
return {
|
|
132791
|
-
|
|
132792
|
-
|
|
132824
|
+
rule: "same-work",
|
|
132825
|
+
message: `Blocked by the follow-up re-delegation guard (same-work rule): this task matches completed task ${existing.id.slice(0, 8)} in this Slack thread (${match.reason}), so the work was already done. If it must run again, pass allowRedelegation: true.`
|
|
132793
132826
|
};
|
|
132794
132827
|
}
|
|
132795
132828
|
}
|
|
132829
|
+
const dispatched = await countAgentDispatchesInThread2(channelId, threadTs, args.creatorAgentId, FOLLOW_UP_DISPATCH_WINDOW_MINUTES);
|
|
132830
|
+
if (dispatched >= FOLLOW_UP_DISPATCH_CAP) {
|
|
132831
|
+
return {
|
|
132832
|
+
rule: "loop-cap",
|
|
132833
|
+
message: `Blocked by the follow-up re-delegation guard (loop-cap rule): you already dispatched ${dispatched} times into this Slack thread in the last ${FOLLOW_UP_DISPATCH_WINDOW_MINUTES / 60} hours (cap ${FOLLOW_UP_DISPATCH_CAP}; a durable script run counts once). If this is a deliberate next step and not a re-delegation loop, pass allowRedelegation: true.`
|
|
132834
|
+
};
|
|
132835
|
+
}
|
|
132796
132836
|
return null;
|
|
132797
132837
|
}
|
|
132798
|
-
var
|
|
132799
|
-
var
|
|
132838
|
+
var FOLLOW_UP_SAME_WORK_WINDOW_MINUTES = 2880, FOLLOW_UP_DISPATCH_CAP = 10, FOLLOW_UP_DISPATCH_WINDOW_MINUTES = 360, FOLLOW_UP_SAME_WORK_PAGE_SIZE = 200;
|
|
132839
|
+
var init_follow_up_redelegation_guard = __esm(() => {
|
|
132800
132840
|
init_db4();
|
|
132841
|
+
init_task_dedup();
|
|
132801
132842
|
});
|
|
132802
132843
|
|
|
132803
132844
|
// src/tools/send-task.ts
|
|
@@ -132841,6 +132882,7 @@ async function sendTaskHandler(ctx, {
|
|
|
132841
132882
|
effort,
|
|
132842
132883
|
profile,
|
|
132843
132884
|
allowDuplicate,
|
|
132885
|
+
allowRedelegation,
|
|
132844
132886
|
slackChannelId,
|
|
132845
132887
|
slackThreadTs,
|
|
132846
132888
|
slackUserId,
|
|
@@ -132860,6 +132902,7 @@ async function sendTaskHandler(ctx, {
|
|
|
132860
132902
|
const requestedLeadOnly = ctx.kind === "user" ? false : leadOnly;
|
|
132861
132903
|
const requestedCapabilities = ctx.kind === "user" ? undefined : requiredCapabilities;
|
|
132862
132904
|
const requestedAllowDuplicate = ctx.kind === "user" ? false : allowDuplicate;
|
|
132905
|
+
const requestedAllowRedelegation = ctx.kind === "user" ? false : allowRedelegation;
|
|
132863
132906
|
const requestedOverrideSlackContext = ctx.kind === "user" ? false : overrideSlackContext;
|
|
132864
132907
|
if (requestedAgentId !== undefined && requestedRoutingReason === undefined) {
|
|
132865
132908
|
return toolErr("routingReason is required when agentId is supplied.");
|
|
@@ -133024,7 +133067,7 @@ async function sendTaskHandler(ctx, {
|
|
|
133024
133067
|
if (ctx.kind === "user" && (taskOptions.agentId !== userLead.id || taskOptions.offeredTo !== undefined)) {
|
|
133025
133068
|
return toolErr("A pre.task.create extension cannot change the user task's Lead assignment.");
|
|
133026
133069
|
}
|
|
133027
|
-
const evaluateDedupGuards = async () => {
|
|
133070
|
+
const evaluateDedupGuards = async (logOverride) => {
|
|
133028
133071
|
const existingTrackerWork = await findExistingLinearTrackerContextWork2(effectiveParentTask?.contextKey, effectiveParentTask?.id);
|
|
133029
133072
|
if (existingTrackerWork) {
|
|
133030
133073
|
const msg = `Skipped: Linear tracker contextKey ${effectiveParentTask?.contextKey} already has ${existingTrackerWork.reason === "active_task" ? "active task" : "linked open PR"} ${existingTrackerWork.task.id.slice(0, 8)}.`;
|
|
@@ -133044,25 +133087,24 @@ async function sendTaskHandler(ctx, {
|
|
|
133044
133087
|
};
|
|
133045
133088
|
}
|
|
133046
133089
|
}
|
|
133047
|
-
|
|
133048
|
-
|
|
133049
|
-
|
|
133050
|
-
|
|
133051
|
-
|
|
133052
|
-
|
|
133053
|
-
|
|
133054
|
-
|
|
133055
|
-
|
|
133056
|
-
|
|
133057
|
-
|
|
133058
|
-
|
|
133059
|
-
|
|
133060
|
-
}
|
|
133090
|
+
const followUpThread = creatorAgentId ? await followUpThreadForSourceTask(sourceTaskId) : null;
|
|
133091
|
+
if (followUpThread && creatorAgentId) {
|
|
133092
|
+
const blocked = await evaluateFollowUpRedelegation({
|
|
133093
|
+
...followUpThread,
|
|
133094
|
+
creatorAgentId,
|
|
133095
|
+
taskDescription,
|
|
133096
|
+
targetAgentId: taskOptions.agentId ?? taskOptions.offeredTo
|
|
133097
|
+
});
|
|
133098
|
+
if (blocked && !requestedAllowRedelegation) {
|
|
133099
|
+
return { ok: false, message: blocked.message };
|
|
133100
|
+
}
|
|
133101
|
+
if (blocked && logOverride) {
|
|
133102
|
+
console.log(`[send-task] follow-up re-delegation override: rule=${blocked.rule} creatorAgentId=${creatorAgentId} sourceTaskId=${sourceTaskId} thread=${followUpThread.channelId}/${followUpThread.threadTs}`);
|
|
133061
133103
|
}
|
|
133062
133104
|
}
|
|
133063
133105
|
return null;
|
|
133064
133106
|
};
|
|
133065
|
-
const guard = await evaluateDedupGuards();
|
|
133107
|
+
const guard = await evaluateDedupGuards(true);
|
|
133066
133108
|
if (guard) {
|
|
133067
133109
|
const guardData = {
|
|
133068
133110
|
yourAgentId: creatorAgentId,
|
|
@@ -133071,7 +133113,7 @@ async function sendTaskHandler(ctx, {
|
|
|
133071
133113
|
return guard.ok ? toolOk(guard.message, { data: guardData }) : toolErr(guard.message, { data: guardData });
|
|
133072
133114
|
}
|
|
133073
133115
|
const created = getDbClient2().transaction(async () => {
|
|
133074
|
-
const raced = await evaluateDedupGuards();
|
|
133116
|
+
const raced = await evaluateDedupGuards(false);
|
|
133075
133117
|
if (raced)
|
|
133076
133118
|
return { success: raced.ok, message: raced.message, task: raced.task };
|
|
133077
133119
|
if (isLinearTrackerContextKey2(effectiveParentTask?.contextKey)) {
|
|
@@ -133176,6 +133218,7 @@ var init_send_task = __esm(() => {
|
|
|
133176
133218
|
init_model_validation();
|
|
133177
133219
|
init_apply_task_create();
|
|
133178
133220
|
init_rbac();
|
|
133221
|
+
init_follow_up_redelegation_guard();
|
|
133179
133222
|
init_slack_routing();
|
|
133180
133223
|
init_task_dedup();
|
|
133181
133224
|
init_task_tool_ctx();
|
|
@@ -133205,7 +133248,8 @@ var init_send_task = __esm(() => {
|
|
|
133205
133248
|
allowCustomModel: boolean().optional().describe("Accept a `model` the model catalog does not list. Without it an unknown model id is rejected. Only for ids the catalog cannot know yet (a fresh launch, a private deployment)."),
|
|
133206
133249
|
effort: ReasoningEffortSchema.optional().describe("Reasoning effort for this task: 'off', 'low', 'medium', 'high', 'xhigh', or 'max'. If omitted, the assignee's REASONING_EFFORT_OVERRIDE/default applies."),
|
|
133207
133250
|
profile: string2().trim().min(1).optional().describe("Model profile name (see list-model-profiles): a named harness + model + effort, applied when the task is claimed. Must run on the assignee's harness. Exclusive with model and modelTier. A set `effort` still wins over the profile's."),
|
|
133208
|
-
allowDuplicate: boolean().default(false).describe("If true, skip duplicate detection and create the task even if a similar one exists."),
|
|
133251
|
+
allowDuplicate: boolean().default(false).describe("If true, skip duplicate detection and create the task even if a similar one exists. Does not bypass the follow-up re-delegation guard; see allowRedelegation."),
|
|
133252
|
+
allowRedelegation: boolean().default(false).describe("Only matters when you call send-task from a follow-up task in a Slack thread. Such a dispatch is blocked when it repeats a task already completed in that thread (same-work rule, unless a task there was cancelled or failed after that completion), or when you already dispatched 10 tasks into the thread in the last 6 hours (loop-cap rule). Set true to dispatch anyway; the override is logged. Use it only for deliberate re-runs or long chains, never to retry a block you have not read."),
|
|
133209
133253
|
slackChannelId: string2().optional().describe("Slack channel ID to post progress updates to. Use this to propagate Slack context when delegating from a Slack thread."),
|
|
133210
133254
|
slackThreadTs: string2().optional().describe("Slack thread timestamp. Required with slackChannelId for thread-level updates."),
|
|
133211
133255
|
slackUserId: string2().optional().describe("Slack user ID of the original requester."),
|
|
@@ -135196,7 +135240,7 @@ var registerSlackLeaveThreadTool = (server) => {
|
|
|
135196
135240
|
if (!slackChannelId || !slackThreadTs) {
|
|
135197
135241
|
return toolErr("No Slack thread context available.");
|
|
135198
135242
|
}
|
|
135199
|
-
await leaveSlackThread(slackChannelId, slackThreadTs, agent.id);
|
|
135243
|
+
await leaveSlackThread(slackChannelId, slackThreadTs, { agentId: agent.id });
|
|
135200
135244
|
return toolOk(`Left Slack thread ${slackChannelId}/${slackThreadTs}. Messages there are ignored until someone @mentions the bot.`, { data: { channelId: slackChannelId, threadTs: slackThreadTs } });
|
|
135201
135245
|
});
|
|
135202
135246
|
};
|
|
@@ -140028,4 +140072,4 @@ var init_server = __esm(() => {
|
|
|
140028
140072
|
loggedToolAllowlistWarnings = new Set;
|
|
140029
140073
|
});
|
|
140030
140074
|
|
|
140031
|
-
export { DEFAULT_NEGOTIATED_PROTOCOL_VERSION, SUPPORTED_PROTOCOL_VERSIONS, isJSONRPCRequest, isJSONRPCResultResponse, isJSONRPCErrorResponse, JSONRPCMessageSchema, isInitializeRequest, init_types, McpServer, init_mcp, repointTrackerSyncBySwarmId, init_tracker, isRuntimePoolWakeable, isAgentReachable, init_reachability, referencedBundlePaths, skillDirs, init_manifest_format, TaskCreationBlockedError, init_errors2, resolveIdentity, renderIdentity, init_identity, recordUnmappedIdentity, init_unmapped_identities, MAX_TASK_ATTACHMENT_BYTES, recordTaskAttachmentUpload, scopeFromAttachment, backingProviderId, init_task_attachment_store, taskModelPin, resumedTaskModelSelection, init_model_pin, listHarnessModelSupport, recordHarnessModelSupport, agentRanModel, getAgentHarnessCliVersion, setAgentHarnessCliVersion, init_harness_model_support, sanitizeModelTierOverrides, parseModelTierOverridesHeader, setAgentModelTierOverrides, previewModelTiers, recordClaimModelResolution, init_model_tier_resolution, harnessModelErrorFor, poolTaskRunsOnHarness, explicitModelError, explicitModelErrorForAgent, init_model_validation, stripSiblingBlock, init_sibling_block, createTaskWithSiblingAwareness, init_sibling_awareness, transcribeAudioNotes, init_transcription, init_templates, buildEffectiveText, bufferedFileFailures, fetchSlackFiles, createSlackTaskWithFiles, notifySlackFileFailures, init_inbound_files, isAddressedToOtherUser, broadcastMatches, routeMessage, extractTaskFromMessage, init_router,
|
|
140075
|
+
export { DEFAULT_NEGOTIATED_PROTOCOL_VERSION, SUPPORTED_PROTOCOL_VERSIONS, isJSONRPCRequest, isJSONRPCResultResponse, isJSONRPCErrorResponse, JSONRPCMessageSchema, isInitializeRequest, init_types, McpServer, init_mcp, repointTrackerSyncBySwarmId, init_tracker, isRuntimePoolWakeable, isAgentReachable, init_reachability, referencedBundlePaths, skillDirs, init_manifest_format, TaskCreationBlockedError, init_errors2, resolveIdentity, renderIdentity, init_identity, recordUnmappedIdentity, init_unmapped_identities, MAX_TASK_ATTACHMENT_BYTES, recordTaskAttachmentUpload, scopeFromAttachment, backingProviderId, init_task_attachment_store, taskModelPin, resumedTaskModelSelection, init_model_pin, listHarnessModelSupport, recordHarnessModelSupport, agentRanModel, getAgentHarnessCliVersion, setAgentHarnessCliVersion, init_harness_model_support, sanitizeModelTierOverrides, parseModelTierOverridesHeader, setAgentModelTierOverrides, previewModelTiers, recordClaimModelResolution, init_model_tier_resolution, harnessModelErrorFor, poolTaskRunsOnHarness, explicitModelError, explicitModelErrorForAgent, init_model_validation, stripSiblingBlock, init_sibling_block, createTaskWithSiblingAwareness, init_sibling_awareness, transcribeAudioNotes, init_transcription, init_templates, buildEffectiveText, bufferedFileFailures, fetchSlackFiles, createSlackTaskWithFiles, notifySlackFileFailures, init_inbound_files, isAddressedToOtherUser, broadcastMatches, routeMessage, extractTaskFromMessage, init_router, extractSlackMessageText, slackInboundMessageText, collectSlackMessageFiles, init_message_text, createAdditiveBuffer, init_additive_buffer, recoverIncompleteRuns, init_recovery, handleWebhookTrigger, verifyHmacSignature, WebhookError, init_triggers, snapshotAndUpdateWorkflow, init_version, RawLlmConfigSchema, RawLlmOutputSchema, executeRawLlm, init_raw_llm, getExecutorRegistry2, initWorkflows2, init_workflows, dispatchScheduleTarget, calculateNextRun2, startScheduler2, stopScheduler2, runScheduleNow2, init_scheduler, ExtensionAssetConflictError, init_assets, ExtensionOwnershipError, getExtensionFiles, getExtensionById, getExtensionByName, listExtensions, listExtensionVersions, updateExtensionMeta, listExtensionRuns, init_db, SDK_ALLOWLIST, mcpToolNameForSdkMethod, init_sdk_allowlist, MCP_OVERFLOW_NAMESPACE, mcpOverflowAuthError, init_kv_overflow, hasKvViewArgs, resolveKvView, init_kv_view, toolErr, createToolRegistrar, init_utils, handleMcpBridge, init_mcp_bridge, Redacted, init_redacted, SCRIPT_SDK_RESPONSE_LIMIT_BYTES, readScriptSdkJsonResponse, init_response_limit, ExtensionConfigError, init_loader, ExtensionLifecycleError, setExtensionLoopbackBaseUrl, enableExtension, disableExtension, activateVersion, ExtensionAssetsInvalidError, installExtensionWithAssets, uninstallExtension, reloadExtension, loadEnabledExtensions, stopExtensionRuntime, init_lifecycle, ExtensionAbortedError2, isRegistered2, isExtensionAgentId2, getExtensionBridgeToken2, resolveBridgeCallOrigin2, extensionIdForAgent2, runContext2, registerLoaded2, unregister2, listRegistered2, dispatchPre2, dispatchPost2, init_dispatcher, REBOOT_RETRY_PIN_TAG2, getPinCandidateAgent2, resolveLeadOnlyRecoveryAssignment2, getResumeGeneration2, getNextResumeGeneration2, inheritedModelSelection2, createWorkerTaskFollowUp2, createResumeFollowUp2, createRerouteDecisionTask2, createPoolStarvationDecisionTask2, init_worker_follow_up, isGitHubEnabled, initGitHub, verifyWebhookSignature, isAgentMailEnabled, initAgentMail, verifyAgentMailWebhook, isInboxAllowed, isSenderAllowed, handleMessageReceived, init_agentmail, isAzureDevOpsEnabled, initAzureDevOps, verifyAzureDevOpsWebhook, isAzureDevOpsUrl, canonicalAzureDevOpsRepoUrl, parseAzureDevOpsRepoUrl, init_azure_devops, createdPullRequestOf, commentedPayloadOf, handlePullRequestCreated, handlePullRequestCommented, handleWorkItemCreated, handleWorkItemUpdated, handleWorkItemCommented, handleWorkItemDeleted, handleWorkItemRestored, initAzureDevOpsOutbound, init_azure_devops2, enqueueAuditRow, enqueueAdmissionRow, flushAuditBuffer, startAuditWriter, stopAuditWriter, startAuditGc, stopAuditGc, init_rbac_audit, getTelemetryIngestAnchor, init_telemetry_ingest_anchor, initApiTelemetry, syncTelemetryEnabled, init_telemetry_enable, isBitbucketEnabled, initBitbucket, verifyBitbucketWebhook, isDuplicateDelivery, markDeliveryProcessed, pullRequestEventOf, pullRequestCommentEventOf, handlePullRequestCreated2, handlePullRequestCommentCreated, handlePullRequestClosed, init_bitbucket, handlePullRequest, handleIssue, handleComment, handlePullRequestReview, handleCheckRun, handleCheckSuite, handleWorkflowRun, init_github, isGitLabEnabled, initGitLab, verifyGitLabWebhook, handleMergeRequest, handleIssue2, handleNote, handlePipeline, init_gitlab, isChatSdkEnabled, getChatSdkConfig, init_config, errorMessage, init_logger, resolveAdapterApiUrl, init_adapters, trackBackground, init_background, TelegramBotApiError, callTelegramBotApi, init_telegram_api, isTrustedTeamsServiceUrl, init_teams_origin, getSessionLabels, rememberSessionLabel, init_session_labels, isChatSdkStopping, startChatSdk, getChatInstance, isChatAdapterConfigured, getChatSdkHealth, stopChatSdk, init_runtime, getJiraMetadata, updateJiraMetadata, clearJiraMetadata, init_metadata, registerJiraWebhook, deleteJiraWebhook, init_webhook_lifecycle, isJiraEnabled, initJira, init_app, handleJiraWebhook, init_webhook, init_jira, handleAgentSessionEvent, handleIssueUpdate, handleIssueDelete, handleAgentSessionPrompted, init_sync, isLinearEnabled, initLinear, init_app2, init_linear, init_slack, isCookieSafePageId, extractPageSession, extractLegacyPageSession, extractAndVerifyCookie, pageSessionSetCookies, init_page_session, resolveHttpRequestAuth, init_auth, getDeploymentEnvValue, loadGlobalConfigsIntoEnv, reloadGlobalConfigsAndIntegrations, scheduleIntegrationsReload, handleCore, init_core, MCP_MAX_TOOL_INPUT_ELEMENTS, MCP_MAX_REQUEST_BODY_BYTES, init_mcp_limits, userCtx, init_task_tool_ctx, requestPrincipal, agentFirstPrincipal, requireAuthKind, rejectGuest, init_request_principal, handleApps, init_apps, cancelApprovalRequest, cancelApprovalRequestAndRun, init_approval_cancel, getUserCommsPrefs, init_requester_comms, getTaskDetailsInputSchema, getTaskDetailsOutputSchema, getTaskDetailsHandler, init_get_task_details, cancelTaskInputSchema, cancelTaskOutputSchema, cancelTaskHandler, init_cancel_task, executeReadOnlyQuery, assertSelectOnlyQuery, handleDbQuery, init_db_query, snapshotMetric, init_version2, AssetKeyAuthorizationError, authorizeAssetKeyWrite, init_asset_key_auth, getPageEditCounter, init_page_versions, snapshotPage, init_version3, assertOAuthAppUrlsSafe, assertOAuthEgressUrlSafe, init_app_validation, listOAuthPresets, listOAuthPresetIds, getOAuthPreset, hydrateOAuthAppFromPreset, init_presets, scopedResourceScopeIdSchema, resolveScopedResourceId, init_scoped_resource, MemoryKeyError, init_key_guard, refreshLinks, init_link_resolver, indexMemoryContent, init_index_content, dedupeMemoryDocumentIds, recordMemoryAccesses, recordRetrievals, init_retrieval, ExplicitSelfDuplicateError, applyRating, init_store, shouldPersistAutomaticTaskMemory, init_automatic_task_gate, guardTerminalTaskResultWrite, init_terminal_result_guard, getTasksInputSchema, getTasksOutputSchema, getTasksHandler, init_get_tasks, reservedNamespaceError, privateNamespaceError, reservedRoomKeyError, init_kv_reserved_namespaces, updateMcpServerChecked, init_mcp_server_checked_update, updateTouchesStdioExecution, init_mcp_server_stdio_gate, canReadMemory, init_access, getLinksForMemory, init_links_store, expandCandidatesWithGraph, init_graph_expansion, isApiDraining, drainApi, init_api_drain, markKapsoMessageRead, sendKapsoReaction, init_client, getKapsoConfig, getKapsoNumberMapping, markKapsoMessageSeen, init_config2, changesAllowMerge, init_repo_merge_policy, updateSwarmRepoChecked, init_repo_checked_update, getCombConfig, init_config3, resolveRoomNamespace, roomRequestInfo, authorizeRoomNamespace, sessionAccessTopic, sessionPresenceRoot, init_auth2, RoomOperationSchema, init_document, removeAwarenessStates, init_awareness, roomTopic, decodeRoomSnapshot, roomView, getRoom, changeRoom, applyRoomUpdate, resetRoom, sweepRooms, closeRooms, removeNamespaceRooms, init_rooms, init_scheduler2, MEMORY_KEYS_DEFAULT_PREFIX, MEMORY_KEYS_MAX_LIMIT, estimateTokens, posteriorMean, listMemoryKeys, checkChunkIntegrity, getMemoryChunks, getPosteriorsByIds, init_key_browser, createEvent, createEventsBatch, getEventCountsFiltered, getEventsFiltered, init_events, mergeScheduleTiming, validateRecurringTiming, init_validate, followUpThreadForSourceTask, evaluateFollowUpRedelegation, init_follow_up_redelegation_guard, checkOutputSchemaShape, sendTaskOutputSchema, sendTaskHandler, init_send_task, steerTaskUserInputSchema, steerTaskOutputSchema, steerTaskHandler, init_steer_task, canClaim, init_budget_admission, emitBudgetRefusalSideEffects, init_budget_refusal_notify, workflowModelErrors, init_model_validation2, patchWorkflowDefinition, init_patch_definition, idempotencyKeyHeader, readIdempotencyKey, replayAcceptedOperation, init_idempotency_key, resolveScriptsOnlyMode, init_scripts_only_mode, ALL_CAPABILITIES, hasCapability, getEnabledCapabilities, createServer, init_server };
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
} from "./cli-dhar9qay.js";
|
|
6
6
|
import {
|
|
7
7
|
runStopHookSessionSummarySubprocess
|
|
8
|
-
} from "./cli-
|
|
8
|
+
} from "./cli-decfb6v8.js";
|
|
9
9
|
import {
|
|
10
10
|
redactRateLimitEventLine,
|
|
11
11
|
SessionErrorTracker,
|
|
@@ -1263,7 +1263,7 @@ class ClaudeAdapter2 {
|
|
|
1263
1263
|
if (transport === "sdk" && isClaudeBridgeEffective(sourceEnv)) {
|
|
1264
1264
|
throw new Error("CLAUDE_TRANSPORT=sdk cannot run with an effective Claude Bridge configuration. Select CLI transport or disable the bridge.");
|
|
1265
1265
|
}
|
|
1266
|
-
const claudeSdk = transport === "sdk" ? await import("./claude-sdk-session-
|
|
1266
|
+
const claudeSdk = transport === "sdk" ? await import("./claude-sdk-session-zgrz6yvc.js") : undefined;
|
|
1267
1267
|
claudeSdk?.validateClaudeSdkAdditionalArgs([
|
|
1268
1268
|
...claudeBinaryArgv.slice(1),
|
|
1269
1269
|
...config.additionalArgs ?? []
|