nexus-agents 2.83.0 → 2.83.1
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-XVPIO5HV.js → child-mcp-config-3ZW2UPKZ.js} +2 -2
- package/dist/{chunk-AINOJRZX.js → chunk-4XSCU4B3.js} +8 -8
- package/dist/{chunk-BZUEUD4G.js → chunk-5QJPM5CB.js} +3 -3
- package/dist/{chunk-633WH2ML.js → chunk-6T3EPABN.js} +1 -1
- package/dist/chunk-6T3EPABN.js.map +1 -0
- package/dist/{chunk-RXVH52UI.js → chunk-6UI4NKT4.js} +2 -2
- package/dist/{chunk-ZIWEEVMI.js → chunk-6XRNFLPI.js} +2 -2
- package/dist/{chunk-YO27YAEX.js → chunk-7V367KT4.js} +4 -4
- package/dist/{chunk-6WDJ3IE4.js → chunk-A6WC5I7V.js} +3 -3
- package/dist/{chunk-2W4QJ27D.js → chunk-BICIQYET.js} +3 -3
- package/dist/{chunk-WJFUTRHX.js → chunk-BUXXAN6V.js} +2 -2
- package/dist/{chunk-ZM5JKJHI.js → chunk-DWOSFYI2.js} +2 -2
- package/dist/{chunk-FHGDJKCZ.js → chunk-ELRNVADA.js} +3 -3
- package/dist/{chunk-AFPHR72D.js → chunk-FHY7I736.js} +2 -2
- package/dist/{chunk-3GJAAENS.js → chunk-HGPIHDC4.js} +3 -3
- package/dist/{chunk-WGSRH5EQ.js → chunk-IM2B3FK2.js} +3 -3
- package/dist/{chunk-PMLVZXAE.js → chunk-J4ZBKE4B.js} +129 -190
- package/dist/chunk-J4ZBKE4B.js.map +1 -0
- package/dist/{chunk-54UXPJVM.js → chunk-JA6ON2RP.js} +2 -2
- package/dist/{chunk-5T6SYCH2.js → chunk-LM2S2QWO.js} +2 -2
- package/dist/{chunk-5T6SYCH2.js.map → chunk-LM2S2QWO.js.map} +1 -1
- package/dist/{chunk-3ASED5PR.js → chunk-MATFDJRW.js} +4 -4
- package/dist/{chunk-FI77TGBY.js → chunk-O3XJLOEX.js} +2 -2
- package/dist/{chunk-4BXQ2OZY.js → chunk-ODKIRXN7.js} +9 -36
- package/dist/chunk-ODKIRXN7.js.map +1 -0
- package/dist/{chunk-NLPMYBIV.js → chunk-SZZS57X7.js} +7 -7
- package/dist/{chunk-RVRXKNND.js → chunk-TKGVRHEI.js} +2 -2
- package/dist/{chunk-U6LDVJS7.js → chunk-UFUR6RBP.js} +2 -2
- package/dist/{chunk-Q6PZMGLU.js → chunk-VXIHHHLQ.js} +2 -2
- package/dist/{chunk-3WUVWZUC.js → chunk-W6MLS2UL.js} +2 -2
- package/dist/{chunk-Z64MSLEK.js → chunk-XODXYOFN.js} +2 -2
- package/dist/{chunk-PPBZQKRP.js → chunk-ZA6AZ7LK.js} +5 -5
- package/dist/{chunk-L362KRSU.js → chunk-ZLGU7T6J.js} +2 -2
- package/dist/{cli-circuit-breaker-Y26NPPNO.js → cli-circuit-breaker-LC4NZUGD.js} +4 -4
- package/dist/cli.js +33 -33
- package/dist/{composite-router-X2ZYIEHH.js → composite-router-GXQ25DO4.js} +2 -2
- package/dist/{consensus-vote-KZ6UURUI.js → consensus-vote-MTLP6E72.js} +12 -12
- package/dist/{context-retriever-QY4FNTDZ.js → context-retriever-GQRC2MVM.js} +6 -6
- package/dist/{doctor-deep-2E2GBMYR.js → doctor-deep-T3UUJX2E.js} +3 -3
- package/dist/{expert-bridge-FHPWDFJX.js → expert-bridge-7LPGCPPR.js} +4 -4
- package/dist/{factory-W6KROBFN.js → factory-3XB5CAAA.js} +5 -5
- package/dist/{factory-STNVY3Y3.js → factory-OKNCTJO6.js} +4 -4
- package/dist/index.d.ts +3 -143
- package/dist/index.js +28 -126
- package/dist/index.js.map +1 -1
- package/dist/{init-opencode-6LVZ4CAQ.js → init-opencode-KDTBKLXS.js} +5 -5
- package/dist/{issue-triage-Y77JI7WF.js → issue-triage-MURMDN2G.js} +4 -4
- package/dist/{registry-command-P5VIAEOL.js → registry-command-D56ROMFJ.js} +2 -2
- package/dist/{repo-security-plan-RHSLO7H6.js → repo-security-plan-N3CDMW6L.js} +3 -3
- package/dist/{research-helpers-synthesize-PVP6JRZV.js → research-helpers-synthesize-36QBOKII.js} +3 -3
- package/dist/{routing-memory-QRIJPRVD.js → routing-memory-6IEPJ3EP.js} +2 -2
- package/dist/{session-memory-WARRGYY7.js → session-memory-X6SCDFER.js} +3 -3
- package/dist/{setup-command-GMP5FI7F.js → setup-command-5AEO5A4Z.js} +11 -11
- package/dist/{setup-config-G3KKZM7O.js → setup-config-RPSVIQJO.js} +3 -3
- package/dist/{setup-custom-api-B63X7ISD.js → setup-custom-api-RBOJT3SS.js} +4 -4
- package/dist/{tool-memory-E7JW4YLT.js → tool-memory-EEHITQRJ.js} +5 -5
- package/dist/{weather-report-RACZWJQL.js → weather-report-6BC3JK5H.js} +2 -2
- package/package.json +1 -1
- package/dist/chunk-4BXQ2OZY.js.map +0 -1
- package/dist/chunk-633WH2ML.js.map +0 -1
- package/dist/chunk-PMLVZXAE.js.map +0 -1
- /package/dist/{child-mcp-config-XVPIO5HV.js.map → child-mcp-config-3ZW2UPKZ.js.map} +0 -0
- /package/dist/{chunk-AINOJRZX.js.map → chunk-4XSCU4B3.js.map} +0 -0
- /package/dist/{chunk-BZUEUD4G.js.map → chunk-5QJPM5CB.js.map} +0 -0
- /package/dist/{chunk-RXVH52UI.js.map → chunk-6UI4NKT4.js.map} +0 -0
- /package/dist/{chunk-ZIWEEVMI.js.map → chunk-6XRNFLPI.js.map} +0 -0
- /package/dist/{chunk-YO27YAEX.js.map → chunk-7V367KT4.js.map} +0 -0
- /package/dist/{chunk-6WDJ3IE4.js.map → chunk-A6WC5I7V.js.map} +0 -0
- /package/dist/{chunk-2W4QJ27D.js.map → chunk-BICIQYET.js.map} +0 -0
- /package/dist/{chunk-WJFUTRHX.js.map → chunk-BUXXAN6V.js.map} +0 -0
- /package/dist/{chunk-ZM5JKJHI.js.map → chunk-DWOSFYI2.js.map} +0 -0
- /package/dist/{chunk-FHGDJKCZ.js.map → chunk-ELRNVADA.js.map} +0 -0
- /package/dist/{chunk-AFPHR72D.js.map → chunk-FHY7I736.js.map} +0 -0
- /package/dist/{chunk-3GJAAENS.js.map → chunk-HGPIHDC4.js.map} +0 -0
- /package/dist/{chunk-WGSRH5EQ.js.map → chunk-IM2B3FK2.js.map} +0 -0
- /package/dist/{chunk-54UXPJVM.js.map → chunk-JA6ON2RP.js.map} +0 -0
- /package/dist/{chunk-3ASED5PR.js.map → chunk-MATFDJRW.js.map} +0 -0
- /package/dist/{chunk-FI77TGBY.js.map → chunk-O3XJLOEX.js.map} +0 -0
- /package/dist/{chunk-NLPMYBIV.js.map → chunk-SZZS57X7.js.map} +0 -0
- /package/dist/{chunk-RVRXKNND.js.map → chunk-TKGVRHEI.js.map} +0 -0
- /package/dist/{chunk-U6LDVJS7.js.map → chunk-UFUR6RBP.js.map} +0 -0
- /package/dist/{chunk-Q6PZMGLU.js.map → chunk-VXIHHHLQ.js.map} +0 -0
- /package/dist/{chunk-3WUVWZUC.js.map → chunk-W6MLS2UL.js.map} +0 -0
- /package/dist/{chunk-Z64MSLEK.js.map → chunk-XODXYOFN.js.map} +0 -0
- /package/dist/{chunk-PPBZQKRP.js.map → chunk-ZA6AZ7LK.js.map} +0 -0
- /package/dist/{chunk-L362KRSU.js.map → chunk-ZLGU7T6J.js.map} +0 -0
- /package/dist/{cli-circuit-breaker-Y26NPPNO.js.map → cli-circuit-breaker-LC4NZUGD.js.map} +0 -0
- /package/dist/{composite-router-X2ZYIEHH.js.map → composite-router-GXQ25DO4.js.map} +0 -0
- /package/dist/{consensus-vote-KZ6UURUI.js.map → consensus-vote-MTLP6E72.js.map} +0 -0
- /package/dist/{context-retriever-QY4FNTDZ.js.map → context-retriever-GQRC2MVM.js.map} +0 -0
- /package/dist/{doctor-deep-2E2GBMYR.js.map → doctor-deep-T3UUJX2E.js.map} +0 -0
- /package/dist/{expert-bridge-FHPWDFJX.js.map → expert-bridge-7LPGCPPR.js.map} +0 -0
- /package/dist/{factory-STNVY3Y3.js.map → factory-3XB5CAAA.js.map} +0 -0
- /package/dist/{factory-W6KROBFN.js.map → factory-OKNCTJO6.js.map} +0 -0
- /package/dist/{init-opencode-6LVZ4CAQ.js.map → init-opencode-KDTBKLXS.js.map} +0 -0
- /package/dist/{issue-triage-Y77JI7WF.js.map → issue-triage-MURMDN2G.js.map} +0 -0
- /package/dist/{registry-command-P5VIAEOL.js.map → registry-command-D56ROMFJ.js.map} +0 -0
- /package/dist/{repo-security-plan-RHSLO7H6.js.map → repo-security-plan-N3CDMW6L.js.map} +0 -0
- /package/dist/{research-helpers-synthesize-PVP6JRZV.js.map → research-helpers-synthesize-36QBOKII.js.map} +0 -0
- /package/dist/{routing-memory-QRIJPRVD.js.map → routing-memory-6IEPJ3EP.js.map} +0 -0
- /package/dist/{session-memory-WARRGYY7.js.map → session-memory-X6SCDFER.js.map} +0 -0
- /package/dist/{setup-command-GMP5FI7F.js.map → setup-command-5AEO5A4Z.js.map} +0 -0
- /package/dist/{setup-config-G3KKZM7O.js.map → setup-config-RPSVIQJO.js.map} +0 -0
- /package/dist/{setup-custom-api-B63X7ISD.js.map → setup-custom-api-RBOJT3SS.js.map} +0 -0
- /package/dist/{tool-memory-E7JW4YLT.js.map → tool-memory-EEHITQRJ.js.map} +0 -0
- /package/dist/{weather-report-RACZWJQL.js.map → weather-report-6BC3JK5H.js.map} +0 -0
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getTokenEnvVars,
|
|
3
3
|
resolveToken
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-XODXYOFN.js";
|
|
5
5
|
import {
|
|
6
6
|
executeExpert
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-SZZS57X7.js";
|
|
8
8
|
import {
|
|
9
9
|
EventTopics,
|
|
10
10
|
NOOP_NOTIFIER,
|
|
@@ -30,7 +30,7 @@ import {
|
|
|
30
30
|
withAccessPolicy,
|
|
31
31
|
withProgressHeartbeat,
|
|
32
32
|
wrapToolWithTimeout
|
|
33
|
-
} from "./chunk-
|
|
33
|
+
} from "./chunk-ODKIRXN7.js";
|
|
34
34
|
import {
|
|
35
35
|
REGISTRY_PATH,
|
|
36
36
|
getProjectRoot,
|
|
@@ -39,14 +39,14 @@ import {
|
|
|
39
39
|
normalizeTopicToCanonical,
|
|
40
40
|
savePapersRegistry,
|
|
41
41
|
synthesizeResearch
|
|
42
|
-
} from "./chunk-
|
|
42
|
+
} from "./chunk-FHY7I736.js";
|
|
43
43
|
import {
|
|
44
44
|
IssueTriage,
|
|
45
45
|
sanitizeInput
|
|
46
|
-
} from "./chunk-
|
|
46
|
+
} from "./chunk-5QJPM5CB.js";
|
|
47
47
|
import {
|
|
48
48
|
generateSecurityPlan
|
|
49
|
-
} from "./chunk-
|
|
49
|
+
} from "./chunk-TKGVRHEI.js";
|
|
50
50
|
import {
|
|
51
51
|
analyzeGitHubRepo
|
|
52
52
|
} from "./chunk-HFOQKCD2.js";
|
|
@@ -59,7 +59,7 @@ import {
|
|
|
59
59
|
getContextForTask,
|
|
60
60
|
inferTaskCategory,
|
|
61
61
|
summarizeContextForPrompt
|
|
62
|
-
} from "./chunk-
|
|
62
|
+
} from "./chunk-HGPIHDC4.js";
|
|
63
63
|
import {
|
|
64
64
|
DEFAULT_RELEVANCE_CONFIG,
|
|
65
65
|
MemoryImportance,
|
|
@@ -67,19 +67,19 @@ import {
|
|
|
67
67
|
generateHyphenId,
|
|
68
68
|
generateUUID,
|
|
69
69
|
getToolMemory
|
|
70
|
-
} from "./chunk-
|
|
70
|
+
} from "./chunk-7V367KT4.js";
|
|
71
71
|
import {
|
|
72
72
|
DEFAULT_TASK_TTL_MS,
|
|
73
73
|
DEFAULT_TOOL_RATE_LIMITS,
|
|
74
74
|
clampTaskTtl
|
|
75
|
-
} from "./chunk-
|
|
75
|
+
} from "./chunk-4XSCU4B3.js";
|
|
76
76
|
import {
|
|
77
77
|
getAvailabilityCache,
|
|
78
78
|
resolveFallback
|
|
79
|
-
} from "./chunk-
|
|
79
|
+
} from "./chunk-W6MLS2UL.js";
|
|
80
80
|
import {
|
|
81
81
|
DEFAULTS
|
|
82
|
-
} from "./chunk-
|
|
82
|
+
} from "./chunk-DWOSFYI2.js";
|
|
83
83
|
import {
|
|
84
84
|
resolveInsideRoot
|
|
85
85
|
} from "./chunk-NUBSJGQZ.js";
|
|
@@ -87,7 +87,7 @@ import {
|
|
|
87
87
|
STOPWORDS,
|
|
88
88
|
capitalizeWords,
|
|
89
89
|
truncateWithInfo
|
|
90
|
-
} from "./chunk-
|
|
90
|
+
} from "./chunk-6T3EPABN.js";
|
|
91
91
|
import {
|
|
92
92
|
CliDetectionCache,
|
|
93
93
|
asRecord,
|
|
@@ -95,7 +95,7 @@ import {
|
|
|
95
95
|
getAvailableClis,
|
|
96
96
|
sleep,
|
|
97
97
|
withTimeout
|
|
98
|
-
} from "./chunk-
|
|
98
|
+
} from "./chunk-ELRNVADA.js";
|
|
99
99
|
import {
|
|
100
100
|
BUILT_IN_EXPERTS,
|
|
101
101
|
BuiltInExpertTypeSchema,
|
|
@@ -107,7 +107,7 @@ import {
|
|
|
107
107
|
} from "./chunk-PQHVC4BD.js";
|
|
108
108
|
import {
|
|
109
109
|
createSessionMemory
|
|
110
|
-
} from "./chunk-
|
|
110
|
+
} from "./chunk-UFUR6RBP.js";
|
|
111
111
|
import {
|
|
112
112
|
AGENT_ROUTER_TIMEOUTS,
|
|
113
113
|
API_TIMEOUTS,
|
|
@@ -178,7 +178,7 @@ import {
|
|
|
178
178
|
resolveModelIdentitySync,
|
|
179
179
|
toExpertTaskAnalysisResult,
|
|
180
180
|
withStep
|
|
181
|
-
} from "./chunk-
|
|
181
|
+
} from "./chunk-6UI4NKT4.js";
|
|
182
182
|
import {
|
|
183
183
|
getNexusDataDir,
|
|
184
184
|
nexusDataPath
|
|
@@ -21086,7 +21086,12 @@ var WorkflowEngine = class {
|
|
|
21086
21086
|
state: "failed",
|
|
21087
21087
|
error: stepResults.error.message
|
|
21088
21088
|
});
|
|
21089
|
-
|
|
21089
|
+
const elapsedMs = getTimeProvider().now() - startTime;
|
|
21090
|
+
const innerErr = stepResults.error;
|
|
21091
|
+
const enriched = new WorkflowError(innerErr.message, {
|
|
21092
|
+
context: { ...innerErr.context ?? {}, executionId, durationMs: elapsedMs }
|
|
21093
|
+
});
|
|
21094
|
+
return err(enriched);
|
|
21090
21095
|
}
|
|
21091
21096
|
const result = {
|
|
21092
21097
|
executionId,
|
|
@@ -23484,10 +23489,10 @@ function calculateZStatistic(params) {
|
|
|
23484
23489
|
function calculateDifferenceCI(p1, p2, total1, total2, confidence) {
|
|
23485
23490
|
const difference = p1 - p2;
|
|
23486
23491
|
const seDiff = Math.sqrt(p1 * (1 - p1) / (total1 || 1) + p2 * (1 - p2) / (total2 || 1));
|
|
23487
|
-
const
|
|
23492
|
+
const z107 = getZScore(confidence);
|
|
23488
23493
|
return {
|
|
23489
|
-
lower: difference -
|
|
23490
|
-
upper: difference +
|
|
23494
|
+
lower: difference - z107 * seDiff,
|
|
23495
|
+
upper: difference + z107 * seDiff,
|
|
23491
23496
|
estimate: difference,
|
|
23492
23497
|
confidence,
|
|
23493
23498
|
n: total1 + total2,
|
|
@@ -23510,11 +23515,11 @@ function proportionConfidenceInterval(successes, total, options = {}) {
|
|
|
23510
23515
|
standardError: 0
|
|
23511
23516
|
};
|
|
23512
23517
|
}
|
|
23513
|
-
const
|
|
23514
|
-
const z210 =
|
|
23518
|
+
const z107 = getZScore(opts.confidence);
|
|
23519
|
+
const z210 = z107 * z107;
|
|
23515
23520
|
const denominator = 1 + z210 / n;
|
|
23516
23521
|
const center = (p + z210 / (2 * n)) / denominator;
|
|
23517
|
-
const margin =
|
|
23522
|
+
const margin = z107 / denominator * Math.sqrt(p * (1 - p) / n + z210 / (4 * n * n));
|
|
23518
23523
|
const lower = Math.max(0, center - margin);
|
|
23519
23524
|
const upper = Math.min(1, center + margin);
|
|
23520
23525
|
const standardError = Math.sqrt(p * (1 - p) / n);
|
|
@@ -23544,8 +23549,8 @@ function meanConfidenceInterval(values, options = {}) {
|
|
|
23544
23549
|
const variance = values.reduce((sum, v) => sum + (v - mean) ** 2, 0) / (n - 1 || 1);
|
|
23545
23550
|
const stdDev = Math.sqrt(variance);
|
|
23546
23551
|
const standardError = stdDev / Math.sqrt(n);
|
|
23547
|
-
const
|
|
23548
|
-
const margin =
|
|
23552
|
+
const z107 = getZScore(opts.confidence);
|
|
23553
|
+
const margin = z107 * standardError;
|
|
23549
23554
|
return {
|
|
23550
23555
|
lower: mean - margin,
|
|
23551
23556
|
upper: mean + margin,
|
|
@@ -26129,14 +26134,14 @@ function successResponse(data) {
|
|
|
26129
26134
|
function errorResponse(message) {
|
|
26130
26135
|
return toolError(message);
|
|
26131
26136
|
}
|
|
26132
|
-
function createFailedResult(workflowName, errorMessage) {
|
|
26137
|
+
function createFailedResult(workflowName, errorMessage, opts = {}) {
|
|
26133
26138
|
const result = {
|
|
26134
|
-
executionId: "unknown",
|
|
26139
|
+
executionId: opts.executionId ?? "unknown",
|
|
26135
26140
|
workflowName,
|
|
26136
26141
|
status: "failed",
|
|
26137
26142
|
stepResults: [],
|
|
26138
26143
|
output: null,
|
|
26139
|
-
durationMs: 0,
|
|
26144
|
+
durationMs: opts.durationMs ?? 0,
|
|
26140
26145
|
error: errorMessage
|
|
26141
26146
|
};
|
|
26142
26147
|
return toolStructuredError({
|
|
@@ -26226,6 +26231,15 @@ function recordWorkflowError(template, errorMessage) {
|
|
|
26226
26231
|
});
|
|
26227
26232
|
}
|
|
26228
26233
|
}
|
|
26234
|
+
function buildFailureEnvelope(workflowName, error) {
|
|
26235
|
+
const ctx = error.context;
|
|
26236
|
+
const executionId = typeof ctx?.["executionId"] === "string" ? ctx["executionId"] : void 0;
|
|
26237
|
+
const durationMs = typeof ctx?.["durationMs"] === "number" ? ctx["durationMs"] : void 0;
|
|
26238
|
+
return createFailedResult(workflowName, error.message, {
|
|
26239
|
+
...executionId !== void 0 ? { executionId } : {},
|
|
26240
|
+
...durationMs !== void 0 ? { durationMs } : {}
|
|
26241
|
+
});
|
|
26242
|
+
}
|
|
26229
26243
|
async function handleRunWorkflow(deps, args) {
|
|
26230
26244
|
const { template, inputs, dryRun } = args;
|
|
26231
26245
|
deps.logger?.debug("run_workflow called", { template, dryRun, inputKeys: Object.keys(inputs) });
|
|
@@ -26244,7 +26258,7 @@ async function handleRunWorkflow(deps, args) {
|
|
|
26244
26258
|
const executeResult = await executeWorkflow(deps, workflow, inputs);
|
|
26245
26259
|
if (!executeResult.ok) {
|
|
26246
26260
|
recordWorkflowError(template, executeResult.error.message);
|
|
26247
|
-
return
|
|
26261
|
+
return buildFailureEnvelope(workflow.name, executeResult.error);
|
|
26248
26262
|
}
|
|
26249
26263
|
recordWorkflowSuccess(
|
|
26250
26264
|
template,
|
|
@@ -26689,7 +26703,7 @@ async function populateUnifiedContextOnState(state) {
|
|
|
26689
26703
|
try {
|
|
26690
26704
|
const taskCandidate = state["task"];
|
|
26691
26705
|
if (typeof taskCandidate !== "string" || taskCandidate === "") return;
|
|
26692
|
-
const { getContextForTask: getContextForTask2, inferTaskCategory: inferTaskCategory2 } = await import("./context-retriever-
|
|
26706
|
+
const { getContextForTask: getContextForTask2, inferTaskCategory: inferTaskCategory2 } = await import("./context-retriever-GQRC2MVM.js");
|
|
26693
26707
|
const ctx = await getContextForTask2({
|
|
26694
26708
|
task: taskCandidate,
|
|
26695
26709
|
category: inferTaskCategory2(taskCandidate),
|
|
@@ -42000,7 +42014,7 @@ async function tryIssueTriage(task) {
|
|
|
42000
42014
|
try {
|
|
42001
42015
|
const issueMatch = task.match(/github\.com\/([^/]+\/[^/]+)\/issues\/(\d+)/);
|
|
42002
42016
|
if (issueMatch === null) return null;
|
|
42003
|
-
const { createIssueTriage } = await import("./issue-triage-
|
|
42017
|
+
const { createIssueTriage } = await import("./issue-triage-MURMDN2G.js");
|
|
42004
42018
|
const triage = createIssueTriage();
|
|
42005
42019
|
const owner = issueMatch[1] ?? "";
|
|
42006
42020
|
const num = issueMatch[2] ?? "";
|
|
@@ -42028,7 +42042,7 @@ var VALID_TEMPLATES = /* @__PURE__ */ new Set([
|
|
|
42028
42042
|
]);
|
|
42029
42043
|
async function classifyWithLLM(task) {
|
|
42030
42044
|
try {
|
|
42031
|
-
const { executeExpert: executeExpert2 } = await import("./expert-bridge-
|
|
42045
|
+
const { executeExpert: executeExpert2 } = await import("./expert-bridge-7LPGCPPR.js");
|
|
42032
42046
|
const prompt = [
|
|
42033
42047
|
"Classify this task into exactly one pipeline template.",
|
|
42034
42048
|
"Templates: dev (implementation/bug fix/refactor), research (investigate/evaluate/compare),",
|
|
@@ -42810,7 +42824,7 @@ var memoryInitPromise = null;
|
|
|
42810
42824
|
async function initPipelineMemory() {
|
|
42811
42825
|
if (cachedMemory !== null) return cachedMemory;
|
|
42812
42826
|
try {
|
|
42813
|
-
const { createSessionMemory: createSessionMemory2 } = await import("./session-memory-
|
|
42827
|
+
const { createSessionMemory: createSessionMemory2 } = await import("./session-memory-X6SCDFER.js");
|
|
42814
42828
|
const { getLearningDir } = await import("./learning-persistence-NX2KHL5T.js");
|
|
42815
42829
|
const mem = createSessionMemory2(getLearningDir());
|
|
42816
42830
|
mem.startSession(`pipeline-${String(getTimeProvider().now())}`);
|
|
@@ -42867,7 +42881,7 @@ function recordRoutingExperience(category, success, durationMs) {
|
|
|
42867
42881
|
callRecord(routingMemoryCache);
|
|
42868
42882
|
return;
|
|
42869
42883
|
}
|
|
42870
|
-
routingMemoryInitPromise ??= import("./routing-memory-
|
|
42884
|
+
routingMemoryInitPromise ??= import("./routing-memory-6IEPJ3EP.js").then(({ createRoutingMemory }) => {
|
|
42871
42885
|
routingMemoryCache ??= createRoutingMemory();
|
|
42872
42886
|
return routingMemoryCache;
|
|
42873
42887
|
}).catch((error) => {
|
|
@@ -42901,7 +42915,7 @@ ${text}` : "";
|
|
|
42901
42915
|
}
|
|
42902
42916
|
async function getWeatherContext() {
|
|
42903
42917
|
try {
|
|
42904
|
-
const { generateWeatherReport: generateWeatherReport2 } = await import("./weather-report-
|
|
42918
|
+
const { generateWeatherReport: generateWeatherReport2 } = await import("./weather-report-6BC3JK5H.js");
|
|
42905
42919
|
const report = generateWeatherReport2({ includeAdaptive: true });
|
|
42906
42920
|
const mappings = "recommendedMappings" in report ? report.recommendedMappings : [];
|
|
42907
42921
|
if (!Array.isArray(mappings) || mappings.length === 0) return "";
|
|
@@ -42919,7 +42933,7 @@ ${lines}
|
|
|
42919
42933
|
}
|
|
42920
42934
|
async function getMemoryContext(task) {
|
|
42921
42935
|
try {
|
|
42922
|
-
const { createSessionMemory: createSessionMemory2 } = await import("./session-memory-
|
|
42936
|
+
const { createSessionMemory: createSessionMemory2 } = await import("./session-memory-X6SCDFER.js");
|
|
42923
42937
|
const { getLearningDir } = await import("./learning-persistence-NX2KHL5T.js");
|
|
42924
42938
|
const memory = createSessionMemory2(getLearningDir(), { maxLearningsInContext: 10 });
|
|
42925
42939
|
const learnings = memory.searchLearnings(task.slice(0, 200));
|
|
@@ -43025,7 +43039,7 @@ ${contextBlock}`;
|
|
|
43025
43039
|
const strategy = config.votingStrategy ?? "higher_order";
|
|
43026
43040
|
await postProgress(config, "Vote", `Running consensus with ${strategy} strategy...`);
|
|
43027
43041
|
try {
|
|
43028
|
-
const { executeVoting } = await import("./consensus-vote-
|
|
43042
|
+
const { executeVoting } = await import("./consensus-vote-MTLP6E72.js");
|
|
43029
43043
|
const votingResult = await executeVoting(
|
|
43030
43044
|
{
|
|
43031
43045
|
proposal: plan.slice(0, 4e3),
|
|
@@ -43952,7 +43966,7 @@ async function searchCodebaseForTask(task) {
|
|
|
43952
43966
|
}
|
|
43953
43967
|
async function queryResearchRegistry(task) {
|
|
43954
43968
|
try {
|
|
43955
|
-
const { synthesizeResearch: synthesizeResearch2 } = await import("./research-helpers-synthesize-
|
|
43969
|
+
const { synthesizeResearch: synthesizeResearch2 } = await import("./research-helpers-synthesize-36QBOKII.js");
|
|
43956
43970
|
const topic = task.split(/[.!?\n]/).filter((s) => s.trim().length > 10)[0]?.trim();
|
|
43957
43971
|
if (topic === void 0) return null;
|
|
43958
43972
|
const result = await synthesizeResearch2(topic.slice(0, 50));
|
|
@@ -44023,7 +44037,7 @@ function createScanStageWrapper() {
|
|
|
44023
44037
|
try {
|
|
44024
44038
|
const slug = ctx.task.match(/([a-zA-Z0-9._-]+\/[a-zA-Z0-9._-]+)/)?.[1];
|
|
44025
44039
|
if (slug !== void 0) {
|
|
44026
|
-
const { generateSecurityPlan: generateSecurityPlan2 } = await import("./repo-security-plan-
|
|
44040
|
+
const { generateSecurityPlan: generateSecurityPlan2 } = await import("./repo-security-plan-N3CDMW6L.js");
|
|
44027
44041
|
const plan = await generateSecurityPlan2({ repo: slug, maxScanners: 10 });
|
|
44028
44042
|
const recs = plan.recommendations.slice(0, 5).map((r) => `${r.priority}: ${r.displayName} (${r.category})`).join("; ");
|
|
44029
44043
|
return output(PIPELINE_STATE_KEYS.FINDINGS, recs, getTimeProvider().now() - start, true);
|
|
@@ -48292,100 +48306,25 @@ var AgreementCascadeConfigSchema = z102.object({
|
|
|
48292
48306
|
// src/cli-adapters/agreement-cascade-router.ts
|
|
48293
48307
|
var logger43 = createLogger({ component: "agreement-cascade-router" });
|
|
48294
48308
|
|
|
48295
|
-
// src/cli-adapters/daao-types.ts
|
|
48296
|
-
import { z as z103 } from "zod";
|
|
48297
|
-
var EncodedFeaturesSchema = z103.object({
|
|
48298
|
-
/** Lexical complexity score (vocabulary diversity, rare words) */
|
|
48299
|
-
lexicalComplexity: z103.number().min(0).max(1),
|
|
48300
|
-
/** Syntactic complexity score (sentence structure, nesting) */
|
|
48301
|
-
syntacticComplexity: z103.number().min(0).max(1),
|
|
48302
|
-
/** Semantic density score (concept density, abstraction level) */
|
|
48303
|
-
semanticDensity: z103.number().min(0).max(1),
|
|
48304
|
-
/** Technical specificity (domain-specific terminology) */
|
|
48305
|
-
technicalSpecificity: z103.number().min(0).max(1),
|
|
48306
|
-
/** Task scope (breadth of requirements) */
|
|
48307
|
-
taskScope: z103.number().min(0).max(1),
|
|
48308
|
-
/** Constraint complexity (constraints, edge cases, requirements) */
|
|
48309
|
-
constraintComplexity: z103.number().min(0).max(1),
|
|
48310
|
-
/** Ambiguity level (inverse - higher means more clear/specific) */
|
|
48311
|
-
clarity: z103.number().min(0).max(1),
|
|
48312
|
-
/** Output complexity expectation */
|
|
48313
|
-
outputComplexity: z103.number().min(0).max(1)
|
|
48314
|
-
});
|
|
48315
|
-
var FeatureWeightsSchema = z103.object({
|
|
48316
|
-
lexicalComplexity: z103.number().min(0).max(1),
|
|
48317
|
-
syntacticComplexity: z103.number().min(0).max(1),
|
|
48318
|
-
semanticDensity: z103.number().min(0).max(1),
|
|
48319
|
-
technicalSpecificity: z103.number().min(0).max(1),
|
|
48320
|
-
taskScope: z103.number().min(0).max(1),
|
|
48321
|
-
constraintComplexity: z103.number().min(0).max(1),
|
|
48322
|
-
clarity: z103.number().min(0).max(1),
|
|
48323
|
-
outputComplexity: z103.number().min(0).max(1)
|
|
48324
|
-
});
|
|
48325
|
-
var DEFAULT_FEATURE_WEIGHTS = {
|
|
48326
|
-
lexicalComplexity: 0.1,
|
|
48327
|
-
syntacticComplexity: 0.1,
|
|
48328
|
-
semanticDensity: 0.15,
|
|
48329
|
-
technicalSpecificity: 0.15,
|
|
48330
|
-
taskScope: 0.15,
|
|
48331
|
-
constraintComplexity: 0.15,
|
|
48332
|
-
clarity: 0.1,
|
|
48333
|
-
// Inverted - high clarity reduces difficulty
|
|
48334
|
-
outputComplexity: 0.1
|
|
48335
|
-
};
|
|
48336
|
-
var DEFAULT_DAAO_THRESHOLDS = {
|
|
48337
|
-
easyUpperBound: 0.35,
|
|
48338
|
-
hardLowerBound: 0.65
|
|
48339
|
-
};
|
|
48340
|
-
var DEFAULT_DAAO_TIER_TO_CLIS = {
|
|
48341
|
-
fast: ["gemini", "codex", "opencode", "claude"],
|
|
48342
|
-
balanced: ["codex", "opencode", "gemini", "claude"],
|
|
48343
|
-
powerful: ["claude", "codex", "opencode", "gemini"]
|
|
48344
|
-
};
|
|
48345
|
-
var DAAOConfigSchema = z103.object({
|
|
48346
|
-
/** Difficulty thresholds for level classification */
|
|
48347
|
-
thresholds: z103.object({
|
|
48348
|
-
easyUpperBound: z103.number().min(0).max(1),
|
|
48349
|
-
hardLowerBound: z103.number().min(0).max(1)
|
|
48350
|
-
}).default(DEFAULT_DAAO_THRESHOLDS),
|
|
48351
|
-
/** Feature weights for difficulty aggregation */
|
|
48352
|
-
weights: FeatureWeightsSchema.default(DEFAULT_FEATURE_WEIGHTS),
|
|
48353
|
-
/** Mapping from model tier to CLI preference order */
|
|
48354
|
-
tierToClis: z103.record(
|
|
48355
|
-
z103.enum(["fast", "balanced", "powerful"]),
|
|
48356
|
-
z103.array(z103.enum(["claude", "gemini", "codex", "opencode"]))
|
|
48357
|
-
).default(DEFAULT_DAAO_TIER_TO_CLIS),
|
|
48358
|
-
/** Enable adaptive calibration from outcomes */
|
|
48359
|
-
enableCalibration: z103.boolean().default(true),
|
|
48360
|
-
/** Maximum outcomes to store for calibration */
|
|
48361
|
-
maxCalibrationOutcomes: z103.number().int().positive().default(1e3),
|
|
48362
|
-
/** Minimum outcomes before applying calibration adjustments */
|
|
48363
|
-
minCalibrationOutcomes: z103.number().int().positive().default(50),
|
|
48364
|
-
/** Reconstruction error threshold for typical patterns */
|
|
48365
|
-
typicalPatternThreshold: z103.number().min(0).max(1).default(0.3),
|
|
48366
|
-
/** Verbose logging */
|
|
48367
|
-
verbose: z103.boolean().default(false)
|
|
48368
|
-
});
|
|
48369
|
-
|
|
48370
48309
|
// src/cli-adapters/task-classifier.ts
|
|
48371
|
-
import { z as
|
|
48372
|
-
var ClassificationPatternsSchema =
|
|
48373
|
-
code:
|
|
48374
|
-
research:
|
|
48375
|
-
documentation:
|
|
48376
|
-
analysis:
|
|
48310
|
+
import { z as z103 } from "zod";
|
|
48311
|
+
var ClassificationPatternsSchema = z103.object({
|
|
48312
|
+
code: z103.array(z103.string()).readonly(),
|
|
48313
|
+
research: z103.array(z103.string()).readonly(),
|
|
48314
|
+
documentation: z103.array(z103.string()).readonly(),
|
|
48315
|
+
analysis: z103.array(z103.string()).readonly()
|
|
48377
48316
|
});
|
|
48378
48317
|
|
|
48379
48318
|
// src/cli-adapters/response-cache-types.ts
|
|
48380
|
-
import { z as
|
|
48381
|
-
var ResponseCacheConfigSchema =
|
|
48382
|
-
defaultTTL:
|
|
48319
|
+
import { z as z104 } from "zod";
|
|
48320
|
+
var ResponseCacheConfigSchema = z104.object({
|
|
48321
|
+
defaultTTL: z104.number().min(1e3).max(36e5).default(3e5),
|
|
48383
48322
|
// 5 minutes
|
|
48384
|
-
maxEntries:
|
|
48385
|
-
maxMemoryMB:
|
|
48386
|
-
cleanupInterval:
|
|
48323
|
+
maxEntries: z104.number().min(10).max(1e5).default(1e3),
|
|
48324
|
+
maxMemoryMB: z104.number().min(1).max(1e3).default(50),
|
|
48325
|
+
cleanupInterval: z104.number().min(1e3).max(6e5).default(6e4),
|
|
48387
48326
|
// 1 minute
|
|
48388
|
-
enableLogging:
|
|
48327
|
+
enableLogging: z104.boolean().default(false)
|
|
48389
48328
|
});
|
|
48390
48329
|
|
|
48391
48330
|
// src/cli-adapters/response-cache-utils.ts
|
|
@@ -48393,12 +48332,12 @@ import { createHash as createHash4 } from "crypto";
|
|
|
48393
48332
|
var logger44 = createLogger({ component: "ResponseCacheUtils" });
|
|
48394
48333
|
|
|
48395
48334
|
// src/cli-adapters/unified-routing-types.ts
|
|
48396
|
-
import { z as
|
|
48397
|
-
var UnifiedRoutingDecisionSchema =
|
|
48398
|
-
selectedCli:
|
|
48399
|
-
confidence:
|
|
48400
|
-
reason:
|
|
48401
|
-
strategy:
|
|
48335
|
+
import { z as z105 } from "zod";
|
|
48336
|
+
var UnifiedRoutingDecisionSchema = z105.object({
|
|
48337
|
+
selectedCli: z105.string(),
|
|
48338
|
+
confidence: z105.number().min(0).max(1),
|
|
48339
|
+
reason: z105.string(),
|
|
48340
|
+
strategy: z105.enum([
|
|
48402
48341
|
"composite",
|
|
48403
48342
|
"quality",
|
|
48404
48343
|
"budget",
|
|
@@ -48410,57 +48349,57 @@ var UnifiedRoutingDecisionSchema = z106.object({
|
|
|
48410
48349
|
"linucb",
|
|
48411
48350
|
"direct"
|
|
48412
48351
|
]),
|
|
48413
|
-
decisionTimeMs:
|
|
48414
|
-
alternatives:
|
|
48415
|
-
stagesExecuted:
|
|
48416
|
-
withinBudget:
|
|
48417
|
-
estimatedComplexity:
|
|
48418
|
-
estimatedTokens:
|
|
48419
|
-
topsisScore:
|
|
48420
|
-
ucbScore:
|
|
48421
|
-
resolvedAtStage:
|
|
48422
|
-
consensusReached:
|
|
48423
|
-
agreementScore:
|
|
48424
|
-
metadata:
|
|
48352
|
+
decisionTimeMs: z105.number().nonnegative(),
|
|
48353
|
+
alternatives: z105.array(z105.string()).readonly(),
|
|
48354
|
+
stagesExecuted: z105.array(z105.string()).readonly(),
|
|
48355
|
+
withinBudget: z105.boolean().optional(),
|
|
48356
|
+
estimatedComplexity: z105.enum(["simple", "moderate", "complex", "expert"]).optional(),
|
|
48357
|
+
estimatedTokens: z105.number().int().positive().optional(),
|
|
48358
|
+
topsisScore: z105.number().optional(),
|
|
48359
|
+
ucbScore: z105.number().optional(),
|
|
48360
|
+
resolvedAtStage: z105.number().int().nonnegative().optional(),
|
|
48361
|
+
consensusReached: z105.boolean().optional(),
|
|
48362
|
+
agreementScore: z105.number().min(0).max(1).optional(),
|
|
48363
|
+
metadata: z105.record(z105.string(), z105.unknown()).optional()
|
|
48425
48364
|
});
|
|
48426
48365
|
|
|
48427
48366
|
// src/learning/outcome-feedback-types.ts
|
|
48428
|
-
import { z as
|
|
48429
|
-
var QualitySignalsSchema =
|
|
48430
|
-
testsPass:
|
|
48431
|
-
lintErrors:
|
|
48432
|
-
userApproved:
|
|
48433
|
-
retryCount:
|
|
48434
|
-
completionRatio:
|
|
48435
|
-
validStructure:
|
|
48436
|
-
coherenceScore:
|
|
48367
|
+
import { z as z106 } from "zod";
|
|
48368
|
+
var QualitySignalsSchema = z106.object({
|
|
48369
|
+
testsPass: z106.boolean().optional(),
|
|
48370
|
+
lintErrors: z106.number().int().min(0).optional(),
|
|
48371
|
+
userApproved: z106.boolean().optional(),
|
|
48372
|
+
retryCount: z106.number().int().min(0).default(0),
|
|
48373
|
+
completionRatio: z106.number().min(0).max(1).default(1),
|
|
48374
|
+
validStructure: z106.boolean().optional(),
|
|
48375
|
+
coherenceScore: z106.number().min(0).max(1).optional()
|
|
48437
48376
|
});
|
|
48438
|
-
var RoutingDecisionSchema =
|
|
48439
|
-
id:
|
|
48440
|
-
timestamp:
|
|
48441
|
-
query:
|
|
48442
|
-
routerType:
|
|
48443
|
-
selectedModel:
|
|
48444
|
-
selectedTier:
|
|
48445
|
-
armIndex:
|
|
48446
|
-
banditContext:
|
|
48447
|
-
queryFeatures:
|
|
48448
|
-
ucbScore:
|
|
48449
|
-
confidence:
|
|
48450
|
-
traceId:
|
|
48451
|
-
domain:
|
|
48377
|
+
var RoutingDecisionSchema = z106.object({
|
|
48378
|
+
id: z106.uuid(),
|
|
48379
|
+
timestamp: z106.iso.datetime(),
|
|
48380
|
+
query: z106.string(),
|
|
48381
|
+
routerType: z106.enum(["linucb", "preference", "quality", "cascade", "topsis"]),
|
|
48382
|
+
selectedModel: z106.string(),
|
|
48383
|
+
selectedTier: z106.enum(["strong", "weak"]).optional(),
|
|
48384
|
+
armIndex: z106.number().int().min(0).optional(),
|
|
48385
|
+
banditContext: z106.record(z106.string(), z106.unknown()).optional(),
|
|
48386
|
+
queryFeatures: z106.record(z106.string(), z106.unknown()).optional(),
|
|
48387
|
+
ucbScore: z106.number().optional(),
|
|
48388
|
+
confidence: z106.number().min(0).max(1).optional(),
|
|
48389
|
+
traceId: z106.string(),
|
|
48390
|
+
domain: z106.string().optional()
|
|
48452
48391
|
});
|
|
48453
|
-
var TaskOutcomeSchema =
|
|
48454
|
-
routingDecisionId:
|
|
48455
|
-
timestamp:
|
|
48456
|
-
outcomeClass:
|
|
48457
|
-
success:
|
|
48458
|
-
qualityScore:
|
|
48459
|
-
durationMs:
|
|
48460
|
-
tokenUsage:
|
|
48461
|
-
errorMessage:
|
|
48392
|
+
var TaskOutcomeSchema = z106.object({
|
|
48393
|
+
routingDecisionId: z106.uuid(),
|
|
48394
|
+
timestamp: z106.iso.datetime(),
|
|
48395
|
+
outcomeClass: z106.enum(["success", "partial", "failure", "timeout", "error"]),
|
|
48396
|
+
success: z106.boolean(),
|
|
48397
|
+
qualityScore: z106.number().min(0).max(1),
|
|
48398
|
+
durationMs: z106.number().min(0),
|
|
48399
|
+
tokenUsage: z106.number().int().min(0),
|
|
48400
|
+
errorMessage: z106.string().optional(),
|
|
48462
48401
|
qualitySignals: QualitySignalsSchema,
|
|
48463
|
-
traceId:
|
|
48402
|
+
traceId: z106.string()
|
|
48464
48403
|
});
|
|
48465
48404
|
var DEFAULT_FEEDBACK_COLLECTOR_CONFIG = {
|
|
48466
48405
|
maxPendingDecisions: 1e3,
|
|
@@ -48475,17 +48414,17 @@ var DEFAULT_FEEDBACK_COLLECTOR_CONFIG = {
|
|
|
48475
48414
|
targetTokenUsage: 2e3,
|
|
48476
48415
|
maxHistorySize: 1e4
|
|
48477
48416
|
};
|
|
48478
|
-
var FeedbackCollectorConfigSchema =
|
|
48479
|
-
maxPendingDecisions:
|
|
48480
|
-
pendingTimeoutMs:
|
|
48481
|
-
enableAutoReward:
|
|
48482
|
-
qualityWeight:
|
|
48483
|
-
speedWeight:
|
|
48484
|
-
efficiencyWeight:
|
|
48485
|
-
retryPenalty:
|
|
48486
|
-
targetDurationMs:
|
|
48487
|
-
targetTokenUsage:
|
|
48488
|
-
maxHistorySize:
|
|
48417
|
+
var FeedbackCollectorConfigSchema = z106.object({
|
|
48418
|
+
maxPendingDecisions: z106.number().int().positive().default(1e3),
|
|
48419
|
+
pendingTimeoutMs: z106.number().positive().default(3e5),
|
|
48420
|
+
enableAutoReward: z106.boolean().default(true),
|
|
48421
|
+
qualityWeight: z106.number().min(0).max(1).default(0.5),
|
|
48422
|
+
speedWeight: z106.number().min(0).max(1).default(0.2),
|
|
48423
|
+
efficiencyWeight: z106.number().min(0).max(1).default(0.2),
|
|
48424
|
+
retryPenalty: z106.number().min(0).max(1).default(0.1),
|
|
48425
|
+
targetDurationMs: z106.number().positive().default(5e3),
|
|
48426
|
+
targetTokenUsage: z106.number().positive().default(2e3),
|
|
48427
|
+
maxHistorySize: z106.number().int().positive().default(1e4)
|
|
48489
48428
|
});
|
|
48490
48429
|
|
|
48491
48430
|
// src/learning/outcome-feedback-helpers.ts
|
|
@@ -50102,7 +50041,7 @@ var GitHubTaskTracker = class {
|
|
|
50102
50041
|
cachedProvider = null;
|
|
50103
50042
|
async getProvider() {
|
|
50104
50043
|
if (this.cachedProvider !== null) return this.cachedProvider;
|
|
50105
|
-
const { createScmProvider } = await import("./factory-
|
|
50044
|
+
const { createScmProvider } = await import("./factory-3XB5CAAA.js");
|
|
50106
50045
|
const result = await createScmProvider({ repo: this.config.repo ?? "" });
|
|
50107
50046
|
if (!result.ok) throw new Error(`SCM provider error: ${result.error.message}`);
|
|
50108
50047
|
this.cachedProvider = result.value;
|
|
@@ -50812,4 +50751,4 @@ export {
|
|
|
50812
50751
|
detectBackend,
|
|
50813
50752
|
createTaskTracker
|
|
50814
50753
|
};
|
|
50815
|
-
//# sourceMappingURL=chunk-
|
|
50754
|
+
//# sourceMappingURL=chunk-J4ZBKE4B.js.map
|