nexus-agents 8.46.11 → 8.46.13

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 (24) hide show
  1. package/dist/{chunk-Q62J7AXA.js → chunk-DWWD7E2S.js} +2 -2
  2. package/dist/{chunk-BSPONVEB.js → chunk-JHN32PTL.js} +17 -10
  3. package/dist/{chunk-BSPONVEB.js.map → chunk-JHN32PTL.js.map} +1 -1
  4. package/dist/{chunk-2FKUGYFZ.js → chunk-LMODIZE4.js} +3 -3
  5. package/dist/{chunk-QX7FSVP2.js → chunk-LVU7XCFO.js} +2 -2
  6. package/dist/{chunk-B4RFPDGA.js → chunk-NBAUSAGE.js} +3 -3
  7. package/dist/{chunk-SHGQ5DYB.js → chunk-YS5V5OIK.js} +2 -2
  8. package/dist/cli.js +7 -24
  9. package/dist/cli.js.map +1 -1
  10. package/dist/{consensus-vote-SYWZBZX5.js → consensus-vote-R3FV4QFQ.js} +4 -4
  11. package/dist/{improvement-review-LRJAS6YY.js → improvement-review-PK4HWORW.js} +4 -4
  12. package/dist/index.d.ts +7 -0
  13. package/dist/index.js +27 -11
  14. package/dist/index.js.map +1 -1
  15. package/dist/{setup-data-dir-7JFXMMFS.js → setup-data-dir-YFIVZI6E.js} +3 -3
  16. package/package.json +1 -1
  17. /package/dist/{chunk-Q62J7AXA.js.map → chunk-DWWD7E2S.js.map} +0 -0
  18. /package/dist/{chunk-2FKUGYFZ.js.map → chunk-LMODIZE4.js.map} +0 -0
  19. /package/dist/{chunk-QX7FSVP2.js.map → chunk-LVU7XCFO.js.map} +0 -0
  20. /package/dist/{chunk-B4RFPDGA.js.map → chunk-NBAUSAGE.js.map} +0 -0
  21. /package/dist/{chunk-SHGQ5DYB.js.map → chunk-YS5V5OIK.js.map} +0 -0
  22. /package/dist/{consensus-vote-SYWZBZX5.js.map → consensus-vote-R3FV4QFQ.js.map} +0 -0
  23. /package/dist/{improvement-review-LRJAS6YY.js.map → improvement-review-PK4HWORW.js.map} +0 -0
  24. /package/dist/{setup-data-dir-7JFXMMFS.js.map → setup-data-dir-YFIVZI6E.js.map} +0 -0
@@ -11,11 +11,11 @@ import {
11
11
  resetCorrelationTracker,
12
12
  runConsensusForGoal,
13
13
  unwrapVoteOrThrow
14
- } from "./chunk-B4RFPDGA.js";
14
+ } from "./chunk-NBAUSAGE.js";
15
15
  import "./chunk-K46JS3AR.js";
16
16
  import "./chunk-OQB3XC5O.js";
17
- import "./chunk-SHGQ5DYB.js";
18
- import "./chunk-Q62J7AXA.js";
17
+ import "./chunk-YS5V5OIK.js";
18
+ import "./chunk-DWWD7E2S.js";
19
19
  import "./chunk-3AWXED62.js";
20
20
  import "./chunk-2SEIMNKE.js";
21
21
  import "./chunk-YGJRO5JK.js";
@@ -50,4 +50,4 @@ export {
50
50
  runConsensusForGoal,
51
51
  unwrapVoteOrThrow
52
52
  };
53
- //# sourceMappingURL=consensus-vote-SYWZBZX5.js.map
53
+ //# sourceMappingURL=consensus-vote-R3FV4QFQ.js.map
@@ -11,9 +11,9 @@ import {
11
11
  loadSelfEvalSignals,
12
12
  registerImprovementReviewTool,
13
13
  runImprovementReview
14
- } from "./chunk-QX7FSVP2.js";
15
- import "./chunk-SHGQ5DYB.js";
16
- import "./chunk-Q62J7AXA.js";
14
+ } from "./chunk-LVU7XCFO.js";
15
+ import "./chunk-YS5V5OIK.js";
16
+ import "./chunk-DWWD7E2S.js";
17
17
  import "./chunk-3AWXED62.js";
18
18
  import "./chunk-KHCFW5LJ.js";
19
19
  import "./chunk-MTYJPPIG.js";
@@ -33,4 +33,4 @@ export {
33
33
  registerImprovementReviewTool,
34
34
  runImprovementReview
35
35
  };
36
- //# sourceMappingURL=improvement-review-LRJAS6YY.js.map
36
+ //# sourceMappingURL=improvement-review-PK4HWORW.js.map
package/dist/index.d.ts CHANGED
@@ -22857,6 +22857,13 @@ interface StoredRoutingDecision {
22857
22857
  readonly reason: string;
22858
22858
  readonly taskProfile: Record<string, unknown>;
22859
22859
  readonly requestId?: string | undefined;
22860
+ /**
22861
+ * Whether a router actually attributed this decision (#5915, closing the
22862
+ * third step of #5812). Absent on a decision read back from a row written
22863
+ * before the column existed, and absence reads as UNMEASURED everywhere —
22864
+ * a legacy row carries no more evidence than the fallback does.
22865
+ */
22866
+ readonly routerTypeMeasured?: boolean | undefined;
22860
22867
  }
