mindforge-cc 6.2.0 → 6.3.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/CHANGELOG.md CHANGED
@@ -1,3 +1,15 @@
1
+ ## [6.3.0] - 2026-04-08
2
+
3
+ ### Added (v6.3.0: Intelligence-Drift Coupling - IDC)
4
+
5
+ - **Dynamic Model Upgrading (IDC)**:
6
+ - Implemented `intelligence-interlock.js` to bridge NDR (Neural Drift Remediation) and ARH (Resource Arbitrage).
7
+ - Added "Critical Drift" alert thresholds to `LogicDriftDetector`.
8
+ - Integrated IDC signals into `AutoRunner`, allowing for proactive model tier upgrades when reasoning decay is detected.
9
+ - Hardened `RouterSteering` to respect mid-wave MIR overrides.
10
+
11
+ ---
12
+
1
13
  ## [6.2.0] - 2026-04-02
2
14
 
3
15
  ### Added (v6.2.0: Sovereign Enterprise Stable)
@@ -17,6 +17,7 @@ const TemporalHub = require('../engine/temporal-hub');
17
17
  const IntentHarvester = require('./intent-harvester');
18
18
  const MeshSelfHealer = require('./mesh-self-healer');
19
19
  const crypto = require('crypto');
20
+ const IntelligenceInterlock = require('../engine/intelligence-interlock');
20
21
 
21
22
  // MindForge v5 Core Modules
22
23
  const PolicyEngine = require('../governance/policy-engine');
@@ -41,6 +42,9 @@ class AutoRunner {
41
42
  // v5 PAR Initialization
42
43
  this.refactorer = new ContextRefactorer();
43
44
  this.c2cThreshold = 0.65;
45
+
46
+ // v6.3 Intelligence Interlock
47
+ this.interlock = IntelligenceInterlock;
44
48
  }
45
49
 
