nexus-agents 8.22.1 → 8.22.2
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/{ast-rule-runner-ZXLN2AXB.js → ast-rule-runner-UMOL7AO3.js} +3 -3
- package/dist/{child-mcp-config-PDM6OAIR.js → child-mcp-config-7DNOX3U3.js} +2 -2
- package/dist/{chunk-CNCBEXU7.js → chunk-2IJOZA75.js} +2 -2
- package/dist/{chunk-QMGLUVF3.js → chunk-2RUDLEIT.js} +7 -7
- package/dist/{chunk-CKJFUTIO.js → chunk-3J5WKA2S.js} +4 -4
- package/dist/{chunk-MTFZV4PR.js → chunk-3MSPZLGF.js} +2 -2
- package/dist/{chunk-OXALB5UB.js → chunk-3R5TFUS5.js} +5 -5
- package/dist/{chunk-RBETGYA5.js → chunk-52QVQASD.js} +8 -8
- package/dist/{chunk-N7X3QEYX.js → chunk-6IOI5SK3.js} +2 -2
- package/dist/{chunk-JGRPCHJG.js → chunk-BAWRHK4W.js} +2 -2
- package/dist/{chunk-T2LJOSFK.js → chunk-BKE522YB.js} +9 -9
- package/dist/{chunk-UUX7IIYR.js → chunk-BU5LR2JJ.js} +2 -2
- package/dist/{chunk-KVS7S2PX.js → chunk-CY6KGPAP.js} +4 -4
- package/dist/{chunk-MXSTGFJK.js → chunk-DW3RU6GC.js} +2 -2
- package/dist/{chunk-DY6VOWVZ.js → chunk-FCIAKQNN.js} +2 -2
- package/dist/{chunk-NMVSENZP.js → chunk-GHBR6ZG3.js} +4 -4
- package/dist/{chunk-G7Y7BICZ.js → chunk-HILA36W2.js} +2 -2
- package/dist/{chunk-JI6BPV3L.js → chunk-HSOZPMQN.js} +2 -2
- package/dist/{chunk-6EDF7PQX.js → chunk-HZ3R63IV.js} +3 -3
- package/dist/{chunk-XRDRZGY7.js → chunk-JNCOVP77.js} +4 -4
- package/dist/{chunk-X7K4OYHQ.js → chunk-KCDE6VIZ.js} +6 -6
- package/dist/{chunk-K726ETND.js → chunk-NG7T6DN5.js} +3 -3
- package/dist/{chunk-N3TDTOWQ.js → chunk-NNM6ZIXQ.js} +58 -48
- package/dist/{chunk-N3TDTOWQ.js.map → chunk-NNM6ZIXQ.js.map} +1 -1
- package/dist/{chunk-7OWFTX6C.js → chunk-OFLMRACR.js} +2 -2
- package/dist/{chunk-YZEYT6HZ.js → chunk-OPWJJXZU.js} +3 -3
- package/dist/{chunk-X46ZSIGP.js → chunk-P3WRF3A7.js} +2 -2
- package/dist/{chunk-CFUQC67J.js → chunk-P4QYPDTB.js} +2 -2
- package/dist/{chunk-UUM4GZR2.js → chunk-QWYY5DD6.js} +5 -5
- package/dist/{chunk-S3SMDOAC.js → chunk-R2CDVI4E.js} +2 -2
- package/dist/{chunk-FPXPEQW2.js → chunk-RZUYKWEY.js} +7 -7
- package/dist/{chunk-DWUIUUYC.js → chunk-SRC2TLRU.js} +2 -2
- package/dist/{chunk-D34HJPQT.js → chunk-SX5EZNPS.js} +36 -36
- package/dist/{chunk-P65RDEER.js → chunk-V2RNDE4R.js} +2 -2
- package/dist/chunk-X76M44I2.js +7 -0
- package/dist/{chunk-WEWVLOZ2.js → chunk-XS423Y73.js} +2 -2
- package/dist/{chunk-PB325ROR.js → chunk-ZWI54SPH.js} +2 -2
- package/dist/{cli-circuit-breaker-JONUYQ7N.js → cli-circuit-breaker-CWQPO6SJ.js} +3 -3
- package/dist/cli.js +43 -43
- package/dist/{composite-router-5OPB7Y4N.js → composite-router-EVIISDZX.js} +2 -2
- package/dist/{consensus-vote-JY7P4NM7.js → consensus-vote-4Q4ZT5U7.js} +17 -17
- package/dist/{context-retriever-KX6KKV76.js → context-retriever-7KBTMNCV.js} +8 -8
- package/dist/{doctor-deep-ZWXASMZG.js → doctor-deep-WFHCOZJY.js} +3 -3
- package/dist/{doctor-live-HOOURKHV.js → doctor-live-LR2TJT45.js} +9 -9
- package/dist/{expert-bridge-6R6SAYE3.js → expert-bridge-KWVJB63Y.js} +4 -4
- package/dist/{factory-NTZZGZ5Z.js → factory-MVWNG55G.js} +9 -9
- package/dist/{factory-EFYRLYTF.js → factory-XOSRNGBJ.js} +5 -5
- package/dist/{improvement-review-CWESXAXL.js → improvement-review-F7CCW4HQ.js} +6 -6
- package/dist/index.d.ts +8 -10
- package/dist/index.js +31 -31
- package/dist/{init-opencode-63T5YU5A.js → init-opencode-EEOVDBRF.js} +6 -6
- package/dist/issue-triage-WVSJEHYI.js +17 -0
- package/dist/{pr-reviewer-helpers-JKU7DC63.js → pr-reviewer-helpers-2ZSPMIG4.js} +4 -4
- package/dist/{registry-command-RHLSYTVC.js → registry-command-SD3YGORZ.js} +2 -2
- package/dist/{repo-security-plan-ZUWFYV4Q.js → repo-security-plan-Z3EHJNZA.js} +3 -3
- package/dist/{research-helpers-synthesize-XA6R3XWS.js → research-helpers-synthesize-KIZIELHL.js} +4 -4
- package/dist/{routing-memory-HSBH26L2.js → routing-memory-RRMEGPQB.js} +2 -2
- package/dist/{session-memory-D3KBSK47.js → session-memory-MMRSHXSO.js} +3 -3
- package/dist/{setup-config-AXO2EHJ5.js → setup-config-54QMOSKC.js} +3 -3
- package/dist/{setup-custom-api-IRGC24YR.js → setup-custom-api-7CCRA6AP.js} +4 -4
- package/dist/setup-data-dir-6OR7TLY6.js +29 -0
- package/dist/{tool-memory-323P5SXG.js → tool-memory-YV64LYJ3.js} +5 -5
- package/dist/{unified-registry-XL6KAFJ6.js → unified-registry-DRKRTGHZ.js} +10 -10
- package/dist/{weather-report-IY647CCD.js → weather-report-PJBGR7WX.js} +2 -2
- package/package.json +1 -1
- package/dist/chunk-SVOAKPZA.js +0 -7
- package/dist/issue-triage-TX7O7ZJT.js +0 -17
- package/dist/setup-data-dir-BNK7ZBQN.js +0 -29
- /package/dist/{ast-rule-runner-ZXLN2AXB.js.map → ast-rule-runner-UMOL7AO3.js.map} +0 -0
- /package/dist/{child-mcp-config-PDM6OAIR.js.map → child-mcp-config-7DNOX3U3.js.map} +0 -0
- /package/dist/{chunk-CNCBEXU7.js.map → chunk-2IJOZA75.js.map} +0 -0
- /package/dist/{chunk-QMGLUVF3.js.map → chunk-2RUDLEIT.js.map} +0 -0
- /package/dist/{chunk-CKJFUTIO.js.map → chunk-3J5WKA2S.js.map} +0 -0
- /package/dist/{chunk-MTFZV4PR.js.map → chunk-3MSPZLGF.js.map} +0 -0
- /package/dist/{chunk-OXALB5UB.js.map → chunk-3R5TFUS5.js.map} +0 -0
- /package/dist/{chunk-RBETGYA5.js.map → chunk-52QVQASD.js.map} +0 -0
- /package/dist/{chunk-N7X3QEYX.js.map → chunk-6IOI5SK3.js.map} +0 -0
- /package/dist/{chunk-JGRPCHJG.js.map → chunk-BAWRHK4W.js.map} +0 -0
- /package/dist/{chunk-T2LJOSFK.js.map → chunk-BKE522YB.js.map} +0 -0
- /package/dist/{chunk-UUX7IIYR.js.map → chunk-BU5LR2JJ.js.map} +0 -0
- /package/dist/{chunk-KVS7S2PX.js.map → chunk-CY6KGPAP.js.map} +0 -0
- /package/dist/{chunk-MXSTGFJK.js.map → chunk-DW3RU6GC.js.map} +0 -0
- /package/dist/{chunk-DY6VOWVZ.js.map → chunk-FCIAKQNN.js.map} +0 -0
- /package/dist/{chunk-NMVSENZP.js.map → chunk-GHBR6ZG3.js.map} +0 -0
- /package/dist/{chunk-G7Y7BICZ.js.map → chunk-HILA36W2.js.map} +0 -0
- /package/dist/{chunk-JI6BPV3L.js.map → chunk-HSOZPMQN.js.map} +0 -0
- /package/dist/{chunk-6EDF7PQX.js.map → chunk-HZ3R63IV.js.map} +0 -0
- /package/dist/{chunk-XRDRZGY7.js.map → chunk-JNCOVP77.js.map} +0 -0
- /package/dist/{chunk-X7K4OYHQ.js.map → chunk-KCDE6VIZ.js.map} +0 -0
- /package/dist/{chunk-K726ETND.js.map → chunk-NG7T6DN5.js.map} +0 -0
- /package/dist/{chunk-7OWFTX6C.js.map → chunk-OFLMRACR.js.map} +0 -0
- /package/dist/{chunk-YZEYT6HZ.js.map → chunk-OPWJJXZU.js.map} +0 -0
- /package/dist/{chunk-X46ZSIGP.js.map → chunk-P3WRF3A7.js.map} +0 -0
- /package/dist/{chunk-CFUQC67J.js.map → chunk-P4QYPDTB.js.map} +0 -0
- /package/dist/{chunk-UUM4GZR2.js.map → chunk-QWYY5DD6.js.map} +0 -0
- /package/dist/{chunk-S3SMDOAC.js.map → chunk-R2CDVI4E.js.map} +0 -0
- /package/dist/{chunk-FPXPEQW2.js.map → chunk-RZUYKWEY.js.map} +0 -0
- /package/dist/{chunk-DWUIUUYC.js.map → chunk-SRC2TLRU.js.map} +0 -0
- /package/dist/{chunk-D34HJPQT.js.map → chunk-SX5EZNPS.js.map} +0 -0
- /package/dist/{chunk-P65RDEER.js.map → chunk-V2RNDE4R.js.map} +0 -0
- /package/dist/{chunk-SVOAKPZA.js.map → chunk-X76M44I2.js.map} +0 -0
- /package/dist/{chunk-WEWVLOZ2.js.map → chunk-XS423Y73.js.map} +0 -0
- /package/dist/{chunk-PB325ROR.js.map → chunk-ZWI54SPH.js.map} +0 -0
- /package/dist/{cli-circuit-breaker-JONUYQ7N.js.map → cli-circuit-breaker-CWQPO6SJ.js.map} +0 -0
- /package/dist/{composite-router-5OPB7Y4N.js.map → composite-router-EVIISDZX.js.map} +0 -0
- /package/dist/{consensus-vote-JY7P4NM7.js.map → consensus-vote-4Q4ZT5U7.js.map} +0 -0
- /package/dist/{context-retriever-KX6KKV76.js.map → context-retriever-7KBTMNCV.js.map} +0 -0
- /package/dist/{doctor-deep-ZWXASMZG.js.map → doctor-deep-WFHCOZJY.js.map} +0 -0
- /package/dist/{doctor-live-HOOURKHV.js.map → doctor-live-LR2TJT45.js.map} +0 -0
- /package/dist/{expert-bridge-6R6SAYE3.js.map → expert-bridge-KWVJB63Y.js.map} +0 -0
- /package/dist/{factory-EFYRLYTF.js.map → factory-MVWNG55G.js.map} +0 -0
- /package/dist/{factory-NTZZGZ5Z.js.map → factory-XOSRNGBJ.js.map} +0 -0
- /package/dist/{improvement-review-CWESXAXL.js.map → improvement-review-F7CCW4HQ.js.map} +0 -0
- /package/dist/{init-opencode-63T5YU5A.js.map → init-opencode-EEOVDBRF.js.map} +0 -0
- /package/dist/{issue-triage-TX7O7ZJT.js.map → issue-triage-WVSJEHYI.js.map} +0 -0
- /package/dist/{pr-reviewer-helpers-JKU7DC63.js.map → pr-reviewer-helpers-2ZSPMIG4.js.map} +0 -0
- /package/dist/{registry-command-RHLSYTVC.js.map → registry-command-SD3YGORZ.js.map} +0 -0
- /package/dist/{repo-security-plan-ZUWFYV4Q.js.map → repo-security-plan-Z3EHJNZA.js.map} +0 -0
- /package/dist/{research-helpers-synthesize-XA6R3XWS.js.map → research-helpers-synthesize-KIZIELHL.js.map} +0 -0
- /package/dist/{routing-memory-HSBH26L2.js.map → routing-memory-RRMEGPQB.js.map} +0 -0
- /package/dist/{session-memory-D3KBSK47.js.map → session-memory-MMRSHXSO.js.map} +0 -0
- /package/dist/{setup-config-AXO2EHJ5.js.map → setup-config-54QMOSKC.js.map} +0 -0
- /package/dist/{setup-custom-api-IRGC24YR.js.map → setup-custom-api-7CCRA6AP.js.map} +0 -0
- /package/dist/{setup-data-dir-BNK7ZBQN.js.map → setup-data-dir-6OR7TLY6.js.map} +0 -0
- /package/dist/{tool-memory-323P5SXG.js.map → tool-memory-YV64LYJ3.js.map} +0 -0
- /package/dist/{unified-registry-XL6KAFJ6.js.map → unified-registry-DRKRTGHZ.js.map} +0 -0
- /package/dist/{weather-report-IY647CCD.js.map → weather-report-PJBGR7WX.js.map} +0 -0
|
@@ -2650,7 +2650,7 @@ function setDefaultRegistry(registry) {
|
|
|
2650
2650
|
}
|
|
2651
2651
|
async function reloadDefaultRegistry() {
|
|
2652
2652
|
globalRegistry = buildDefaultRegistry();
|
|
2653
|
-
const { resetGlobalRegistry } = await import("./unified-registry-
|
|
2653
|
+
const { resetGlobalRegistry } = await import("./unified-registry-DRKRTGHZ.js");
|
|
2654
2654
|
resetGlobalRegistry();
|
|
2655
2655
|
return globalRegistry;
|
|
2656
2656
|
}
|
|
@@ -14983,25 +14983,16 @@ function recordPreferenceSignal(query, strongModelPreferred, quality, deps) {
|
|
|
14983
14983
|
);
|
|
14984
14984
|
deps.logger.debug("Recorded preference", { strongModelPreferred });
|
|
14985
14985
|
}
|
|
14986
|
-
function
|
|
14987
|
-
if (deps.lastRoutedTask?.task.content === task.content) {
|
|
14988
|
-
return {
|
|
14989
|
-
difficulty: deps.lastRoutedTask.difficulty,
|
|
14990
|
-
selectedCli: deps.lastRoutedTask.selectedCli
|
|
14991
|
-
};
|
|
14992
|
-
}
|
|
14993
|
-
if (deps.zeroRouter === void 0) {
|
|
14994
|
-
return { difficulty: 0.5, selectedCli: "claude" };
|
|
14995
|
-
}
|
|
14996
|
-
const estimate = deps.zeroRouter.estimateDifficulty(task);
|
|
14997
|
-
return { difficulty: estimate.aggregateScore, selectedCli: "claude" };
|
|
14998
|
-
}
|
|
14999
|
-
function recordZeroRouterOutcome(task, success, qualityScore, deps) {
|
|
14986
|
+
function recordZeroRouterOutcome(task, success, qualityScore, deps, attribution) {
|
|
15000
14987
|
if (deps.zeroRouter === void 0) {
|
|
15001
14988
|
deps.logger.debug("ZeroRouter not enabled, skipping difficulty outcome");
|
|
15002
14989
|
return;
|
|
15003
14990
|
}
|
|
15004
|
-
|
|
14991
|
+
if (attribution === void 0) {
|
|
14992
|
+
deps.logger.debug("Skipping difficulty calibration: no routing attribution");
|
|
14993
|
+
return;
|
|
14994
|
+
}
|
|
14995
|
+
const { difficulty, selectedCli } = attribution;
|
|
15005
14996
|
const outcome = buildDifficultyOutcome(
|
|
15006
14997
|
task.content,
|
|
15007
14998
|
difficulty,
|
|
@@ -15161,17 +15152,13 @@ var CompositeRouter = class _CompositeRouter {
|
|
|
15161
15152
|
};
|
|
15162
15153
|
totalDecisionTimeMs = 0;
|
|
15163
15154
|
budgetRejections = 0;
|
|
15164
|
-
// Track last routing for difficulty outcome recording
|
|
15165
|
-
lastRoutedTask;
|
|
15166
15155
|
// Track last traceId for metrics correlation (Issue #559)
|
|
15167
15156
|
lastTraceId;
|
|
15168
15157
|
/**
|
|
15169
|
-
*
|
|
15170
|
-
*
|
|
15171
|
-
* `success` when `recordDifficultyOutcome` reports the matching outcome.
|
|
15172
|
-
* The task content itself is never persisted.
|
|
15158
|
+
* Route-time outcome data keyed by the exact task object for execution-safe
|
|
15159
|
+
* feedback joins. Weak keys avoid retaining abandoned task objects.
|
|
15173
15160
|
*/
|
|
15174
|
-
|
|
15161
|
+
pendingRoutingOutcomes = /* @__PURE__ */ new WeakMap();
|
|
15175
15162
|
constructor(adapters, config, logger14) {
|
|
15176
15163
|
const {
|
|
15177
15164
|
preferenceRouterConfig,
|
|
@@ -15373,7 +15360,7 @@ var CompositeRouter = class _CompositeRouter {
|
|
|
15373
15360
|
*/
|
|
15374
15361
|
async consultUnifiedContext(task) {
|
|
15375
15362
|
try {
|
|
15376
|
-
const { getContextForTask, inferTaskCategory } = await import("./context-retriever-
|
|
15363
|
+
const { getContextForTask, inferTaskCategory } = await import("./context-retriever-7KBTMNCV.js");
|
|
15377
15364
|
const ctx = await getContextForTask({
|
|
15378
15365
|
task: task.content,
|
|
15379
15366
|
category: inferTaskCategory(task.content),
|
|
@@ -15425,7 +15412,7 @@ var CompositeRouter = class _CompositeRouter {
|
|
|
15425
15412
|
const slot = routingArmDisplaySlot(arm);
|
|
15426
15413
|
const reward = computeQualityReward(slot, success, durationMs2);
|
|
15427
15414
|
this.recordOutcome(arm, task, reward, success);
|
|
15428
|
-
this.
|
|
15415
|
+
this.recordExecutedDifficultyOutcome(decision, task, success);
|
|
15429
15416
|
if (this.latencyTracker !== void 0) {
|
|
15430
15417
|
this.latencyTracker.record(slot, durationMs2, success);
|
|
15431
15418
|
}
|
|
@@ -15496,7 +15483,6 @@ var CompositeRouter = class _CompositeRouter {
|
|
|
15496
15483
|
if (pipelineResult.error.stage === "budget-filter") this.budgetRejections++;
|
|
15497
15484
|
return pipelineResult;
|
|
15498
15485
|
}
|
|
15499
|
-
this.trackLastRoutedTask(task, pipelineResult.value);
|
|
15500
15486
|
const decisionResult = this.buildRoutingDecision({
|
|
15501
15487
|
...pipelineResult.value,
|
|
15502
15488
|
taskProfile,
|
|
@@ -15504,7 +15490,7 @@ var CompositeRouter = class _CompositeRouter {
|
|
|
15504
15490
|
startTime
|
|
15505
15491
|
});
|
|
15506
15492
|
if (decisionResult.ok) {
|
|
15507
|
-
this.
|
|
15493
|
+
this.trackPendingRoutingOutcome(task, decisionResult.value);
|
|
15508
15494
|
}
|
|
15509
15495
|
return decisionResult;
|
|
15510
15496
|
} catch (error) {
|
|
@@ -15585,14 +15571,18 @@ var CompositeRouter = class _CompositeRouter {
|
|
|
15585
15571
|
knnRoutingStage: this.knnRoutingStage
|
|
15586
15572
|
};
|
|
15587
15573
|
}
|
|
15588
|
-
|
|
15589
|
-
if (
|
|
15590
|
-
this.
|
|
15591
|
-
task,
|
|
15592
|
-
selectedCli: result.selectedCli,
|
|
15593
|
-
difficulty: result.difficultyEstimate.aggregateScore
|
|
15594
|
-
};
|
|
15574
|
+
trackPendingRoutingOutcome(task, decision) {
|
|
15575
|
+
if (this.pendingRoutingOutcomes.get(task)?.modelShadow !== void 0) {
|
|
15576
|
+
this.logger.debug("Dropping incomplete model-selection shadow comparison after task reroute");
|
|
15595
15577
|
}
|
|
15578
|
+
const difficultyAttribution = decision.difficultyEstimate === void 0 ? void 0 : {
|
|
15579
|
+
difficulty: decision.difficultyEstimate.aggregateScore,
|
|
15580
|
+
selectedCli: decision.cliName
|
|
15581
|
+
};
|
|
15582
|
+
this.pendingRoutingOutcomes.set(task, {
|
|
15583
|
+
difficultyAttribution,
|
|
15584
|
+
modelShadow: this.computePendingModelShadow(task, decision)
|
|
15585
|
+
});
|
|
15596
15586
|
}
|
|
15597
15587
|
/**
|
|
15598
15588
|
* Compute the model-selection SHADOW comparison for a routed decision
|
|
@@ -15610,17 +15600,16 @@ var CompositeRouter = class _CompositeRouter {
|
|
|
15610
15600
|
* tier selector — sampling it would mislabel the agree/diverge cohorts and
|
|
15611
15601
|
* pad the volume criterion with garbage (#4218 review).
|
|
15612
15602
|
*/
|
|
15613
|
-
|
|
15603
|
+
computePendingModelShadow(task, decision) {
|
|
15614
15604
|
try {
|
|
15615
|
-
if (!isRouteModelShadowEnabled() || decision.difficultyTier === void 0) return;
|
|
15616
|
-
if (task.model !== void 0) return;
|
|
15605
|
+
if (!isRouteModelShadowEnabled() || decision.difficultyTier === void 0) return void 0;
|
|
15606
|
+
if (task.model !== void 0) return void 0;
|
|
15617
15607
|
logModelSelectionReadinessOnce(this.logger);
|
|
15618
15608
|
const comparison = computeModelSelectionShadow(
|
|
15619
15609
|
routingArmDisplaySlot(decision.cliName),
|
|
15620
15610
|
decision.difficultyTier,
|
|
15621
15611
|
decision.model
|
|
15622
15612
|
);
|
|
15623
|
-
this.pendingModelShadow = { ...comparison, taskContent: task.content };
|
|
15624
15613
|
this.logger.debug("Model-selection shadow computed (#4197)", {
|
|
15625
15614
|
cli: comparison.cli,
|
|
15626
15615
|
tier: comparison.tier,
|
|
@@ -15628,27 +15617,25 @@ var CompositeRouter = class _CompositeRouter {
|
|
|
15628
15617
|
shadowModel: comparison.shadowModel,
|
|
15629
15618
|
agree: comparison.agree
|
|
15630
15619
|
});
|
|
15620
|
+
return comparison;
|
|
15631
15621
|
} catch (error) {
|
|
15632
15622
|
const failures = recordModelSelectionShadowFailure();
|
|
15633
15623
|
this.logger.warn("Model-selection shadow failed (non-fatal, #4197)", {
|
|
15634
15624
|
error: getErrorMessage(error),
|
|
15635
15625
|
failures
|
|
15636
15626
|
});
|
|
15627
|
+
return void 0;
|
|
15637
15628
|
}
|
|
15638
15629
|
}
|
|
15639
15630
|
/**
|
|
15640
15631
|
* Join a pending model-selection shadow comparison with its task outcome and
|
|
15641
|
-
* persist the completed record (#4197).
|
|
15642
|
-
* {@link getDifficultyInfo}'s lastRoutedTask join. `costUsd` is deliberately
|
|
15632
|
+
* persist the completed record (#4197). `costUsd` is deliberately
|
|
15643
15633
|
* absent: the routing outcome path measures no per-decision cost today, and
|
|
15644
15634
|
* the readiness gate's cost criterion stays fail-closed until it does.
|
|
15645
15635
|
* Exception-guarded — an outcome-join failure never breaks outcome recording.
|
|
15646
15636
|
*/
|
|
15647
|
-
joinModelSelectionShadowOutcome(
|
|
15648
|
-
const pending = this.pendingModelShadow;
|
|
15637
|
+
joinModelSelectionShadowOutcome(pending, success) {
|
|
15649
15638
|
if (pending === void 0) return;
|
|
15650
|
-
if (pending.taskContent !== task.content) return;
|
|
15651
|
-
this.pendingModelShadow = void 0;
|
|
15652
15639
|
try {
|
|
15653
15640
|
persistModelSelectionShadowRecord({
|
|
15654
15641
|
schema: MODEL_SELECTION_SHADOW_SCHEMA_VERSION,
|
|
@@ -15755,8 +15742,31 @@ var CompositeRouter = class _CompositeRouter {
|
|
|
15755
15742
|
recordPreferenceSignal(query, strongModelPreferred, quality, this.getOutcomeDependencies());
|
|
15756
15743
|
}
|
|
15757
15744
|
recordDifficultyOutcome(task, success, qualityScore) {
|
|
15758
|
-
|
|
15759
|
-
this.
|
|
15745
|
+
const pending = this.pendingRoutingOutcomes.get(task);
|
|
15746
|
+
this.pendingRoutingOutcomes.delete(task);
|
|
15747
|
+
this.finishDifficultyOutcome(task, success, qualityScore, pending);
|
|
15748
|
+
}
|
|
15749
|
+
recordExecutedDifficultyOutcome(decision, task, success) {
|
|
15750
|
+
const pending = this.pendingRoutingOutcomes.get(task);
|
|
15751
|
+
this.pendingRoutingOutcomes.delete(task);
|
|
15752
|
+
const difficultyAttribution = decision.difficultyEstimate === void 0 ? void 0 : {
|
|
15753
|
+
difficulty: decision.difficultyEstimate.aggregateScore,
|
|
15754
|
+
selectedCli: decision.cliName
|
|
15755
|
+
};
|
|
15756
|
+
this.finishDifficultyOutcome(task, success, void 0, {
|
|
15757
|
+
difficultyAttribution,
|
|
15758
|
+
modelShadow: pending?.modelShadow
|
|
15759
|
+
});
|
|
15760
|
+
}
|
|
15761
|
+
finishDifficultyOutcome(task, success, qualityScore, pending) {
|
|
15762
|
+
recordZeroRouterOutcome(
|
|
15763
|
+
task,
|
|
15764
|
+
success,
|
|
15765
|
+
qualityScore,
|
|
15766
|
+
this.getOutcomeDependencies(),
|
|
15767
|
+
pending?.difficultyAttribution
|
|
15768
|
+
);
|
|
15769
|
+
this.joinModelSelectionShadowOutcome(pending?.modelShadow, success);
|
|
15760
15770
|
}
|
|
15761
15771
|
hasMinimumPreferenceData() {
|
|
15762
15772
|
return hasMinimumPreferenceData(this.getOutcomeDependencies());
|
|
@@ -15768,7 +15778,7 @@ var CompositeRouter = class _CompositeRouter {
|
|
|
15768
15778
|
linucbBandit: this.linucbBandit,
|
|
15769
15779
|
preferenceRouter: this.preferenceRouter,
|
|
15770
15780
|
zeroRouter: this.zeroRouter,
|
|
15771
|
-
lastRoutedTask:
|
|
15781
|
+
lastRoutedTask: void 0,
|
|
15772
15782
|
budgetRouter: this.budgetRouter,
|
|
15773
15783
|
budgetConstraints: this.config.budgetConstraints
|
|
15774
15784
|
};
|
|
@@ -17031,4 +17041,4 @@ export {
|
|
|
17031
17041
|
AgentCapability,
|
|
17032
17042
|
OrchestratorError
|
|
17033
17043
|
};
|
|
17034
|
-
//# sourceMappingURL=chunk-
|
|
17044
|
+
//# sourceMappingURL=chunk-NNM6ZIXQ.js.map
|