nexus-agents 2.175.0 → 2.176.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 (122) hide show
  1. package/dist/{child-mcp-config-XD4ODQJW.js → child-mcp-config-HPWYQFLG.js} +2 -2
  2. package/dist/{chunk-KNIHV2UA.js → chunk-2DE5L734.js} +2 -2
  3. package/dist/{chunk-AHJYZNQU.js → chunk-46XEDJRB.js} +2 -2
  4. package/dist/{chunk-MTVSYN4U.js → chunk-4OPEUDHY.js} +8 -8
  5. package/dist/{chunk-CFZGSZEX.js → chunk-4S6S6S2S.js} +2 -2
  6. package/dist/{chunk-G4HDWPDT.js → chunk-5ALUADB6.js} +2 -2
  7. package/dist/{chunk-Z4BSY2MW.js → chunk-5LTRHNOI.js} +3 -3
  8. package/dist/{chunk-PBWM7MFA.js → chunk-5YXHHEAG.js} +5 -5
  9. package/dist/{chunk-67ZQSIGP.js → chunk-7TXEBDRM.js} +2 -2
  10. package/dist/{chunk-QDYZCME4.js → chunk-AHXJCVMV.js} +35 -35
  11. package/dist/{chunk-JIJA2RY5.js → chunk-APXGDZV4.js} +8 -8
  12. package/dist/{chunk-IZS3BWQB.js → chunk-CGD63GSC.js} +5 -5
  13. package/dist/{chunk-YAJ4XUD2.js → chunk-CNHPSIHY.js} +13 -8
  14. package/dist/chunk-CNHPSIHY.js.map +1 -0
  15. package/dist/{chunk-LZ2ATWVV.js → chunk-ECBV4JNL.js} +2 -2
  16. package/dist/{chunk-67CGSBQW.js → chunk-G42V4A5Q.js} +2 -2
  17. package/dist/{chunk-QY5CJKNS.js → chunk-G5URP3V7.js} +7 -7
  18. package/dist/{chunk-ZUOQBQN7.js → chunk-H4LZLG3P.js} +5 -5
  19. package/dist/{chunk-D7S4ZZS6.js → chunk-J4BGV5VE.js} +2 -2
  20. package/dist/{chunk-5Y4RWZ3M.js → chunk-J55NMZ7R.js} +2 -2
  21. package/dist/{chunk-EY6CGIGS.js → chunk-JGL5HYZL.js} +3 -3
  22. package/dist/{chunk-FFVDD6MS.js → chunk-JRKF4FYO.js} +2 -2
  23. package/dist/{chunk-QDPGKVHH.js → chunk-N3XDPW64.js} +8 -8
  24. package/dist/{chunk-JXJAHGX2.js → chunk-NQU4LNN7.js} +4 -4
  25. package/dist/{chunk-TYLCYSUQ.js → chunk-QI5U2YUL.js} +2 -2
  26. package/dist/{chunk-HULJ7IYD.js → chunk-QQ3CUUBU.js} +8 -216
  27. package/dist/chunk-QQ3CUUBU.js.map +1 -0
  28. package/dist/{chunk-FSVJJBIK.js → chunk-U5CV76ZW.js} +2 -2
  29. package/dist/{chunk-4OZPWLKY.js → chunk-WMV2CXBB.js} +2 -2
  30. package/dist/{chunk-CXF5KR7V.js → chunk-WT4BJODZ.js} +5 -5
  31. package/dist/{chunk-DALN2VV4.js → chunk-XAWRBQB7.js} +3 -3
  32. package/dist/{chunk-QCWBPQF2.js → chunk-XES5DPHV.js} +3 -3
  33. package/dist/{chunk-GL4WGBKE.js → chunk-XZJU6WLL.js} +4 -4
  34. package/dist/{chunk-C7TM6GM7.js → chunk-YB4QE7MD.js} +2 -2
  35. package/dist/{chunk-QJ2Z6SMD.js → chunk-YU2JCUM7.js} +2 -2
  36. package/dist/{chunk-OM2NE5EZ.js → chunk-Z55WHIRU.js} +2 -2
  37. package/dist/{cli-circuit-breaker-UVYGXMC3.js → cli-circuit-breaker-PJOQTGFZ.js} +3 -3
  38. package/dist/cli.js +40 -40
  39. package/dist/{composite-router-RMZL4257.js → composite-router-IRXFQSB6.js} +2 -2
  40. package/dist/{consensus-vote-REULZA53.js → consensus-vote-O6Q266QE.js} +16 -16
  41. package/dist/{context-retriever-RZZWVBOR.js → context-retriever-GO6ET3MF.js} +8 -8
  42. package/dist/{doctor-deep-HV4TJTJV.js → doctor-deep-6HCHHMRP.js} +3 -3
  43. package/dist/{expert-bridge-ET6VC2JL.js → expert-bridge-6OLG6THF.js} +4 -4
  44. package/dist/{factory-KQML5DIT.js → factory-7OM526WB.js} +9 -9
  45. package/dist/{factory-2VRY5UT7.js → factory-MJFGYMNE.js} +5 -5
  46. package/dist/{improvement-review-33RKE6ZV.js → improvement-review-PALAAG7V.js} +5 -5
  47. package/dist/index.d.ts +19 -137
  48. package/dist/index.js +32 -36
  49. package/dist/index.js.map +1 -1
  50. package/dist/{init-opencode-H4KHTVI6.js → init-opencode-NUMHNVIF.js} +6 -6
  51. package/dist/{issue-triage-3WQXLNRD.js → issue-triage-N7GFXNPY.js} +6 -6
  52. package/dist/{pr-reviewer-helpers-NMOXAE4O.js → pr-reviewer-helpers-6EIUJPXS.js} +4 -4
  53. package/dist/{registry-command-ZV7WMEYO.js → registry-command-SVTX7FKB.js} +2 -2
  54. package/dist/{repo-security-plan-U6SMBTSU.js → repo-security-plan-AT7LOXLG.js} +3 -3
  55. package/dist/{research-helpers-synthesize-IUIZIZTV.js → research-helpers-synthesize-R722YWRS.js} +4 -4
  56. package/dist/{routing-memory-7EFOXSIE.js → routing-memory-4FXQT5H6.js} +2 -2
  57. package/dist/{session-memory-IFVVJ2YP.js → session-memory-ZQJ6AUSQ.js} +3 -3
  58. package/dist/{setup-command-K2VBZISN.js → setup-command-VAAYESH5.js} +14 -14
  59. package/dist/{setup-config-GA2YVE4R.js → setup-config-MYLZ2UHR.js} +3 -3
  60. package/dist/{setup-custom-api-E7V4XEKX.js → setup-custom-api-WZPLTGRQ.js} +4 -4
  61. package/dist/{tool-memory-ZJ5WR3DL.js → tool-memory-5REJXBCB.js} +5 -5
  62. package/dist/unified-registry-FM3QB2VN.js +26 -0
  63. package/dist/{weather-report-MMOOGRWG.js → weather-report-Y2GYJA6I.js} +2 -2
  64. package/package.json +1 -1
  65. package/dist/chunk-HULJ7IYD.js.map +0 -1
  66. package/dist/chunk-YAJ4XUD2.js.map +0 -1
  67. package/dist/unified-registry-56JY5W3B.js +0 -28
  68. /package/dist/{child-mcp-config-XD4ODQJW.js.map → child-mcp-config-HPWYQFLG.js.map} +0 -0
  69. /package/dist/{chunk-KNIHV2UA.js.map → chunk-2DE5L734.js.map} +0 -0
  70. /package/dist/{chunk-AHJYZNQU.js.map → chunk-46XEDJRB.js.map} +0 -0
  71. /package/dist/{chunk-MTVSYN4U.js.map → chunk-4OPEUDHY.js.map} +0 -0
  72. /package/dist/{chunk-CFZGSZEX.js.map → chunk-4S6S6S2S.js.map} +0 -0
  73. /package/dist/{chunk-G4HDWPDT.js.map → chunk-5ALUADB6.js.map} +0 -0
  74. /package/dist/{chunk-Z4BSY2MW.js.map → chunk-5LTRHNOI.js.map} +0 -0
  75. /package/dist/{chunk-PBWM7MFA.js.map → chunk-5YXHHEAG.js.map} +0 -0
  76. /package/dist/{chunk-67ZQSIGP.js.map → chunk-7TXEBDRM.js.map} +0 -0
  77. /package/dist/{chunk-QDYZCME4.js.map → chunk-AHXJCVMV.js.map} +0 -0
  78. /package/dist/{chunk-JIJA2RY5.js.map → chunk-APXGDZV4.js.map} +0 -0
  79. /package/dist/{chunk-IZS3BWQB.js.map → chunk-CGD63GSC.js.map} +0 -0
  80. /package/dist/{chunk-LZ2ATWVV.js.map → chunk-ECBV4JNL.js.map} +0 -0
  81. /package/dist/{chunk-67CGSBQW.js.map → chunk-G42V4A5Q.js.map} +0 -0
  82. /package/dist/{chunk-QY5CJKNS.js.map → chunk-G5URP3V7.js.map} +0 -0
  83. /package/dist/{chunk-ZUOQBQN7.js.map → chunk-H4LZLG3P.js.map} +0 -0
  84. /package/dist/{chunk-D7S4ZZS6.js.map → chunk-J4BGV5VE.js.map} +0 -0
  85. /package/dist/{chunk-5Y4RWZ3M.js.map → chunk-J55NMZ7R.js.map} +0 -0
  86. /package/dist/{chunk-EY6CGIGS.js.map → chunk-JGL5HYZL.js.map} +0 -0
  87. /package/dist/{chunk-FFVDD6MS.js.map → chunk-JRKF4FYO.js.map} +0 -0
  88. /package/dist/{chunk-QDPGKVHH.js.map → chunk-N3XDPW64.js.map} +0 -0
  89. /package/dist/{chunk-JXJAHGX2.js.map → chunk-NQU4LNN7.js.map} +0 -0
  90. /package/dist/{chunk-TYLCYSUQ.js.map → chunk-QI5U2YUL.js.map} +0 -0
  91. /package/dist/{chunk-FSVJJBIK.js.map → chunk-U5CV76ZW.js.map} +0 -0
  92. /package/dist/{chunk-4OZPWLKY.js.map → chunk-WMV2CXBB.js.map} +0 -0
  93. /package/dist/{chunk-CXF5KR7V.js.map → chunk-WT4BJODZ.js.map} +0 -0
  94. /package/dist/{chunk-DALN2VV4.js.map → chunk-XAWRBQB7.js.map} +0 -0
  95. /package/dist/{chunk-QCWBPQF2.js.map → chunk-XES5DPHV.js.map} +0 -0
  96. /package/dist/{chunk-GL4WGBKE.js.map → chunk-XZJU6WLL.js.map} +0 -0
  97. /package/dist/{chunk-C7TM6GM7.js.map → chunk-YB4QE7MD.js.map} +0 -0
  98. /package/dist/{chunk-QJ2Z6SMD.js.map → chunk-YU2JCUM7.js.map} +0 -0
  99. /package/dist/{chunk-OM2NE5EZ.js.map → chunk-Z55WHIRU.js.map} +0 -0
  100. /package/dist/{cli-circuit-breaker-UVYGXMC3.js.map → cli-circuit-breaker-PJOQTGFZ.js.map} +0 -0
  101. /package/dist/{composite-router-RMZL4257.js.map → composite-router-IRXFQSB6.js.map} +0 -0
  102. /package/dist/{consensus-vote-REULZA53.js.map → consensus-vote-O6Q266QE.js.map} +0 -0
  103. /package/dist/{context-retriever-RZZWVBOR.js.map → context-retriever-GO6ET3MF.js.map} +0 -0
  104. /package/dist/{doctor-deep-HV4TJTJV.js.map → doctor-deep-6HCHHMRP.js.map} +0 -0
  105. /package/dist/{expert-bridge-ET6VC2JL.js.map → expert-bridge-6OLG6THF.js.map} +0 -0
  106. /package/dist/{factory-2VRY5UT7.js.map → factory-7OM526WB.js.map} +0 -0
  107. /package/dist/{factory-KQML5DIT.js.map → factory-MJFGYMNE.js.map} +0 -0
  108. /package/dist/{improvement-review-33RKE6ZV.js.map → improvement-review-PALAAG7V.js.map} +0 -0
  109. /package/dist/{init-opencode-H4KHTVI6.js.map → init-opencode-NUMHNVIF.js.map} +0 -0
  110. /package/dist/{issue-triage-3WQXLNRD.js.map → issue-triage-N7GFXNPY.js.map} +0 -0
  111. /package/dist/{pr-reviewer-helpers-NMOXAE4O.js.map → pr-reviewer-helpers-6EIUJPXS.js.map} +0 -0
  112. /package/dist/{registry-command-ZV7WMEYO.js.map → registry-command-SVTX7FKB.js.map} +0 -0
  113. /package/dist/{repo-security-plan-U6SMBTSU.js.map → repo-security-plan-AT7LOXLG.js.map} +0 -0
  114. /package/dist/{research-helpers-synthesize-IUIZIZTV.js.map → research-helpers-synthesize-R722YWRS.js.map} +0 -0
  115. /package/dist/{routing-memory-7EFOXSIE.js.map → routing-memory-4FXQT5H6.js.map} +0 -0
  116. /package/dist/{session-memory-IFVVJ2YP.js.map → session-memory-ZQJ6AUSQ.js.map} +0 -0
  117. /package/dist/{setup-command-K2VBZISN.js.map → setup-command-VAAYESH5.js.map} +0 -0
  118. /package/dist/{setup-config-GA2YVE4R.js.map → setup-config-MYLZ2UHR.js.map} +0 -0
  119. /package/dist/{setup-custom-api-E7V4XEKX.js.map → setup-custom-api-WZPLTGRQ.js.map} +0 -0
  120. /package/dist/{tool-memory-ZJ5WR3DL.js.map → tool-memory-5REJXBCB.js.map} +0 -0
  121. /package/dist/{unified-registry-56JY5W3B.js.map → unified-registry-FM3QB2VN.js.map} +0 -0
  122. /package/dist/{weather-report-MMOOGRWG.js.map → weather-report-Y2GYJA6I.js.map} +0 -0
