omnius 1.0.955 → 1.0.956

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.
@@ -104,6 +104,7 @@ export declare class MemorySourceResolver {
104
104
  private open;
105
105
  private mac;
106
106
  private verified;
107
+ private retainEntry;
107
108
  admit(issuer: MemoryContractIssuer, result: MemorySearchResultV1, admissions: readonly MemorySourceAdmission[]): Promise<Array<{
108
109
  sourceRef: string;
109
110
  status: "ready" | "unavailable";
@@ -128,4 +129,5 @@ export declare class MemorySourceResolver {
128
129
  items: MemorySourceOpenItem[];
129
130
  matches: MemorySearchMatchV1[];
130
131
  }>;
132
+ private expandRanges;
131
133
  }
@@ -445,6 +445,12 @@ export interface AgenticRunnerOptions {
445
445
  admitted: false;
446
446
  feedback: string;
447
447
  }>;
448
+ /** Host-only negative readiness from an original current native review.
449
+ * Absence grants nothing; this callback never starts inference or work. */
450
+ readCurrentNativeCompletionDeficit?: () => Readonly<{
451
+ revision: string;
452
+ reason: string;
453
+ }> | undefined;
448
454
  /**
449
455
  * Typed host decision describing which runtime effects must exist before a
450
456
  * declared successful outcome is authoritative. The runner never derives
@@ -2391,6 +2397,7 @@ export declare class AgenticRunner {
2391
2397
  private _lastVerificationInvalidatingMutation;
2392
2398
  private _completionReadinessVerificationAuthority;
2393
2399
  private _completionReadinessDeliveryAuthority;
2400
+ private _readCurrentNativeCompletionDeficit;
2394
2401
  private _currentFactualCompletionDeficit;
2395
2402
  private _completionReadinessSnapshot;
2396
2403
  /**
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: 42390118 bytes
4
- sha256: 93fa66e706c9c55d0cb17f47117a55a0f13c7d4bb639f4cb18cbd2bc754f6d42
3
+ size: 42432200 bytes
4
+ sha256: f13fd1f09a97d5d5b1fe1285fad390705198861d1266b4b1312649eecc436944
package/dist/library.js CHANGED
@@ -664,6 +664,25 @@ var init_memorySourceResolver = __esm({
664
664
  throw new Error("source_custody_invalid");
665
665
  return JSON.parse(payload2);
666
666
  }
667
+ retainEntry(db, key2, binding, sourceRef, entry) {
668
+ const payload2 = JSON.stringify(entry), mac = this.mac(key2, payload2);
669
+ db.transaction(() => {
670
+ const previous = db.prepare("SELECT payload,mac FROM memory_source_admission WHERE binding=? AND issuer_ref=? AND source_ref=? AND source_kind=?").get(binding.revision, entry.issuerRef, sourceRef, entry.sourceKind);
671
+ if (previous) {
672
+ const old = this.verified(key2, previous.payload, previous.mac);
673
+ if (old.fullSha256 !== entry.fullSha256 || old.version !== entry.version)
674
+ throw new Error("source_version_conflict");
675
+ if (stableMemoryHash(old) !== stableMemoryHash(entry))
676
+ db.prepare("UPDATE memory_source_admission SET payload=?,mac=? WHERE binding=? AND issuer_ref=? AND source_ref=? AND source_kind=?").run(payload2, mac, binding.revision, entry.issuerRef, sourceRef, entry.sourceKind);
677
+ return;
678
+ }
679
+ const size = db.prepare("SELECT COUNT(*) n, COALESCE(SUM(length(CAST(payload AS BLOB))),0) bytes FROM (SELECT payload FROM memory_source_admission UNION ALL SELECT payload FROM memory_source_query)").get();
680
+ if (size.n >= this.maxEntries || size.bytes + Buffer.byteLength(payload2) > this.maxBytes)
681
+ throw new Error("source_catalog_quota");
682
+ db.prepare("INSERT INTO memory_source_admission(binding,source_ref,payload,mac,issuer_ref,source_kind) VALUES(?,?,?,?,?,?)").run(binding.revision, sourceRef, payload2, mac, entry.issuerRef, entry.sourceKind);
683
+ }).immediate();
684
+ remember(hotAdmissions, stableMemoryHash([this.root, binding.revision, sourceRef, entry.issuerRef, entry.sourceKind]), stableMemoryHash(entry), 4096);
685
+ }
667
686
  async admit(issuer, result, admissions) {
668
687
  const binding = this.binding();
669
688
  if (issuer.readIssuedResult(result) !== result || result.bindingRevision !== binding.revision)
@@ -705,23 +724,7 @@ var init_memorySourceResolver = __esm({
705
724
  throw new Error("scope_superseded");
706
725
  opened = this.open(true);
707
726
  const { db, key: key2 } = opened;
708
- const payload2 = JSON.stringify(entry), mac = this.mac(key2, payload2);
709
- db.transaction(() => {
710
- const previous = db.prepare("SELECT payload,mac FROM memory_source_admission WHERE binding=? AND issuer_ref=? AND source_ref=? AND source_kind=?").get(binding.revision, result.issuerRef, admission.sourceRef, entry.sourceKind);
711
- if (previous) {
712
- const old = this.verified(key2, previous.payload, previous.mac);
713
- if (old.fullSha256 !== fullSha256 || old.version !== entry.version)
714
- throw new Error("source_version_conflict");
715
- if (stableMemoryHash(old) !== stableMemoryHash(entry))
716
- db.prepare("UPDATE memory_source_admission SET payload=?,mac=? WHERE binding=? AND issuer_ref=? AND source_ref=? AND source_kind=?").run(payload2, mac, binding.revision, result.issuerRef, admission.sourceRef, entry.sourceKind);
717
- return;
718
- }
719
- const size = db.prepare("SELECT COUNT(*) n, COALESCE(SUM(length(CAST(payload AS BLOB))),0) bytes FROM (SELECT payload FROM memory_source_admission UNION ALL SELECT payload FROM memory_source_query)").get();
720
- if (size.n >= this.maxEntries || size.bytes + Buffer.byteLength(payload2) > this.maxBytes)
721
- throw new Error("source_catalog_quota");
722
- db.prepare("INSERT INTO memory_source_admission(binding,source_ref,payload,mac,issuer_ref,source_kind) VALUES(?,?,?,?,?,?)").run(binding.revision, admission.sourceRef, payload2, mac, result.issuerRef, entry.sourceKind);
723
- }).immediate();
724
- remember(hotAdmissions, stableMemoryHash([this.root, binding.revision, admission.sourceRef, entry.issuerRef, entry.sourceKind]), stableMemoryHash(entry), 4096);
727
+ this.retainEntry(db, key2, binding, admission.sourceRef, entry);
725
728
  this.readyBinding = binding.revision;
726
729
  status2.push({ sourceRef: admission.sourceRef, status: "ready", sourceKind: entry.sourceKind });
727
730
  } catch (error) {
@@ -826,7 +829,11 @@ var init_memorySourceResolver = __esm({
826
829
  });
827
830
  opened.db.close();
828
831
  opened = void 0;
829
- const expanded = await this.expand(refs3.map((source_ref, i) => ({ source_ref, max_bytes: entries[i].source.byteLength })), options);
832
+ const expanded = await this.expandRanges(refs3.map((source_ref, i) => ({
833
+ source_ref,
834
+ ...entries[i].sourceWindow ? { start_byte: entries[i].sourceWindow.startByte } : {},
835
+ max_bytes: entries[i].source.byteLength
836
+ })), options, false);
830
837
  if (expanded.items.some((i) => i.status !== "ready"))
831
838
  throw new Error("cursor_invalidated");
832
839
  const matches = expanded.matches.map((match2, i) => {
@@ -846,6 +853,9 @@ var init_memorySourceResolver = __esm({
846
853
  }
847
854
  }
848
855
  async expand(requests, options = {}) {
856
+ return this.expandRanges(requests, options, true);
857
+ }
858
+ async expandRanges(requests, options, retainRangeHandles) {
849
859
  const items = [], matches = [];
850
860
  const binding = this.binding();
851
861
  let remaining = this.maxBatchBytes;
@@ -875,6 +885,12 @@ var init_memorySourceResolver = __esm({
875
885
  throw new Error("source_custody_invalid");
876
886
  if (entries.some((value) => value.fullSha256 !== entry.fullSha256 || value.version !== entry.version || value.sourceKind !== entry.sourceKind))
877
887
  throw new Error("source_admission_ambiguous");
888
+ const window2 = entry.sourceWindow, currentSource = entry.currentSource ?? entry.source;
889
+ if (window2 !== void 0) {
890
+ if (!window2 || Object.keys(window2).length !== 3 || !Number.isSafeInteger(window2.startByte) || !Number.isSafeInteger(window2.endByte) || window2.startByte < 0 || window2.endByte < window2.startByte || window2.endByte > entry.fullBytes || window2.endByte - window2.startByte !== entry.source.byteLength || !handle(window2.parentSourceRef) || !isMemorySourceV1(entry.currentSource) || entry.source.derivation?.id !== "exact_source_range" || entry.source.derivation.version !== "1" || entry.source.derivation.parentSourceRefs.length !== 1 || entry.source.derivation.parentSourceRefs[0] !== window2.parentSourceRef || entry.source.version !== stableMemoryHash([entry.version, entry.fullSha256, window2.startByte, window2.endByte]) || ["namespace", "storeRef", "scopeRef", "occurrenceId"].some((field) => currentSource[field] !== entry.source[field]))
891
+ throw new Error("source_custody_invalid");
892
+ } else if (entry.currentSource !== void 0)
893
+ throw new Error("source_custody_invalid");
878
894
  const cursorCustody = stableMemoryHash([entry.issuerRef, entry.sourceKind, request.source_ref]);
879
895
  if (memorySourceRef(entry.source) !== request.source_ref || !allowed(binding, entry.source))
880
896
  throw new Error("scope_denied");
@@ -897,7 +913,7 @@ var init_memorySourceResolver = __esm({
897
913
  }
898
914
  if (!Number.isSafeInteger(start) || start < 0 || start > entry.fullBytes)
899
915
  throw new Error("source_range_invalid");
900
- const current6 = await this.options.readCurrent(entry.locator, entry.source);
916
+ const current6 = await this.options.readCurrent(entry.locator, currentSource);
901
917
  if (options.signal?.aborted)
902
918
  throw new Error("source_read_cancelled");
903
919
  if (this.binding().revision !== binding.revision)
@@ -922,12 +938,16 @@ var init_memorySourceResolver = __esm({
922
938
  throw new Error(current6.reasonCode ?? "source_version_changed");
923
939
  sourceKind = entry.sourceKind;
924
940
  scopeName2 ??= entry.source.scopeName;
925
- text20 = await this.options.archive.read({ reference: entry.archiveRef, sha256: entry.fullSha256, maxBytes: this.maxSourceBytes, source: entry.source });
941
+ text20 = await this.options.archive.read({ reference: entry.archiveRef, sha256: entry.fullSha256, maxBytes: this.maxSourceBytes, source: currentSource });
926
942
  }
927
943
  if (Buffer.byteLength(text20) !== entry.fullBytes || sha(text20) !== entry.fullSha256)
928
944
  throw new Error("source_hash_mismatch");
929
945
  stale ||= current6.historical === true;
930
- const sourceBytes = Buffer.from(text20, "utf8"), preview2 = sourceBytes.subarray(0, entry.source.byteLength);
946
+ const sourceBytes = Buffer.from(text20, "utf8");
947
+ const originalPreview = sourceBytes.subarray(0, currentSource.byteLength);
948
+ if (originalPreview.length !== currentSource.byteLength || memoryContentHash(originalPreview) !== currentSource.contentSha256)
949
+ throw new Error("source_identity_unverified");
950
+ const preview2 = window2 ? sourceBytes.subarray(window2.startByte, window2.endByte) : originalPreview;
931
951
  if (preview2.length !== entry.source.byteLength || memoryContentHash(preview2) !== entry.source.contentSha256)
932
952
  throw new Error("source_identity_unverified");
933
953
  if (options.signal?.aborted)
@@ -957,6 +977,13 @@ var init_memorySourceResolver = __esm({
957
977
  coverage: start === 0 && end === bytes5.length ? "full" : "partial",
958
978
  derivation: { id: "exact_source_range", version: "1", parentSourceRefs: [request.source_ref] }
959
979
  });
980
+ if (retainRangeHandles)
981
+ this.retainEntry(db, key2, binding, memorySourceRef(source2), {
982
+ ...entry,
983
+ source: source2,
984
+ currentSource,
985
+ sourceWindow: { startByte: start, endByte: end, parentSourceRef: request.source_ref }
986
+ });
960
987
  matches.push({ source: source2, text: selected, routeId: "retained_exact_source" });
961
988
  Object.assign(item, {
962
989
  status: "ready",
@@ -88378,6 +88405,18 @@ var init_file_edit = __esm({
88378
88405
  }
88379
88406
  });
88380
88407
 
88408
+ // packages/execution/dist/tools/memory-operation-contract.js
88409
+ function memorySearchModelGuidance(telegramBranch = false) {
88410
+ return MEMORY_SEARCH_MODEL_GUIDANCE + (telegramBranch ? " Telegram pages require the original branch=general|chat; expansion may narrow to that branch." : "");
88411
+ }
88412
+ var MEMORY_SEARCH_MODEL_GUIDANCE;
88413
+ var init_memory_operation_contract = __esm({
88414
+ "packages/execution/dist/tools/memory-operation-contract.js"() {
88415
+ "use strict";
88416
+ MEMORY_SEARCH_MODEL_GUIDANCE = "Search: query (+store/filters); expand/open: source_ref or sources with byte/cursor fields only, omit query, store and max_results because the handle binds source/scope; page: action=page,cursor; status: action=status; memory is quoted historical evidence.";
88417
+ }
88418
+ });
88419
+
88381
88420
  // packages/execution/dist/tools/legacy-memory-view.js
88382
88421
  var init_legacy_memory_view = __esm({
88383
88422
  "packages/execution/dist/tools/legacy-memory-view.js"() {
@@ -88390,6 +88429,7 @@ var init_legacy_memory_view = __esm({
88390
88429
  var init_memory_source_adapter = __esm({
88391
88430
  "packages/execution/dist/tools/memory-source-adapter.js"() {
88392
88431
  "use strict";
88432
+ init_memory_operation_contract();
88393
88433
  init_dist2();
88394
88434
  init_legacy_memory_view();
88395
88435
  }
@@ -88459,6 +88499,7 @@ var DEFAULT_INLINE_KG_MAX_BYTES, DEFAULT_INLINE_EPISODES_MAX_BYTES;
88459
88499
  var init_memory_search = __esm({
88460
88500
  "packages/execution/dist/tools/memory-search.js"() {
88461
88501
  "use strict";
88502
+ init_memory_operation_contract();
88462
88503
  init_native_memory_view_provider();
88463
88504
  init_memory_source_adapter();
88464
88505
  init_dist2();
@@ -341858,6 +341899,7 @@ var init_delegation_contract = __esm({
341858
341899
  });
341859
341900
 
341860
341901
  // packages/execution/dist/tools/full-sub-agent.js
341902
+ var FULL_SUB_AGENT_MODEL_GUIDANCE;
341861
341903
  var init_full_sub_agent = __esm({
341862
341904
  "packages/execution/dist/tools/full-sub-agent.js"() {
341863
341905
  "use strict";
@@ -341866,6 +341908,7 @@ var init_full_sub_agent = __esm({
341866
341908
  init_full_sub_agent_events();
341867
341909
  init_delegation_contract();
341868
341910
  init_process_lifecycle();
341911
+ FULL_SUB_AGENT_MODEL_GUIDANCE = "Delegate independent work in parallel to scoped child processes. Keep native IDs for status/output/stop and independently verify results.";
341869
341912
  }
341870
341913
  });
341871
341914
 
@@ -344331,6 +344374,7 @@ var init_dist5 = __esm({
344331
344374
  init_distributions();
344332
344375
  init_work_mode_capability();
344333
344376
  init_native_memory_view_provider();
344377
+ init_memory_operation_contract();
344334
344378
  }
344335
344379
  });
344336
344380
 
@@ -372313,6 +372357,34 @@ function createNativeStructuredStateCustody(host2) {
372313
372357
  // packages/orchestrator/dist/native-memory-views.js
372314
372358
  var sha17 = (v) => createHash79("sha256").update(v).digest("hex");
372315
372359
  var route = (store) => `native_${store === "structured_records" ? "structured" : store === "project_temporal_graph" ? "temporal" : "procedure"}_view`;
372360
+ var structuredCueStopWords = new Set("a an and are as at be by for from in is it of on or that the this to was were with".split(" "));
372361
+ var normalizeStructuredCue = (text20) => text20.normalize("NFKC").toLowerCase().trim().replace(/\s+/gu, " ");
372362
+ var structuredCueAtoms = /[\p{L}\p{N}][\p{L}\p{N}\p{M}]*(?:[-_][\p{L}\p{N}][\p{L}\p{N}\p{M}]*)*/gu;
372363
+ function compileStructuredCues(text20) {
372364
+ const normalized4 = normalizeStructuredCue(text20);
372365
+ return { normalized: normalized4, terms: new Set([...normalized4.matchAll(structuredCueAtoms)].map((match2) => match2[0]).filter((atom) => !structuredCueStopWords.has(atom))) };
372366
+ }
372367
+ function scoreStructuredCues(record11, query) {
372368
+ const key2 = normalizeStructuredCue(record11.canonicalKey ?? ""), found = /* @__PURE__ */ new Set();
372369
+ const scan = (text20) => {
372370
+ for (const match2 of text20.matchAll(structuredCueAtoms)) {
372371
+ const atom = match2[0];
372372
+ if (query.terms.has(atom))
372373
+ found.add(atom);
372374
+ for (const part of atom.split(/[-_]/u))
372375
+ if (query.terms.has(part))
372376
+ found.add(part);
372377
+ }
372378
+ };
372379
+ scan(key2);
372380
+ const keyCues = found.size, exactKey = key2.length > 0 && key2 === query.normalized;
372381
+ if (exactKey)
372382
+ return [1, keyCues];
372383
+ if (!query.terms.size)
372384
+ return;
372385
+ scan(normalizeStructuredCue(record11.body));
372386
+ return found.size === query.terms.size ? [0, keyCues] : void 0;
372387
+ }
372316
372388
  function createNativeMemoryViews(host2) {
372317
372389
  const initialCustody = host2.structuredStateCustody ? void 0 : createNativeStructuredStateCustody(host2);
372318
372390
  const provider = {
@@ -372374,7 +372446,8 @@ function createNativeMemoryViews(host2) {
372374
372446
  try {
372375
372447
  db2.exec("BEGIN");
372376
372448
  const store = new StructuredMemoryStore(db2, { readOnly: true }), view = store.queryView({ scopeIds: ids4, activeAt: request.validAt, recordedAsOf: request.recordedAsOf, limit: 1e3 });
372377
- const matching = view.records.filter((record11) => record11.provenance.length > 0 && record11.rootSourceIds.length > 0).filter((record11) => [record11.body, record11.canonicalKey ?? ""].join(" ").toLowerCase().includes(request.query.toLowerCase()));
372449
+ const cues = compileStructuredCues(request.query);
372450
+ const matching = view.records.filter((record11) => record11.provenance.length > 0 && record11.rootSourceIds.length > 0).map((record11, index) => ({ record: record11, index, score: scoreStructuredCues(record11, cues) })).filter((candidate) => candidate.score !== void 0).sort((left, right) => right.score[0] - left.score[0] || right.score[1] - left.score[1] || left.index - right.index).map((candidate) => candidate.record);
372378
372451
  for (const record11 of matching.slice(0, request.limit)) {
372379
372452
  const identity10 = { schema: view.schema, semantics: view.semantics, record: { recordRef: sha17(JSON.stringify([binding.workspaceRef, "structured", record11.id])), body: record11.body, memoryClass: record11.memoryClass, canonicalKey: record11.canonicalKey, fidelity: record11.fidelity, validFrom: record11.validFrom, validUntil: record11.validUntil, recordedAt: record11.createdAt, recordedUntil: record11.recordedUntil }, rootSourceIds: record11.rootSourceIds, distinctOriginalSourceCount: record11.rootSourceIds.length, unresolvedCanonicalAlternatives: view.unresolvedCanonicalAlternatives.filter((a) => a.recordIds.includes(record11.id)).map((a) => ({ canonicalKey: a.canonicalKey, recordRefs: a.recordIds.map((id8) => sha17(JSON.stringify([binding.workspaceRef, "structured", id8]))) })), coverage: view.coverage };
372380
372453
  const parentIds = [];
@@ -385628,6 +385701,7 @@ var MODEL_LED_SYSTEM_PROMPT = [
385628
385701
  "You are Omnius, a collaborator working with the user on their projects.",
385629
385702
  "Keep the current request and requested deliverable in view. Use relevant conversation and project instructions to understand the work. A request for a plan calls for a plan the user can assess; implementation follows the user's requested scope.",
385630
385703
  "Choose your approach and tools from the task and available evidence. Inspect the source and results needed to resolve uncertainty. Carry useful findings forward, adapt when facts change, and respond when you have enough information. Ask a concise question when a missing decision prevents useful progress.",
385704
+ "When authorized delegation tools and worker capacity are available, use parallel sub-agents for independent, bounded parts of the task. Give each child its goal, relevant source context, allowed paths, constraints, and expected evidence. Coordinate disjoint write scopes and keep dependent edits together. For asynchronous children, retain their original IDs for status and output, continue useful parent work, then integrate and independently verify their results. Respect capacity feedback and continue authorized parent work when a worker is unavailable.",
385631
385705
  "For implementation, make coherent changes that fit the existing project and check the resulting behavior. For planning or review, explain the proposed approach, tradeoffs, and remaining decisions.",
385632
385706
  "Keep progress updates brief and useful. Present the result, relevant checks, and material limitations clearly. Distinguish observations from assumptions."
385633
385707
  ].join("\n\n");
@@ -389839,7 +389913,9 @@ function compactSchema(value) {
389839
389913
  return schema2;
389840
389914
  }
389841
389915
  var CORE_TOOL_GUIDANCE = {
389916
+ full_sub_agent: FULL_SUB_AGENT_MODEL_GUIDANCE,
389842
389917
  shell: SHELL_MODEL_GUIDANCE,
389918
+ memory_search: MEMORY_SEARCH_MODEL_GUIDANCE,
389843
389919
  task_complete: "Finish with the complete visible answer in user_reply. The host verifies completion and delivery.",
389844
389920
  tool_search: "Discover callable tools by query. Use their returned schemas before calling them.",
389845
389921
  telegram_progress: "Send or edit one authorized progress message in the current chat.",
@@ -389862,7 +389938,9 @@ function compactToolSchemaAnnotations(tools) {
389862
389938
  const fn = { ...original };
389863
389939
  if (typeof fn.description === "string") {
389864
389940
  const name = typeof fn.name === "string" ? fn.name : "";
389865
- const brief = CORE_TOOL_GUIDANCE[name];
389941
+ const parameters = fn.parameters;
389942
+ const branches = parameters?.properties?.branch?.enum;
389943
+ const brief = name === "memory_search" && branches?.includes("general") && branches.includes("chat") ? memorySearchModelGuidance(true) : CORE_TOOL_GUIDANCE[name];
389866
389944
  if (brief)
389867
389945
  fn.description = brief;
389868
389946
  else
@@ -412418,6 +412496,23 @@ ${JSON.stringify({
412418
412496
  }
412419
412497
  return { requirements, mappings };
412420
412498
  }
412499
+ _readCurrentNativeCompletionDeficit() {
412500
+ if (!this.options.readCurrentNativeCompletionDeficit)
412501
+ return;
412502
+ try {
412503
+ const value = this.options.readCurrentNativeCompletionDeficit();
412504
+ if (value === void 0)
412505
+ return;
412506
+ if (!value || !/^[a-f0-9]{64}$/.test(value.revision) || typeof value.reason !== "string" || !value.reason.trim() || value.reason.length > 1600)
412507
+ throw new Error("Invalid current native completion deficit");
412508
+ return { revision: value.revision, reason: value.reason };
412509
+ } catch {
412510
+ return {
412511
+ revision: _createHash("sha256").update(`${this.currentArtifactRunId()}:${this._taskEpoch}:native-goal-read-unavailable`).digest("hex"),
412512
+ reason: "The current native completion disposition is unavailable."
412513
+ };
412514
+ }
412515
+ }
412421
412516
  _currentFactualCompletionDeficit() {
412422
412517
  if (!this._isTelegramSurface() || !this.options.expectedOutcomeContract)
412423
412518
  return null;
@@ -412462,6 +412557,7 @@ ${JSON.stringify({
412462
412557
  blocking: blocking.slice(0, 12).map(({ id: id8, kind: kind2, status: status2, reasonCode }) => ({ id: id8, kind: kind2, status: status2, reasonCode })),
412463
412558
  failedEvidenceIds: failed.slice(0, 12),
412464
412559
  blockerIds: snapshot2.blockerIds.slice(0, 12),
412560
+ nativeGoalAssessment: this._readCurrentNativeCompletionDeficit(),
412465
412561
  observedCommands: commands,
412466
412562
  latestRecordedMutation: mutation ? {
412467
412563
  evidenceId: mutation.id,
@@ -412490,6 +412586,7 @@ ${JSON.stringify({
412490
412586
  const executionSnapshot2 = semanticAdmissionRequired || this._taskObjectiveContract?.criteria.some((criterion) => criterion.semanticVerification) ? this.getTaskExecutionSnapshot() : void 0;
412491
412587
  const objectiveFrontier = executionSnapshot2?.frontier ?? this._objectiveFrontier;
412492
412588
  const objectiveHeld = objectiveFrontier && (objectiveFrontier.decision === "externally_blocked" || objectiveFrontier.decision === "needs_input" || objectiveFrontier.blockedCriterionIds.length > 0 || objectiveFrontier.blockerEvidenceIds.length > 0);
412589
+ const nativeDeficit = ["completed", "incomplete_verification"].includes(input2.requestedTerminalStatus) ? this._readCurrentNativeCompletionDeficit() : void 0;
412493
412590
  const authorityInput = {
412494
412591
  runId: this.currentArtifactRunId(),
412495
412592
  taskEpoch: this._taskEpoch,
@@ -412499,7 +412596,13 @@ ${JSON.stringify({
412499
412596
  semanticAdmissionRequired,
412500
412597
  semanticAdmission: this.options.taskSemanticAdmission ?? this._completionLedger?.semanticAdmission,
412501
412598
  sessionId: this._sessionId,
412502
- constraints: [...this._completionReadinessConstraints(), ...semanticAdmissionRequired ? [{
412599
+ constraints: [...this._completionReadinessConstraints(), ...nativeDeficit ? [{
412600
+ id: "native-goal-assessment-current",
412601
+ kind: "constraint",
412602
+ revision: nativeDeficit.revision,
412603
+ acknowledged: true,
412604
+ status: "blocked"
412605
+ }] : [], ...semanticAdmissionRequired ? [{
412503
412606
  id: "human-requirement-steering-current",
412504
412607
  kind: "constraint",
412505
412608
  revision: taskExecutionDigest(this.getCurrentSteeringInputsSnapshot().map(({ inputId, content, intent }) => ({ inputId, content, intent }))),
@@ -412820,6 +412923,7 @@ runtime_module_sha256=${record11.runtimeProvenance.module.sha256 ?? "unknown"}`
412820
412923
  continueOnDurableWorkProgress: options?.continueOnDurableWorkProgress ?? options?.maxTurns === void 0,
412821
412924
  acceptTextOnlyCompletion: options?.acceptTextOnlyCompletion ?? false,
412822
412925
  admitTextOnlyCompletionCandidate: options?.admitTextOnlyCompletionCandidate,
412926
+ readCurrentNativeCompletionDeficit: options?.readCurrentNativeCompletionDeficit,
412823
412927
  expectedOutcomeContract,
412824
412928
  taskObjectiveContract,
412825
412929
  taskSemanticAdmissionRequired: options?.taskSemanticAdmissionRequired ?? false,
@@ -55365,6 +55365,13 @@ var init_dist3 = __esm({
55365
55365
  }
55366
55366
  });
55367
55367
 
55368
+ // packages/execution/dist/tools/memory-operation-contract.js
55369
+ var init_memory_operation_contract = __esm({
55370
+ "packages/execution/dist/tools/memory-operation-contract.js"() {
55371
+ "use strict";
55372
+ }
55373
+ });
55374
+
55368
55375
  // packages/execution/dist/tools/legacy-memory-view.js
55369
55376
  var init_legacy_memory_view = __esm({
55370
55377
  "packages/execution/dist/tools/legacy-memory-view.js"() {
@@ -55377,6 +55384,7 @@ var init_legacy_memory_view = __esm({
55377
55384
  var init_memory_source_adapter = __esm({
55378
55385
  "packages/execution/dist/tools/memory-source-adapter.js"() {
55379
55386
  "use strict";
55387
+ init_memory_operation_contract();
55380
55388
  init_dist3();
55381
55389
  init_legacy_memory_view();
55382
55390
  }
@@ -55411,6 +55419,7 @@ var DEFAULT_INLINE_KG_MAX_BYTES, DEFAULT_INLINE_EPISODES_MAX_BYTES;
55411
55419
  var init_memory_search = __esm({
55412
55420
  "packages/execution/dist/tools/memory-search.js"() {
55413
55421
  "use strict";
55422
+ init_memory_operation_contract();
55414
55423
  init_native_memory_view_provider();
55415
55424
  init_memory_source_adapter();
55416
55425
  init_dist3();
@@ -304063,6 +304072,7 @@ var init_dist5 = __esm({
304063
304072
  init_distributions();
304064
304073
  init_work_mode_capability();
304065
304074
  init_native_memory_view_provider();
304075
+ init_memory_operation_contract();
304066
304076
  }
304067
304077
  });
304068
304078
 
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "omnius",
3
- "version": "1.0.955",
3
+ "version": "1.0.956",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "omnius",
9
- "version": "1.0.955",
9
+ "version": "1.0.956",
10
10
  "hasInstallScript": true,
11
11
  "license": "CC-BY-NC-4.0",
12
12
  "dependencies": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "omnius",
3
- "version": "1.0.955",
3
+ "version": "1.0.956",
4
4
  "description": "AI coding agent powered by open-source models (Ollama/vLLM) — interactive TUI with agentic tool-calling loop",
5
5
  "type": "module",
6
6
  "main": "./dist/library.js",