nexus-agents 2.135.0 → 2.137.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{child-mcp-config-RIEZRHWO.js → child-mcp-config-LCWPKOYE.js} +4 -3
- package/dist/{child-mcp-config-RIEZRHWO.js.map → child-mcp-config-LCWPKOYE.js.map} +1 -1
- package/dist/{chunk-PZ3MGLJU.js → chunk-23J7J37D.js} +52 -50
- package/dist/{chunk-PZ3MGLJU.js.map → chunk-23J7J37D.js.map} +1 -1
- package/dist/{chunk-3IT473PY.js → chunk-2SWMXQZF.js} +4 -4
- package/dist/{chunk-PQHVC4BD.js → chunk-2XRPKJKX.js} +23 -12
- package/dist/chunk-2XRPKJKX.js.map +1 -0
- package/dist/{chunk-FGQL4LZP.js → chunk-5MMHH5WK.js} +3 -3
- package/dist/{chunk-GM5F2FO5.js → chunk-7QEGSYSU.js} +2 -2
- package/dist/{chunk-XM3OQXN5.js → chunk-7QR2RTA4.js} +7 -7
- package/dist/{chunk-K5O7SSOH.js → chunk-7XCQJXN4.js} +13 -13
- package/dist/{chunk-KAIRRC5R.js → chunk-AL7ZYHAF.js} +4 -4
- package/dist/{chunk-T77RGBUF.js → chunk-AYA7K5F5.js} +4 -4
- package/dist/{chunk-52N3NGEY.js → chunk-D2XWKFZ2.js} +2 -2
- package/dist/{chunk-GZ4NF4ZW.js → chunk-DHVMSIT5.js} +83 -93
- package/dist/chunk-DHVMSIT5.js.map +1 -0
- package/dist/{chunk-4NANSSKX.js → chunk-DKU7O4V2.js} +2 -2
- package/dist/{chunk-OQZQITVU.js → chunk-DOCEHXLQ.js} +3 -3
- package/dist/{chunk-JWWCNN76.js → chunk-DPHEFR5X.js} +14 -12
- package/dist/{chunk-JWWCNN76.js.map → chunk-DPHEFR5X.js.map} +1 -1
- package/dist/{chunk-HDBV64A3.js → chunk-DTHMBYSV.js} +2 -2
- package/dist/{chunk-ILH5TZAX.js → chunk-H3B7H67H.js} +4 -4
- package/dist/{chunk-HGYJLSLL.js → chunk-H4ATQPGQ.js} +2 -2
- package/dist/{chunk-ME4DQ6BI.js → chunk-HC5CUX6C.js} +88 -31
- package/dist/chunk-HC5CUX6C.js.map +1 -0
- package/dist/{chunk-ZVIBVJBI.js → chunk-J2HWO3J3.js} +13 -81
- package/dist/chunk-J2HWO3J3.js.map +1 -0
- package/dist/{chunk-C46YFMFO.js → chunk-JFKNUEZ7.js} +2 -2
- package/dist/{chunk-WRP5COST.js → chunk-K62WRHHK.js} +2 -2
- package/dist/{chunk-CBJN5MYW.js → chunk-KWZC5LFC.js} +11 -8
- package/dist/chunk-KWZC5LFC.js.map +1 -0
- package/dist/{chunk-V6XZFDFR.js → chunk-LMMLLGZZ.js} +2 -2
- package/dist/{chunk-DXVQ6VFB.js → chunk-MNHNQC7R.js} +3 -3
- package/dist/{chunk-QX2Y5QWO.js → chunk-MNXLJ2VX.js} +2 -2
- package/dist/{chunk-4L4VXVKC.js → chunk-MXDMJGVG.js} +4 -4
- package/dist/{chunk-MREIJMH7.js → chunk-NJW5GQUF.js} +3 -3
- package/dist/chunk-NL7SZQPW.js +44 -0
- package/dist/chunk-NL7SZQPW.js.map +1 -0
- package/dist/{chunk-FNYTCR6R.js → chunk-NRJLOBGA.js} +6 -6
- package/dist/{chunk-C4GDV57D.js → chunk-NYSOJBF5.js} +3 -3
- package/dist/{chunk-C5FWXNAR.js → chunk-PLKWH53F.js} +8 -8
- package/dist/{chunk-2QTDOKWV.js → chunk-Q3EZN3Z2.js} +2 -2
- package/dist/chunk-RER74KD6.js +92 -0
- package/dist/chunk-RER74KD6.js.map +1 -0
- package/dist/{chunk-JA3SDBVY.js → chunk-RTBVZCLD.js} +2 -2
- package/dist/{chunk-SMRXY5ZN.js → chunk-XUH2UFSG.js} +2 -2
- package/dist/{chunk-BGGX3BXC.js → chunk-YPGTIJEW.js} +2 -2
- package/dist/{chunk-5MWNLEU2.js → chunk-ZJ3WGARD.js} +3 -3
- package/dist/cli-circuit-breaker-TNV2PBLS.js +14 -0
- package/dist/cli.d.ts +1 -1
- package/dist/cli.js +142 -89
- package/dist/cli.js.map +1 -1
- package/dist/{composite-router-DU22RBNQ.js → composite-router-KM4BPVY4.js} +4 -3
- package/dist/consensus-vote-HHA73ME6.js +39 -0
- package/dist/{consensus-vote-types-CYBHW8vY.d.ts → consensus-vote-types-Dx4pf3YW.d.ts} +16 -0
- package/dist/{context-retriever-BWLNV73G.js → context-retriever-MAZKHYRD.js} +12 -10
- package/dist/{dist-C4457XNQ.js → dist-KGTVHDVC.js} +4 -2
- package/dist/doctor-deep-XCMFGGJ3.js +13 -0
- package/dist/{expert-bridge-4YXDWOMR.js → expert-bridge-EA3U3GKU.js} +6 -5
- package/dist/factory-FACKN4IN.js +22 -0
- package/dist/factory-Y5WCLQDB.js +15 -0
- package/dist/{improvement-review-GUPEYLGP.js → improvement-review-F7TKX4LQ.js} +6 -5
- package/dist/index.d.ts +7 -7
- package/dist/index.js +64 -62
- package/dist/index.js.map +1 -1
- package/dist/{init-opencode-3ETCD3BE.js → init-opencode-ZYGGEUZN.js} +8 -7
- package/dist/{init-opencode-3ETCD3BE.js.map → init-opencode-ZYGGEUZN.js.map} +1 -1
- package/dist/issue-triage-NI2ZDVTB.js +17 -0
- package/dist/{learning-persistence-2KO4CXNL.js → learning-persistence-M3OTCCNI.js} +3 -2
- package/dist/{pr-reviewer-helpers-56FWDR3G.js → pr-reviewer-helpers-L7L6O3VQ.js} +6 -5
- package/dist/{registry-command-PYAMTDT2.js → registry-command-K2KWID5D.js} +4 -3
- package/dist/{registry-command-PYAMTDT2.js.map → registry-command-K2KWID5D.js.map} +1 -1
- package/dist/{repo-security-plan-WJM2JXPT.js → repo-security-plan-PCGHBEGZ.js} +5 -4
- package/dist/research-helpers-synthesize-R45KXXNH.js +15 -0
- package/dist/{routing-memory-K54FC6WD.js → routing-memory-TLB5EY7J.js} +4 -3
- package/dist/{session-memory-G5DWGR6S.js → session-memory-PUEUWVIN.js} +5 -4
- package/dist/{setup-command-7IN7ORLV.js → setup-command-TIGCMJRZ.js} +13 -12
- package/dist/setup-config-SLFGQ5F2.js +11 -0
- package/dist/{setup-custom-api-2IDPBBER.js → setup-custom-api-SVCRCSKY.js} +5 -4
- package/dist/{setup-custom-api-2IDPBBER.js.map → setup-custom-api-SVCRCSKY.js.map} +1 -1
- package/dist/tool-memory-COQWIFB6.js +22 -0
- package/dist/tool-memory-registry-adapters-DLSE4SQH.js +12 -0
- package/dist/unified-registry-44DIG4XK.js +25 -0
- package/dist/{weather-report-RYUENMV5.js → weather-report-WK7TJPMM.js} +4 -3
- package/dist/weather-report-WK7TJPMM.js.map +1 -0
- package/package.json +2 -2
- package/dist/chunk-CBJN5MYW.js.map +0 -1
- package/dist/chunk-GZ4NF4ZW.js.map +0 -1
- package/dist/chunk-ME4DQ6BI.js.map +0 -1
- package/dist/chunk-PQHVC4BD.js.map +0 -1
- package/dist/chunk-ZVIBVJBI.js.map +0 -1
- package/dist/cli-circuit-breaker-QONQNI3B.js +0 -13
- package/dist/consensus-vote-ZBSY2SCU.js +0 -37
- package/dist/doctor-deep-JW3Y5ZD2.js +0 -12
- package/dist/factory-3HBHEN54.js +0 -14
- package/dist/factory-7XUQGSHC.js +0 -21
- package/dist/issue-triage-7QHWTJRD.js +0 -16
- package/dist/research-helpers-synthesize-K4Z4BYGI.js +0 -14
- package/dist/setup-config-PTRDCT22.js +0 -10
- package/dist/tool-memory-GGQVY2GX.js +0 -20
- package/dist/unified-registry-3QASCESS.js +0 -24
- /package/dist/{chunk-3IT473PY.js.map → chunk-2SWMXQZF.js.map} +0 -0
- /package/dist/{chunk-FGQL4LZP.js.map → chunk-5MMHH5WK.js.map} +0 -0
- /package/dist/{chunk-GM5F2FO5.js.map → chunk-7QEGSYSU.js.map} +0 -0
- /package/dist/{chunk-XM3OQXN5.js.map → chunk-7QR2RTA4.js.map} +0 -0
- /package/dist/{chunk-K5O7SSOH.js.map → chunk-7XCQJXN4.js.map} +0 -0
- /package/dist/{chunk-KAIRRC5R.js.map → chunk-AL7ZYHAF.js.map} +0 -0
- /package/dist/{chunk-T77RGBUF.js.map → chunk-AYA7K5F5.js.map} +0 -0
- /package/dist/{chunk-52N3NGEY.js.map → chunk-D2XWKFZ2.js.map} +0 -0
- /package/dist/{chunk-4NANSSKX.js.map → chunk-DKU7O4V2.js.map} +0 -0
- /package/dist/{chunk-OQZQITVU.js.map → chunk-DOCEHXLQ.js.map} +0 -0
- /package/dist/{chunk-HDBV64A3.js.map → chunk-DTHMBYSV.js.map} +0 -0
- /package/dist/{chunk-ILH5TZAX.js.map → chunk-H3B7H67H.js.map} +0 -0
- /package/dist/{chunk-HGYJLSLL.js.map → chunk-H4ATQPGQ.js.map} +0 -0
- /package/dist/{chunk-C46YFMFO.js.map → chunk-JFKNUEZ7.js.map} +0 -0
- /package/dist/{chunk-WRP5COST.js.map → chunk-K62WRHHK.js.map} +0 -0
- /package/dist/{chunk-V6XZFDFR.js.map → chunk-LMMLLGZZ.js.map} +0 -0
- /package/dist/{chunk-DXVQ6VFB.js.map → chunk-MNHNQC7R.js.map} +0 -0
- /package/dist/{chunk-QX2Y5QWO.js.map → chunk-MNXLJ2VX.js.map} +0 -0
- /package/dist/{chunk-4L4VXVKC.js.map → chunk-MXDMJGVG.js.map} +0 -0
- /package/dist/{chunk-MREIJMH7.js.map → chunk-NJW5GQUF.js.map} +0 -0
- /package/dist/{chunk-FNYTCR6R.js.map → chunk-NRJLOBGA.js.map} +0 -0
- /package/dist/{chunk-C4GDV57D.js.map → chunk-NYSOJBF5.js.map} +0 -0
- /package/dist/{chunk-C5FWXNAR.js.map → chunk-PLKWH53F.js.map} +0 -0
- /package/dist/{chunk-2QTDOKWV.js.map → chunk-Q3EZN3Z2.js.map} +0 -0
- /package/dist/{chunk-JA3SDBVY.js.map → chunk-RTBVZCLD.js.map} +0 -0
- /package/dist/{chunk-SMRXY5ZN.js.map → chunk-XUH2UFSG.js.map} +0 -0
- /package/dist/{chunk-BGGX3BXC.js.map → chunk-YPGTIJEW.js.map} +0 -0
- /package/dist/{chunk-5MWNLEU2.js.map → chunk-ZJ3WGARD.js.map} +0 -0
- /package/dist/{cli-circuit-breaker-QONQNI3B.js.map → cli-circuit-breaker-TNV2PBLS.js.map} +0 -0
- /package/dist/{composite-router-DU22RBNQ.js.map → composite-router-KM4BPVY4.js.map} +0 -0
- /package/dist/{consensus-vote-ZBSY2SCU.js.map → consensus-vote-HHA73ME6.js.map} +0 -0
- /package/dist/{context-retriever-BWLNV73G.js.map → context-retriever-MAZKHYRD.js.map} +0 -0
- /package/dist/{dist-C4457XNQ.js.map → dist-KGTVHDVC.js.map} +0 -0
- /package/dist/{doctor-deep-JW3Y5ZD2.js.map → doctor-deep-XCMFGGJ3.js.map} +0 -0
- /package/dist/{expert-bridge-4YXDWOMR.js.map → expert-bridge-EA3U3GKU.js.map} +0 -0
- /package/dist/{factory-3HBHEN54.js.map → factory-FACKN4IN.js.map} +0 -0
- /package/dist/{factory-7XUQGSHC.js.map → factory-Y5WCLQDB.js.map} +0 -0
- /package/dist/{improvement-review-GUPEYLGP.js.map → improvement-review-F7TKX4LQ.js.map} +0 -0
- /package/dist/{issue-triage-7QHWTJRD.js.map → issue-triage-NI2ZDVTB.js.map} +0 -0
- /package/dist/{learning-persistence-2KO4CXNL.js.map → learning-persistence-M3OTCCNI.js.map} +0 -0
- /package/dist/{pr-reviewer-helpers-56FWDR3G.js.map → pr-reviewer-helpers-L7L6O3VQ.js.map} +0 -0
- /package/dist/{repo-security-plan-WJM2JXPT.js.map → repo-security-plan-PCGHBEGZ.js.map} +0 -0
- /package/dist/{research-helpers-synthesize-K4Z4BYGI.js.map → research-helpers-synthesize-R45KXXNH.js.map} +0 -0
- /package/dist/{routing-memory-K54FC6WD.js.map → routing-memory-TLB5EY7J.js.map} +0 -0
- /package/dist/{session-memory-G5DWGR6S.js.map → session-memory-PUEUWVIN.js.map} +0 -0
- /package/dist/{setup-command-7IN7ORLV.js.map → setup-command-TIGCMJRZ.js.map} +0 -0
- /package/dist/{setup-config-PTRDCT22.js.map → setup-config-SLFGQ5F2.js.map} +0 -0
- /package/dist/{tool-memory-GGQVY2GX.js.map → tool-memory-COQWIFB6.js.map} +0 -0
- /package/dist/{unified-registry-3QASCESS.js.map → tool-memory-registry-adapters-DLSE4SQH.js.map} +0 -0
- /package/dist/{weather-report-RYUENMV5.js.map → unified-registry-44DIG4XK.js.map} +0 -0
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createLogger
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import "./chunk-
|
|
3
|
+
} from "./chunk-KWZC5LFC.js";
|
|
4
|
+
import "./chunk-NL7SZQPW.js";
|
|
5
|
+
import "./chunk-DHVMSIT5.js";
|
|
5
6
|
import "./chunk-ZPWHCABL.js";
|
|
6
7
|
|
|
7
8
|
// src/cli-adapters/child-mcp-config.ts
|
|
@@ -59,4 +60,4 @@ export {
|
|
|
59
60
|
generateMcpConfig,
|
|
60
61
|
getDefaultAllowedTools
|
|
61
62
|
};
|
|
62
|
-
//# sourceMappingURL=child-mcp-config-
|
|
63
|
+
//# sourceMappingURL=child-mcp-config-LCWPKOYE.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/cli-adapters/child-mcp-config.ts"],"sourcesContent":["/**\n * nexus-agents/cli-adapters - Child CLI MCP Config Generator\n *\n * Generates MCP server configuration for child Claude CLI sessions so\n * spawned agents can call back into nexus-agents' MCP tools (memory,\n * research, etc.). Used by `pipeline/expert-bridge.ts` to give expert\n * agents tool access. Originally lived under `swe-bench/` (#1413);\n * relocated here in #2515 — the helper is generic CLI-spawn\n * infrastructure, not benchmark-specific.\n *\n * @module cli-adapters/child-mcp-config\n */\n\nimport { writeFile, mkdtemp, rm } from 'node:fs/promises';\nimport { join } from 'node:path';\nimport { tmpdir } from 'node:os';\nimport { createLogger } from '../core/index.js';\n\nconst logger = createLogger({ component: 'swe-bench-mcp-config' });\n\n/**\n * MCP server entry in Claude CLI config format.\n */\ninterface McpServerEntry {\n readonly command: string;\n readonly args: readonly string[];\n readonly env?: Readonly<Record<string, string>>;\n}\n\n/**\n * MCP config file format for Claude CLI (--mcp-config).\n */\ninterface McpConfigFile {\n readonly mcpServers: Readonly<Record<string, McpServerEntry>>;\n}\n\n/**\n * Options for generating MCP config.\n */\nexport interface McpConfigOptions {\n /** Path to nexus-agents CLI entry point. */\n readonly cliPath?: string;\n /** Additional environment variables for the MCP server. */\n readonly env?: Readonly<Record<string, string>>;\n /** Custom allowed tools (default: read-only subset). */\n readonly allowedTools?: readonly string[];\n}\n\n/** Default read-only tools available to SWE-bench child sessions. */\nconst DEFAULT_ALLOWED_TOOLS: readonly string[] = [\n 'memory_query',\n 'memory_stats',\n 'research_query',\n 'research_discover',\n 'weather_report',\n 'delegate_to_model',\n];\n\n/**\n * Resolves the nexus-agents CLI path.\n * Uses the built dist/cli.js relative to this package.\n */\nfunction resolveCliPath(override?: string): string {\n if (override !== undefined) return override;\n // Resolve relative to this file: src/swe-bench/ → dist/cli.js\n // At runtime we're in dist/swe-bench/, so go up one level\n const distDir = join(__dirname, '..');\n return join(distDir, 'cli.js');\n}\n\n/**\n * Builds the MCP config object for a nexus-agents server.\n */\nfunction buildConfig(options?: McpConfigOptions): McpConfigFile {\n const cliPath = resolveCliPath(options?.cliPath);\n const tools = options?.allowedTools ?? DEFAULT_ALLOWED_TOOLS;\n\n const entry: McpServerEntry = {\n command: 'node',\n args: [cliPath, '--mode=server'],\n ...(options?.env !== undefined ? { env: options.env } : {}),\n };\n\n return {\n mcpServers: {\n 'nexus-agents': entry,\n },\n };\n\n // Note: tool allowlisting is handled by Claude CLI's --allowedTools flag,\n // not in the MCP config itself. The caller should pass tools separately.\n void tools;\n}\n\n/**\n * Generated MCP config with path and cleanup function.\n */\nexport interface GeneratedMcpConfig {\n /** Path to the generated config file. */\n readonly configPath: string;\n /** Cleanup function to remove temp files. */\n readonly cleanup: () => Promise<void>;\n /** Allowed tools list for --allowedTools flag. */\n readonly allowedTools: readonly string[];\n}\n\n/**\n * Generates an MCP config file for Claude CLI child sessions.\n *\n * Creates a temporary JSON file that can be passed to `claude --mcp-config`.\n * Returns the file path and a cleanup function.\n */\nexport async function generateMcpConfig(options?: McpConfigOptions): Promise<GeneratedMcpConfig> {\n const config = buildConfig(options);\n const tools = options?.allowedTools ?? DEFAULT_ALLOWED_TOOLS;\n\n const tempDir = await mkdtemp(join(tmpdir(), 'nexus-mcp-'));\n const configPath = join(tempDir, 'mcp-config.json');\n\n await writeFile(configPath, JSON.stringify(config, null, 2), 'utf-8');\n\n const cleanup = async (): Promise<void> => {\n await rm(tempDir, { recursive: true, force: true }).catch((e: unknown) => {\n logger.debug('Best-effort cleanup failed', {\n error: e instanceof Error ? e.message : String(e),\n });\n });\n };\n\n return { configPath, cleanup, allowedTools: tools };\n}\n\n/**\n * Gets the default allowed tools for SWE-bench MCP sessions.\n */\nexport function getDefaultAllowedTools(): readonly string[] {\n return DEFAULT_ALLOWED_TOOLS;\n}\n"],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../src/cli-adapters/child-mcp-config.ts"],"sourcesContent":["/**\n * nexus-agents/cli-adapters - Child CLI MCP Config Generator\n *\n * Generates MCP server configuration for child Claude CLI sessions so\n * spawned agents can call back into nexus-agents' MCP tools (memory,\n * research, etc.). Used by `pipeline/expert-bridge.ts` to give expert\n * agents tool access. Originally lived under `swe-bench/` (#1413);\n * relocated here in #2515 — the helper is generic CLI-spawn\n * infrastructure, not benchmark-specific.\n *\n * @module cli-adapters/child-mcp-config\n */\n\nimport { writeFile, mkdtemp, rm } from 'node:fs/promises';\nimport { join } from 'node:path';\nimport { tmpdir } from 'node:os';\nimport { createLogger } from '../core/index.js';\n\nconst logger = createLogger({ component: 'swe-bench-mcp-config' });\n\n/**\n * MCP server entry in Claude CLI config format.\n */\ninterface McpServerEntry {\n readonly command: string;\n readonly args: readonly string[];\n readonly env?: Readonly<Record<string, string>>;\n}\n\n/**\n * MCP config file format for Claude CLI (--mcp-config).\n */\ninterface McpConfigFile {\n readonly mcpServers: Readonly<Record<string, McpServerEntry>>;\n}\n\n/**\n * Options for generating MCP config.\n */\nexport interface McpConfigOptions {\n /** Path to nexus-agents CLI entry point. */\n readonly cliPath?: string;\n /** Additional environment variables for the MCP server. */\n readonly env?: Readonly<Record<string, string>>;\n /** Custom allowed tools (default: read-only subset). */\n readonly allowedTools?: readonly string[];\n}\n\n/** Default read-only tools available to SWE-bench child sessions. */\nconst DEFAULT_ALLOWED_TOOLS: readonly string[] = [\n 'memory_query',\n 'memory_stats',\n 'research_query',\n 'research_discover',\n 'weather_report',\n 'delegate_to_model',\n];\n\n/**\n * Resolves the nexus-agents CLI path.\n * Uses the built dist/cli.js relative to this package.\n */\nfunction resolveCliPath(override?: string): string {\n if (override !== undefined) return override;\n // Resolve relative to this file: src/swe-bench/ → dist/cli.js\n // At runtime we're in dist/swe-bench/, so go up one level\n const distDir = join(__dirname, '..');\n return join(distDir, 'cli.js');\n}\n\n/**\n * Builds the MCP config object for a nexus-agents server.\n */\nfunction buildConfig(options?: McpConfigOptions): McpConfigFile {\n const cliPath = resolveCliPath(options?.cliPath);\n const tools = options?.allowedTools ?? DEFAULT_ALLOWED_TOOLS;\n\n const entry: McpServerEntry = {\n command: 'node',\n args: [cliPath, '--mode=server'],\n ...(options?.env !== undefined ? { env: options.env } : {}),\n };\n\n return {\n mcpServers: {\n 'nexus-agents': entry,\n },\n };\n\n // Note: tool allowlisting is handled by Claude CLI's --allowedTools flag,\n // not in the MCP config itself. The caller should pass tools separately.\n void tools;\n}\n\n/**\n * Generated MCP config with path and cleanup function.\n */\nexport interface GeneratedMcpConfig {\n /** Path to the generated config file. */\n readonly configPath: string;\n /** Cleanup function to remove temp files. */\n readonly cleanup: () => Promise<void>;\n /** Allowed tools list for --allowedTools flag. */\n readonly allowedTools: readonly string[];\n}\n\n/**\n * Generates an MCP config file for Claude CLI child sessions.\n *\n * Creates a temporary JSON file that can be passed to `claude --mcp-config`.\n * Returns the file path and a cleanup function.\n */\nexport async function generateMcpConfig(options?: McpConfigOptions): Promise<GeneratedMcpConfig> {\n const config = buildConfig(options);\n const tools = options?.allowedTools ?? DEFAULT_ALLOWED_TOOLS;\n\n const tempDir = await mkdtemp(join(tmpdir(), 'nexus-mcp-'));\n const configPath = join(tempDir, 'mcp-config.json');\n\n await writeFile(configPath, JSON.stringify(config, null, 2), 'utf-8');\n\n const cleanup = async (): Promise<void> => {\n await rm(tempDir, { recursive: true, force: true }).catch((e: unknown) => {\n logger.debug('Best-effort cleanup failed', {\n error: e instanceof Error ? e.message : String(e),\n });\n });\n };\n\n return { configPath, cleanup, allowedTools: tools };\n}\n\n/**\n * Gets the default allowed tools for SWE-bench MCP sessions.\n */\nexport function getDefaultAllowedTools(): readonly string[] {\n return DEFAULT_ALLOWED_TOOLS;\n}\n"],"mappings":";;;;;;;;AAaA,SAAS,WAAW,SAAS,UAAU;AACvC,SAAS,YAAY;AACrB,SAAS,cAAc;AAGvB,IAAM,SAAS,aAAa,EAAE,WAAW,uBAAuB,CAAC;AA+BjE,IAAM,wBAA2C;AAAA,EAC/C;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAMA,SAAS,eAAe,UAA2B;AACjD,MAAI,aAAa,OAAW,QAAO;AAGnC,QAAM,UAAU,KAAK,WAAW,IAAI;AACpC,SAAO,KAAK,SAAS,QAAQ;AAC/B;AAKA,SAAS,YAAY,SAA2C;AAC9D,QAAM,UAAU,eAAe,SAAS,OAAO;AAC/C,QAAM,QAAQ,SAAS,gBAAgB;AAEvC,QAAM,QAAwB;AAAA,IAC5B,SAAS;AAAA,IACT,MAAM,CAAC,SAAS,eAAe;AAAA,IAC/B,GAAI,SAAS,QAAQ,SAAY,EAAE,KAAK,QAAQ,IAAI,IAAI,CAAC;AAAA,EAC3D;AAEA,SAAO;AAAA,IACL,YAAY;AAAA,MACV,gBAAgB;AAAA,IAClB;AAAA,EACF;AAIA,OAAK;AACP;AAoBA,eAAsB,kBAAkB,SAAyD;AAC/F,QAAM,SAAS,YAAY,OAAO;AAClC,QAAM,QAAQ,SAAS,gBAAgB;AAEvC,QAAM,UAAU,MAAM,QAAQ,KAAK,OAAO,GAAG,YAAY,CAAC;AAC1D,QAAM,aAAa,KAAK,SAAS,iBAAiB;AAElD,QAAM,UAAU,YAAY,KAAK,UAAU,QAAQ,MAAM,CAAC,GAAG,OAAO;AAEpE,QAAM,UAAU,YAA2B;AACzC,UAAM,GAAG,SAAS,EAAE,WAAW,MAAM,OAAO,KAAK,CAAC,EAAE,MAAM,CAAC,MAAe;AACxE,aAAO,MAAM,8BAA8B;AAAA,QACzC,OAAO,aAAa,QAAQ,EAAE,UAAU,OAAO,CAAC;AAAA,MAClD,CAAC;AAAA,IACH,CAAC;AAAA,EACH;AAEA,SAAO,EAAE,YAAY,SAAS,cAAc,MAAM;AACpD;AAKO,SAAS,yBAA4C;AAC1D,SAAO;AACT;","names":[]}
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
generateSecurityPlan
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-RTBVZCLD.js";
|
|
4
|
+
import {
|
|
5
|
+
analyzeGitHubRepo
|
|
6
|
+
} from "./chunk-HFOQKCD2.js";
|
|
4
7
|
import {
|
|
5
8
|
CodebaseIndex,
|
|
6
9
|
extractSymbolIndex,
|
|
@@ -11,9 +14,14 @@ import {
|
|
|
11
14
|
SARIF_LEVEL_MAP,
|
|
12
15
|
SEVERITY_ORDER
|
|
13
16
|
} from "./chunk-WAYGXUSM.js";
|
|
17
|
+
import {
|
|
18
|
+
DEFAULT_TASK_TTL_MS,
|
|
19
|
+
DEFAULT_TOOL_RATE_LIMITS,
|
|
20
|
+
clampTaskTtl
|
|
21
|
+
} from "./chunk-DPHEFR5X.js";
|
|
14
22
|
import {
|
|
15
23
|
executeExpert
|
|
16
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-7QR2RTA4.js";
|
|
17
25
|
import {
|
|
18
26
|
JobStatusSchema,
|
|
19
27
|
collectRealVotes,
|
|
@@ -32,24 +40,24 @@ import {
|
|
|
32
40
|
toJobSummary,
|
|
33
41
|
warnIfSimulatedOutsideTests,
|
|
34
42
|
writeJobCancelled
|
|
35
|
-
} from "./chunk-
|
|
43
|
+
} from "./chunk-HC5CUX6C.js";
|
|
36
44
|
import {
|
|
37
45
|
normalizeTopicToCanonical,
|
|
38
46
|
synthesizeResearch
|
|
39
|
-
} from "./chunk-
|
|
47
|
+
} from "./chunk-ZJ3WGARD.js";
|
|
40
48
|
import {
|
|
41
49
|
IssueTriage,
|
|
42
50
|
createAuditTrail,
|
|
43
51
|
createGraphAuditBridge,
|
|
44
52
|
emitPipelinePolicyEvent
|
|
45
|
-
} from "./chunk-
|
|
53
|
+
} from "./chunk-MXDMJGVG.js";
|
|
46
54
|
import {
|
|
47
55
|
resolveEnvMode,
|
|
48
56
|
sanitizeInput
|
|
49
|
-
} from "./chunk-
|
|
57
|
+
} from "./chunk-MNXLJ2VX.js";
|
|
50
58
|
import {
|
|
51
59
|
withPrerequisite
|
|
52
|
-
} from "./chunk-
|
|
60
|
+
} from "./chunk-AL7ZYHAF.js";
|
|
53
61
|
import {
|
|
54
62
|
NOOP_NOTIFIER,
|
|
55
63
|
RateLimiter,
|
|
@@ -71,10 +79,7 @@ import {
|
|
|
71
79
|
withAccessPolicy,
|
|
72
80
|
withProgressHeartbeat,
|
|
73
81
|
wrapToolWithTimeout
|
|
74
|
-
} from "./chunk-
|
|
75
|
-
import {
|
|
76
|
-
analyzeGitHubRepo
|
|
77
|
-
} from "./chunk-HFOQKCD2.js";
|
|
82
|
+
} from "./chunk-NJW5GQUF.js";
|
|
78
83
|
import {
|
|
79
84
|
addResearchPaper,
|
|
80
85
|
addSourceToRegistry,
|
|
@@ -102,36 +107,31 @@ import {
|
|
|
102
107
|
parseRegistry,
|
|
103
108
|
sourceExistsInRegistry,
|
|
104
109
|
summarizeContextForPrompt
|
|
105
|
-
} from "./chunk-
|
|
110
|
+
} from "./chunk-PLKWH53F.js";
|
|
106
111
|
import {
|
|
107
112
|
getTokenEnvVars,
|
|
108
113
|
resolveToken
|
|
109
|
-
} from "./chunk-
|
|
114
|
+
} from "./chunk-LMMLLGZZ.js";
|
|
110
115
|
import {
|
|
111
116
|
loadPapersRegistry,
|
|
112
117
|
loadTechniquesRegistry
|
|
113
|
-
} from "./chunk-
|
|
118
|
+
} from "./chunk-JFKNUEZ7.js";
|
|
119
|
+
import {
|
|
120
|
+
resolveInsideRoot
|
|
121
|
+
} from "./chunk-NUBSJGQZ.js";
|
|
114
122
|
import {
|
|
115
123
|
DEFAULT_RELEVANCE_CONFIG,
|
|
116
124
|
MemoryImportance,
|
|
117
125
|
calculateTextJaccardSimilarity,
|
|
118
126
|
getToolMemory
|
|
119
|
-
} from "./chunk-
|
|
120
|
-
import {
|
|
121
|
-
createSessionMemory
|
|
122
|
-
} from "./chunk-52N3NGEY.js";
|
|
123
|
-
import {
|
|
124
|
-
DEFAULT_TASK_TTL_MS,
|
|
125
|
-
DEFAULT_TOOL_RATE_LIMITS,
|
|
126
|
-
clampTaskTtl
|
|
127
|
-
} from "./chunk-JWWCNN76.js";
|
|
128
|
-
import {
|
|
129
|
-
resolveInsideRoot
|
|
130
|
-
} from "./chunk-NUBSJGQZ.js";
|
|
127
|
+
} from "./chunk-J2HWO3J3.js";
|
|
131
128
|
import {
|
|
132
129
|
STOPWORDS,
|
|
133
130
|
truncateWithInfo
|
|
134
131
|
} from "./chunk-6T3EPABN.js";
|
|
132
|
+
import {
|
|
133
|
+
createSessionMemory
|
|
134
|
+
} from "./chunk-D2XWKFZ2.js";
|
|
135
135
|
import {
|
|
136
136
|
BUILT_IN_EXPERTS,
|
|
137
137
|
BuiltInExpertTypeSchema,
|
|
@@ -140,13 +140,13 @@ import {
|
|
|
140
140
|
} from "./chunk-ZM4O442V.js";
|
|
141
141
|
import {
|
|
142
142
|
getMemoryRegistry
|
|
143
|
-
} from "./chunk-
|
|
143
|
+
} from "./chunk-2XRPKJKX.js";
|
|
144
144
|
import {
|
|
145
145
|
EventTopics,
|
|
146
146
|
createEvent,
|
|
147
147
|
getGlobalEventBus,
|
|
148
148
|
getGlobalRegistry
|
|
149
|
-
} from "./chunk-
|
|
149
|
+
} from "./chunk-H3B7H67H.js";
|
|
150
150
|
import {
|
|
151
151
|
CliDetectionCache,
|
|
152
152
|
asRecord,
|
|
@@ -154,19 +154,19 @@ import {
|
|
|
154
154
|
getAvailableClis,
|
|
155
155
|
sleep,
|
|
156
156
|
withTimeout
|
|
157
|
-
} from "./chunk-
|
|
157
|
+
} from "./chunk-7XCQJXN4.js";
|
|
158
158
|
import {
|
|
159
159
|
DEFAULTS
|
|
160
|
-
} from "./chunk-
|
|
160
|
+
} from "./chunk-DKU7O4V2.js";
|
|
161
161
|
import {
|
|
162
162
|
getAvailabilityCache,
|
|
163
163
|
getCliForModelId,
|
|
164
164
|
resolveFallback
|
|
165
|
-
} from "./chunk-
|
|
165
|
+
} from "./chunk-DTHMBYSV.js";
|
|
166
166
|
import {
|
|
167
167
|
generateHyphenId,
|
|
168
168
|
generateUUID
|
|
169
|
-
} from "./chunk-
|
|
169
|
+
} from "./chunk-K62WRHHK.js";
|
|
170
170
|
import {
|
|
171
171
|
AGENT_ROUTER_TIMEOUTS,
|
|
172
172
|
API_TIMEOUTS,
|
|
@@ -258,14 +258,16 @@ import {
|
|
|
258
258
|
selectStrategyByManifest,
|
|
259
259
|
toExpertTaskAnalysisResult,
|
|
260
260
|
withStep
|
|
261
|
-
} from "./chunk-
|
|
261
|
+
} from "./chunk-KWZC5LFC.js";
|
|
262
262
|
import {
|
|
263
263
|
ensureLearningDir,
|
|
264
264
|
getMetaOutcomesFile,
|
|
265
|
-
isPersistenceEnabled
|
|
265
|
+
isPersistenceEnabled
|
|
266
|
+
} from "./chunk-NL7SZQPW.js";
|
|
267
|
+
import {
|
|
266
268
|
nexusDataPath,
|
|
267
269
|
nexusDataPathEnsure
|
|
268
|
-
} from "./chunk-
|
|
270
|
+
} from "./chunk-DHVMSIT5.js";
|
|
269
271
|
|
|
270
272
|
// src/agents/state-machine-types.ts
|
|
271
273
|
var VALID_TRANSITIONS = /* @__PURE__ */ new Map([
|
|
@@ -26290,7 +26292,7 @@ function execIdFields(executionId) {
|
|
|
26290
26292
|
async function populateUnifiedContextOnState(state, options) {
|
|
26291
26293
|
const taskCandidate = state["task"];
|
|
26292
26294
|
if (typeof taskCandidate !== "string" || taskCandidate === "") return;
|
|
26293
|
-
const { getContextForTask: getContextForTask2, inferTaskCategory: inferTaskCategory2 } = await import("./context-retriever-
|
|
26295
|
+
const { getContextForTask: getContextForTask2, inferTaskCategory: inferTaskCategory2 } = await import("./context-retriever-MAZKHYRD.js");
|
|
26294
26296
|
const category = inferTaskCategory2(taskCandidate);
|
|
26295
26297
|
const executionId = options?.executionId;
|
|
26296
26298
|
const execFields = execIdFields(executionId);
|
|
@@ -41387,7 +41389,7 @@ async function tryIssueTriage(task) {
|
|
|
41387
41389
|
try {
|
|
41388
41390
|
const issueMatch = task.match(/github\.com\/([^/]+\/[^/]+)\/issues\/(\d+)/);
|
|
41389
41391
|
if (issueMatch === null) return null;
|
|
41390
|
-
const { createIssueTriage } = await import("./issue-triage-
|
|
41392
|
+
const { createIssueTriage } = await import("./issue-triage-NI2ZDVTB.js");
|
|
41391
41393
|
const triage = createIssueTriage();
|
|
41392
41394
|
const owner = issueMatch[1] ?? "";
|
|
41393
41395
|
const num = issueMatch[2] ?? "";
|
|
@@ -41415,7 +41417,7 @@ var VALID_TEMPLATES = /* @__PURE__ */ new Set([
|
|
|
41415
41417
|
]);
|
|
41416
41418
|
async function classifyWithLLM(task) {
|
|
41417
41419
|
try {
|
|
41418
|
-
const { executeExpert: executeExpert2 } = await import("./expert-bridge-
|
|
41420
|
+
const { executeExpert: executeExpert2 } = await import("./expert-bridge-EA3U3GKU.js");
|
|
41419
41421
|
const prompt = [
|
|
41420
41422
|
"Classify this task into exactly one pipeline template.",
|
|
41421
41423
|
"Templates: dev (implementation/bug fix/refactor), research (investigate/evaluate/compare),",
|
|
@@ -43181,8 +43183,8 @@ var memoryInitPromise = null;
|
|
|
43181
43183
|
async function initPipelineMemory() {
|
|
43182
43184
|
if (cachedMemory !== null) return cachedMemory;
|
|
43183
43185
|
try {
|
|
43184
|
-
const { createSessionMemory: createSessionMemory2 } = await import("./session-memory-
|
|
43185
|
-
const { getLearningDir } = await import("./learning-persistence-
|
|
43186
|
+
const { createSessionMemory: createSessionMemory2 } = await import("./session-memory-PUEUWVIN.js");
|
|
43187
|
+
const { getLearningDir } = await import("./learning-persistence-M3OTCCNI.js");
|
|
43186
43188
|
const mem = createSessionMemory2(getLearningDir());
|
|
43187
43189
|
mem.startSession(`pipeline-${String(getTimeProvider().now())}`);
|
|
43188
43190
|
cachedMemory = {
|
|
@@ -43243,7 +43245,7 @@ function recordRoutingExperience(category, success, durationMs, tokensUsed = 0,
|
|
|
43243
43245
|
callRecord(routingMemoryCache);
|
|
43244
43246
|
return;
|
|
43245
43247
|
}
|
|
43246
|
-
routingMemoryInitPromise ??= import("./routing-memory-
|
|
43248
|
+
routingMemoryInitPromise ??= import("./routing-memory-TLB5EY7J.js").then(({ createRoutingMemory }) => {
|
|
43247
43249
|
routingMemoryCache ??= createRoutingMemory();
|
|
43248
43250
|
return routingMemoryCache;
|
|
43249
43251
|
}).catch((error) => {
|
|
@@ -43277,7 +43279,7 @@ ${text}` : "";
|
|
|
43277
43279
|
}
|
|
43278
43280
|
async function getWeatherContext() {
|
|
43279
43281
|
try {
|
|
43280
|
-
const { generateWeatherReport: generateWeatherReport2 } = await import("./weather-report-
|
|
43282
|
+
const { generateWeatherReport: generateWeatherReport2 } = await import("./weather-report-WK7TJPMM.js");
|
|
43281
43283
|
const report = generateWeatherReport2({ includeAdaptive: true });
|
|
43282
43284
|
const mappings = "recommendedMappings" in report ? report.recommendedMappings : [];
|
|
43283
43285
|
if (!Array.isArray(mappings) || mappings.length === 0) return "";
|
|
@@ -43295,8 +43297,8 @@ ${lines}
|
|
|
43295
43297
|
}
|
|
43296
43298
|
async function getMemoryContext(task) {
|
|
43297
43299
|
try {
|
|
43298
|
-
const { createSessionMemory: createSessionMemory2 } = await import("./session-memory-
|
|
43299
|
-
const { getLearningDir } = await import("./learning-persistence-
|
|
43300
|
+
const { createSessionMemory: createSessionMemory2 } = await import("./session-memory-PUEUWVIN.js");
|
|
43301
|
+
const { getLearningDir } = await import("./learning-persistence-M3OTCCNI.js");
|
|
43300
43302
|
const memory = createSessionMemory2(getLearningDir(), { maxLearningsInContext: 10 });
|
|
43301
43303
|
const learnings = memory.searchLearnings(task.slice(0, 200));
|
|
43302
43304
|
if (learnings.length === 0) return "";
|
|
@@ -43407,7 +43409,7 @@ ${contextBlock}`;
|
|
|
43407
43409
|
const strategy = config.votingStrategy ?? "higher_order";
|
|
43408
43410
|
await postProgress(config, "Vote", `Running consensus with ${strategy} strategy...`);
|
|
43409
43411
|
try {
|
|
43410
|
-
const { executeVoting } = await import("./consensus-vote-
|
|
43412
|
+
const { executeVoting } = await import("./consensus-vote-HHA73ME6.js");
|
|
43411
43413
|
const votingResult = await executeVoting(
|
|
43412
43414
|
{
|
|
43413
43415
|
proposal: buildVoteProposal(plan, research),
|
|
@@ -43844,7 +43846,7 @@ async function searchCodebaseForTask(task) {
|
|
|
43844
43846
|
}
|
|
43845
43847
|
async function queryResearchRegistry(task) {
|
|
43846
43848
|
try {
|
|
43847
|
-
const { synthesizeResearch: synthesizeResearch2 } = await import("./research-helpers-synthesize-
|
|
43849
|
+
const { synthesizeResearch: synthesizeResearch2 } = await import("./research-helpers-synthesize-R45KXXNH.js");
|
|
43848
43850
|
const topic = task.split(/[.!?\n]/).filter((s) => s.trim().length > 10)[0]?.trim();
|
|
43849
43851
|
if (topic === void 0) return null;
|
|
43850
43852
|
const result = await synthesizeResearch2(topic.slice(0, 50));
|
|
@@ -43915,7 +43917,7 @@ function createScanStageWrapper() {
|
|
|
43915
43917
|
try {
|
|
43916
43918
|
const slug = ctx.task.match(/([a-zA-Z0-9._-]+\/[a-zA-Z0-9._-]+)/)?.[1];
|
|
43917
43919
|
if (slug !== void 0) {
|
|
43918
|
-
const { generateSecurityPlan: generateSecurityPlan2 } = await import("./repo-security-plan-
|
|
43920
|
+
const { generateSecurityPlan: generateSecurityPlan2 } = await import("./repo-security-plan-PCGHBEGZ.js");
|
|
43919
43921
|
const plan = await generateSecurityPlan2({ repo: slug, maxScanners: 10 });
|
|
43920
43922
|
const recs = plan.recommendations.slice(0, 5).map((r) => `${r.priority}: ${r.displayName} (${r.category})`).join("; ");
|
|
43921
43923
|
return output(PIPELINE_STATE_KEYS.FINDINGS, recs, getTimeProvider().now() - start, true);
|
|
@@ -46021,7 +46023,7 @@ var GitHubTaskTracker = class {
|
|
|
46021
46023
|
cachedProvider = null;
|
|
46022
46024
|
async getProvider() {
|
|
46023
46025
|
if (this.cachedProvider !== null) return this.cachedProvider;
|
|
46024
|
-
const { createScmProvider } = await import("./factory-
|
|
46026
|
+
const { createScmProvider } = await import("./factory-Y5WCLQDB.js");
|
|
46025
46027
|
const result = await createScmProvider({ repo: this.config.repo ?? "" });
|
|
46026
46028
|
if (!result.ok) throw new Error(`SCM provider error: ${result.error.message}`);
|
|
46027
46029
|
this.cachedProvider = result.value;
|
|
@@ -46786,7 +46788,7 @@ async function probeSource(source, includeModelIds) {
|
|
|
46786
46788
|
}
|
|
46787
46789
|
}
|
|
46788
46790
|
async function defaultSources(includeOpenRouter) {
|
|
46789
|
-
const { createAllAdapters: createAllAdapters2 } = await import("./factory-
|
|
46791
|
+
const { createAllAdapters: createAllAdapters2 } = await import("./factory-FACKN4IN.js");
|
|
46790
46792
|
const adapters = createAllAdapters2();
|
|
46791
46793
|
return buildDefaultModelSources(adapters, { includeOpenRouter });
|
|
46792
46794
|
}
|
|
@@ -50909,4 +50911,4 @@ export {
|
|
|
50909
50911
|
shutdownFeedbackSubscriber,
|
|
50910
50912
|
createEventBusBridge
|
|
50911
50913
|
};
|
|
50912
|
-
//# sourceMappingURL=chunk-
|
|
50914
|
+
//# sourceMappingURL=chunk-23J7J37D.js.map
|