@@ -3,7 +3,7 @@ import {
3
3
  createLogger,
4
4
  err,
5
5
  ok
6
- } from "./chunk-YAJ4XUD2.js";
6
+ } from "./chunk-CNHPSIHY.js";
7
7
 
8
8
  // src/adapters/sdk/types.ts
9
9
  var PROVIDER_ENV_KEYS = {
@@ -169,4 +169,4 @@ export {
169
169
  validateCustomApiBaseUrl,
170
170
  assertCustomApiHostResolvesPublic
171
171
  };
172
- //# sourceMappingURL=chunk-LZ2ATWVV.js.map
172
+ //# sourceMappingURL=chunk-ECBV4JNL.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  getTimeProvider
3
- } from "./chunk-YAJ4XUD2.js";
3
+ } from "./chunk-CNHPSIHY.js";
4
4
 
5
5
  // src/security/audit-trail.ts
6
6
  var MAX_EVENTS = 1e4;
@@ -205,4 +205,4 @@ export {
205
205
  createGraphAuditBridge,
206
206
  createAuditTrail
207
207
  };
208
- //# sourceMappingURL=chunk-67CGSBQW.js.map
208
+ //# sourceMappingURL=chunk-G42V4A5Q.js.map
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  resolveCliSlot
3
- } from "./chunk-5Y4RWZ3M.js";
3
+ } from "./chunk-J55NMZ7R.js";
4
4
  import {
5
5
  createLogger,
6
6
  getTimeProvider,
7
7
  isRateLimitText
8
- } from "./chunk-YAJ4XUD2.js";
8
+ } from "./chunk-CNHPSIHY.js";
9
9
 
