omnius 1.0.528 → 1.0.530
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 +73 -21
- package/npm-shrinkwrap.json +2 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -573902,7 +573902,7 @@ ${fileLines}`);
|
|
|
573902
573902
|
const counts = { ok: 0, failed: 0, blocked: 0 };
|
|
573903
573903
|
for (const ev of events) {
|
|
573904
573904
|
const preview = ev.outputPreview ?? "";
|
|
573905
|
-
if (preview.includes("[FOCUS SUPERVISOR BLOCK]") || preview.includes("[STOP RE-RUNNING") || preview.includes("[CACHED VERIFIER FAILURE") || preview.includes("[REPEAT GATE")) {
|
|
573905
|
+
if (preview.includes("[FOCUS SUPERVISOR BLOCK]") || preview.includes("[STOP RE-RUNNING") || preview.includes("[CACHED VERIFIER FAILURE") || preview.includes("[REPEAT GATE") || preview.includes("[CACHED READ — content unchanged")) {
|
|
573906
573906
|
counts.blocked++;
|
|
573907
573907
|
} else if (ev.success === false) {
|
|
573908
573908
|
counts.failed++;
|
|
@@ -576963,6 +576963,7 @@ var init_evidenceLedger = __esm({
|
|
|
576963
576963
|
* "re-read me"). Bounded to `maxChars`; ContextFrameBuilder budgets again.
|
|
576964
576964
|
*/
|
|
576965
576965
|
renderBlock(maxChars = 6e3) {
|
|
576966
|
+
this.lastRenderBodyPaths.clear();
|
|
576966
576967
|
if (this.entries.size === 0)
|
|
576967
576968
|
return null;
|
|
576968
576969
|
const sorted = [...this.entries.values()].sort((a2, b) => b.lastReadTurn - a2.lastReadTurn);
|
|
@@ -576986,11 +576987,23 @@ var init_evidenceLedger = __esm({
|
|
|
576986
576987
|
}
|
|
576987
576988
|
continue;
|
|
576988
576989
|
}
|
|
576990
|
+
if (!e2.stale && e2.fidelity === "full") {
|
|
576991
|
+
this.lastRenderBodyPaths.add(e2.path);
|
|
576992
|
+
}
|
|
576989
576993
|
lines.push(chunk);
|
|
576990
576994
|
used += chunk.length;
|
|
576991
576995
|
}
|
|
576992
576996
|
return lines.join("\n");
|
|
576993
576997
|
}
|
|
576998
|
+
/**
|
|
576999
|
+
* CE-A1: whether the last renderBlock() emitted this path's FULL content
|
|
577000
|
+
* body into the active context frame. Used by the repeat gate to decide
|
|
577001
|
+
* between a stub (content visible) and rehydration (content evicted).
|
|
577002
|
+
*/
|
|
577003
|
+
renderedFullInLastBlock(path16) {
|
|
577004
|
+
return this.lastRenderBodyPaths.has(path16);
|
|
577005
|
+
}
|
|
577006
|
+
lastRenderBodyPaths = /* @__PURE__ */ new Set();
|
|
576994
577007
|
};
|
|
576995
577008
|
}
|
|
576996
577009
|
});
|
|
@@ -578877,6 +578890,20 @@ var init_focusSupervisor = __esm({
|
|
|
578877
578890
|
get currentDirective() {
|
|
578878
578891
|
return this.directive;
|
|
578879
578892
|
}
|
|
578893
|
+
/**
|
|
578894
|
+
* CE-A1: the runner rehydrated evicted evidence back into the model's
|
|
578895
|
+
* window. Any read-oriented directive is now satisfiable (or already
|
|
578896
|
+
* satisfied), and prior "ignored directive" counts were artifacts of the
|
|
578897
|
+
* model being unable to see the content it was told to use. Reset the
|
|
578898
|
+
* escalation state instead of punishing the recovery.
|
|
578899
|
+
*/
|
|
578900
|
+
noteEvidenceRehydration(target) {
|
|
578901
|
+
this.ignoredDirectiveStreak = 0;
|
|
578902
|
+
this.lastIgnoredDirectiveTurn = null;
|
|
578903
|
+
if (this.directive && (this.directive.requiredNextAction === "read_authoritative_target" || this.directive.requiredNextAction === "use_cached_evidence")) {
|
|
578904
|
+
this.clearSatisfiedDirective(`evidence for ${target} rehydrated into the live context`, 0);
|
|
578905
|
+
}
|
|
578906
|
+
}
|
|
578880
578907
|
hasTool(name10) {
|
|
578881
578908
|
return this.availableTools === null || this.availableTools.has(name10);
|
|
578882
578909
|
}
|
|
@@ -591631,16 +591658,13 @@ ${sections.join("\n")}` : sections.join("\n");
|
|
|
591631
591658
|
*/
|
|
591632
591659
|
_buildRepeatGateBlock(toolName, args, hits) {
|
|
591633
591660
|
const argPreview = JSON.stringify(args ?? {}).slice(0, 200);
|
|
591634
|
-
const progressStep = this._todoWriteAvailable() ? ` 1.
|
|
591661
|
+
const progressStep = this._todoWriteAvailable() ? ` 1. todo_write — decompose the remaining work into concrete, verifiable steps and mark the current one in_progress.` : ` 1. Name the concrete next action against the evidence already in your context.`;
|
|
591635
591662
|
return [
|
|
591636
|
-
`[REPEAT GATE]
|
|
591637
|
-
`
|
|
591638
|
-
``,
|
|
591639
|
-
`You are looping because progress tracking has drifted. Before any further redundant calls you MUST:`,
|
|
591663
|
+
`[REPEAT GATE] ${toolName}(${argPreview}) repeat #${hits} — not executed; the result is unchanged and already known.`,
|
|
591664
|
+
`Next (pick one):`,
|
|
591640
591665
|
progressStep,
|
|
591641
|
-
` 2.
|
|
591642
|
-
|
|
591643
|
-
`Do NOT repeat this exact call. If you believe state changed, perform the concrete change first, then retry with distinct evidence.`
|
|
591666
|
+
` 2. Act on the evidence you already have: edit/write the implicated file, run a verification command, or task_complete with evidence.`,
|
|
591667
|
+
`If state changed, make the concrete change first, then retry with distinct arguments.`
|
|
591644
591668
|
].join("\n");
|
|
591645
591669
|
}
|
|
591646
591670
|
_buildRepeatCachedEvidenceNotice(toolName, args, hits, cachedResult) {
|
|
@@ -591648,14 +591672,11 @@ ${sections.join("\n")}` : sections.join("\n");
|
|
|
591648
591672
|
const target = this.extractPrimaryToolPath(args) || argPreview;
|
|
591649
591673
|
const summary = this._summarizeCachedToolResult(toolName, cachedResult);
|
|
591650
591674
|
return [
|
|
591651
|
-
"[
|
|
591652
|
-
|
|
591675
|
+
"[CACHED READ — content unchanged and already in your context]",
|
|
591676
|
+
`${toolName}(${argPreview}) repeat #${hits}; not re-executed.`,
|
|
591653
591677
|
`target=${target}`,
|
|
591654
|
-
"This call was not executed again, and the cached payload was not re-emitted because repeating it bloats the model context.",
|
|
591655
591678
|
summary,
|
|
591656
|
-
""
|
|
591657
|
-
this._todoWriteAvailable() ? "Required next action: use the active evidence frame/tool cache and take a concrete next step: edit/write, run verification, update todos with changed state, or task_complete with evidence." : "Required next action: use the active evidence frame/tool cache and take a concrete next step: edit/write, run verification, or task_complete with evidence.",
|
|
591658
|
-
"If you need different information, use a distinct offset/limit/query. For broad multi-file discovery, use file_explore, grep_search, fanout_explore, or full_sub_agent instead of repeating this call."
|
|
591679
|
+
"The full content is in your active context frame. For different information use a distinct offset/limit/query; for broad discovery use file_explore, grep_search, or fanout_explore."
|
|
591659
591680
|
].join("\n");
|
|
591660
591681
|
}
|
|
591661
591682
|
_summarizeCachedToolResult(toolName, output) {
|
|
@@ -592483,7 +592504,8 @@ ${blob}
|
|
|
592483
592504
|
callMetaById.set(c9.id, {
|
|
592484
592505
|
name: name10,
|
|
592485
592506
|
path: path16,
|
|
592486
|
-
argsPreview: rawArgs.slice(0, 120)
|
|
592507
|
+
argsPreview: rawArgs.slice(0, 120),
|
|
592508
|
+
rawArgs
|
|
592487
592509
|
});
|
|
592488
592510
|
}
|
|
592489
592511
|
}
|
|
@@ -592502,6 +592524,7 @@ ${blob}
|
|
|
592502
592524
|
const clearCount = toolResultIndices.length - keepResults;
|
|
592503
592525
|
const toClear = toolResultIndices.slice(0, clearCount);
|
|
592504
592526
|
let cleared = 0;
|
|
592527
|
+
const clearedFingerprints = /* @__PURE__ */ new Set();
|
|
592505
592528
|
for (const idx of toClear) {
|
|
592506
592529
|
const msg = messages2[idx];
|
|
592507
592530
|
const content = typeof msg.content === "string" ? msg.content : "";
|
|
@@ -592535,6 +592558,15 @@ ${blob}
|
|
|
592535
592558
|
}
|
|
592536
592559
|
messages2[idx] = { ...msg, content: stub };
|
|
592537
592560
|
cleared++;
|
|
592561
|
+
if (meta?.rawArgs) {
|
|
592562
|
+
try {
|
|
592563
|
+
const parsed = JSON.parse(meta.rawArgs);
|
|
592564
|
+
const exactFp = this._buildToolFingerprint(meta.name, parsed);
|
|
592565
|
+
clearedFingerprints.add(exactFp);
|
|
592566
|
+
clearedFingerprints.add(this._resolveReadCoverageFingerprint(meta.name, parsed, exactFp));
|
|
592567
|
+
} catch {
|
|
592568
|
+
}
|
|
592569
|
+
}
|
|
592538
592570
|
}
|
|
592539
592571
|
if (idleGapMs > IDLE_THRESHOLD_MS && !this._thinkingClearLatched) {
|
|
592540
592572
|
this._thinkingClearLatched = true;
|
|
@@ -592562,8 +592594,10 @@ ${blob}
|
|
|
592562
592594
|
}
|
|
592563
592595
|
if (cleared > 0) {
|
|
592564
592596
|
if (recentToolResults) {
|
|
592565
|
-
for (const entry of recentToolResults
|
|
592566
|
-
|
|
592597
|
+
for (const [fp, entry] of recentToolResults) {
|
|
592598
|
+
if (clearedFingerprints.has(fp))
|
|
592599
|
+
entry.compacted = true;
|
|
592600
|
+
}
|
|
592567
592601
|
}
|
|
592568
592602
|
this.emit({
|
|
592569
592603
|
type: "status",
|
|
@@ -597372,7 +597406,25 @@ Read the current file if needed, make a different concrete edit, or move to veri
|
|
|
597372
597406
|
}
|
|
597373
597407
|
}
|
|
597374
597408
|
if (repeatGateEligible && _existingFp !== void 0 && _repeatGateMax > 0) {
|
|
597375
|
-
|
|
597409
|
+
const _rehydrateArgs = tc.arguments;
|
|
597410
|
+
const _rehydratePath = String(_rehydrateArgs?.["path"] ?? _rehydrateArgs?.["file"] ?? "");
|
|
597411
|
+
const _visibleViaEvidenceFrame = _rehydratePath.length > 0 && (this._evidenceLedger?.renderedFullInLastBlock(this._normalizeEvidencePath(_rehydratePath)) ?? false);
|
|
597412
|
+
if (isReadLike && _existingFp.compacted && !_visibleViaEvidenceFrame) {
|
|
597413
|
+
const cachedResult = this.sanitizeCachedToolResult(tc.name, _existingFp.result);
|
|
597414
|
+
_existingFp.compacted = false;
|
|
597415
|
+
const priorHits = dedupHitCount.get(toolFingerprint) ?? 1;
|
|
597416
|
+
dedupHitCount.set(toolFingerprint, Math.max(0, priorHits - 1));
|
|
597417
|
+
this._focusSupervisor?.noteEvidenceRehydration(this.extractPrimaryToolPath(tc.arguments ?? {}) || tc.name);
|
|
597418
|
+
repeatShortCircuit = {
|
|
597419
|
+
success: true,
|
|
597420
|
+
output: [
|
|
597421
|
+
"[REHYDRATED FROM CACHE — unchanged since last read; not re-executed]",
|
|
597422
|
+
cachedResult
|
|
597423
|
+
].join("\n"),
|
|
597424
|
+
runtimeAuthored: true,
|
|
597425
|
+
noop: true
|
|
597426
|
+
};
|
|
597427
|
+
} else if (criticDecision.hitNumber >= _repeatGateMax) {
|
|
597376
597428
|
if (isReadLike) {
|
|
597377
597429
|
repeatShortCircuit = {
|
|
597378
597430
|
success: true,
|
|
@@ -601647,7 +601699,7 @@ ${marker}` : marker);
|
|
|
601647
601699
|
].filter(Boolean).join("\n"));
|
|
601648
601700
|
}
|
|
601649
601701
|
shouldBypassDiscoveryCompaction(output) {
|
|
601650
|
-
return output.includes("[IMAGE_BASE64:") || output.includes("[BRANCH-EXTRACT]") || output.includes("[REPEAT GATE - cached evidence not re-sent]") || output.includes("[Tool output truncated") || output.includes(TRIAGE_ENVELOPE_MARKER);
|
|
601702
|
+
return output.includes("[IMAGE_BASE64:") || output.includes("[BRANCH-EXTRACT]") || output.includes("[REPEAT GATE - cached evidence not re-sent]") || output.includes("[CACHED READ — content unchanged") || output.includes("[REHYDRATED FROM CACHE") || output.includes("[Tool output truncated") || output.includes(TRIAGE_ENVELOPE_MARKER);
|
|
601651
601703
|
}
|
|
601652
601704
|
countTextLines(text2) {
|
|
601653
601705
|
if (!text2)
|
|
@@ -638607,7 +638659,7 @@ function isNoisySessionHistoryLine(line) {
|
|
|
638607
638659
|
const clean5 = cleanSessionHistoryDisplayLine(line || "");
|
|
638608
638660
|
if (!clean5) return true;
|
|
638609
638661
|
const withoutEventPrefix = clean5.replace(/^(?:E|W|⚠)\s+/, "");
|
|
638610
|
-
const noise2 = /^(?:Previous session found|REST API:|Nexus P2P network connected|No context to restore|Starting fresh|Use \/endpoint|Knowledge graph:|Zettelkasten:|Episodes captured:|Current OMNIUS_HOST:|Loaded TUI session|General session$|Chat tui:sess|TUI session\b|Using (?:expanded )?context model|Using model|Context (?:auto-)?restored|Context restored|Recovered session|Last task:|Voice feedback enabled\b|Clone ref:|clone-[^\s]+\.wav$|Memory maintenance:|reclaimed\b.*\.?$|Task timeout reached during backend retry|Incomplete: task timed out\b|Task incomplete\b|Tokens:\s*[\d,~]+|\(manual save\)|continue$|\[VRAM|VRAM |model_info|KV |arch[ -]capped|i\s+(?:starting|loaded|using|context|rest|nexus|previous)\b)
|
|
638662
|
+
const noise2 = /^(?:Previous session found|REST API:|Nexus P2P network connected|No context to restore|Starting fresh|Use \/endpoint|Knowledge graph:|Zettelkasten:|Episodes captured:|Current OMNIUS_HOST:|Loaded TUI session|General session$|Chat tui:sess|TUI session\b|Using (?:expanded )?context model|Using model|Context (?:auto-)?restored|Context restored|Recovered session|Last task:|Voice feedback enabled\b|Clone ref:|clone-[^\s]+\.wav$|Memory maintenance:|reclaimed\b.*\.?$|Task timeout reached during backend retry|Incomplete: task timed out\b|Task incomplete\b|Tokens:\s*[\d,~]+|\(manual save\)|continue$|\[VRAM|VRAM |model_info|KV |arch[ -]capped|i\s+(?:starting|loaded|using|context|rest|nexus|previous)\b|\bSHELL TRANSCRIPT\b|Invoking todo write|decompositionContract|Todos have been modified successfully|continuing with python|🔊|SHELL)$/i;
|
|
638611
638663
|
return noise2.test(clean5) || noise2.test(withoutEventPrefix);
|
|
638612
638664
|
}
|
|
638613
638665
|
function sanitizeRestoredSessionLines(lines, options2 = {}) {
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "omnius",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.530",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "omnius",
|
|
9
|
-
"version": "1.0.
|
|
9
|
+
"version": "1.0.530",
|
|
10
10
|
"bundleDependencies": [
|
|
11
11
|
"image-to-ascii"
|
|
12
12
|
],
|
package/package.json
CHANGED