46
50
  async run() {
@@ -79,7 +83,10 @@ class AutoRunner {
79
83
  // Pillar 7 (DHH): Check for Human Steering
80
84
  await this.checkHumanSteering(isReliable);
81
85
 
82
- await this.executeWave();
86
+ // v6.3 IDC: Check for Intelligence Drift & Upgrade Signal
87
+ const idcStatus = await this.checkIntelligenceDrift();
88
+
89
+ await this.executeWave(idcStatus);
83
90
  }
84
91
 
85
92
  await this.complete();
@@ -96,8 +103,34 @@ class AutoRunner {
96
103
  return false; // Placeholder for now
97
104
  }
98
105
 
99
- async executeWave() {
106
+ async executeWave(idcStatus = {}) {
100
107
  // Parallel task execution logic...
108
+ if (idcStatus.action === 'UPGRADE_MIR') {
109
+ console.log(`[IDC-ACTIVE] Wave executing with MIR Override: ${idcStatus.new_mir}`);
110
+ }
111
+ }
112
+
113
+ /**
114
+ * v6.3 IDC: Intelligence-Drift Coupling
115
+ * Detects if the internal reasoning of previous tasks suggests intelligence decay.
116
+ */
117
+ async checkIntelligenceDrift() {
118
+ // Get the most recent high-density reasoning thought from audit
119
+ const events = this.getRecentAuditEvents(5);
120
+ const lastThought = events.reverse().find(e => e.thought || e.reasoning);
121
+
122
+ if (lastThought) {
123
+ const result = this.interlock.evaluate(lastThought.span_id || 'wave-context', lastThought.thought || lastThought.reasoning);
124
+ if (result.action === 'UPGRADE_MIR') {
125
+ this.writeAudit({
126
+ event: 'intelligence_upgrade_signalled',
127
+ new_mir: result.new_mir,
128
+ reason: result.reason
129
+ });
130
+ return result;
131
+ }
132
+ }
133
+ return { action: 'CONTINUE' };
101
134
  }
102
135
 
103
136
  async pause() {
@@ -0,0 +1,39 @@
1
+ /**
2
+ * MindForge v6.3.0 — Intelligence-Drift Coupling (IDC)
3
+ * Component: Intelligence Interlock
4
+ *
5
+ * New architectural bridge that listens for critical logic-drift signals
6
+ * and triggers proactive model upgrades in the steering engine.
7
+ */
8
+ 'use strict';
9
+
10
+ const driftDetector = require('./logic-drift-detector');
11
+ const routerSteering = require('../revops/router-steering-v2');
12
+
13
+ class IntelligenceInterlock {
14
+ constructor() {
15
+ this.UPGRADE_THRESHOLD = 0.50; // v6.3.0 Threshold (Recalibrated for IDC readiness)
16
+ }
17
+
18
+ /**
19
+ * Evaluates if a model upgrade is required based on reasoning drift.
20
+ * @param {string} spanId
21
+ * @param {string} thought
22
+ */
23
+ evaluate(spanId, thought) {
24
+ const analysis = driftDetector.analyze(spanId, thought);
25
+
26
+ if (analysis.drift_score > this.UPGRADE_THRESHOLD) {
27
+ console.log(`[IDC] Critical Drift Detected (${analysis.drift_score}). Recommending intelligence upgrade for Span ${spanId}.`);
28
+ return {
29
+ action: 'UPGRADE_MIR',
30
+ new_mir: 99, // Force maximum intelligence (Tier 1+)
31
+ reason: analysis.markers
32
+ };
33
+ }
34
+
35
+ return { action: 'CONTINUE', drift: analysis.drift_score };
36
+ }
37
+ }
38
+
39
+ module.exports = new IntelligenceInterlock();
@@ -11,6 +11,7 @@ class LogicDriftDetector {
11
11
  constructor() {
12
12
  this.sessionDriftHistory = new Map(); // spanId -> [scores]
13
13
  this.DRIFT_THRESHOLD = 0.75;
14
+ this.CRITICAL_DRIFT_THRESHOLD = 0.50; // v6.3.0: Recalibrated for IDC intervention readiness
14
15
  }
15
16
 
16
17
  /**
@@ -0,0 +1,40 @@
1
+ /**
2
+ * MindForge v6.3.0 — IDC Verification Test
3
+ *
4
+ * Simulates a scenario where an agent starts "rambling" (low semantic density)
5
+ * and repeats itself, triggering the Intelligence Interlock to upgrade the MIR.
6
+ */
7
+ 'use strict';
8
+
9
+ const interlock = require('./intelligence-interlock');
10
+
11
+ async function runTest() {
12
+ console.log('🧪 Starting IDC Verification Test...');
13
+
14
+ const spanId = 'test-span-drift-001';
15
+
16
+ // 1. Stable thought
17
+ console.log('\n--- Step 1: Stable Thought ---');
18
+ const t1 = "I will implement the authentication controller by defining the login and signup routes first.";
19
+ const r1 = interlock.evaluate(spanId, t1);
20
+ console.log(`Result: ${r1.action}, Drift: ${r1.drift || 'N/A'}`);
21
+
22
+ // 2. Drifting thought (Rambling and Repetitive)
23
+ console.log('\n--- Step 2: Drifting Thought (Injection) ---');
24
+ const t2 = "I will implement the implement the implement the logic of the logic of the logic and then i will implement and then i will implement implement implement implement implement implement implement implement.";
25
+ const r2 = interlock.evaluate(spanId, t2);
26
+ console.log(`Result: ${r2.action}, Drift: ${r2.drift || 'N/A'}`);
27
+
28
+ if (r2.action === 'UPGRADE_MIR') {
29
+ console.log('✅ SUCCESS: IDC triggered an upgrade signal for critical drift.');
30
+ console.log(`Target MIR: ${r2.new_mir}`);
31
+ } else {
32
+ console.error('❌ FAILURE: IDC failed to trigger upgrade even with extreme repetition.');
33
+ process.exit(1);
34
+ }
35
+ }
36
+
37
+ runTest().catch(err => {
38
+ console.error(err);
39
+ process.exit(1);
40
+ });
@@ -21,7 +21,7 @@ class RouterSteering {
21
21
  * @param {Object} preferences - Manual overrides (optional)
22
22
  */
23
23
  async steer(spanId, taskDescription, preferences = {}) {
24
- const mir = this._calculateMIR(taskDescription);
24
+ const mir = preferences.mir || this._calculateMIR(taskDescription);
25
25
  const recommendation = marketEvaluator.getBestProvider(mir);
26
26
 
27
27
  const selection = {
package/package.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "mindforge-cc",
3
- "version": "6.2.0",
3
+ "version": "6.3.0",
4
+
4
5
  "description": "MindForge — Sovereign Agentic Intelligence Framework. (CADIA v6.2 & PQAS Enabled)",
5
6
  "bin": {
6
7
  "mindforge-cc": "bin/install.js"