10
10
  // src/pipeline/expert-bridge.ts
11
11
  function resolveCliFromModelString(model) {
@@ -21,7 +21,7 @@ async function getMcpConfigPath() {
21
21
  if (cachedMcpConfigPath !== null) return cachedMcpConfigPath;
22
22
  mcpConfigInitPromise ??= (async () => {
23
23
  try {
24
- const { generateMcpConfig } = await import("./child-mcp-config-XD4ODQJW.js");
24
+ const { generateMcpConfig } = await import("./child-mcp-config-HPWYQFLG.js");
25
25
  const config = await generateMcpConfig();
26
26
  cachedMcpConfigPath = config.configPath;
27
27
  cachedMcpConfigCleanup = config.cleanup;
@@ -93,8 +93,8 @@ var routerInitPromise = null;
93
93
  async function getRouter() {
94
94
  if (cachedRouter !== null) return cachedRouter;
95
95
  routerInitPromise ??= (async () => {
96
- const { createAllAdapters } = await import("./factory-KQML5DIT.js");
97
- const { createCompositeRouter } = await import("./composite-router-RMZL4257.js");
96
+ const { createAllAdapters } = await import("./factory-7OM526WB.js");
97
+ const { createCompositeRouter } = await import("./composite-router-IRXFQSB6.js");
98
98
  const adapters = createAllAdapters();
99
99
  if (adapters.size === 0) {
100
100
  routerInitPromise = null;
@@ -102,7 +102,7 @@ async function getRouter() {
102
102
  }
103
103
  cachedRouter = adaptCompositeRouter(createCompositeRouter(adapters));
104
104
  try {
105
- const { createCliCircuitBreakerIntegration } = await import("./cli-circuit-breaker-UVYGXMC3.js");
105
+ const { createCliCircuitBreakerIntegration } = await import("./cli-circuit-breaker-PJOQTGFZ.js");
106
106
  cachedCircuitBreaker = createCliCircuitBreakerIntegration([...adapters.values()]);
107
107
  } catch (error) {
108
108
  const msg = error instanceof Error ? error.message : String(error);
@@ -213,4 +213,4 @@ export {
213
213
  tokenSplitFromUsage,
214
214
  executeExpert
215
215
  };
216
- //# sourceMappingURL=chunk-QY5CJKNS.js.map
216
+ //# sourceMappingURL=chunk-G5URP3V7.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  runConfigInitSync
3
- } from "./chunk-OM2NE5EZ.js";
3
+ } from "./chunk-Z55WHIRU.js";
4
4
  import {
5
5
  VERSION,
6
6
  checkApiKeys,
@@ -8,13 +8,13 @@ import {
8
8
  checkSqlite,
9
9
  defaultConfig,
10
10
  initDataDirectories
11
- } from "./chunk-JIJA2RY5.js";
11
+ } from "./chunk-APXGDZV4.js";
12
12
  import {
13
13
  BUILT_IN_EXPERTS
14
14
  } from "./chunk-YPNQPT2F.js";
15
15
  import {
16
16
  probeAllClis
17
- } from "./chunk-QDPGKVHH.js";
17
+ } from "./chunk-N3XDPW64.js";
18
18
  import {
19
19
  CLI_SUBPROCESS_TIMEOUTS,
20
20
  colors,
@@ -25,7 +25,7 @@ import {
25
25
  getErrorMessage,
26
26
  getTimeProvider,
27
27
  symbols
28
- } from "./chunk-YAJ4XUD2.js";
28
+ } from "./chunk-CNHPSIHY.js";
29
29
  import {
30
30
  ensureGitignored,
31
31
  findRepoRoot
@@ -2001,4 +2001,4 @@ export {
2001
2001
  setupCommand,
2002
2002
  setupCommandAsync
2003
2003
  };
2004
- //# sourceMappingURL=chunk-ZUOQBQN7.js.map
2004
+ //# sourceMappingURL=chunk-H4LZLG3P.js.map
@@ -4,7 +4,7 @@ import {
4
4
  import {
5
5
  createLogger,
6
6
  getTimeProvider
7
- } from "./chunk-YAJ4XUD2.js";
7
+ } from "./chunk-CNHPSIHY.js";
8
8
 
9
9
  // src/mcp/tools/scanner-registry-fetcher.ts
10
10
  import { z } from "zod";
@@ -721,4 +721,4 @@ export {
721
721
  generateSecurityPlan,
722
722
  buildPlanFromAnalysis
723
723
  };
724
- //# sourceMappingURL=chunk-D7S4ZZS6.js.map
724
+ //# sourceMappingURL=chunk-J4BGV5VE.js.map
@@ -3,7 +3,7 @@ import {
3
3
  MODEL_IDS,
4
4
  getTimeProvider,
5
5
  resolveModelIdentitySync
6
- } from "./chunk-YAJ4XUD2.js";
6
+ } from "./chunk-CNHPSIHY.js";
7
7
 
8
8
  // src/config/model-availability.ts
9
9
  var DEFAULT_TTL_MS = 6e4;
@@ -150,4 +150,4 @@ export {
150
150
  resetAvailabilityCache,
151
151
  filterAvailableModels
152
152
  };
153
- //# sourceMappingURL=chunk-5Y4RWZ3M.js.map
153
+ //# sourceMappingURL=chunk-J55NMZ7R.js.map
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  loadPapersRegistry
3
- } from "./chunk-AHJYZNQU.js";
3
+ } from "./chunk-46XEDJRB.js";
4
4
  import {
5
5
  getErrorMessage
6
- } from "./chunk-YAJ4XUD2.js";
6
+ } from "./chunk-CNHPSIHY.js";
7
7
 
8
8
  // src/cli/research-helpers-synthesize.ts
9
9
  import { z } from "zod";
@@ -876,4 +876,4 @@ export {
876
876
  AttributedInsightSchema,
877
877
  synthesizeResearch
878
878
  };
879
- //# sourceMappingURL=chunk-EY6CGIGS.js.map
879
+ //# sourceMappingURL=chunk-JGL5HYZL.js.map
@@ -2,7 +2,7 @@ import {
2
2
  createLogger,
3
3
  err,
4
4
  ok
5
- } from "./chunk-YAJ4XUD2.js";
5
+ } from "./chunk-CNHPSIHY.js";
6
6
 
7
7
  // src/scm/token-resolver.ts
8
8
  import { execFile } from "child_process";
@@ -87,4 +87,4 @@ export {
87
87
  hasToken,
88
88
  getTokenEnvVars
89
89
  };
90
- //# sourceMappingURL=chunk-FFVDD6MS.js.map
90
+ //# sourceMappingURL=chunk-JRKF4FYO.js.map
@@ -5,34 +5,34 @@ import {
5
5
  planOptionalParams,
6
6
  requireApiKey,
7
7
  validateApiKeyPresence
8
- } from "./chunk-TYLCYSUQ.js";
8
+ } from "./chunk-QI5U2YUL.js";
9
9
  import {
10
10
  CUSTOM_API_DEFAULT_MODEL
11
- } from "./chunk-4OZPWLKY.js";
11
+ } from "./chunk-WMV2CXBB.js";
12
12
  import {
13
13
  CUSTOM_API_BASE_URL_ENV,
14
14
  PROVIDER_ENV_KEYS,
15
15
  assertCustomApiHostResolvesPublic,
16
16
  validateCustomApiBaseUrl
17
- } from "./chunk-LZ2ATWVV.js";
17
+ } from "./chunk-ECBV4JNL.js";
18
18
  import {
19
19
  nexusMkdtempSync
20
20
  } from "./chunk-YAF73ZMR.js";