22861
22868
  /**
22862
22869
  * Stored task outcome record.
package/dist/index.js CHANGED
@@ -552,7 +552,7 @@ import {
552
552
  withLogging,
553
553
  withRetry,
554
554
  withRetryWrapper
555
- } from "./chunk-BSPONVEB.js";
555
+ } from "./chunk-JHN32PTL.js";
556
556
  import {
557
557
  FALLBACK_SCANNER_DATA,
558
558
  buildPlanFromAnalysis,
@@ -585,7 +585,7 @@ import {
585
585
  connectTransport,
586
586
  createServer,
587
587
  startStdioServer
588
- } from "./chunk-2FKUGYFZ.js";
588
+ } from "./chunk-LMODIZE4.js";
589
589
  import {
590
590
  OPENAI_MODELS,
591
591
  OPENAI_MODEL_ALIASES,
@@ -643,7 +643,7 @@ import {
643
643
  generateProposalId,
644
644
  parseAgentPairKey,
645
645
  registerConsensusVoteTool
646
- } from "./chunk-B4RFPDGA.js";
646
+ } from "./chunk-NBAUSAGE.js";
647
647
  import "./chunk-K46JS3AR.js";
648
648
  import {
649
649
  allOf
@@ -701,7 +701,7 @@ import {
701
701
  import {
702
702
  ImprovementReviewInputSchema,
703
703
  registerImprovementReviewTool
704
- } from "./chunk-QX7FSVP2.js";
704
+ } from "./chunk-LVU7XCFO.js";
705
705
  import {
706
706
  AgentPerformanceSchema,
707
707
  ConsensusAlgorithmSchema,
@@ -737,10 +737,10 @@ import {
737
737
  toolSuccess,
738
738
  toolSuccessStructured,
739
739
  validateToolInput
740
- } from "./chunk-SHGQ5DYB.js";
740
+ } from "./chunk-YS5V5OIK.js";
741
741
  import {
742
742
  VERSION
743
- } from "./chunk-Q62J7AXA.js";
743
+ } from "./chunk-DWWD7E2S.js";
744
744
  import {
745
745
  AuditTrail,
746
746
  createAuditTrail,
@@ -1003,9 +1003,16 @@ function createDecisionsTable(db) {
1003
1003
  confidence REAL NOT NULL,
1004
1004
  reason TEXT NOT NULL,
1005
1005
  task_profile TEXT NOT NULL,
1006
- request_id TEXT
1006
+ request_id TEXT,
1007
+ router_type_measured INTEGER
1007
1008
  )
1008
1009
  `);
1010
+ migrateDecisionsTable(db);
1011
+ }
1012
+ function migrateDecisionsTable(db) {
1013
+ const columns = db.prepare("PRAGMA table_info(routing_decisions)").all();
1014
+ if (columns.some((c) => c.name === "router_type_measured")) return;
1015
+ db.exec("ALTER TABLE routing_decisions ADD COLUMN router_type_measured INTEGER");
1009
1016
  }
1010
1017
  function createOutcomesTable(db) {
1011
1018
  db.exec(`
@@ -1064,7 +1071,11 @@ function rowToDecision(row) {
1064
1071
  confidence: row.confidence,
1065
1072
  reason: row.reason,
1066
1073
  taskProfile,
1067
- requestId: row.request_id ?? void 0
1074
+ requestId: row.request_id ?? void 0,
1075
+ // NULL (legacy row, pre-#5915) and 0 both mean UNMEASURED. Defaulting a
1076
+ // NULL to measured would re-create the exact inflation #5812 removed, on
1077
+ // the history rather than the live stats.
1078
+ routerTypeMeasured: row.router_type_measured === 1
1068
1079
  };
1069
1080
  }
1070
1081
  function rowToOutcome(row) {
@@ -1093,8 +1104,8 @@ function rowToStats(row) {
1093
1104
  var INSERT_DECISION_SQL = `
1094
1105
  INSERT OR REPLACE INTO routing_decisions
1095
1106
  (id, trace_id, timestamp, router_type, selected_model, alternative_models,
1096
- confidence, reason, task_profile, request_id)
1097
- VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
1107
+ confidence, reason, task_profile, request_id, router_type_measured)
1108
+ VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
1098
1109
  `;
1099
1110
  var INSERT_OUTCOME_SQL = `
1100
1111
  INSERT OR REPLACE INTO task_outcomes
@@ -1222,7 +1233,12 @@ var SQLiteOutcomeStorage = class {
1222
1233
  decision.confidence,
1223
1234
  decision.reason,
1224
1235
  JSON.stringify(decision.taskProfile),
1225
- decision.requestId ?? null
1236
+ decision.requestId ?? null,
1237
+ // Only an explicit `true` is measured. `undefined` writes 0, not NULL:
1238
+ // a decision built today that did not say it was measured is not the
1239
+ // same thing as a row from before the column existed, and conflating
1240
+ // them would make the migration indistinguishable from a live gap.
1241
+ decision.routerTypeMeasured === true ? 1 : 0
1226
1242
  );
1227
1243
  this.logger.debug("Stored routing decision", {
1228
1244
  id: decision.id,