@desplega.ai/agent-swarm 1.121.0 → 1.122.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (84) hide show
  1. package/README.md +3 -3
  2. package/dist/{actions-mwshtkf7.js → actions-k3bwtmgy.js} +5 -5
  3. package/dist/{app-skbty91x.js → app-knevny0f.js} +3 -3
  4. package/dist/{assistant-tg7dhfj8.js → assistant-as8087ft.js} +8 -8
  5. package/dist/{boot-reembed-ntjmeyh2.js → boot-reembed-1dcc1yyk.js} +3 -3
  6. package/dist/{boot-reembed-q5x0xpcp.js → boot-reembed-j305cpdr.js} +4 -4
  7. package/dist/{boot-scrub-logs-5gznsfbe.js → boot-scrub-logs-w9qkjzkm.js} +2 -2
  8. package/dist/{cli-s8bdcke2.js → cli-00yr0kxv.js} +1 -1
  9. package/dist/{cli-6s3ytc5x.js → cli-16dv125e.js} +27 -2
  10. package/dist/cli-3dpj7atn.js +11 -0
  11. package/dist/{cli-srjqn7fd.js → cli-3ptjc655.js} +1 -1
  12. package/dist/{cli-vg3zrw6h.js → cli-586x669g.js} +4 -4
  13. package/dist/{cli-5hpvd15x.js → cli-60q15ncp.js} +2 -2
  14. package/dist/{cli-ghq3v4c9.js → cli-7jb8mk4n.js} +1 -1
  15. package/dist/{cli-ky8esb8t.js → cli-8sv69q06.js} +3 -3
  16. package/dist/{cli-072t49hf.js → cli-8x745f40.js} +3 -3
  17. package/dist/{cli-3b1ayz83.js → cli-9fhxk91h.js} +5 -5
  18. package/dist/{cli-nf7sadev.js → cli-bxdb36d2.js} +2 -2
  19. package/dist/{cli-g9vva2qh.js → cli-fc1gvt9c.js} +1 -1
  20. package/dist/{cli-agdrxyex.js → cli-haeq79yf.js} +1 -1
  21. package/dist/{cli-7pzae66m.js → cli-hjq6c6vz.js} +1 -1
  22. package/dist/{cli-b2mqkg1h.js → cli-j89ph4c4.js} +2 -2
  23. package/dist/{cli-4pfweq4x.js → cli-kpfsabp2.js} +5 -5
  24. package/dist/{cli-95rbe11h.js → cli-m7dmk462.js} +12 -9
  25. package/dist/{cli-0df2g86x.js → cli-mjxnr12j.js} +1 -1
  26. package/dist/{cli-3fxqwfh3.js → cli-qf0qxzw5.js} +5 -5
  27. package/dist/{cli-vp9r4ap4.js → cli-qnmj37m5.js} +2 -2
  28. package/dist/{cli-tv7vekye.js → cli-tc8xk5zh.js} +1 -1
  29. package/dist/{cli-dmzv0986.js → cli-vh3h1grg.js} +10 -1
  30. package/dist/{cli-46etyprn.js → cli-w48hgc2y.js} +1 -1
  31. package/dist/{cli-avw9ev3x.js → cli-wmx631p8.js} +14 -11
  32. package/dist/{cli-gdpx70nc.js → cli-y3an9mk7.js} +19 -19
  33. package/dist/{cli-1728qh70.js → cli-z3hcrghs.js} +1 -1
  34. package/dist/{cli-p9w7kb3h.js → cli-zpa6gjwq.js} +1 -1
  35. package/dist/{cli-7pt9sc83.js → cli-zweca3q3.js} +3 -2
  36. package/dist/cli.js +10 -10
  37. package/dist/{codex-adapter-mmy741zd.js → codex-adapter-0kv2meed.js} +3 -2
  38. package/dist/{codex-session-runner-sazmx9zt.js → codex-session-runner-m1e1v4r0.js} +3 -2
  39. package/dist/{commands-cxxye5e4.js → commands-6j54dz62.js} +2 -2
  40. package/dist/{db-ab1954b7.js → db-gcnz2tqx.js} +2 -2
  41. package/dist/{handlers-fmfe2343.js → handlers-c43sm2h1.js} +8 -8
  42. package/dist/{hook-ygnw3cvt.js → hook-y1p25vm5.js} +3 -2
  43. package/dist/{http-kactcc0z.js → http-bsz1rze1.js} +35 -34
  44. package/dist/{index-gmzs6a2q.js → index-03zn2rz7.js} +10 -9
  45. package/dist/{index-g86j2yt5.js → index-7swcv6rv.js} +7 -7
  46. package/dist/{index-hmp82wn0.js → index-8m5gd1vs.js} +12 -11
  47. package/dist/{index-6erq0wvk.js → index-qyzfh62q.js} +11 -10
  48. package/dist/{keepalive-3cvt26dw.js → keepalive-69v93p45.js} +5 -5
  49. package/dist/{lead-ysf26cjr.js → lead-xn8kfchy.js} +23 -22
  50. package/dist/{maintenance-9npwptbb.js → maintenance-g2x7q13q.js} +4 -4
  51. package/dist/{oauth-refresh-sweep-0r2v76vw.js → oauth-refresh-sweep-j80szsyr.js} +4 -4
  52. package/dist/{onboard-ddb1674a.js → onboard-e3xcjt8b.js} +2 -2
  53. package/dist/{opencode-adapter-h6rkxwrk.js → opencode-adapter-s3nhtp9m.js} +4 -1
  54. package/dist/{otel-impl-b43bkq8e.js → otel-impl-24egvjaa.js} +1 -1
  55. package/dist/{pi-mono-adapter-ke789738.js → pi-mono-adapter-k3z6e5fn.js} +102 -4
  56. package/dist/{pricing-refresh-2rqf114z.js → pricing-refresh-01kg9gky.js} +4 -4
  57. package/dist/{rbac-roles-6vtafvzb.js → rbac-roles-f9bdj93y.js} +2 -2
  58. package/dist/{rbac-roles-5wkhc8xv.js → rbac-roles-jqfp0zza.js} +3 -3
  59. package/dist/{seed-pricing-23wrb873.js → seed-pricing-z2t7rank.js} +3 -3
  60. package/dist/{setup-6rny4fk6.js → setup-kw2ps002.js} +2 -2
  61. package/dist/{worker-yapewe14.js → worker-336w8930.js} +23 -22
  62. package/openapi.json +1 -1
  63. package/package.json +1 -1
  64. package/src/be/memory/constants.ts +7 -6
  65. package/src/be/memory/graph-expansion.ts +3 -3
  66. package/src/be/memory/raters/llm-summarizer.ts +10 -2
  67. package/src/commands/provider-credentials.ts +2 -1
  68. package/src/http/memory.ts +2 -1
  69. package/src/providers/codex-adapter.ts +3 -0
  70. package/src/providers/opencode-adapter.ts +40 -0
  71. package/src/providers/pi-mono-adapter.ts +179 -1
  72. package/src/providers/pi-mono-extension.ts +9 -0
  73. package/src/tests/agent-avatar-resolution.test.ts +170 -0
  74. package/src/tests/memory-feature-flags.test.ts +45 -0
  75. package/src/tests/memory-rater-llm-summarizer.test.ts +24 -0
  76. package/src/tests/opencode-plugin.test.ts +43 -0
  77. package/src/tests/openrouter-base-url.test.ts +256 -0
  78. package/src/tests/pi-mono-adapter.test.ts +90 -0
  79. package/src/tools/memory-search.ts +2 -1
  80. package/src/utils/internal-ai/complete-structured.ts +19 -1
  81. package/src/utils/internal-ai/summarize-session.ts +7 -0
  82. package/src/utils/openrouter-base-url.ts +28 -0
  83. package/src/workflows/executors/raw-llm.ts +2 -1
  84. package/src/workflows/executors/validate.ts +2 -1