21
21
  import {
22
22
  getAvailabilityCache
23
- } from "./chunk-5Y4RWZ3M.js";
23
+ } from "./chunk-J55NMZ7R.js";
24
24
  import {
25
25
  extractSystemPrompt
26
26
  } from "./chunk-QZUG667L.js";
27
27
  import {
28
28
  generateHyphenId
29
- } from "./chunk-C7TM6GM7.js";
29
+ } from "./chunk-YB4QE7MD.js";
30
30
  import {
31
31
  CliCircuitBreaker,
32
32
  DEFAULT_CIRCUIT_BREAKER_CONFIG,
33
33
  getCliCircuitBreakerSnapshot,
34
34
  getDefaultCliCircuitBreakerRegistry
35
- } from "./chunk-G4HDWPDT.js";
35
+ } from "./chunk-5ALUADB6.js";
36
36
  import {
37
37
  CLI_SUBPROCESS_TIMEOUTS,
38
38
  CLI_TIMEOUTS,
@@ -69,7 +69,7 @@ import {
69
69
  ok,
70
70
  parseRetryAfterMs,
71
71
  resolveCliAlias
72
- } from "./chunk-YAJ4XUD2.js";
72
+ } from "./chunk-CNHPSIHY.js";
73
73
 
74
74
  // src/cli-adapters/cli-to-model-adapter.ts
