omnius 1.0.894 → 1.0.896
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 +2 -2
- package/dist/library.js +159 -26
- package/npm-shrinkwrap.json +2 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
[diffend] Oversized file quarantined before diffing.
|
|
2
2
|
name: package/dist/index.js
|
|
3
|
-
size:
|
|
4
|
-
sha256:
|
|
3
|
+
size: 38875008 bytes
|
|
4
|
+
sha256: 68babdf45203d8b438fd02cb58ce852894c7908a2f2ecce16824561106ab6496
|
package/dist/library.js
CHANGED
|
@@ -3508,6 +3508,13 @@ function currentHostEnvironment() {
|
|
|
3508
3508
|
function cpuOffloadAllowedFromEnv(env = currentHostEnvironment()) {
|
|
3509
3509
|
return env[OMNIUS_CPU_OFFLOAD_ALLOWED_ENV] === "1";
|
|
3510
3510
|
}
|
|
3511
|
+
function contextHeadroomMibFromEnv(env = currentHostEnvironment()) {
|
|
3512
|
+
const raw = env[OMNIUS_CONTEXT_HEADROOM_MIB_ENV]?.trim();
|
|
3513
|
+
if (!raw || !/^\d+$/.test(raw))
|
|
3514
|
+
return void 0;
|
|
3515
|
+
const value = Number(raw);
|
|
3516
|
+
return value <= CONTEXT_HEADROOM_MAX_MIB ? value : void 0;
|
|
3517
|
+
}
|
|
3511
3518
|
function normalizeGpuUuidList(value) {
|
|
3512
3519
|
if (value === void 0)
|
|
3513
3520
|
return void 0;
|
|
@@ -3544,13 +3551,15 @@ function isGpuUuidEnabled(uuid, enabledUuids = enabledGpuUuidsFromEnv()) {
|
|
|
3544
3551
|
return true;
|
|
3545
3552
|
return Boolean(uuid && enabledUuids.includes(uuid));
|
|
3546
3553
|
}
|
|
3547
|
-
var OMNIUS_GPU_ENABLED_UUIDS_ENV, OMNIUS_GPU_PREFERRED_UUID_ENV, OMNIUS_CPU_OFFLOAD_ALLOWED_ENV;
|
|
3554
|
+
var OMNIUS_GPU_ENABLED_UUIDS_ENV, OMNIUS_GPU_PREFERRED_UUID_ENV, OMNIUS_CPU_OFFLOAD_ALLOWED_ENV, OMNIUS_CONTEXT_HEADROOM_MIB_ENV, CONTEXT_HEADROOM_MAX_MIB;
|
|
3548
3555
|
var init_gpu_selection = __esm({
|
|
3549
3556
|
"packages/schemas/dist/gpu-selection.js"() {
|
|
3550
3557
|
"use strict";
|
|
3551
3558
|
OMNIUS_GPU_ENABLED_UUIDS_ENV = "OMNIUS_GPU_ENABLED_UUIDS";
|
|
3552
3559
|
OMNIUS_GPU_PREFERRED_UUID_ENV = "OMNIUS_GPU_PREFERRED_UUID";
|
|
3553
3560
|
OMNIUS_CPU_OFFLOAD_ALLOWED_ENV = "OMNIUS_CPU_OFFLOAD_ALLOWED";
|
|
3561
|
+
OMNIUS_CONTEXT_HEADROOM_MIB_ENV = "OMNIUS_CONTEXT_HEADROOM_MIB";
|
|
3562
|
+
CONTEXT_HEADROOM_MAX_MIB = 1048576;
|
|
3554
3563
|
}
|
|
3555
3564
|
});
|
|
3556
3565
|
|
|
@@ -350078,22 +350087,86 @@ function recordToolEvidence(ledger, input) {
|
|
|
350078
350087
|
});
|
|
350079
350088
|
}
|
|
350080
350089
|
function addCompletionClaims(ledger, claims) {
|
|
350090
|
+
const at = nowIso4();
|
|
350091
|
+
const assertion = {
|
|
350092
|
+
assertedAtIso: at,
|
|
350093
|
+
assertedRunId: ledger.runId,
|
|
350094
|
+
assertedEvidenceSequence: ledger.evidence.length
|
|
350095
|
+
};
|
|
350081
350096
|
const byId = new Map(ledger.proposedClaims.map((claim) => [claim.id, claim]));
|
|
350082
350097
|
const byMeaning = new Map(ledger.proposedClaims.map((claim) => [normalizeCompletionKey(claim.text, "claim"), claim.id]));
|
|
350098
|
+
const assertedMeanings = /* @__PURE__ */ new Set();
|
|
350083
350099
|
for (const claim of claims) {
|
|
350084
350100
|
const meaning = normalizeCompletionKey(claim.text, "claim");
|
|
350085
|
-
if (meaning
|
|
350101
|
+
if (meaning)
|
|
350102
|
+
assertedMeanings.add(meaning);
|
|
350103
|
+
const existingId = meaning ? byMeaning.get(meaning) : void 0;
|
|
350104
|
+
const existing = existingId ? byId.get(existingId) : void 0;
|
|
350105
|
+
if (existing) {
|
|
350106
|
+
const { supersededAtIso: _superseded, ...reasserted } = existing;
|
|
350107
|
+
byId.set(existing.id, { ...reasserted, ...assertion });
|
|
350086
350108
|
continue;
|
|
350087
|
-
|
|
350109
|
+
}
|
|
350110
|
+
byId.set(claim.id, {
|
|
350111
|
+
...claim,
|
|
350112
|
+
recordedAtIso: claim.recordedAtIso ?? at,
|
|
350113
|
+
recordedRunId: claim.recordedRunId ?? ledger.runId,
|
|
350114
|
+
...assertion
|
|
350115
|
+
});
|
|
350088
350116
|
if (meaning)
|
|
350089
350117
|
byMeaning.set(meaning, claim.id);
|
|
350090
350118
|
}
|
|
350119
|
+
if (claims.some((claim) => claim.source === "task_complete_summary")) {
|
|
350120
|
+
for (const [id5, claim] of byId) {
|
|
350121
|
+
if (claim.source !== "task_complete_summary" || claim.supersededAtIso)
|
|
350122
|
+
continue;
|
|
350123
|
+
if (assertedMeanings.has(normalizeCompletionKey(claim.text, "claim")))
|
|
350124
|
+
continue;
|
|
350125
|
+
byId.set(id5, { ...claim, supersededAtIso: at });
|
|
350126
|
+
}
|
|
350127
|
+
}
|
|
350091
350128
|
return {
|
|
350092
350129
|
...ledger,
|
|
350093
350130
|
proposedClaims: Array.from(byId.values()),
|
|
350094
|
-
updatedAtIso:
|
|
350131
|
+
updatedAtIso: at
|
|
350095
350132
|
};
|
|
350096
350133
|
}
|
|
350134
|
+
function isAppliedMutation(evidence) {
|
|
350135
|
+
return (evidence.role === "mutation" || evidence.kind === "file_change") && evidence.success !== false && evidence.receipt?.cancelled !== true;
|
|
350136
|
+
}
|
|
350137
|
+
function assessCompletionClaimCurrentness(ledger, claim) {
|
|
350138
|
+
if (claim.source === "derived")
|
|
350139
|
+
return { current: true };
|
|
350140
|
+
if (claim.supersededAtIso) {
|
|
350141
|
+
return {
|
|
350142
|
+
current: false,
|
|
350143
|
+
reason: "superseded_by_later_summary",
|
|
350144
|
+
endedAtIso: claim.supersededAtIso
|
|
350145
|
+
};
|
|
350146
|
+
}
|
|
350147
|
+
const sequence = claim.assertedEvidenceSequence;
|
|
350148
|
+
if (sequence !== void 0 && Number.isFinite(sequence)) {
|
|
350149
|
+
const hasPaths = claimPathSignals(claim).length > 0;
|
|
350150
|
+
for (let index = Math.max(0, sequence); index < ledger.evidence.length; index++) {
|
|
350151
|
+
const item = ledger.evidence[index];
|
|
350152
|
+
if (!isAppliedMutation(item))
|
|
350153
|
+
continue;
|
|
350154
|
+
if (hasPaths ? hasClaimPathOverlap(claim, item) : claim.status !== "supported") {
|
|
350155
|
+
return {
|
|
350156
|
+
current: false,
|
|
350157
|
+
reason: "artifact_revised_after_claim",
|
|
350158
|
+
endedAtIso: item.observedAtIso,
|
|
350159
|
+
supersedingEvidenceId: item.id
|
|
350160
|
+
};
|
|
350161
|
+
}
|
|
350162
|
+
}
|
|
350163
|
+
}
|
|
350164
|
+
const assertedRun = claim.assertedRunId ?? claim.recordedRunId;
|
|
350165
|
+
if (assertedRun && ledger.runId && assertedRun !== ledger.runId) {
|
|
350166
|
+
return { current: false, reason: "recorded_in_prior_run" };
|
|
350167
|
+
}
|
|
350168
|
+
return { current: true };
|
|
350169
|
+
}
|
|
350097
350170
|
function claimPathSignals(claim) {
|
|
350098
350171
|
const sourcePaths = (claim.sourceSignals ?? []).filter((signal) => /[/.]/.test(signal));
|
|
350099
350172
|
return cleanTargetPaths([...claim.workspaceSignals, ...sourcePaths]);
|
|
@@ -360881,7 +360954,7 @@ function buildIntegrationClosure(input) {
|
|
|
360881
360954
|
});
|
|
360882
360955
|
}
|
|
360883
360956
|
}
|
|
360884
|
-
const claims = (ledger?.proposedClaims ?? []).slice(-MAX_CLAIMS);
|
|
360957
|
+
const claims = (ledger?.proposedClaims ?? []).filter((claim) => assessCompletionClaimCurrentness(ledger, claim).current).slice(-MAX_CLAIMS);
|
|
360885
360958
|
for (const claim of claims) {
|
|
360886
360959
|
const claimId = nodeId("claim", claim.id);
|
|
360887
360960
|
addNode({
|
|
@@ -362559,7 +362632,7 @@ function renderReasoningSlice(slice, maxCharacters = slice.selection.maxCharacte
|
|
|
362559
362632
|
};
|
|
362560
362633
|
const renderedNodeIds = /* @__PURE__ */ new Set();
|
|
362561
362634
|
for (const node of [...slice.nodes].sort((left, right) => nodePriority(left) - nodePriority(right) || left.nodeId.localeCompare(right.nodeId))) {
|
|
362562
|
-
if (append(`- ${node.nodeId} [${node.kind}/${node.status}/${node.authority}] ${options.objectiveReference && node.kind === "objective" ? `[see ${options.objectiveReference}]` : node.label}`)) {
|
|
362635
|
+
if (append(`- ${node.nodeId} [${node.kind}/${node.status}/${node.authority}] ${options.objectiveReference && node.kind === "objective" ? `[see ${options.objectiveReference}]` : node.kind === "claim" && node.status === "superseded" ? "(historical assertion; see Historical claims — not a current fact)" : node.label}`)) {
|
|
362563
362636
|
renderedNodeIds.add(node.nodeId);
|
|
362564
362637
|
}
|
|
362565
362638
|
}
|
|
@@ -362571,11 +362644,21 @@ function renderReasoningSlice(slice, maxCharacters = slice.selection.maxCharacte
|
|
|
362571
362644
|
}
|
|
362572
362645
|
append(`- ${edge.sourceNodeId} --${edge.kind}--> ${edge.targetNodeId}`);
|
|
362573
362646
|
}
|
|
362647
|
+
const historical = slice.claims.filter(isHistoricalClaim);
|
|
362648
|
+
const current2 = slice.claims.filter((claim) => !isHistoricalClaim(claim));
|
|
362574
362649
|
append("Claims:");
|
|
362575
|
-
if (
|
|
362650
|
+
if (current2.length === 0)
|
|
362576
362651
|
append("- none");
|
|
362577
|
-
for (const claim of
|
|
362578
|
-
append(`- ${claim.claimId} [${claim.status}/${claim.authority ?? "inferred"}] ${claim.statement}`);
|
|
362652
|
+
for (const claim of current2) {
|
|
362653
|
+
append(`- ${claim.claimId} [${claim.status}/${claim.authority ?? "inferred"}]${claimProvenance(claim)} ${claim.statement}`);
|
|
362654
|
+
}
|
|
362655
|
+
if (historical.length > 0) {
|
|
362656
|
+
append("Historical claims (superseded or revised by later evidence; retained for audit, NOT current facts — rely on current observations):");
|
|
362657
|
+
for (const claim of historical) {
|
|
362658
|
+
const reason = claimTag(claim, "currentness:") ?? "historical";
|
|
362659
|
+
const by = claimTag(claim, "superseded-by:");
|
|
362660
|
+
append(`- ${claim.claimId} [historical/${reason}${by ? ` by ${by}` : ""}]${claimProvenance(claim)} was: ${claim.statement}`);
|
|
362661
|
+
}
|
|
362579
362662
|
}
|
|
362580
362663
|
append("Conflicts:");
|
|
362581
362664
|
if (slice.conflicts.length === 0)
|
|
@@ -362593,6 +362676,21 @@ function renderReasoningSlice(slice, maxCharacters = slice.selection.maxCharacte
|
|
|
362593
362676
|
lines.push(closing);
|
|
362594
362677
|
return lines.join("\n").slice(0, budget);
|
|
362595
362678
|
}
|
|
362679
|
+
function claimTag(claim, prefix) {
|
|
362680
|
+
return claim.tags.find((tag) => tag.startsWith(prefix))?.slice(prefix.length);
|
|
362681
|
+
}
|
|
362682
|
+
function isHistoricalClaim(claim) {
|
|
362683
|
+
return claim.tags.includes("historical");
|
|
362684
|
+
}
|
|
362685
|
+
function claimProvenance(claim) {
|
|
362686
|
+
const parts = [
|
|
362687
|
+
claimTag(claim, "run:") ? `run=${claimTag(claim, "run:")}` : "",
|
|
362688
|
+
claim.validFrom ? `at=${claim.validFrom}` : "",
|
|
362689
|
+
claimTag(claim, "evidence-seq:") !== void 0 ? `evidence-seq=${claimTag(claim, "evidence-seq:")}` : "",
|
|
362690
|
+
claim.validTo ? `until=${claim.validTo}` : ""
|
|
362691
|
+
].filter(Boolean);
|
|
362692
|
+
return parts.length > 0 ? ` (${parts.join(" ")})` : "";
|
|
362693
|
+
}
|
|
362596
362694
|
function iso(value, fallback) {
|
|
362597
362695
|
return value && Number.isFinite(Date.parse(value)) ? value : fallback;
|
|
362598
362696
|
}
|
|
@@ -362677,8 +362775,23 @@ function todoActionContract(todo, nodeId2) {
|
|
|
362677
362775
|
risk
|
|
362678
362776
|
};
|
|
362679
362777
|
}
|
|
362680
|
-
function claimAuthority(claim) {
|
|
362681
|
-
|
|
362778
|
+
function claimAuthority(claim, currentness) {
|
|
362779
|
+
if (claim.source === "derived" || !currentness.current)
|
|
362780
|
+
return "inferred";
|
|
362781
|
+
return claim.status === "supported" ? "adopted" : "inferred";
|
|
362782
|
+
}
|
|
362783
|
+
function validIso(value) {
|
|
362784
|
+
return value && Number.isFinite(Date.parse(value)) ? new Date(Date.parse(value)).toISOString() : void 0;
|
|
362785
|
+
}
|
|
362786
|
+
function claimProvenanceTags(claim, currentness) {
|
|
362787
|
+
const run = claim.assertedRunId ?? claim.recordedRunId;
|
|
362788
|
+
return [
|
|
362789
|
+
...run ? [`run:${run}`.slice(0, 128)] : [],
|
|
362790
|
+
...claim.assertedEvidenceSequence !== void 0 ? [`evidence-seq:${claim.assertedEvidenceSequence}`] : [],
|
|
362791
|
+
currentness.current ? "currentness:current" : `currentness:${currentness.reason}`,
|
|
362792
|
+
...currentness.current ? [] : ["historical"],
|
|
362793
|
+
...currentness.supersedingEvidenceId ? [`superseded-by:${currentness.supersedingEvidenceId}`.slice(0, 128)] : []
|
|
362794
|
+
];
|
|
362682
362795
|
}
|
|
362683
362796
|
function evidenceRole(evidence) {
|
|
362684
362797
|
if (evidence.receipt?.cancelled === true)
|
|
@@ -363579,6 +363692,11 @@ function buildWorkGraphProjectionPatch(input) {
|
|
|
363579
363692
|
return completionClaim.evidenceIds.some((id5) => proofIds.has(id5));
|
|
363580
363693
|
});
|
|
363581
363694
|
const subjectNodeId = matchedTodo ? todoNodeIds.get(matchedTodo.id) ?? objectiveId : objectiveId;
|
|
363695
|
+
const currentness = assessCompletionClaimCurrentness(ledger, completionClaim);
|
|
363696
|
+
const authority = claimAuthority(completionClaim, currentness);
|
|
363697
|
+
const validFrom = validIso(completionClaim.assertedAtIso ?? completionClaim.recordedAtIso);
|
|
363698
|
+
const endedAt = currentness.current ? void 0 : validIso(currentness.endedAtIso);
|
|
363699
|
+
const validTo = endedAt && validFrom && Date.parse(endedAt) < Date.parse(validFrom) ? validFrom : endedAt;
|
|
363582
363700
|
const claim = {
|
|
363583
363701
|
schemaVersion: input.graph.schemaVersion,
|
|
363584
363702
|
claimId,
|
|
@@ -363589,11 +363707,17 @@ function buildWorkGraphProjectionPatch(input) {
|
|
|
363589
363707
|
confidence: completionClaim.status === "supported" ? 1 : 0.5,
|
|
363590
363708
|
evidenceRefIds: evidenceIds,
|
|
363591
363709
|
dependsOnClaimIds: [],
|
|
363592
|
-
tags: [
|
|
363710
|
+
tags: [
|
|
363711
|
+
WORK_GRAPH_PROJECTION_ID,
|
|
363712
|
+
completionClaim.riskCategory,
|
|
363713
|
+
...claimProvenanceTags(completionClaim, currentness)
|
|
363714
|
+
],
|
|
363593
363715
|
subjectNodeId,
|
|
363594
363716
|
predicate: "completion_outcome",
|
|
363595
363717
|
objectValue: completionClaim.attainedState,
|
|
363596
|
-
|
|
363718
|
+
...validFrom ? { validFrom } : {},
|
|
363719
|
+
...validTo ? { validTo } : {},
|
|
363720
|
+
authority
|
|
363597
363721
|
};
|
|
363598
363722
|
claims.set(claimId, claim);
|
|
363599
363723
|
const claimNodeId = scopedId("claim-node", completionClaim.id);
|
|
@@ -363602,20 +363726,25 @@ function buildWorkGraphProjectionPatch(input) {
|
|
|
363602
363726
|
nodeId: claimNodeId,
|
|
363603
363727
|
kind: "claim",
|
|
363604
363728
|
label: completionClaim.text.slice(0, 1e3),
|
|
363605
|
-
status: completionClaim.status === "supported" ? "complete" : completionClaim.status === "contradicted" ? "invalid" : completionClaim.status === "blocked" ? "blocked" : "proposed",
|
|
363606
|
-
authority
|
|
363729
|
+
status: !currentness.current ? "superseded" : completionClaim.status === "supported" ? "complete" : completionClaim.status === "contradicted" ? "invalid" : completionClaim.status === "blocked" ? "blocked" : "proposed",
|
|
363730
|
+
authority,
|
|
363607
363731
|
parentNodeId: subjectNodeId,
|
|
363608
363732
|
bindingIds: [],
|
|
363609
363733
|
evidenceRefIds: evidenceIds,
|
|
363610
363734
|
reference: { type: "claim", claimId },
|
|
363611
|
-
attributes: projectedAttributes(
|
|
363735
|
+
attributes: projectedAttributes(authority, {
|
|
363612
363736
|
materiality: completionClaim.materiality,
|
|
363613
363737
|
riskCategory: completionClaim.riskCategory,
|
|
363614
|
-
requiresIndependentEvidence: completionClaim.requiresIndependentEvidence
|
|
363738
|
+
requiresIndependentEvidence: completionClaim.requiresIndependentEvidence,
|
|
363739
|
+
currentness: currentness.current ? "current" : "historical",
|
|
363740
|
+
...currentness.reason ? { currentnessReason: currentness.reason } : {},
|
|
363741
|
+
...currentness.supersedingEvidenceId ? { supersedingEvidenceId: currentness.supersedingEvidenceId } : {},
|
|
363742
|
+
...completionClaim.assertedRunId ?? completionClaim.recordedRunId ? { assertedRunId: completionClaim.assertedRunId ?? completionClaim.recordedRunId } : {},
|
|
363743
|
+
...completionClaim.assertedEvidenceSequence !== void 0 ? { assertedEvidenceSequence: completionClaim.assertedEvidenceSequence } : {}
|
|
363615
363744
|
})
|
|
363616
363745
|
});
|
|
363617
363746
|
addEdge(subjectNodeId, claimNodeId, "contains");
|
|
363618
|
-
if (matchedTodo) {
|
|
363747
|
+
if (matchedTodo && currentness.current) {
|
|
363619
363748
|
const proofNodes = [
|
|
363620
363749
|
...todoMutationNodeIds.get(matchedTodo.id) ?? [],
|
|
363621
363750
|
...todoArtifactNodeIds.get(matchedTodo.id) ?? []
|
|
@@ -363728,7 +363857,7 @@ function graphId(value) {
|
|
|
363728
363857
|
const digest8 = createHash79("sha256").update(value).digest("hex").slice(0, 20);
|
|
363729
363858
|
return `work-graph:${digest8}`;
|
|
363730
363859
|
}
|
|
363731
|
-
function
|
|
363860
|
+
function validIso2(value) {
|
|
363732
363861
|
return value && Number.isFinite(Date.parse(value)) ? value : (/* @__PURE__ */ new Date()).toISOString();
|
|
363733
363862
|
}
|
|
363734
363863
|
var OperationalWorkGraphController = class {
|
|
@@ -363753,7 +363882,7 @@ var OperationalWorkGraphController = class {
|
|
|
363753
363882
|
graphId: options.graphId ?? graphId(options.persistenceKey),
|
|
363754
363883
|
title: options.title ?? "Omnius operational work graph",
|
|
363755
363884
|
revision: "revision:0",
|
|
363756
|
-
createdAt:
|
|
363885
|
+
createdAt: validIso2(options.now)
|
|
363757
363886
|
});
|
|
363758
363887
|
if (this.persist && !restored)
|
|
363759
363888
|
this.save();
|
|
@@ -365361,7 +365490,7 @@ function sha2566(value) {
|
|
|
365361
365490
|
function normalizedPath(value) {
|
|
365362
365491
|
return bounded2(value, 1e3).replace(/\\/g, "/").replace(/\/+/g, "/");
|
|
365363
365492
|
}
|
|
365364
|
-
function
|
|
365493
|
+
function validIso3(value) {
|
|
365365
365494
|
return typeof value === "string" && Number.isFinite(Date.parse(value));
|
|
365366
365495
|
}
|
|
365367
365496
|
function evidenceMap(mappings) {
|
|
@@ -365396,7 +365525,7 @@ function receiptHasValidIdentity(receipt) {
|
|
|
365396
365525
|
}
|
|
365397
365526
|
if (!bounded2(receipt.cwd, 2e3))
|
|
365398
365527
|
return false;
|
|
365399
|
-
if (!
|
|
365528
|
+
if (!validIso3(receipt.startedAtIso) || !validIso3(receipt.finishedAtIso))
|
|
365400
365529
|
return false;
|
|
365401
365530
|
return Date.parse(receipt.finishedAtIso) >= Date.parse(receipt.startedAtIso);
|
|
365402
365531
|
}
|
|
@@ -365465,7 +365594,7 @@ function latestDelivery(requirement, mappedEvidenceIds, evidence) {
|
|
|
365465
365594
|
entry,
|
|
365466
365595
|
ordinal,
|
|
365467
365596
|
receipt: normalizeCompletionDeliveryReceipt(entry.deliveryReceipt)
|
|
365468
|
-
})).filter((item) => Boolean(item.receipt &&
|
|
365597
|
+
})).filter((item) => Boolean(item.receipt && validIso3(item.receipt.deliveredAtIso) && (!requirement.provider || item.receipt.provider === requirement.provider) && (!requirement.target || item.receipt.target === requirement.target))).sort((left, right) => Date.parse(left.receipt.deliveredAtIso) - Date.parse(right.receipt.deliveredAtIso) || left.ordinal - right.ordinal);
|
|
365469
365598
|
const selected = candidates.at(-1);
|
|
365470
365599
|
if (!selected)
|
|
365471
365600
|
return { status: "unverified" };
|
|
@@ -365854,7 +365983,7 @@ function validateOverrideReceipt(value) {
|
|
|
365854
365983
|
const reason = bounded2(record9["reason"], 2e3);
|
|
365855
365984
|
const persistedAtIso = bounded2(record9["persistedAtIso"], 80);
|
|
365856
365985
|
const receiptId = bounded2(record9["receiptId"], 100);
|
|
365857
|
-
if (!runId || !SHA2562.test(readinessHash) || !reason || !
|
|
365986
|
+
if (!runId || !SHA2562.test(readinessHash) || !reason || !validIso3(persistedAtIso)) {
|
|
365858
365987
|
return null;
|
|
365859
365988
|
}
|
|
365860
365989
|
const expected = `override-${receiptDigest({
|
|
@@ -365913,7 +366042,7 @@ function persistCompletionReadinessOverride(stateDir, input) {
|
|
|
365913
366042
|
if (!reason)
|
|
365914
366043
|
throw new TypeError("Override reason is required");
|
|
365915
366044
|
const persistedAtIso = input.persistedAtIso ?? (/* @__PURE__ */ new Date()).toISOString();
|
|
365916
|
-
if (!
|
|
366045
|
+
if (!validIso3(persistedAtIso))
|
|
365917
366046
|
throw new TypeError("Invalid persistedAtIso");
|
|
365918
366047
|
const path7 = completionReadinessOverridePath(stateDir, runId, input.readinessHash);
|
|
365919
366048
|
const existing = loadCompletionReadinessOverride(stateDir, runId, input.readinessHash);
|
|
@@ -365964,7 +366093,7 @@ function persistCompletionReadinessOverride(stateDir, input) {
|
|
|
365964
366093
|
function reconcileCompletionReadiness(input) {
|
|
365965
366094
|
const runId = requiredId(input.runId, "runId");
|
|
365966
366095
|
const generatedAtIso = input.generatedAtIso ?? (/* @__PURE__ */ new Date()).toISOString();
|
|
365967
|
-
if (!
|
|
366096
|
+
if (!validIso3(generatedAtIso))
|
|
365968
366097
|
throw new TypeError("Invalid generatedAtIso");
|
|
365969
366098
|
const requestedTerminalStatus = input.requestedTerminalStatus ?? "completed";
|
|
365970
366099
|
const built = buildCompletionObligations(input);
|
|
@@ -431369,6 +431498,10 @@ var OllamaAgenticBackend = class _OllamaAgenticBackend {
|
|
|
431369
431498
|
if (cpuOffloadAllowedFromEnv()) {
|
|
431370
431499
|
headers["X-Ollama-Unify-CPU-Offload"] = "allow";
|
|
431371
431500
|
}
|
|
431501
|
+
const contextHeadroomMib = contextHeadroomMibFromEnv();
|
|
431502
|
+
if (contextHeadroomMib !== void 0) {
|
|
431503
|
+
headers["X-Ollama-Unify-Context-Headroom-MiB"] = String(contextHeadroomMib);
|
|
431504
|
+
}
|
|
431372
431505
|
const envOverride = process.env["OMNIUS_OLLAMA_BROKER_ADMISSION_WAIT_MS"];
|
|
431373
431506
|
const classDefault = workloadClass === "background" ? 500 : workloadClass === "interactive-control" ? 3e4 : void 0;
|
|
431374
431507
|
const configured = Number.parseInt(String(request?.brokerAdmissionWaitMs ?? envOverride ?? classDefault ?? 0), 10);
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "omnius",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.896",
|
|
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.896",
|
|
10
10
|
"bundleDependencies": [
|
|
11
11
|
"image-to-ascii"
|
|
12
12
|
],
|
package/package.json
CHANGED