package/README.md CHANGED
@@ -134,7 +134,7 @@ Check [our templates](https://templates.agent-swarm.dev) for a quick start.
134
134
  - **Scripts as external APIs** — expose a saved script as a public `POST /api/x/script/<id>` endpoint with optional bearer auth, typed input validation, and per-endpoint usage tracking. [Guide →](https://docs.agent-swarm.dev/docs/guides/scripts-external-apis)
135
135
  - **Typed script API connections** — lead-managed OpenAPI, GraphQL, and MCP connections generate `ctx.api.*` / `ctx.mcp.*` clients for scripts, with credential bindings and OAuth-backed auth kept server-side. [Guide →](https://docs.agent-swarm.dev/docs/guides/script-connections)
136
136
  - **E2B-backed eval harness** — run a scenario × harness-config matrix against real swarm stacks, capture transcripts/artifacts, and grade outcomes with deterministic checks plus LLM or agentic judges. [Guide →](https://docs.agent-swarm.dev/docs/guides/evals-harness)
137
- - **Harness & LLM agnostic** — run with Claude Code, Claude Bridge, OpenAI Codex, pi-mono (Anthropic, OpenRouter, or Amazon Bedrock), Devin, Claude Managed Agents, raw LLMs, or opencode. Tasks, schedules, and workflow agent-task nodes can use portable `modelTier` intent (`smol`, `regular`, `smart`, `ultra`), and operators can set per-agent reasoning effort (`off` → `max`, where supported) without changing task payloads. [Harness config →](https://docs.agent-swarm.dev/docs/guides/harness-configuration) · [Add a new provider →](https://docs.agent-swarm.dev/docs/guides/harness-providers)
137
+ - **Harness & LLM agnostic** — run with Claude Code, Claude Bridge, OpenAI Codex, pi-mono (Anthropic, OpenRouter, or Amazon Bedrock), Devin, Claude Managed Agents, raw LLMs, or opencode. Route every OpenRouter-backed harness, workflow, and summarizer through an OpenAI-compatible gateway with `OPENROUTER_BASE_URL`. Tasks, schedules, and workflow agent-task nodes can use portable `modelTier` intent (`smol`, `regular`, `smart`, `ultra`), and operators can set per-agent reasoning effort (`off` → `max`, where supported) without changing task payloads. [Harness config →](https://docs.agent-swarm.dev/docs/guides/harness-configuration) · [Add a new provider →](https://docs.agent-swarm.dev/docs/guides/harness-providers)
138
138
  - **OpenTelemetry traces plus OTLP cost/token metrics** — export API + worker traces and finalized session cost/token counters through the same OTLP pipeline for dashboarding in SigNoz, Datadog, Tempo, or another compatible backend. [Observability →](https://docs.agent-swarm.dev/docs/guides/observability-opentelemetry)
139
139
  - **Follow-up continuity across all harnesses** — child tasks inherit a bounded prior-task context preamble built from the task chain, so continuity survives restarts and works the same across every provider. [Task lifecycle →](https://docs.agent-swarm.dev/docs/concepts/task-lifecycle)
140
140
  - **Skills & MCP servers** — reusable procedural knowledge, bundled skill reference files, and per-agent MCP servers with scope cascade. [MCP tools →](https://docs.agent-swarm.dev/docs/reference/mcp-tools)
@@ -142,7 +142,7 @@ Check [our templates](https://templates.agent-swarm.dev) for a quick start.
142
142
  - **Config-driven metrics dashboards** — define read-only SQL widgets, version them, and render them in the dashboard without shipping custom frontend code. [Metrics API →](https://docs.agent-swarm.dev/docs/api-reference/stats)
143
143
  - **DB-backed pages** — agents publish HTML or JSON pages (reports, dashboards, action specs) via `create_page`, remove stale pages with `delete-page`, and share them with public / authed / password modes, version history, view counters, diff helpers, and PDF export. [MCP tools → Pages](https://docs.agent-swarm.dev/docs/reference/mcp-tools#pages-tools)
144
144
  - **KV store** — Redis-like namespaced key/value store with auto-scoped context (Slack thread / PR / Linear issue / page). [MCP tools → KV](https://docs.agent-swarm.dev/docs/reference/mcp-tools#kv-tools)
145
- - **Real-time dashboard + task attachments** — monitor agents, tasks, and inter-agent chat; rename sessions inline; customize each agent's icon and color; filter Pages, Approval Requests, and workflow definitions with URL-backed search/facets; create tasks with uploaded files from the sessions composer; and preview task attachments inline above session prompts. [app.agent-swarm.dev →](https://app.agent-swarm.dev)
145
+ - **Real-time dashboard + task attachments** — monitor agents, tasks, and inter-agent chat; rename sessions inline; search a broad Lucide catalog to customize each agent's icon and color; filter Pages, Approval Requests, and workflow definitions with URL-backed search/facets; create tasks with uploaded files from the sessions composer; and preview task attachments inline above session prompts. [app.agent-swarm.dev →](https://app.agent-swarm.dev)
146
146
 
147
147
  ## Quick Start
148
148
 
@@ -217,7 +217,7 @@ Missing one? Ask the swarm to build it.
217
217
 
218
218
  ## Dashboard
219
219
 
220
- Real-time monitoring of agents, tasks, and inter-agent chat. Session titles can be renamed inline, and agent profiles can use a custom Lucide icon and color while retaining deterministic defaults. Use the hosted version at [app.agent-swarm.dev](https://app.agent-swarm.dev), or run locally:
220
+ Real-time monitoring of agents, tasks, and inter-agent chat. Session titles can be renamed inline, and agent profiles can search hundreds of Lucide icons, pick a color, and retain deterministic defaults when no customization is set. Use the hosted version at [app.agent-swarm.dev](https://app.agent-swarm.dev), or run locally:
221
221
 
222
222
  ```bash
223
223
  cd apps/ui && bun install && bun run dev
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  resolveSlackUserId
3
- } from "./cli-nf7sadev.js";
4
- import"./cli-srjqn7fd.js";
3
+ } from "./cli-bxdb36d2.js";
4
+ import"./cli-3ptjc655.js";
5
5
  import {
6
6
  createTaskWithSiblingAwareness
7
- } from "./cli-s8bdcke2.js";
7
+ } from "./cli-00yr0kxv.js";
8
8
  import {
9
9
  buildCancelledBlocks,
10
10
  getTaskLink
@@ -19,9 +19,9 @@ import {
19
19
  init_context_key,
20
20
  init_db,
21
21
  slackContextKey
22
- } from "./cli-0df2g86x.js";
22
+ } from "./cli-mjxnr12j.js";
23
23
  import"./cli-z2zcxes1.js";
24
- import"./cli-46etyprn.js";
24
+ import"./cli-w48hgc2y.js";
25
25
  import"./cli-4j2mrzag.js";
26
26
  import"./cli-bw80ck94.js";
27
27
  import"./cli-xz9aq0rf.js";
@@ -3,15 +3,15 @@ import {
3
3
  initSlackApp,
4
4
  startSlackApp,
5
5
  stopSlackApp
6
- } from "./cli-3b1ayz83.js";
6
+ } from "./cli-9fhxk91h.js";
7
7
  import"./cli-rkndnn90.js";
8
8
  import"./cli-b0p7rfnd.js";
9
9
  import"./cli-ma04faw5.js";
10
10
  import"./cli-wspgs9bt.js";
11
11
  import"./cli-dh55d5fg.js";
12
- import"./cli-0df2g86x.js";
12
+ import"./cli-mjxnr12j.js";
13
13
  import"./cli-z2zcxes1.js";
14
- import"./cli-46etyprn.js";
14
+ import"./cli-w48hgc2y.js";
15
15
  import"./cli-4j2mrzag.js";
16
16
  import"./cli-bw80ck94.js";
17
17
  import"./cli-xz9aq0rf.js";
@@ -1,21 +1,21 @@
1
1
  import {
2
2
  bufferThreadMessage,
3
3
  wasEventSeen
4
- } from "./cli-4pfweq4x.js";
4
+ } from "./cli-kpfsabp2.js";
5
5
  import {
6
6
  hasOtherUserMention
7
- } from "./cli-g9vva2qh.js";
7
+ } from "./cli-fc1gvt9c.js";
8
8
  import {
9
9
  resolveSlackUserId,
10
10
  rewriteSlackMentions
11
- } from "./cli-nf7sadev.js";
12
- import"./cli-srjqn7fd.js";
11
+ } from "./cli-bxdb36d2.js";
12
+ import"./cli-3ptjc655.js";
13
13
  import {
14
14
  createTaskWithSiblingAwareness
15
- } from "./cli-s8bdcke2.js";
15
+ } from "./cli-00yr0kxv.js";
16
16
  import {
17
17
  require_dist
18
- } from "./cli-3b1ayz83.js";
18
+ } from "./cli-9fhxk91h.js";
19
19
  import"./cli-rkndnn90.js";
20
20
  import"./cli-b0p7rfnd.js";
21
21
  import"./cli-ma04faw5.js";
@@ -30,9 +30,9 @@ import {
30
30
  init_resolver,
31
31
  resolveTemplate,
32
32
  slackContextKey
33
- } from "./cli-0df2g86x.js";
33
+ } from "./cli-mjxnr12j.js";
34
34
  import"./cli-z2zcxes1.js";
35
- import"./cli-46etyprn.js";
35
+ import"./cli-w48hgc2y.js";
36
36
  import"./cli-4j2mrzag.js";
37
37
  import"./cli-bw80ck94.js";
38
38
  import"./cli-xz9aq0rf.js";
@@ -3,14 +3,14 @@ import {
3
3
  getEmbeddingProvider,
4
4
  getMemoryStore,
5
5
  init_constants
6
- } from "./cli-3fxqwfh3.js";
6
+ } from "./cli-qf0qxzw5.js";
7
7
  import"./cli-q25ejbyn.js";
8
8
  import {
9
9
  getDb,
10
10
  init_db
11
- } from "./cli-0df2g86x.js";
11
+ } from "./cli-mjxnr12j.js";
12
12
  import"./cli-z2zcxes1.js";
13
- import"./cli-46etyprn.js";
13
+ import"./cli-w48hgc2y.js";
14
14
  import"./cli-4j2mrzag.js";
15
15
  import"./cli-bw80ck94.js";
16
16
  import"./cli-xz9aq0rf.js";
@@ -1,15 +1,15 @@
1
1
  import {
2
2
  embedScript,
3
3
  embeddingProvider
4
- } from "./cli-5hpvd15x.js";
5
- import"./cli-3fxqwfh3.js";
4
+ } from "./cli-60q15ncp.js";
5
+ import"./cli-qf0qxzw5.js";
6
6
  import"./cli-q25ejbyn.js";
7
7
  import {
8
8
  getDb,
9
9
  init_db
10
- } from "./cli-0df2g86x.js";
10
+ } from "./cli-mjxnr12j.js";
11
11
  import"./cli-z2zcxes1.js";
12
- import"./cli-46etyprn.js";
12
+ import"./cli-w48hgc2y.js";
13
13
  import"./cli-4j2mrzag.js";
14
14
  import"./cli-bw80ck94.js";
15
15
  import"./cli-xz9aq0rf.js";
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  getDb,
3
3
  init_db
4
- } from "./cli-0df2g86x.js";
4
+ } from "./cli-mjxnr12j.js";
5
5
  import"./cli-z2zcxes1.js";
6
- import"./cli-46etyprn.js";
6
+ import"./cli-w48hgc2y.js";
7
7
  import {
8
8
  init_secret_scrubber,
9
9
  scrubSecrets
@@ -3,7 +3,7 @@ import {
3
3
  getAgentById,
4
4
  getInProgressTasksByContextKey,
5
5
  init_db
6
- } from "./cli-0df2g86x.js";
6
+ } from "./cli-mjxnr12j.js";
7
7
 
8
8
  // src/tasks/sibling-awareness.ts
9
9
  init_db();
@@ -21,6 +21,10 @@ import {
21
21
  import {
22
22
  applyReasoningEffort
23
23
  } from "./cli-e61fs2hp.js";
24
+ import {
25
+ DEFAULT_OPENROUTER_BASE_URL,
26
+ getOpenRouterBaseUrl
27
+ } from "./cli-3dpj7atn.js";
24
28
  import {
25
29
  init_credentials,
26
30
  validateOpencodeCredentials
@@ -1646,6 +1650,21 @@ async function readSpawnOutput(stream) {
1646
1650
  function formatUnknownError(err) {
1647
1651
  return err instanceof Error ? err.message : String(err);
1648
1652
  }
1653
+ function applyOpenRouterBaseUrlOverride(opencodeConfig, env = process.env) {
1654
+ const openRouterBaseUrl = getOpenRouterBaseUrl(env);
1655
+ if (openRouterBaseUrl === DEFAULT_OPENROUTER_BASE_URL)
1656
+ return;
1657
+ opencodeConfig.provider = {
1658
+ ...opencodeConfig.provider,
1659
+ openrouter: {
1660
+ ...opencodeConfig.provider?.openrouter,
1661
+ options: {
1662
+ ...opencodeConfig.provider?.openrouter?.options,
1663
+ baseURL: openRouterBaseUrl
1664
+ }
1665
+ }
1666
+ };
1667
+ }
1649
1668
  async function refreshOpenRouterModelCache(opencodeConfig, configFilePath, dataHomePath) {
1650
1669
  const binary = process.env.OPENCODE_BINARY || "opencode";
1651
1670
  const proc = Bun.spawn([binary, "models", "--refresh", "openrouter"], {
@@ -2072,6 +2091,7 @@ class OpencodeAdapter {
2072
2091
  }
2073
2092
  };
2074
2093
  }
2094
+ applyOpenRouterBaseUrlOverride(opencodeConfig, config.env ?? process.env);
2075
2095
  try {
2076
2096
  await Bun.write(configFilePath, JSON.stringify(opencodeConfig, null, 2));
2077
2097
  } catch {}
@@ -2081,13 +2101,18 @@ class OpencodeAdapter {
2081
2101
  SWARM_API_KEY: process.env.SWARM_API_KEY,
2082
2102
  SWARM_AGENT_ID: process.env.SWARM_AGENT_ID,
2083
2103
  SWARM_TASK_ID: process.env.SWARM_TASK_ID,
2084
- SWARM_IS_LEAD: process.env.SWARM_IS_LEAD
2104
+ SWARM_IS_LEAD: process.env.SWARM_IS_LEAD,
2105
+ OPENROUTER_BASE_URL: process.env.OPENROUTER_BASE_URL
2085
2106
  };
2086
2107
  process.env.SWARM_API_URL = config.apiUrl;
2087
2108
  process.env.SWARM_API_KEY = config.apiKey;
2088
2109
  process.env.SWARM_AGENT_ID = config.agentId;
2089
2110
  process.env.SWARM_TASK_ID = config.taskId;
2090
2111
  process.env.SWARM_IS_LEAD = config.role === "lead" ? "true" : "false";
2112
+ const spawnOpenRouterBaseUrl = getOpenRouterBaseUrl(config.env ?? process.env);
2113
+ if (spawnOpenRouterBaseUrl !== DEFAULT_OPENROUTER_BASE_URL) {
2114
+ process.env.OPENROUTER_BASE_URL = spawnOpenRouterBaseUrl;
2115
+ }
2091
2116
  process.env.CONTEXT_MODE_EXTERNAL_MCP_NUDGE_EVERY = CTX_MODE_NUDGE_EVERY;
2092
2117
  const prevOpencodeConfig = process.env.OPENCODE_CONFIG;
2093
2118
  process.env.OPENCODE_CONFIG = configFilePath;
@@ -2198,4 +2223,4 @@ class OpencodeAdapter {
2198
2223
  }
2199
2224
  }
2200
2225
 
2201
- export { checkOpencodeCredentials, _setOpenRouterModelCacheRefreshForTests, resolveContextModePluginPath, OpencodeSession, OpencodeAdapter };
2226
+ export { checkOpencodeCredentials, applyOpenRouterBaseUrlOverride, _setOpenRouterModelCacheRefreshForTests, resolveContextModePluginPath, OpencodeSession, OpencodeAdapter };
@@ -0,0 +1,11 @@
1
+ // src/utils/openrouter-base-url.ts
2
+ var DEFAULT_OPENROUTER_BASE_URL = "https://openrouter.ai/api/v1";
3
+ function getOpenRouterBaseUrl(env = process.env) {
4
+ const raw = env.OPENROUTER_BASE_URL;
5
+ if (typeof raw === "string" && raw.trim().length > 0) {
6
+ return raw.trim().replace(/\/+$/, "");
7
+ }
8
+ return DEFAULT_OPENROUTER_BASE_URL;
9
+ }
10
+
11
+ export { DEFAULT_OPENROUTER_BASE_URL, getOpenRouterBaseUrl };
@@ -4,7 +4,7 @@ import {
4
4
  incrKv,
5
5
  init_db,
6
6
  upsertKv
7
- } from "./cli-0df2g86x.js";
7
+ } from "./cli-mjxnr12j.js";
8
8
 
9
9
  // src/be/users.ts
10
10
  init_db();
@@ -4,15 +4,15 @@ import {
4
4
  handleScheduleTrigger,
5
5
  runScript,
6
6
  startWorkflowExecution
7
- } from "./cli-95rbe11h.js";
7
+ } from "./cli-m7dmk462.js";
8
8
  import {
9
9
  getScript,
10
10
  getScriptApiConnectionDescriptors,
11
11
  getScriptMcpConnectionDescriptors
12
- } from "./cli-072t49hf.js";
12
+ } from "./cli-8x745f40.js";
13
13
  import {
14
14
  createTaskWithSiblingAwareness
15
- } from "./cli-s8bdcke2.js";
15
+ } from "./cli-00yr0kxv.js";
16
16
  import {
17
17
  getDb,
18
18
  getDueScheduledTasks,
@@ -24,7 +24,7 @@ import {
24
24
  scheduleContextKey,
25
25
  telemetry,
26
26
  updateScheduledTask
27
- } from "./cli-0df2g86x.js";
27
+ } from "./cli-mjxnr12j.js";
28
28
  import {
29
29
  __commonJS,
30
30
  __require,
@@ -4,11 +4,11 @@ import {
4
4
  getEmbeddingProvider,
5
5
  init_embedding,
6
6
  serializeEmbedding
7
- } from "./cli-3fxqwfh3.js";
7
+ } from "./cli-qf0qxzw5.js";
8
8
  import {
9
9
  getDb,
10
10
  init_db
11
- } from "./cli-0df2g86x.js";
11
+ } from "./cli-mjxnr12j.js";
12
12
  import {
13
13
  init_secret_scrubber,
14
14
  scrubSecrets
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  getDb,
3
3
  init_db
4
- } from "./cli-0df2g86x.js";
4
+ } from "./cli-mjxnr12j.js";
5
5
 
6
6
  // src/be/seed-pricing.ts
7
7
  init_db();
@@ -7,11 +7,11 @@ import {
7
7
  getPinCandidateAgent,
8
8
  getResumeGeneration,
9
9
  repointTrackerSyncBySwarmId
10
- } from "./cli-agdrxyex.js";
10
+ } from "./cli-haeq79yf.js";
11
11
  import {
12
12
  getExecutorRegistry,
13
13
  recoverIncompleteRuns
14
- } from "./cli-95rbe11h.js";
14
+ } from "./cli-m7dmk462.js";
15
15
  import {
16
16
  MAX_EMPTY_POLLS,
17
17
  assignUnassignedTaskPending,
@@ -51,7 +51,7 @@ import {
51
51
  resolveTemplate,
52
52
  supersedeTask,
53
53
  updateAgentStatus
54
- } from "./cli-0df2g86x.js";
54
+ } from "./cli-mjxnr12j.js";
55
55
 
56
56
  // src/heartbeat/heartbeat.ts
57
57
  init_db();
@@ -3,7 +3,7 @@ import {
3
3
  } from "./cli-jkhwmmgg.js";
4
4
  import {
5
5
  embedScript
6
- } from "./cli-5hpvd15x.js";
6
+ } from "./cli-60q15ncp.js";
7
7
  import {
8
8
  calculatePKCECodeChallenge,
9
9
  generateRandomCodeVerifier,
@@ -12,7 +12,7 @@ import {
12
12
  getOAuthAppById,
13
13
  updateAuthorizationTokens,
14
14
  upsertAuthorization
15
- } from "./cli-1728qh70.js";
15
+ } from "./cli-z3hcrghs.js";
16
16
  import {
17
17
  computeContentHash,
18
18
  decryptSecret,
@@ -28,7 +28,7 @@ import {
28
28
  normalizeDateRequired,
29
29
  placeholderForConfigKey,
30
30
  upsertSwarmConfig
31
- } from "./cli-0df2g86x.js";
31
+ } from "./cli-mjxnr12j.js";
32
32
  import {
33
33
  init_secret_scrubber,
34
34
  refreshSecretScrubberCache,
@@ -27,7 +27,7 @@ import {
27
27
  getTaskById,
28
28
  init_db,
29
29
  setSlackMessageTracking
30
- } from "./cli-0df2g86x.js";
30
+ } from "./cli-mjxnr12j.js";
31
31
  import {
32
32
  require_receiver,
33
33
  require_sender,
@@ -55073,13 +55073,13 @@ async function initSlackApp() {
55073
55073
  socketMode: true,
55074
55074
  logLevel: import_bolt.LogLevel.DEBUG
55075
55075
  });
55076
- const { registerMessageHandler } = await import("./handlers-fmfe2343.js");
55077
- const { registerCommandHandler } = await import("./commands-cxxye5e4.js");
55078
- const { registerActionHandlers } = await import("./actions-mwshtkf7.js");
55076
+ const { registerMessageHandler } = await import("./handlers-c43sm2h1.js");
55077
+ const { registerCommandHandler } = await import("./commands-6j54dz62.js");
55078
+ const { registerActionHandlers } = await import("./actions-k3bwtmgy.js");
55079
55079
  registerMessageHandler(app);
55080
55080
  registerCommandHandler(app);
55081
55081
  registerActionHandlers(app);
55082
- const { createAssistant } = await import("./assistant-tg7dhfj8.js");
55082
+ const { createAssistant } = await import("./assistant-as8087ft.js");
55083
55083
  app.assistant(createAssistant());
55084
55084
  return app;
55085
55085
  }
@@ -4,12 +4,12 @@ import {
4
4
  linkIdentity,
5
5
  recordUnmappedIdentity,
6
6
  resolveIdentity
7
- } from "./cli-srjqn7fd.js";
7
+ } from "./cli-3ptjc655.js";
8
8
  import {
9
9
  getKv,
10
10
  init_db,
11
11
  upsertKv
12
- } from "./cli-0df2g86x.js";
12
+ } from "./cli-mjxnr12j.js";
13
13
 
14
14
  // src/slack/enrich.ts
15
15
  init_db();
@@ -3,7 +3,7 @@ import {
3
3
  getAgentWorkingOnThread,
4
4
  getAllAgents,
5
5
  init_db
6
- } from "./cli-0df2g86x.js";
6
+ } from "./cli-mjxnr12j.js";
7
7
 
8
8
  // src/slack/router.ts
9
9
  init_db();
@@ -18,7 +18,7 @@ import {
18
18
  init_templates1 as init_templates,
19
19
  normalizeDateRequired,
20
20
  resolveTemplate
21
- } from "./cli-0df2g86x.js";
21
+ } from "./cli-mjxnr12j.js";
22
22
 
23
23
  // src/be/db-queries/tracker.ts
24
24
  init_date_utils();
@@ -4,7 +4,7 @@ import {
4
4
  import {
5
5
  getDb,
6
6
  init_db
7
- } from "./cli-0df2g86x.js";
7
+ } from "./cli-mjxnr12j.js";
8
8
 
9
9
  // src/be/rbac-roles.ts
10
10
  init_db();
@@ -1,13 +1,13 @@
1
1
  import {
2
2
  buildModelsDevSeedRows
3
- } from "./cli-ghq3v4c9.js";
3
+ } from "./cli-7jb8mk4n.js";
4
4
  import {
5
5
  createLogEntry,
6
6
  getActivePricingRow,
7
7
  getDb,
8
8
  init_db,
9
9
  insertPricingRow
10
- } from "./cli-0df2g86x.js";
10
+ } from "./cli-mjxnr12j.js";
11
11
  import {
12
12
  init_secret_scrubber,
13
13
  scrubSecrets
@@ -1,17 +1,17 @@
1
1
  import {
2
2
  createAdditiveBuffer,
3
3
  extractSlackMessageText
4
- } from "./cli-g9vva2qh.js";
4
+ } from "./cli-fc1gvt9c.js";
5
5
  import {
6
6
  rewriteSlackMentions
7
- } from "./cli-nf7sadev.js";
7
+ } from "./cli-bxdb36d2.js";
8
8
  import {
9
9
  createTaskWithSiblingAwareness
10
- } from "./cli-s8bdcke2.js";
10
+ } from "./cli-00yr0kxv.js";
11
11
  import {
12
12
  getSlackApp,
13
13
  registerTreeMessage
14
- } from "./cli-3b1ayz83.js";
14
+ } from "./cli-9fhxk91h.js";
15
15
  import {
16
16
  buildBufferFlushBlocks
17
17
  } from "./cli-ma04faw5.js";
@@ -24,7 +24,7 @@ import {
24
24
  init_registry,
25
25
  registerTemplate,
26
26
  slackContextKey
27
- } from "./cli-0df2g86x.js";
27
+ } from "./cli-mjxnr12j.js";
28
28
 
29
29
  // src/slack/event-dedup.ts
30
30
  var DEFAULT_TTL_MS = 300000;
@@ -1,10 +1,13 @@
1
1
  import {
2
2
  getApiKey
3
3
  } from "./cli-f14fvzag.js";
4
+ import {
5
+ getOpenRouterBaseUrl
6
+ } from "./cli-3dpj7atn.js";
4
7
  import {
5
8
  ensureAuthorizationTokenOrThrow,
6
9
  oauthAppRowToProviderConfig
7
- } from "./cli-tv7vekye.js";
10
+ } from "./cli-tc8xk5zh.js";
8
11
  import {
9
12
  getScript,
10
13
  getScriptApiConnectionDescriptors,
@@ -12,15 +15,15 @@ import {
12
15
  getScriptVersion,
13
16
  listRelationalCredentialBindings,
14
17
  validateScriptImports
15
- } from "./cli-072t49hf.js";
18
+ } from "./cli-8x745f40.js";
16
19
  import {
17
20
  getAuthorizationById,
18
21
  getOAuthApp,
19
22
  getOAuthAppById
20
- } from "./cli-1728qh70.js";
23
+ } from "./cli-z3hcrghs.js";
21
24
  import {
22
25
  withSiblingAwareness
23
- } from "./cli-s8bdcke2.js";
26
+ } from "./cli-00yr0kxv.js";
24
27
  import {
25
28
  getAppUrl
26
29
  } from "./cli-dh55d5fg.js";
@@ -74,7 +77,7 @@ import {
74
77
  updateWorkflowRun,
75
78
  updateWorkflowRunStep,
76
79
  workflowContextKey
77
- } from "./cli-0df2g86x.js";
80
+ } from "./cli-mjxnr12j.js";
78
81
  import {
79
82
  init_secret_scrubber,
80
83
  isSensitiveKey,
@@ -2620,7 +2623,7 @@ class HumanInTheLoopExecutor extends BaseExecutor {
2620
2623
  }
2621
2624
  if (notification.channel === "slack") {
2622
2625
  try {
2623
- const { getSlackApp } = await import("./app-skbty91x.js");
2626
+ const { getSlackApp } = await import("./app-knevny0f.js");
2624
2627
  const slackApp = getSlackApp();
2625
2628
  if (!slackApp) {
2626
2629
  console.warn("[HITL] Slack not initialized — cannot send notification");
@@ -2734,7 +2737,7 @@ class NotifyExecutor extends BaseExecutor {
2734
2737
  }
2735
2738
  }
2736
2739
  case "slack": {
2737
- const { getSlackApp } = await import("./app-skbty91x.js");
2740
+ const { getSlackApp } = await import("./app-knevny0f.js");
2738
2741
  const app = getSlackApp();
2739
2742
  if (!app) {
2740
2743
  return {
@@ -2859,7 +2862,7 @@ async function executeRawLlm(config) {
2859
2862
  try {
2860
2863
  const { createOpenAI } = await import("./index-2dgfj9av.js");
2861
2864
  const openrouter = createOpenAI({
2862
- baseURL: "https://openrouter.ai/api/v1",
2865
+ baseURL: getOpenRouterBaseUrl(),
2863
2866
  apiKey: process.env.OPENROUTER_API_KEY
2864
2867
  });
2865
2868
  const model = openrouter(modelName);
@@ -3625,7 +3628,7 @@ class ValidateExecutor extends BaseExecutor {
3625
3628
  const { createOpenAI } = await import("./index-2dgfj9av.js");
3626
3629
  const { generateObject, jsonSchema } = await import("./index-t2snazez.js");
3627
3630
  const openrouter = createOpenAI({
3628
- baseURL: "https://openrouter.ai/api/v1",
3631
+ baseURL: getOpenRouterBaseUrl(),
3629
3632
  apiKey: process.env.OPENROUTER_API_KEY
3630
3633
  });
3631
3634
  const { object } = await generateObject({
@@ -5,7 +5,7 @@ import {
5
5
  import {
6
6
  init_package,
7
7
  package_default
8
- } from "./cli-46etyprn.js";
8
+ } from "./cli-w48hgc2y.js";
9
9
  import {
10
10
  init_secret_scrubber,
11
11
  scrubSecrets
@@ -6,7 +6,7 @@ import {
6
6
  getDb,
7
7
  init_db,
8
8
  isSqliteVecAvailable
9
- } from "./cli-0df2g86x.js";
9
+ } from "./cli-mjxnr12j.js";
10
10
  import {
11
11
  __esm,
12
12
  __export,
@@ -22,12 +22,12 @@ function numEnv(key, fallback) {
22
22
  return Number.isNaN(parsed) ? fallback : parsed;
23
23
  }
24
24
  function isHybridSearchEnabled() {
25
- const val = process.env.MEMORY_HYBRID_SEARCH ?? "0";
26
- return val === "1" || val.toLowerCase() === "true";
25
+ const val = process.env.MEMORY_HYBRID_SEARCH?.trim().toLowerCase();
26
+ return val !== "0" && val !== "false";
27
27
  }
28
28
  function isGraphExpansionEnabled() {
29
- const val = process.env.MEMORY_GRAPH_EXPANSION ?? "0";
30
- return val === "1" || val.toLowerCase() === "true";
29
+ const val = process.env.MEMORY_GRAPH_EXPANSION?.trim().toLowerCase();
30
+ return val !== "0" && val !== "false";
31
31
  }
32
32
  var TTL_DEFAULTS, GLOBAL_HALF_LIFE_OVERRIDE, GLOBAL_HALF_LIFE, RECENCY_DECAY_HALF_LIFE, RECENCY_DECAY_HALF_LIFE_DAYS, SOURCE_QUALITY_MULTIPLIER, MIN_SIMILARITY, ACCESS_BOOST_MAX_MULTIPLIER, ACCESS_BOOST_RECENCY_WINDOW_HOURS, CANDIDATE_SET_MULTIPLIER, EMBEDDING_DIMENSIONS, DEFAULT_EMBEDDING_MODEL = "openai/text-embedding-3-small", PROTECTED_SOURCES;
33
33
  var init_constants = __esm(() => {
@@ -2,7 +2,7 @@ import {
2
2
  getScriptApiTypes,
3
3
  getScriptMcpTypes,
4
4
  require_typescript
5
- } from "./cli-072t49hf.js";
5
+ } from "./cli-8x745f40.js";
6
6
  import {
7
7
  deleteSwarmConfigByKey,
8
8
  getAgentById,
@@ -11,7 +11,7 @@ import {
11
11
  getSwarmConfigs,
12
12
  init_db,
13
13
  upsertSwarmConfig
14
- } from "./cli-0df2g86x.js";
14
+ } from "./cli-mjxnr12j.js";
15
15
  import {
16
16
  init_secret_scrubber,
17
17
  scrubSecrets
@@ -11,7 +11,7 @@ import {
11
11
  markAuthorizationRefreshFailed,
12
12
  releaseOAuthRefreshLock,
13
13
  updateAuthorizationTokens
14
- } from "./cli-1728qh70.js";
14
+ } from "./cli-z3hcrghs.js";
15
15
  import {
16
16
  init_secret_scrubber,
17
17
  registerVolatileSecret,