75
75
  var CliToModelAdapter = class {
@@ -4741,4 +4741,4 @@ export {
4741
4741
  SdkAdapter,
4742
4742
  createAutoAdapter
4743
4743
  };
4744
- //# sourceMappingURL=chunk-QDPGKVHH.js.map
4744
+ //# sourceMappingURL=chunk-N3XDPW64.js.map
@@ -5,7 +5,7 @@ import {
5
5
  } from "./chunk-6T3EPABN.js";
6
6
  import {
7
7
  SessionMemory
8
- } from "./chunk-FSVJJBIK.js";
8
+ } from "./chunk-U5CV76ZW.js";
9
9
  import {
10
10
  StatsOnlyAdapter,
11
11
  ensureSharedMemoryRegistry
@@ -15,7 +15,7 @@ import {
15
15
  } from "./chunk-KSQSWEFH.js";
16
16
  import {
17
17
  generateId
18
- } from "./chunk-C7TM6GM7.js";
18
+ } from "./chunk-YB4QE7MD.js";
19
19
  import {
20
20
  ErrorCode,
21
21
  NexusError,
@@ -28,7 +28,7 @@ import {
28
28
  getTimeProvider,
29
29
  ok,
30
30
  setSharedMobiMemDbPathResolver
31
- } from "./chunk-YAJ4XUD2.js";
31
+ } from "./chunk-CNHPSIHY.js";
32
32
  import {
33
33
  nexusDataPath
34
34
  } from "./chunk-OQLFRJCW.js";
