open-agents-ai 0.187.512 → 0.187.513
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/index.js +64 -0
- package/npm-shrinkwrap.json +33 -33
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -525777,6 +525777,14 @@ var init_agenticRunner = __esm({
|
|
|
525777
525777
|
_pendingStagnationEntry = null;
|
|
525778
525778
|
// MEM_PATH item #8: persistent codebase map (lazy-init at session start).
|
|
525779
525779
|
_codebaseMap = null;
|
|
525780
|
+
// REG-58 (root-cause from stax stuck-loop triage): track the most recent
|
|
525781
|
+
// turn where a *creative* edit landed (file_write / file_edit / batch_edit
|
|
525782
|
+
// / file_patch). When too many turns elapse without one, the agent is in
|
|
525783
|
+
// "exploration without action" mode — read-loops on the same file at
|
|
525784
|
+
// different offsets, repeated tsc invocations producing identical errors,
|
|
525785
|
+
// etc. Fires stagnation independent of failure/variant thresholds because
|
|
525786
|
+
// those metrics get diluted by successful file_reads.
|
|
525787
|
+
_lastFileWriteTurn = -1;
|
|
525780
525788
|
// MEM_PATH item #9: adaptive retrieval cache. When the (goalHash, recent-tool-sig)
|
|
525781
525789
|
// hasn't changed since last retrieval, skip the PPR call entirely and reuse
|
|
525782
525790
|
// the previous memoryLines.
|
|
@@ -527916,6 +527924,7 @@ Respond with your assessment, then take action.`;
|
|
|
527916
527924
|
this._runErrorCount = 0;
|
|
527917
527925
|
this._runErrorPatterns = [];
|
|
527918
527926
|
this._runWhatWorked = [];
|
|
527927
|
+
this._lastFileWriteTurn = -1;
|
|
527919
527928
|
this._fileRegistry.clear();
|
|
527920
527929
|
this._memexArchive.clear();
|
|
527921
527930
|
this._sessionId = process.env["OA_SESSION_ID"] && String(process.env["OA_SESSION_ID"]) || `session-${Date.now()}`;
|
|
@@ -528328,6 +528337,32 @@ TASK: ${task}` : task;
|
|
|
528328
528337
|
timestamp: (/* @__PURE__ */ new Date()).toISOString()
|
|
528329
528338
|
});
|
|
528330
528339
|
}
|
|
528340
|
+
const REG58_NO_WRITE_BUDGET = 30;
|
|
528341
|
+
if (turn > stagnationCooldownUntilTurn && this._lastFileWriteTurn >= 0 && turn - this._lastFileWriteTurn >= REG58_NO_WRITE_BUDGET && process.env["OA_DISABLE_REG58"] !== "1") {
|
|
528342
|
+
const gap = turn - this._lastFileWriteTurn;
|
|
528343
|
+
const replan = `[STAGNATION REPLAN — REG-58 no-write convergence]
|
|
528344
|
+
You have made ${gap} tool calls without a single file_write/file_edit/batch_edit/file_patch since turn ${this._lastFileWriteTurn}. That is exploration-without-action. STOP retrying the current approach.
|
|
528345
|
+
|
|
528346
|
+
Respond with EXACTLY this structure before your next tool call:
|
|
528347
|
+
HYPOTHESES (3 distinct theories why progress stalled):
|
|
528348
|
+
1. ...
|
|
528349
|
+
2. ...
|
|
528350
|
+
3. ...
|
|
528351
|
+
PICK: <number 1-3>
|
|
528352
|
+
WHY: <one sentence>
|
|
528353
|
+
FALSIFICATION: <observable signal that would refute the pick>
|
|
528354
|
+
NEXT ACTION: <a single creative edit — file_write / file_edit / batch_edit — that tests the picked hypothesis>
|
|
528355
|
+
|
|
528356
|
+
If the hypothesis cannot be tested by a creative edit, ask the human via task_complete with summary 'BLOCKED: <reason>'.`;
|
|
528357
|
+
messages2.push({ role: "system", content: replan });
|
|
528358
|
+
stagnationCooldownUntilTurn = turn + 8;
|
|
528359
|
+
this.emit({
|
|
528360
|
+
type: "status",
|
|
528361
|
+
content: `REG-58 NO-WRITE STAGNATION — ${gap} turns since last creative edit (turn ${this._lastFileWriteTurn})`,
|
|
528362
|
+
timestamp: (/* @__PURE__ */ new Date()).toISOString()
|
|
528363
|
+
});
|
|
528364
|
+
this._lastFileWriteTurn = turn;
|
|
528365
|
+
}
|
|
528331
528366
|
if (turn > stagnationCooldownUntilTurn && stagnationWindow.length >= STAG_MIN_SAMPLES) {
|
|
528332
528367
|
const cutoffTurn = turn - STAG_WINDOW_TURNS;
|
|
528333
528368
|
const cutoffTs = Date.now() - STAG_WINDOW_MS;
|
|
@@ -530245,6 +530280,29 @@ ${criticDecision.cachedResult.slice(0, 500)}` : `[BLOCKED — the observer confi
|
|
|
530245
530280
|
if (obs.summaryLine) {
|
|
530246
530281
|
if (obs.hasCritical) {
|
|
530247
530282
|
messages2.push({ role: "system", content: obs.summaryLine });
|
|
530283
|
+
if (process.env["OA_DISABLE_REG59"] !== "1") {
|
|
530284
|
+
messages2.push({
|
|
530285
|
+
role: "system",
|
|
530286
|
+
content: `[STAGNATION REPLAN — REG-59 same-error escalation]
|
|
530287
|
+
The error cluster you keep hitting has occurred 5+ times. Your current approach is NOT working. STOP retrying it.
|
|
530288
|
+
|
|
530289
|
+
Respond with EXACTLY this structure before your next tool call:
|
|
530290
|
+
HYPOTHESES (3 NEW theories — must be DIFFERENT from anything tried so far):
|
|
530291
|
+
1. ...
|
|
530292
|
+
2. ...
|
|
530293
|
+
3. ...
|
|
530294
|
+
PICK: <number 1-3>
|
|
530295
|
+
WHY: <one sentence — what makes this hypothesis NEW>
|
|
530296
|
+
FALSIFICATION: <observable signal that would refute the pick>
|
|
530297
|
+
NEXT ACTION: <single tool call that tests the picked hypothesis — preferably a creative edit, not a read>`
|
|
530298
|
+
});
|
|
530299
|
+
stagnationCooldownUntilTurn = turn + 8;
|
|
530300
|
+
this.emit({
|
|
530301
|
+
type: "status",
|
|
530302
|
+
content: `REG-59 SAME-ERROR ESCALATION — forcing structured re-plan after 5+ identical cluster hits`,
|
|
530303
|
+
timestamp: (/* @__PURE__ */ new Date()).toISOString()
|
|
530304
|
+
});
|
|
530305
|
+
}
|
|
530248
530306
|
} else {
|
|
530249
530307
|
pushSoftInjection("system", obs.summaryLine);
|
|
530250
530308
|
}
|
|
@@ -530944,6 +531002,12 @@ ${criticDecision.cachedResult.slice(0, 500)}` : `[BLOCKED — the observer confi
|
|
|
530944
531002
|
timestamp: (/* @__PURE__ */ new Date()).toISOString()
|
|
530945
531003
|
});
|
|
530946
531004
|
this._taskState.toolCallCount++;
|
|
531005
|
+
if (result && result.success !== false) {
|
|
531006
|
+
const creativeTools = ["file_write", "file_edit", "batch_edit", "file_patch"];
|
|
531007
|
+
if (creativeTools.includes(tc.name)) {
|
|
531008
|
+
this._lastFileWriteTurn = turn;
|
|
531009
|
+
}
|
|
531010
|
+
}
|
|
530947
531011
|
if (result && result.success === false) {
|
|
530948
531012
|
this._runErrorCount++;
|
|
530949
531013
|
const errMsg = result.error || "";
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "open-agents-ai",
|
|
3
|
-
"version": "0.187.
|
|
3
|
+
"version": "0.187.513",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "open-agents-ai",
|
|
9
|
-
"version": "0.187.
|
|
9
|
+
"version": "0.187.513",
|
|
10
10
|
"hasInstallScript": true,
|
|
11
11
|
"license": "CC-BY-NC-4.0",
|
|
12
12
|
"dependencies": {
|
|
@@ -677,45 +677,45 @@
|
|
|
677
677
|
}
|
|
678
678
|
},
|
|
679
679
|
"node_modules/@libp2p/http-fetch": {
|
|
680
|
-
"version": "4.0.
|
|
681
|
-
"resolved": "https://registry.npmjs.org/@libp2p/http-fetch/-/http-fetch-4.0.
|
|
682
|
-
"integrity": "sha512-
|
|
680
|
+
"version": "4.0.2",
|
|
681
|
+
"resolved": "https://registry.npmjs.org/@libp2p/http-fetch/-/http-fetch-4.0.2.tgz",
|
|
682
|
+
"integrity": "sha512-fpUfevPjinWgEit+NO7LcYPH2of0pv+qHfznB0zchwJr1ngpb5EBzk4IqU8xCkO3LkdObKAxwz9fvrQvAFxUXA==",
|
|
683
683
|
"license": "Apache-2.0 OR MIT",
|
|
684
684
|
"dependencies": {
|
|
685
685
|
"@achingbrain/http-parser-js": "^0.5.9",
|
|
686
686
|
"@libp2p/http-utils": "^2.0.0",
|
|
687
|
-
"@libp2p/interface": "^3.0
|
|
687
|
+
"@libp2p/interface": "^3.2.0",
|
|
688
688
|
"uint8arrays": "^5.1.0"
|
|
689
689
|
}
|
|
690
690
|
},
|
|
691
691
|
"node_modules/@libp2p/http-peer-id-auth": {
|
|
692
|
-
"version": "2.0.
|
|
693
|
-
"resolved": "https://registry.npmjs.org/@libp2p/http-peer-id-auth/-/http-peer-id-auth-2.0.
|
|
694
|
-
"integrity": "sha512-
|
|
692
|
+
"version": "2.0.1",
|
|
693
|
+
"resolved": "https://registry.npmjs.org/@libp2p/http-peer-id-auth/-/http-peer-id-auth-2.0.1.tgz",
|
|
694
|
+
"integrity": "sha512-CKXuhHQ4+lxBEZkAdXPsSBMU2N9ajPEo+zX7Yj32NXjRjlRkoRCQBwpUtW/GzJVG0bgxp4bDRqFsMJjKpBM4CQ==",
|
|
695
695
|
"license": "Apache-2.0 OR MIT",
|
|
696
696
|
"dependencies": {
|
|
697
|
-
"@libp2p/crypto": "^5.1.
|
|
698
|
-
"@libp2p/interface": "^3.0
|
|
699
|
-
"@libp2p/peer-id": "^6.0.
|
|
697
|
+
"@libp2p/crypto": "^5.1.15",
|
|
698
|
+
"@libp2p/interface": "^3.2.0",
|
|
699
|
+
"@libp2p/peer-id": "^6.0.6",
|
|
700
700
|
"uint8-varint": "^2.0.4",
|
|
701
701
|
"uint8arrays": "^5.1.0"
|
|
702
702
|
}
|
|
703
703
|
},
|
|
704
704
|
"node_modules/@libp2p/http-utils": {
|
|
705
|
-
"version": "2.0.
|
|
706
|
-
"resolved": "https://registry.npmjs.org/@libp2p/http-utils/-/http-utils-2.0.
|
|
707
|
-
"integrity": "sha512-
|
|
705
|
+
"version": "2.0.2",
|
|
706
|
+
"resolved": "https://registry.npmjs.org/@libp2p/http-utils/-/http-utils-2.0.2.tgz",
|
|
707
|
+
"integrity": "sha512-Fx+C3hqSv7Y+lc41kUXVuiLqBWv8j3OWWdOf0R6og61pOS97/GJeDj5uAFHbCZxr2RNihhnpi8OjJ8b/bAJJmw==",
|
|
708
708
|
"license": "Apache-2.0 OR MIT",
|
|
709
709
|
"dependencies": {
|
|
710
710
|
"@achingbrain/http-parser-js": "^0.5.9",
|
|
711
|
-
"@libp2p/interface": "^3.0
|
|
712
|
-
"@libp2p/peer-id": "^6.0.
|
|
713
|
-
"@libp2p/utils": "^7.0.
|
|
711
|
+
"@libp2p/interface": "^3.2.0",
|
|
712
|
+
"@libp2p/peer-id": "^6.0.6",
|
|
713
|
+
"@libp2p/utils": "^7.0.15",
|
|
714
714
|
"@multiformats/multiaddr": "^13.0.1",
|
|
715
715
|
"@multiformats/multiaddr-to-uri": "^12.0.0",
|
|
716
716
|
"@multiformats/uri-to-multiaddr": "^10.0.0",
|
|
717
|
-
"it-to-browser-readablestream": "^2.0.
|
|
718
|
-
"multiformats": "^13.4.
|
|
717
|
+
"it-to-browser-readablestream": "^2.0.14",
|
|
718
|
+
"multiformats": "^13.4.2",
|
|
719
719
|
"race-event": "^1.6.1",
|
|
720
720
|
"readable-stream": "^4.7.0",
|
|
721
721
|
"uint8arraylist": "^2.4.8",
|
|
@@ -723,18 +723,18 @@
|
|
|
723
723
|
}
|
|
724
724
|
},
|
|
725
725
|
"node_modules/@libp2p/http-websocket": {
|
|
726
|
-
"version": "2.0.
|
|
727
|
-
"resolved": "https://registry.npmjs.org/@libp2p/http-websocket/-/http-websocket-2.0.
|
|
728
|
-
"integrity": "sha512-
|
|
726
|
+
"version": "2.0.2",
|
|
727
|
+
"resolved": "https://registry.npmjs.org/@libp2p/http-websocket/-/http-websocket-2.0.2.tgz",
|
|
728
|
+
"integrity": "sha512-wPvosBSHAkbX9yi8NCFout9y7pamyT8nOEVZkjPhBBuIHerI6Q21NFopavtq+xLht+WOPcwJkEcNs/sFqABs4g==",
|
|
729
729
|
"license": "Apache-2.0 OR MIT",
|
|
730
730
|
"dependencies": {
|
|
731
731
|
"@achingbrain/http-parser-js": "^0.5.9",
|
|
732
732
|
"@libp2p/http-utils": "^2.0.0",
|
|
733
|
-
"@libp2p/interface": "^3.0
|
|
734
|
-
"@libp2p/interface-internal": "^3.0
|
|
735
|
-
"@libp2p/utils": "^7.0.
|
|
733
|
+
"@libp2p/interface": "^3.2.0",
|
|
734
|
+
"@libp2p/interface-internal": "^3.1.0",
|
|
735
|
+
"@libp2p/utils": "^7.0.15",
|
|
736
736
|
"@multiformats/multiaddr": "^13.0.1",
|
|
737
|
-
"multiformats": "^13.4.
|
|
737
|
+
"multiformats": "^13.4.2",
|
|
738
738
|
"race-event": "^1.6.1",
|
|
739
739
|
"uint8arraylist": "^2.4.8",
|
|
740
740
|
"uint8arrays": "^5.1.0"
|
|
@@ -2156,9 +2156,9 @@
|
|
|
2156
2156
|
}
|
|
2157
2157
|
},
|
|
2158
2158
|
"node_modules/bare-stream": {
|
|
2159
|
-
"version": "2.13.
|
|
2160
|
-
"resolved": "https://registry.npmjs.org/bare-stream/-/bare-stream-2.13.
|
|
2161
|
-
"integrity": "sha512-
|
|
2159
|
+
"version": "2.13.1",
|
|
2160
|
+
"resolved": "https://registry.npmjs.org/bare-stream/-/bare-stream-2.13.1.tgz",
|
|
2161
|
+
"integrity": "sha512-Vp0cnjYyrEC4whYTymQ+YZi6pBpfiICZO3cfRG8sy67ZNWe951urv1x4eW1BKNngw3U+3fPYb5JQvHbCtxH7Ow==",
|
|
2162
2162
|
"license": "Apache-2.0",
|
|
2163
2163
|
"optional": true,
|
|
2164
2164
|
"dependencies": {
|
|
@@ -2431,9 +2431,9 @@
|
|
|
2431
2431
|
}
|
|
2432
2432
|
},
|
|
2433
2433
|
"node_modules/cborg": {
|
|
2434
|
-
"version": "5.1.
|
|
2435
|
-
"resolved": "https://registry.npmjs.org/cborg/-/cborg-5.1.
|
|
2436
|
-
"integrity": "sha512-
|
|
2434
|
+
"version": "5.1.1",
|
|
2435
|
+
"resolved": "https://registry.npmjs.org/cborg/-/cborg-5.1.1.tgz",
|
|
2436
|
+
"integrity": "sha512-BDbSRIp6XrQXkTc7g+DN0RB9RrDPTUfals2ecWUlt3juPLjbAvy/V72mJcXY0Ehu0Dq/3WpNCOCT68HUTbW+lw==",
|
|
2437
2437
|
"license": "Apache-2.0",
|
|
2438
2438
|
"bin": {
|
|
2439
2439
|
"cborg": "lib/bin.js"
|
package/package.json
CHANGED