@remnic/core 10.0.67 → 10.0.68

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.
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  Orchestrator
3
- } from "./chunk-LFYEQK45.js";
3
+ } from "./chunk-FAF4A76Q.js";
4
4
  import "./chunk-5QV6CE6K.js";
5
5
  import "./chunk-GGD2YDS6.js";
6
6
  import "./chunk-5PHOU5QI.js";
@@ -8059,30 +8059,40 @@ var ExtractionPersistCoordinator = class {
8059
8059
  const factWriteOutcome = await persistUnderFactDedupWindow(
8060
8060
  targetStorage.dir,
8061
8061
  raceRecheck(targetStorage, contentHashDedupKey),
8062
- async () => targetStorage.writeSealedMemory(factWriteEnvelope, {
8063
- importance,
8064
- supersedes,
8065
- links: links.length > 0 ? links : void 0,
8066
- intentGoal: inferredIntent?.goal,
8067
- intentActionType: inferredIntent?.actionType,
8068
- intentEntityTypes: inferredIntent?.entityTypes,
8069
- memoryKind,
8070
- ...biTemporal ? { observedAt: biTemporal.observedAt, eventTimeSource: biTemporal.eventTimeSource, ...biTemporal.validUntil ? { invalidAt: biTemporal.validUntil } : {} } : {},
8071
- contentHashSource: writeCategory === "fact" ? fact.content : void 0,
8072
- // Faithfulness gate (issue #1576).
8073
- ...faithfulnessFm ? { faithfulness: faithfulnessFm } : {},
8074
- ...faithfulnessEnforceStatus ? { status: faithfulnessEnforceStatus } : {},
8075
- // Claim-level provenance spans (issue #1575 PR 2). Carry verified
8076
- // sources + the coarse strength tag from the extraction validator
8077
- // through to frontmatter so they survive end-to-end.
8078
- ...fact.sources && fact.sources.length > 0 ? { sources: fact.sources } : {},
8079
- ...fact.provenance ? { provenance: fact.provenance } : {},
8080
- // PR #2016: never defer inside the commit window (chunked-path
8081
- // rule): a peer loading an authoritative index after the release
8082
- // must see this hash, or its recheck misses and duplicates it.
8083
- deferHashIndexSave: false,
8084
- ...factToolScoped ? { toolScoped: true } : {}
8085
- })
8062
+ async () => {
8063
+ const factWrite2 = await targetStorage.writeSealedMemory(factWriteEnvelope, {
8064
+ importance,
8065
+ supersedes,
8066
+ links: links.length > 0 ? links : void 0,
8067
+ intentGoal: inferredIntent?.goal,
8068
+ intentActionType: inferredIntent?.actionType,
8069
+ intentEntityTypes: inferredIntent?.entityTypes,
8070
+ memoryKind,
8071
+ ...biTemporal ? { observedAt: biTemporal.observedAt, eventTimeSource: biTemporal.eventTimeSource, ...biTemporal.validUntil ? { invalidAt: biTemporal.validUntil } : {} } : {},
8072
+ contentHashSource: writeCategory === "fact" ? fact.content : void 0,
8073
+ // Faithfulness gate (issue #1576).
8074
+ ...faithfulnessFm ? { faithfulness: faithfulnessFm } : {},
8075
+ ...faithfulnessEnforceStatus ? { status: faithfulnessEnforceStatus } : {},
8076
+ // Claim-level provenance spans (issue #1575 PR 2). Carry verified
8077
+ // sources + the coarse strength tag from the extraction validator
8078
+ // through to frontmatter so they survive end-to-end.
8079
+ ...fact.sources && fact.sources.length > 0 ? { sources: fact.sources } : {},
8080
+ ...fact.provenance ? { provenance: fact.provenance } : {},
8081
+ // PR #2016: never defer inside the commit window (chunked-path
8082
+ // rule): a peer loading an authoritative index after the release
8083
+ // must see this hash, or its recheck misses and duplicates it.
8084
+ deferHashIndexSave: false,
8085
+ ...factToolScoped ? { toolScoped: true } : {}
8086
+ });
8087
+ if (!factWrite2.tombstoneBlocked) {
8088
+ try {
8089
+ await this.deps.addContentHashDedup(targetStorage, contentHashDedupKey);
8090
+ } catch (err) {
8091
+ log.warn(`content-hash dedup registration failed for memory ${factWrite2.id}: ${err}`);
8092
+ }
8093
+ }
8094
+ return factWrite2;
8095
+ }
8086
8096
  ).catch(finalizeOnWindowFailure);
8087
8097
  if (factWriteOutcome.suppressed) {
8088
8098
  await backfillDuplicateTemporalBounds();
@@ -8239,17 +8249,6 @@ var ExtractionPersistCoordinator = class {
8239
8249
  ...factToolScoped ? { toolScoped: true } : {}
8240
8250
  });
8241
8251
  }
8242
- try {
8243
- const canonicalFactContent = citationEnabled && hasCitationForTemplate(fact.content, citationTemplate) ? stripCitationForTemplate(fact.content, citationTemplate) : fact.content;
8244
- const hashRegisterKey = writeCategory === "procedure" ? buildProcedurePersistBody(fact.content, fact.procedureSteps) : canonicalFactContent;
8245
- if (!tombstoneBlocked) {
8246
- await this.deps.addContentHashDedup(targetStorage, hashRegisterKey);
8247
- }
8248
- } catch (err) {
8249
- log.warn(
8250
- `content-hash dedup registration failed for memory ${memoryId}: ${err}`
8251
- );
8252
- }
8253
8252
  } catch (err) {
8254
8253
  await finalizeCommittedWrites(true).catch(
8255
8254
  (finalizeErr) => log.warn(`committed-write finalization after post-write failure failed: ${finalizeErr}`)
@@ -31777,4 +31776,4 @@ export {
31777
31776
  qmdStartupCollectionChecksWithTimeout,
31778
31777
  Orchestrator
31779
31778
  };
31780
- //# sourceMappingURL=chunk-LFYEQK45.js.map
31779
+ //# sourceMappingURL=chunk-FAF4A76Q.js.map