@@ -5552,4 +5552,4 @@ export {
5552
5552
  reinitializeMemoryBackends,
5553
5553
  ToolMemoryManager
5554
5554
  };
5555
- //# sourceMappingURL=chunk-JXJAHGX2.js.map
5555
+ //# sourceMappingURL=chunk-NQU4LNN7.js.map
@@ -11,7 +11,7 @@ import {
11
11
  isRateLimitLikeError,
12
12
  lookupInTreeCapability,
13
13
  ok
14
- } from "./chunk-YAJ4XUD2.js";
14
+ } from "./chunk-CNHPSIHY.js";
15
15
 
16
16
  // src/config/model-parameter-support.ts
17
17
  function parseClaudeMajorMinor(bareId) {
@@ -828,4 +828,4 @@ export {
828
828
  DEFAULT_COLLECT_STREAM_MAX_CHUNKS,
829
829
  collectStream
830
830
  };
831
- //# sourceMappingURL=chunk-TYLCYSUQ.js.map
831
+ //# sourceMappingURL=chunk-QI5U2YUL.js.map
@@ -1,21 +1,18 @@
1
1
  import {
2
2
  createAutoAdapter
3
- } from "./chunk-QDPGKVHH.js";
3
+ } from "./chunk-N3XDPW64.js";
4
4
  import {
5
5
  mapModelErrorToCategory
6
- } from "./chunk-G4HDWPDT.js";
6
+ } from "./chunk-5ALUADB6.js";
7
7
  import {
8
8
  CLI_NAMES,
9
9
  CircularBuffer,
10
- ErrorCode,
11
10
  ModelError,
12
11
  TASK_SPECIALIZATION_MATRIX,
13
12
  createLogger,
14
13
  detectTaskCategory,
15
14
  err,
16
- getDefaultAvailableModelsCache,
17
15
  getDefaultModelForCli,
18
- getDefaultRegistry,
19
16
  getErrorMessage,
20
17
  getInTreeCapabilitiesMatrix,
21
18
  getRandomProvider,
@@ -24,7 +21,7 @@ import {
24
21
  ok,
25
22
  recordRateLimitEvent,
26
23
  toRateLimitError
27
- } from "./chunk-YAJ4XUD2.js";
24
+ } from "./chunk-CNHPSIHY.js";
28
25
 
29
26
  // src/agents/collaboration/event-bus-helpers.ts
30
27
  import { randomUUID } from "crypto";
@@ -615,193 +612,10 @@ function mapSelectionSource(selection) {
615
612
  return "api";
616
613
  }
617
614
 
618
- // src/adapters/model-not-found-fallback.ts
619
- var logger = createLogger({ component: "model-not-found-fallback" });
620
- function withModelNotFoundFallback(inner, options = {}) {
621
- const registry = options.registry ?? getDefaultRegistry();
622
- const cache = options.cache ?? getDefaultAvailableModelsCache();
623
- const resolvedOptions = {
624
- cache,
625
- registry,
626
- adapterFactory: options.adapterFactory,
627
- onRetirement: options.onRetirement
628
- };
629
- const wrapped = {
630
- providerId: inner.providerId,
631
- modelId: inner.modelId,
632
- capabilities: inner.capabilities,
633
- countTokens: (text) => inner.countTokens(text),
634
- validateConfig: () => inner.validateConfig(),
635
- stream: (request) => streamWithFallback(inner, request, resolvedOptions),
636
- complete: (request) => completeWithFallback(inner, request, resolvedOptions)
637
- };
638
- if (typeof inner.listModels === "function") {
639
- const list = inner.listModels.bind(inner);
640
- wrapped.listModels = () => list();
641
- }
642
- return wrapped;
643
- }
644
- async function completeWithFallback(inner, request, options) {
645
- const first = await inner.complete(request);
646
- if (first.ok) return first;
647
- if (first.error.code !== ErrorCode.MODEL_NOT_FOUND) return first;
648
- const fallback = await pickFallback(inner.modelId, options.cache, options.registry);
649
- if (fallback === null) {
650
- logger.warn("Model not found and no fallback available", {
651
- modelId: inner.modelId,
652
- providerId: inner.providerId,
653
- errorMessage: first.error.message
654
- });
655
- return first;
656
- }
657
- logger.info("Model retirement detected; retrying with fallback", {
658
- retiredModelId: inner.modelId,
659
- fallbackModelId: fallback,
660
- providerId: inner.providerId
661
- });
662
- notifyRetirement(options.onRetirement, {
663
- retiredModelId: inner.modelId,
664
- fallbackModelId: fallback,
665
- providerId: inner.providerId,
666
- errorMessage: first.error.message
667
- });
668
- if (options.adapterFactory === void 0) {
669
- return err(
670
- new ModelError(`${first.error.message} \u2014 suggested fallback: ${fallback}`, {
671
- code: ErrorCode.MODEL_NOT_FOUND,
672
- cause: first.error
673
- })
674
- );
675
- }
676
- const fallbackAdapter = options.adapterFactory(fallback);
677
- const retried = await fallbackAdapter.complete(request);
678
- if (retried.ok) return retried;
679
- return err(
680
- new ModelError(`Fallback ${fallback} also failed: ${retried.error.message}`, {
681
- code: retried.error.code,
682
- cause: retried.error
683
- })
684
- );
685
- }
686
- async function* streamWithFallback(inner, request, options) {
687
- try {
688
- for await (const chunk of inner.stream(request)) {
689
- yield chunk;
690
- }
691
- return;
692
- } catch (e) {
693
- if (!isModelNotFoundError(e)) throw e;
694
- const fallbackAdapter = await resolveStreamFallback(inner, e, options);
695
- for await (const chunk of fallbackAdapter.stream(request)) {
696
- yield chunk;
697
- }
698
- }
699
- }
700
- async function resolveStreamFallback(inner, cause, options) {
701
- const fallback = await pickFallback(inner.modelId, options.cache, options.registry);
702
- if (fallback === null) {
703
- logger.warn("Stream model not found and no fallback available", {
704
- modelId: inner.modelId,
705
- providerId: inner.providerId,
706
- errorMessage: cause instanceof Error ? cause.message : String(cause)
707
- });
708
- throw cause;
709
- }
710
- logger.info("Stream retirement detected; restarting with fallback (restart-from-zero)", {
711
- retiredModelId: inner.modelId,
712
- fallbackModelId: fallback,
713
- providerId: inner.providerId
714
- });
715
- notifyRetirement(options.onRetirement, {
716
- retiredModelId: inner.modelId,
717
- fallbackModelId: fallback,
718
- providerId: inner.providerId,
719
- errorMessage: cause instanceof Error ? cause.message : String(cause)
720
- });
721
- if (options.adapterFactory === void 0) {
722
- const message = `${cause instanceof Error ? cause.message : String(cause)} \u2014 suggested fallback: ${fallback}`;
723
- const causeErr = cause instanceof Error ? cause : void 0;
724
- throw new ModelError(
725
- message,
726
- causeErr !== void 0 ? { code: ErrorCode.MODEL_NOT_FOUND, cause: causeErr } : { code: ErrorCode.MODEL_NOT_FOUND }
727
- );
728
- }
729
- return options.adapterFactory(fallback);
730
- }
731
- function isModelNotFoundError(e) {
732
- if (e instanceof ModelError) {
733
- return e.code === ErrorCode.MODEL_NOT_FOUND;
734
- }
735
- if (typeof e === "object" && e !== null && "code" in e) {
736
- return e.code === ErrorCode.MODEL_NOT_FOUND;
737
- }
738
- return false;
739
- }
740
- function notifyRetirement(cb, info) {
741
- if (cb === void 0) return;
742
- try {
743
- cb(info);
744
- } catch (e) {
745
- logger.debug("onRetirement callback threw", {
746
- error: e instanceof Error ? e.message : String(e)
747
- });
748
- }
749
- }
750
- async function pickFallback(retiredModelId, cache, registry) {
751
- const refreshed = await cache.refresh();
752
- if (refreshed.length === 0) return null;
753
- const target = registry.getEntry(retiredModelId);
754
- const sameFamily = refreshed.find((m) => {
755
- if (m.id === retiredModelId) return false;
756
- const candidate = registry.getEntry(m.id);
757
- return candidate.family === target.family && candidate.vendor === target.vendor;
758
- });
759
- if (sameFamily !== void 0) return sameFamily.id;
760
- const sameVendor = refreshed.find((m) => {
761
- if (m.id === retiredModelId) return false;
762
- const candidate = registry.getEntry(m.id);
763
- return candidate.vendor === target.vendor;
764
- });
765
- return sameVendor?.id ?? null;
766
- }
767
- function wrapResilientWithFallback(inner, options = {}) {
768
- const wrapped = withModelNotFoundFallback(inner, options);
769
- const surface = {
770
- getHealth: inner.getHealth.bind(inner),
771
- refresh: inner.refresh.bind(inner),
772
- setPreferredCli: inner.setPreferredCli.bind(inner),
773
- onFailover: inner.onFailover.bind(inner),
774
- dispose: inner.dispose.bind(inner)
775
- };
776
- const explicit = Object.assign(wrapped, surface);
777
- const innerAsRecord = inner;
778
- return new Proxy(explicit, {
779
- get(target, prop, receiver) {
780
- if (prop in target) return Reflect.get(target, prop, receiver);
781
- const innerProp = innerAsRecord[prop];
782
- if (typeof innerProp === "function") {
783
- return innerProp.bind(inner);
784
- }
785
- return innerProp;
786
- }
787
- });
788
- }
789
-
790
615
  // src/adapters/unified-registry.ts
791
- function withDefaultOnRetirement(enabled, options, logger2) {
792
- if (!enabled) return options;
793
- return {
794
- ...options,
795
- onRetirement: options?.onRetirement ?? ((info) => {
796
- logger2.warn("Model retired via not-found fallback", { retirement: info });
797
- })
798
- };
799
- }
800
616
  var UnifiedAdapterRegistry = class {
801
617
  logger;
802
618
  defaultCliTimeoutMs;
803
- enableMissingModelFallback;
804
- missingModelFallbackOptions;
805
619
  /** Per-CLI adapter cache — max 3 entries (claude/gemini/codex). */
806
620
  cliAdapters = /* @__PURE__ */ new Map();
807
621
  /** Default adapter for unscoped requests. */
@@ -809,29 +623,11 @@ var UnifiedAdapterRegistry = class {
809
623
  constructor(config) {
810
624
  this.logger = config?.logger ?? createLogger({ component: "unified-registry" });
811
625
  this.defaultCliTimeoutMs = config?.defaultCliTimeoutMs;
812
- this.enableMissingModelFallback = config?.enableMissingModelFallback ?? false;
813
- this.missingModelFallbackOptions = withDefaultOnRetirement(
814
- this.enableMissingModelFallback,
815
- config?.missingModelFallbackOptions,
816
- this.logger
817
- );
818
626
  this.logger.info("UnifiedAdapterRegistry initialized", {
819
627
  categories: TASK_SPECIALIZATION_MATRIX.length,
820
- models: getInTreeCapabilitiesMatrix().models.length,
821
- missingModelFallback: this.enableMissingModelFallback
628
+ models: getInTreeCapabilitiesMatrix().models.length
822
629
  });
823
630
  }
824
- /**
825
- * Apply the MODEL_NOT_FOUND fallback decorator if enabled, otherwise
826
- * return the adapter unchanged. The recursion guard from the original
827
- * issue is unnecessary here: the decorator's retry path uses the
828
- * caller-supplied `adapterFactory`; without one, it surfaces an
829
- * enriched error and never re-enters the resilient layer.
830
- */
831
- maybeWrap(adapter) {
832
- if (!this.enableMissingModelFallback) return adapter;
833
- return wrapResilientWithFallback(adapter, this.missingModelFallbackOptions);
834
- }
835
631
  // --------------------------------------------------------------------------
836
632
  // Public API
837
633
  // --------------------------------------------------------------------------
@@ -881,11 +677,10 @@ var UnifiedAdapterRegistry = class {
881
677
  defaultCliTimeoutMs: this.defaultCliTimeoutMs
882
678
  }
883
679
  });
884
- const adapter = this.maybeWrap(raw);
680
+ const adapter = raw;
885
681
  this.cliAdapters.set(cli, adapter);
886
682
  this.logger.info("Created CLI-specific adapter", {
887
- cli,
888
- missingModelFallback: this.enableMissingModelFallback
683
+ cli
889
684
  });
890
685
  return adapter;
891
686
  }
@@ -933,7 +728,7 @@ var UnifiedAdapterRegistry = class {
933
728
  defaultCliTimeoutMs: this.defaultCliTimeoutMs
934
729
  }
935
730
  });
936
- this.defaultAdapter = this.maybeWrap(raw);
731
+ this.defaultAdapter = raw;
937
732
  return this.defaultAdapter;
938
733
  }
939
734
  /**
@@ -1033,12 +828,9 @@ export {
1033
828
  getGlobalEventBus,
1034
829
  createEvent,
1035
830
  EventTopics,
1036
- withModelNotFoundFallback,
1037
- wrapResilientWithFallback,
1038
- withDefaultOnRetirement,
1039
831
  UnifiedAdapterRegistry,
1040
832
  createUnifiedRegistry,
1041
833
  getGlobalRegistry,
1042
834
  resetGlobalRegistry
1043
835
  };
1044
- //# sourceMappingURL=chunk-HULJ7IYD.js.map
836
+ //# sourceMappingURL=chunk-QQ3CUUBU.js.map