opencode-swarm 7.166.1 → 7.166.2

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.
Files changed (93) hide show
  1. package/binaries/win32-arm64/swarm-sandbox-runner.exe +0 -0
  2. package/binaries/win32-x64/swarm-sandbox-runner.exe +0 -0
  3. package/dist/background/candidate-contract.d.ts +14 -0
  4. package/dist/background/pr-subscriptions.d.ts +33 -1
  5. package/dist/background/workspace-snapshot.d.ts +41 -0
  6. package/dist/cli/{coder-settlement-x0h3h6vd.js → coder-settlement-pv86n7n4.js} +13 -13
  7. package/dist/cli/{config-doctor-pjcjeh8f.js → config-doctor-fy1aytwt.js} +4 -4
  8. package/dist/cli/{core-v11pd1yk.js → core-1d9vqbt4.js} +2 -2
  9. package/dist/cli/{curation-policy-jtzwz6bc.js → curation-policy-gnpgc3z7.js} +7 -5
  10. package/dist/cli/{curator-ssvd7evd.js → curator-a4rbehfr.js} +39 -39
  11. package/dist/cli/{curator-drift-jpdfwae9.js → curator-drift-efmgp1v2.js} +6 -6
  12. package/dist/cli/curator-llm-factory-cwg62ynw.js +70 -0
  13. package/dist/cli/{dispatch-591v13pp.js → dispatch-tmb929w8.js} +2 -2
  14. package/dist/cli/{evidence-summary-service-mw6tnsp9.js → evidence-summary-service-dvp1kbm4.js} +17 -17
  15. package/dist/cli/{gate-evidence-jymaxb82.js → gate-evidence-qf27gdfx.js} +9 -8
  16. package/dist/cli/guardrail-explain-zskpzgsr.js +71 -0
  17. package/dist/cli/{guardrail-log-kzq2sktb.js → guardrail-log-qhw3knjt.js} +9 -9
  18. package/dist/cli/{guardrail-reset-ea1g3g7d.js → guardrail-reset-84ydxdg3.js} +39 -39
  19. package/dist/cli/{hive-promoter-ghjbgsms.js → hive-promoter-y2daybf6.js} +39 -39
  20. package/dist/cli/{index-52xdezsh.js → index-0a0jsbhg.js} +5 -5
  21. package/dist/cli/{index-a7rw4g4s.js → index-14z9en94.js} +3 -3
  22. package/dist/cli/{index-gy0nyfbw.js → index-19hjpqsy.js} +61 -16
  23. package/dist/cli/{index-bkd3450m.js → index-22sannyk.js} +7 -7
  24. package/dist/cli/{index-8fr2wn18.js → index-2n1v8ft1.js} +1 -1
  25. package/dist/cli/{index-zha9bdj9.js → index-3nww2vnx.js} +11 -11
  26. package/dist/cli/{index-gr8ppbq3.js → index-3wtfrjcx.js} +3 -3
  27. package/dist/cli/{index-bfr392e7.js → index-4kwxpnf8.js} +13 -6
  28. package/dist/cli/{index-xwkn5hse.js → index-7mxrqy4r.js} +7 -7
  29. package/dist/cli/{index-jx9f4ke1.js → index-7pp8fz4j.js} +1 -1
  30. package/dist/cli/{index-6rff2h8x.js → index-8nv3bc9h.js} +4 -4
  31. package/dist/cli/{index-2y4kargd.js → index-9ccxcjdm.js} +4 -4
  32. package/dist/cli/{index-hwj25q9r.js → index-bks56jbg.js} +70 -53
  33. package/dist/cli/{index-8hqkrd2j.js → index-bysyj3z4.js} +1 -1
  34. package/dist/cli/{index-yt25kpvz.js → index-c0eyq4rp.js} +4 -4
  35. package/dist/cli/{index-c20gf089.js → index-c23w8t46.js} +1 -1
  36. package/dist/cli/{index-wf12wckd.js → index-e0bjbadr.js} +1 -1
  37. package/dist/cli/{index-axf65x87.js → index-fkk7x6sy.js} +5 -5
  38. package/dist/cli/{index-17yszqs5.js → index-ft1tnx0e.js} +1 -1
  39. package/dist/cli/{index-399nq780.js → index-gy55mc55.js} +285 -177
  40. package/dist/cli/{index-k5w284js.js → index-hbjax6hy.js} +17 -17
  41. package/dist/cli/{index-2v17wb75.js → index-hgphhnrp.js} +2 -2
  42. package/dist/cli/{index-hvk3zs62.js → index-j81kpway.js} +1 -1
  43. package/dist/cli/{index-066xxa4q.js → index-jgtje76m.js} +7 -7
  44. package/dist/cli/{index-xezfx7ge.js → index-jr6tppv9.js} +47 -13
  45. package/dist/cli/{index-nph5g4em.js → index-kd68b6mg.js} +2 -2
  46. package/dist/cli/{index-crjx4sx0.js → index-nrdj94za.js} +41 -41
  47. package/dist/cli/{index-79sr3fd1.js → index-nthqfxzz.js} +2 -2
  48. package/dist/cli/{index-6chhqq2n.js → index-p0r5fn7y.js} +94 -3
  49. package/dist/cli/{index-fc1dqzjp.js → index-qmp4gxac.js} +1 -1
  50. package/dist/cli/{index-j29nkq5d.js → index-st47knj6.js} +4 -4
  51. package/dist/cli/{index-edm41q4j.js → index-sxe3t040.js} +2 -2
  52. package/dist/cli/{index-w11whwn3.js → index-sxsyd7kf.js} +9 -9
  53. package/dist/cli/{index-13egyjgv.js → index-ty0wg9yp.js} +5 -5
  54. package/dist/cli/{index-0g5v4s0x.js → index-wz258yje.js} +14 -14
  55. package/dist/cli/{index-ybcxvv17.js → index-x4azb6qj.js} +2 -2
  56. package/dist/cli/{index-1zqf2pny.js → index-x8cvbkjs.js} +2 -2
  57. package/dist/cli/{index-aftapk6j.js → index-y3dtdn2f.js} +3 -3
  58. package/dist/cli/{index-gerkwyrr.js → index-ytsts0zj.js} +1 -1
  59. package/dist/cli/{index-3tyym20r.js → index-z1kmkh72.js} +2 -2
  60. package/dist/cli/index.js +39 -39
  61. package/dist/cli/{knowledge-escalator-3pjed4tq.js → knowledge-escalator-aq7gzhpd.js} +14 -14
  62. package/dist/cli/{knowledge-events-a5dwkg30.js → knowledge-events-9z5sskyv.js} +12 -12
  63. package/dist/cli/{knowledge-link-1zykfk1p.js → knowledge-link-ps2v4s18.js} +6 -4
  64. package/dist/cli/{knowledge-store-h85efsak.js → knowledge-store-1hzt2a0t.js} +7 -5
  65. package/dist/cli/{knowledge-validator-76qrf1ev.js → knowledge-validator-xe1fza7c.js} +9 -7
  66. package/dist/cli/{pending-delegations-zgwfqfac.js → pending-delegations-0nfjg7vp.js} +13 -13
  67. package/dist/cli/{pr-subscriptions-fzy3ks1k.js → pr-subscriptions-8974hwa0.js} +19 -13
  68. package/dist/cli/{pr-workflow-gate-1gtsn7f0.js → pr-workflow-gate-xgak5wvz.js} +39 -39
  69. package/dist/cli/{runner-j3acybhs.js → runner-7zqbp81n.js} +8 -5
  70. package/dist/cli/{scan-cursor-ahwkxa8j.js → scan-cursor-hc4v0c90.js} +8 -6
  71. package/dist/cli/{schema-27sedbfk.js → schema-w1hsvw1h.js} +2 -2
  72. package/dist/cli/{scope-persistence-q792yfxh.js → scope-persistence-k17003v4.js} +16 -15
  73. package/dist/cli/{skill-generator-g8wbjw6v.js → skill-generator-tbxgpc9x.js} +16 -16
  74. package/dist/cli/{snapshot-coordination-init-y6spakwm.js → snapshot-coordination-init-vaf34wf0.js} +39 -39
  75. package/dist/cli/{telemetry-9h1z2w9d.js → telemetry-8qn4eag5.js} +5 -1
  76. package/dist/cli/{workspace-snapshot-6z9rk7xw.js → workspace-snapshot-y85jy6gs.js} +11 -1
  77. package/dist/cli/{worktree-collision-ownership-pmpnftkd.js → worktree-collision-ownership-r3jdke7h.js} +14 -14
  78. package/dist/cli/{worktree-isolation-4053n0px.js → worktree-isolation-sa1tbqff.js} +39 -39
  79. package/dist/evidence/phase-participation.d.ts +1 -1
  80. package/dist/hooks/guardrails/execution-stall.d.ts +10 -5
  81. package/dist/hooks/hive-promoter.d.ts +28 -5
  82. package/dist/hooks/repo-graph-builder.d.ts +14 -0
  83. package/dist/hooks/system-enhancer.d.ts +21 -0
  84. package/dist/index.js +124 -122
  85. package/dist/observability/catalog.d.ts +1 -1
  86. package/dist/session/snapshot-writer.d.ts +42 -0
  87. package/dist/telemetry.d.ts +31 -1
  88. package/dist/utils/atomic-write.d.ts +32 -0
  89. package/dist/utils/swarm-artifact-cache.d.ts +6 -0
  90. package/package.json +1 -1
  91. package/dist/cli/curator-llm-factory-da5q3gg6.js +0 -70
  92. package/dist/cli/guardrail-explain-eva1yrtf.js +0 -71
  93. package/dist/cli/{index-2sqgbmtq.js → index-d5qf7hvh.js} +3 -3
@@ -8,7 +8,7 @@ import {
8
8
  isCommandAvailable,
9
9
  resolveLocalNodeTool,
10
10
  tool
11
- } from "./index-2sqgbmtq.js";
11
+ } from "./index-d5qf7hvh.js";
12
12
  import {
13
13
  captureWorkingTreeFingerprint,
14
14
  createModelEvaluationExecutor,
@@ -16,7 +16,7 @@ import {
16
16
  resolveExecutableFromPath,
17
17
  runEvaluation,
18
18
  runExternalTool
19
- } from "./index-hvk3zs62.js";
19
+ } from "./index-j81kpway.js";
20
20
  import {
21
21
  finalizeShellAuditForClose,
22
22
  isPolicyProtectedPath,
@@ -25,13 +25,13 @@ import {
25
25
  protectedRoots,
26
26
  redactDecisionLineForArchive,
27
27
  stableCanonicalStringify
28
- } from "./index-gr8ppbq3.js";
28
+ } from "./index-3wtfrjcx.js";
29
29
  import {
30
30
  detectStraySwarmDirs,
31
31
  readDoctorArtifact,
32
32
  removeStraySwarmDir,
33
33
  runConfigDoctor
34
- } from "./index-8fr2wn18.js";
34
+ } from "./index-2n1v8ft1.js";
35
35
  import {
36
36
  MAX_TRANSIENT_RETRIES,
37
37
  archiveEvidence,
@@ -72,7 +72,7 @@ import {
72
72
  updateTaskCheckpointReceipt,
73
73
  updateTaskStatus,
74
74
  validateProjectRoot
75
- } from "./index-0g5v4s0x.js";
75
+ } from "./index-wz258yje.js";
76
76
  import {
77
77
  EvaluationTaskV1Schema,
78
78
  GateAuditManifestV1Schema,
@@ -89,7 +89,7 @@ import {
89
89
  saveGateAuditResult,
90
90
  savePromotionDecision,
91
91
  saveTaskSetSnapshot
92
- } from "./index-17yszqs5.js";
92
+ } from "./index-ft1tnx0e.js";
93
93
  import {
94
94
  canonicalHash,
95
95
  canonicalJson,
@@ -128,15 +128,15 @@ import {
128
128
  retireSkill,
129
129
  selectCandidateEntries,
130
130
  syncBundledProjectSkillsIfMissingAsync
131
- } from "./index-066xxa4q.js";
131
+ } from "./index-jgtje76m.js";
132
132
  import {
133
133
  readRecentEscalations
134
- } from "./index-13egyjgv.js";
134
+ } from "./index-ty0wg9yp.js";
135
135
  import {
136
136
  alreadyCuratedThisGeneration,
137
137
  claimNextScanBatch,
138
138
  resolveCohortId
139
- } from "./index-ybcxvv17.js";
139
+ } from "./index-x4azb6qj.js";
140
140
  import {
141
141
  CURATOR_INIT_PROMPT,
142
142
  CURATOR_PHASE_PROMPT,
@@ -148,7 +148,7 @@ import {
148
148
  getGlobalEventBus,
149
149
  getGroupCommitWriter,
150
150
  importLegacyJsonl
151
- } from "./index-8hqkrd2j.js";
151
+ } from "./index-bysyj3z4.js";
152
152
  import {
153
153
  buildOpenSpecProjectionSync,
154
154
  detectSpeckit,
@@ -167,7 +167,7 @@ import {
167
167
  sweepStale,
168
168
  unsubscribe,
169
169
  updateSnapshot
170
- } from "./index-xezfx7ge.js";
170
+ } from "./index-jr6tppv9.js";
171
171
  import {
172
172
  clearWorktreeMergeStatus,
173
173
  getAllWorktreeMergeFailures,
@@ -179,7 +179,7 @@ import {
179
179
  listCoderSettlementWalStates,
180
180
  recoverCoderSettlement,
181
181
  recoverStaleCoderSettlements
182
- } from "./index-k5w284js.js";
182
+ } from "./index-hbjax6hy.js";
183
183
  import {
184
184
  parsePorcelainV2Snapshot,
185
185
  resolveCommitCountSince,
@@ -207,12 +207,12 @@ import {
207
207
  resolveRemoteUrlIdentity,
208
208
  resolveRemoteUrlIdentityAsync,
209
209
  switchPrFeedbackTrackingCandidateAsync
210
- } from "./index-6chhqq2n.js";
210
+ } from "./index-p0r5fn7y.js";
211
211
  import {
212
212
  WORKTREE_LIFECYCLE_LOCK_FILE,
213
213
  recordWorktreeProvisioningOwner,
214
214
  removeWorktreeProvisioningOwner
215
- } from "./index-1zqf2pny.js";
215
+ } from "./index-x8cvbkjs.js";
216
216
  import {
217
217
  getLanguageForExtension
218
218
  } from "./index-b43rt5ph.js";
@@ -248,13 +248,13 @@ import {
248
248
  transitionTaskWorkflowEvidence,
249
249
  withTaskEvidenceTransaction,
250
250
  writeWorkflowWalFile
251
- } from "./index-yt25kpvz.js";
251
+ } from "./index-c0eyq4rp.js";
252
252
  import {
253
253
  isPathUnderSwarmWorktreeBase,
254
254
  makeWorktreeBranchName,
255
255
  provisionWorktree,
256
256
  removeWorktree
257
- } from "./index-fc1dqzjp.js";
257
+ } from "./index-qmp4gxac.js";
258
258
  import {
259
259
  DEFAULT_STALE_DELEGATION_TIMEOUT_MS,
260
260
  DELEGATION_COMPACTION_HIGH_WATER_BYTES,
@@ -288,7 +288,7 @@ import {
288
288
  scanBackgroundCoderReservationsForAdmission,
289
289
  scanDelegationsForRecovery,
290
290
  sweepStaleDelegations
291
- } from "./index-w11whwn3.js";
291
+ } from "./index-sxsyd7kf.js";
292
292
  import {
293
293
  MAX_EVENT_LOG_ENTRIES,
294
294
  _internals,
@@ -304,13 +304,13 @@ import {
304
304
  recordKnowledgeEvent,
305
305
  recordPhaseCloseIntent,
306
306
  resolveKnowledgeEventsPath
307
- } from "./index-zha9bdj9.js";
307
+ } from "./index-3nww2vnx.js";
308
308
  import {
309
309
  estimateTokens,
310
310
  readSwarmFileAsync,
311
311
  safeHook,
312
312
  validateSwarmPath
313
- } from "./index-bfr392e7.js";
313
+ } from "./index-4kwxpnf8.js";
314
314
  import {
315
315
  bunFile,
316
316
  bunSpawn,
@@ -330,17 +330,17 @@ import {
330
330
  validateActionableFields,
331
331
  validateLesson,
332
332
  validateSkillPath
333
- } from "./index-6rff2h8x.js";
333
+ } from "./index-8nv3bc9h.js";
334
334
  import {
335
335
  authorizeCuration,
336
336
  buildConfigFingerprintInput
337
- } from "./index-c20gf089.js";
337
+ } from "./index-c23w8t46.js";
338
338
  import {
339
339
  cohortConfigFingerprint
340
340
  } from "./index-rtry5xyf.js";
341
341
  import {
342
342
  resolveWorktreeIsolationConfig
343
- } from "./index-nph5g4em.js";
343
+ } from "./index-kd68b6mg.js";
344
344
  import {
345
345
  RetrospectiveEvidenceSchema
346
346
  } from "./index-3qf1vxtb.js";
@@ -350,7 +350,7 @@ import {
350
350
  clearAllScopes,
351
351
  clearScopeBindingFromDisk,
352
352
  clearScopeBindings
353
- } from "./index-xwkn5hse.js";
353
+ } from "./index-7mxrqy4r.js";
354
354
  import {
355
355
  appendLedgerEvent,
356
356
  computePlanLedgerHash,
@@ -363,7 +363,7 @@ import {
363
363
  readPlanEpochIdentity,
364
364
  replayFromLedgerWithStatus,
365
365
  takeSnapshotEvent
366
- } from "./index-2y4kargd.js";
366
+ } from "./index-9ccxcjdm.js";
367
367
  import {
368
368
  CORE_EVENT_LOCKED,
369
369
  appendCoreEventSync,
@@ -373,7 +373,7 @@ import {
373
373
  hasSpecDriftAuditEvent,
374
374
  hasTaskRepairAuditEvent,
375
375
  readCoreEvents
376
- } from "./index-2v17wb75.js";
376
+ } from "./index-hgphhnrp.js";
377
377
  import {
378
378
  DEFAULT_QA_GATES,
379
379
  computeProfileHash,
@@ -381,7 +381,7 @@ import {
381
381
  getEffectiveGates,
382
382
  getProfileLookupForIdentity,
383
383
  setGatesForIdentity
384
- } from "./index-79sr3fd1.js";
384
+ } from "./index-nthqfxzz.js";
385
385
  import {
386
386
  MAX_COORDINATION_STATE_LIST_ROWS,
387
387
  deleteCoordinationImports,
@@ -393,7 +393,7 @@ import {
393
393
  listCoordinationStates,
394
394
  transitionCoordinationState,
395
395
  withCoordinationTransaction
396
- } from "./index-jx9f4ke1.js";
396
+ } from "./index-7pp8fz4j.js";
397
397
  import {
398
398
  DURABILITY_CLASSES,
399
399
  closeAllProjectDbs,
@@ -401,7 +401,7 @@ import {
401
401
  getProjectDb,
402
402
  projectDbExists,
403
403
  projectDbPath
404
- } from "./index-aftapk6j.js";
404
+ } from "./index-y3dtdn2f.js";
405
405
  import {
406
406
  canonicalExistingFilesystemPath,
407
407
  canonicalPathForFutureIo,
@@ -416,7 +416,7 @@ import {
416
416
  observeCuratorCompliance,
417
417
  observeStoreHealth,
418
418
  readLearningHealth
419
- } from "./index-axf65x87.js";
419
+ } from "./index-fkk7x6sy.js";
420
420
  import {
421
421
  appendKnowledge,
422
422
  appendRejectedLesson,
@@ -446,7 +446,7 @@ import {
446
446
  transactFile,
447
447
  transactKnowledge,
448
448
  wordBigrams
449
- } from "./index-bkd3450m.js";
449
+ } from "./index-22sannyk.js";
450
450
  import {
451
451
  resolveHiveDataDir,
452
452
  resolveHiveEventsPath,
@@ -462,14 +462,7 @@ import {
462
462
  resolveLinkDir,
463
463
  sanitizeLinkId,
464
464
  writeLinkPointer
465
- } from "./index-a7rw4g4s.js";
466
- import {
467
- canonicalRootKeyFresh,
468
- compositeSessionKey,
469
- lexicalRootAliasKey,
470
- sameProjectRoot,
471
- sessionKeySuffix
472
- } from "./index-7qefgq4j.js";
465
+ } from "./index-14z9en94.js";
473
466
  import {
474
467
  assertProjectRoot,
475
468
  atomicWriteFile,
@@ -478,7 +471,7 @@ import {
478
471
  listActiveLocks,
479
472
  tryAcquireLock,
480
473
  withEvidenceLock
481
- } from "./index-edm41q4j.js";
474
+ } from "./index-sxe3t040.js";
482
475
  import {
483
476
  atomicWriteSwarmFile,
484
477
  atomicWriteSwarmFileSync,
@@ -486,13 +479,21 @@ import {
486
479
  matchTempGrammar,
487
480
  parseTargetBasename,
488
481
  resetSwarmArtifactCache
489
- } from "./index-gy0nyfbw.js";
482
+ } from "./index-19hjpqsy.js";
490
483
  import {
491
484
  emit,
492
485
  extractWorkflowIds,
493
486
  getLastHeartbeat,
494
487
  telemetry
495
- } from "./index-hwj25q9r.js";
488
+ } from "./index-bks56jbg.js";
489
+ import {
490
+ canonicalRootKey,
491
+ canonicalRootKeyFresh,
492
+ compositeSessionKey,
493
+ lexicalRootAliasKey,
494
+ sameProjectRoot,
495
+ sessionKeySuffix
496
+ } from "./index-7qefgq4j.js";
496
497
  import {
497
498
  require_proper_lockfile
498
499
  } from "./index-7g4c7s5r.js";
@@ -503,7 +504,7 @@ import {
503
504
  loadGateOverrides,
504
505
  loadPluginConfig,
505
506
  loadPluginConfigWithMeta
506
- } from "./index-52xdezsh.js";
507
+ } from "./index-0a0jsbhg.js";
507
508
  import {
508
509
  init_git_executable,
509
510
  resolveGitExecutable,
@@ -530,7 +531,7 @@ import {
530
531
  resolveAutoReviewConfig,
531
532
  resolveGeneratedAgentRole,
532
533
  stripKnownSwarmPrefix
533
- } from "./index-wf12wckd.js";
534
+ } from "./index-e0bjbadr.js";
534
535
  import {
535
536
  AGENT_TOOL_MAP,
536
537
  ALL_AGENT_NAMES,
@@ -583,7 +584,7 @@ import {
583
584
 
584
585
  // src/hooks/delegation-gate/worktree-isolation.ts
585
586
  init_constants();
586
- import { createHash as createHash39 } from "crypto";
587
+ import { createHash as createHash40 } from "crypto";
587
588
  import * as fs57 from "fs/promises";
588
589
  import * as path123 from "path";
589
590
  init_executor();
@@ -6966,12 +6967,13 @@ async function commitTaskTerminalUnderPlanLock(options) {
6966
6967
 
6967
6968
  // src/hooks/pr-workflow-gate.ts
6968
6969
  init_zod();
6969
- import { createHash as createHash11, randomUUID as randomUUID4 } from "crypto";
6970
+ import { createHash as createHash12, randomUUID as randomUUID4 } from "crypto";
6970
6971
  import { readFileSync as readFileSync6, statSync as statSync5 } from "fs";
6971
6972
  import * as fsp5 from "fs/promises";
6972
6973
  import * as path15 from "path";
6973
6974
 
6974
6975
  // src/background/candidate-contract.ts
6976
+ import { createHash as createHash4 } from "crypto";
6975
6977
  var CANDIDATE_SEVERITIES = [
6976
6978
  "INFO",
6977
6979
  "LOW",
@@ -7413,6 +7415,31 @@ function normalizeCandidateArtifact(rawText, fallbackFamily) {
7413
7415
  repairKinds
7414
7416
  };
7415
7417
  }
7418
+ var CANDIDATE_ARTIFACT_CACHE_CAPACITY = 512;
7419
+ var candidateArtifactCache = new Map;
7420
+ var candidateArtifactCacheHits = 0;
7421
+ var candidateArtifactCacheMisses = 0;
7422
+ function candidateArtifactCacheKey(rawText, fallbackFamily) {
7423
+ return createHash4("sha256").update(`${rawText}\x00${fallbackFamily}`).digest("hex");
7424
+ }
7425
+ function normalizeCandidateArtifactCached(rawText, fallbackFamily) {
7426
+ const key = candidateArtifactCacheKey(rawText, fallbackFamily);
7427
+ const hit = candidateArtifactCache.get(key);
7428
+ if (hit !== undefined) {
7429
+ candidateArtifactCacheHits++;
7430
+ return hit;
7431
+ }
7432
+ candidateArtifactCacheMisses++;
7433
+ const result = normalizeCandidateArtifact(rawText, fallbackFamily);
7434
+ if (candidateArtifactCache.size >= CANDIDATE_ARTIFACT_CACHE_CAPACITY) {
7435
+ const oldest = candidateArtifactCache.keys().next().value;
7436
+ if (oldest !== undefined) {
7437
+ candidateArtifactCache.delete(oldest);
7438
+ }
7439
+ }
7440
+ candidateArtifactCache.set(key, result);
7441
+ return result;
7442
+ }
7416
7443
  function analyzeCandidateLaneContext(context) {
7417
7444
  const issues = [];
7418
7445
  const baseBound = Boolean(context.expected_lane || context.expected_lanes);
@@ -8284,7 +8311,7 @@ ${trimmed}`;
8284
8311
 
8285
8312
  // src/background/lane-output-store.ts
8286
8313
  init_zod();
8287
- import { createHash as createHash4 } from "crypto";
8314
+ import { createHash as createHash5 } from "crypto";
8288
8315
  import {
8289
8316
  existsSync as existsSync7,
8290
8317
  mkdirSync as mkdirSync4,
@@ -8359,12 +8386,12 @@ function hasValidArtifactIntegrity(artifact, expectedRef) {
8359
8386
  return artifact.ref === expectedRef && artifact.ref === expectedArtifactRef;
8360
8387
  }
8361
8388
  function digestText(text) {
8362
- return createHash4("sha256").update(text).digest("hex");
8389
+ return createHash5("sha256").update(text).digest("hex");
8363
8390
  }
8364
8391
 
8365
8392
  // src/background/pr-review-trigger-contract.ts
8366
8393
  init_zod();
8367
- import { createHash as createHash5 } from "crypto";
8394
+ import { createHash as createHash6 } from "crypto";
8368
8395
  var PR_REVIEW_TRIGGER_DEFINITIONS = [
8369
8396
  {
8370
8397
  id: "auth-identity-secrets",
@@ -8681,7 +8708,7 @@ function prReviewTriggerLedgerDigest(rows) {
8681
8708
  row.result,
8682
8709
  row.evidence
8683
8710
  ]);
8684
- return createHash5("sha256").update(JSON.stringify(canonical)).digest("hex");
8711
+ return createHash6("sha256").update(JSON.stringify(canonical)).digest("hex");
8685
8712
  }
8686
8713
  function parsedReceipt(schemaVersion, rows, coverageDegradations = [], baseVerification) {
8687
8714
  return {
@@ -8948,7 +8975,7 @@ var _internals14 = {
8948
8975
  };
8949
8976
 
8950
8977
  // src/memory/redaction.ts
8951
- import { createHash as createHash6 } from "crypto";
8978
+ import { createHash as createHash7 } from "crypto";
8952
8979
  var SECRET_PATTERNS = [
8953
8980
  { type: "openai_api_key", pattern: /\bsk-[A-Za-z0-9_-]{20,}\b/g },
8954
8981
  {
@@ -9010,7 +9037,7 @@ function classifyStoredFingerprintAlgorithmVersion(rawStoredVersion, currentVers
9010
9037
  }
9011
9038
  function computeMemoryCohortFingerprint(input) {
9012
9039
  const canonical = stableCanonicalStringify(input);
9013
- return createHash6("sha256").update(canonical).digest("hex").slice(0, 12);
9040
+ return createHash7("sha256").update(canonical).digest("hex").slice(0, 12);
9014
9041
  }
9015
9042
  function buildMemoryCohortFingerprintInput(config) {
9016
9043
  return {
@@ -9051,12 +9078,12 @@ function redactSecrets(text) {
9051
9078
 
9052
9079
  // src/pr-review/authorization.ts
9053
9080
  init_zod();
9054
- import { createHash as createHash8, randomUUID as randomUUID3 } from "crypto";
9081
+ import { createHash as createHash9, randomUUID as randomUUID3 } from "crypto";
9055
9082
  import * as fsp3 from "fs/promises";
9056
9083
  import * as path13 from "path";
9057
9084
 
9058
9085
  // src/pr-review/persistence.ts
9059
- import { createHash as createHash7, randomUUID as randomUUID2 } from "crypto";
9086
+ import { createHash as createHash8, randomUUID as randomUUID2 } from "crypto";
9060
9087
  import * as fsp2 from "fs/promises";
9061
9088
  import * as path12 from "path";
9062
9089
  function normalizeSessionID(sessionID) {
@@ -9069,7 +9096,7 @@ function normalizeSessionID(sessionID) {
9069
9096
  function prWorkflowSessionFileStem(sessionID) {
9070
9097
  const normalized = normalizeSessionID(sessionID);
9071
9098
  const slug = normalized.replace(/[^A-Za-z0-9_.-]/g, "_").slice(0, 80) || "session";
9072
- const digest2 = createHash7("sha256").update(normalized).digest("hex").slice(0, 12);
9099
+ const digest2 = createHash8("sha256").update(normalized).digest("hex").slice(0, 12);
9073
9100
  return `${slug}-${digest2}`;
9074
9101
  }
9075
9102
  var WORKFLOW_GATE_DIR = "pr-workflow-gates";
@@ -9455,13 +9482,13 @@ async function importLegacyPrWorkflowGateStateIfNeeded(directory, sessionID, all
9455
9482
  return null;
9456
9483
  throw error2;
9457
9484
  }
9458
- const legacy = allowSalvagedImport ? (await (await import("./pr-workflow-gate-1gtsn7f0.js")).readPrWorkflowGateStateForRecovery(directory, sessionID))?.state ?? null : await readPrWorkflowGateStateFileFromDisk(filePath, sessionID);
9485
+ const legacy = allowSalvagedImport ? (await (await import("./pr-workflow-gate-xgak5wvz.js")).readPrWorkflowGateStateForRecovery(directory, sessionID))?.state ?? null : await readPrWorkflowGateStateFileFromDisk(filePath, sessionID);
9459
9486
  if (!legacy)
9460
9487
  return null;
9461
9488
  const namespace = workflowGateStateCoordinationNamespace(sessionID);
9462
9489
  const outcome = importCoordinationOnce(directory, {
9463
9490
  source: workflowGateStateRelativePath(sessionID),
9464
- sourceDigest: createHash7("sha256").update(raw).digest("hex"),
9491
+ sourceDigest: createHash8("sha256").update(raw).digest("hex"),
9465
9492
  rowCount: 1,
9466
9493
  emptyNamespace: namespace
9467
9494
  }, () => {
@@ -9525,7 +9552,7 @@ async function deleteStateWhileLocked(directory, sessionID, options = {}) {
9525
9552
  let recoveryState = null;
9526
9553
  if (!currentAuthoritative) {
9527
9554
  if (options.allowSalvagedRead) {
9528
- const { readPrWorkflowGateStateForRecovery } = await import("./pr-workflow-gate-1gtsn7f0.js");
9555
+ const { readPrWorkflowGateStateForRecovery } = await import("./pr-workflow-gate-xgak5wvz.js");
9529
9556
  recoveryState = (await readPrWorkflowGateStateForRecovery(directory, normalizedSessionID))?.state ?? null;
9530
9557
  }
9531
9558
  if (!recoveryState) {
@@ -10130,7 +10157,7 @@ async function readAuthorizationsAuthoritative(directory, sessionID) {
10130
10157
  return null;
10131
10158
  const outcome = importCoordinationOnce(directory, {
10132
10159
  source: path13.join("pr-review", "reentry-authorizations", `${prWorkflowSessionFileStem(sessionID)}.json`),
10133
- sourceDigest: createHash8("sha256").update(raw).digest("hex"),
10160
+ sourceDigest: createHash9("sha256").update(raw).digest("hex"),
10134
10161
  rowCount: legacy.authorizations.length,
10135
10162
  emptyNamespace: reentryAuthorizationCoordinationNamespace(sessionID)
10136
10163
  }, () => {
@@ -10556,7 +10583,7 @@ function rollbackPrReviewCircuitProbe(circuit, nowMs, openDurationMs) {
10556
10583
 
10557
10584
  // src/pr-review/completion.ts
10558
10585
  init_zod();
10559
- import { createHash as createHash9 } from "crypto";
10586
+ import { createHash as createHash10 } from "crypto";
10560
10587
  import { readFileSync as readFileSync5 } from "fs";
10561
10588
  import * as fsp4 from "fs/promises";
10562
10589
  import * as path14 from "path";
@@ -10985,7 +11012,7 @@ async function readAndVerifyCoverageDisclosure(directory, state) {
10985
11012
  throw new Error("BLOCKED: PR_REVIEW partial base coverage disclosure path does not match its bound run");
10986
11013
  }
10987
11014
  const raw = await readBoundedSwarmRegularFile(directory, relativePath, PR_REVIEW_COVERAGE_DISCLOSURE_MAX_BYTES, "PR_REVIEW partial base coverage disclosure");
10988
- const digest2 = createHash9("sha256").update(raw, "utf8").digest("hex");
11015
+ const digest2 = createHash10("sha256").update(raw, "utf8").digest("hex");
10989
11016
  if (digest2 !== expectedDigest) {
10990
11017
  throw new Error("BLOCKED: PR_REVIEW partial base coverage disclosure digest does not match durable state");
10991
11018
  }
@@ -11092,7 +11119,7 @@ async function admitPrReviewPartialBaseCoverage(directory, sessionID, runId, unr
11092
11119
  throw error2;
11093
11120
  }
11094
11121
  }
11095
- const digest2 = createHash9("sha256").update(raw, "utf8").digest("hex");
11122
+ const digest2 = createHash10("sha256").update(raw, "utf8").digest("hex");
11096
11123
  try {
11097
11124
  return await writeStateWhileLocked(directory, {
11098
11125
  ...state,
@@ -11122,7 +11149,7 @@ async function rollbackPrReviewPartialBaseCoverageAdmission(directory, sessionID
11122
11149
  const absolutePath = validateSwarmPath(directory, options.relativePath);
11123
11150
  try {
11124
11151
  const raw = await fsp4.readFile(absolutePath, "utf8");
11125
- const digest2 = createHash9("sha256").update(raw, "utf8").digest("hex");
11152
+ const digest2 = createHash10("sha256").update(raw, "utf8").digest("hex");
11126
11153
  if (digest2 !== options.digest)
11127
11154
  return false;
11128
11155
  } catch (error2) {
@@ -11184,7 +11211,7 @@ async function readPrReviewTerminalCoverageForReport(directory, sessionID) {
11184
11211
  }
11185
11212
 
11186
11213
  // src/pr-review/legacy-transcript-adapter.ts
11187
- import { createHash as createHash10 } from "crypto";
11214
+ import { createHash as createHash11 } from "crypto";
11188
11215
  init_logger();
11189
11216
  var gateHelpers2;
11190
11217
  function bindPrReviewTranscriptAdapterHelpers(helpers) {
@@ -11373,7 +11400,7 @@ function validateReviewerVerdictFields(fields) {
11373
11400
  return parsed.success ? [...parsed.data] : null;
11374
11401
  }
11375
11402
  function reviewerVerdictRowDigest(fields) {
11376
- return createHash10("sha256").update(fields.join("\x00")).digest("hex");
11403
+ return createHash11("sha256").update(fields.join("\x00")).digest("hex");
11377
11404
  }
11378
11405
  function parseLaneItemVerdicts(text, itemIds, phase, reviewerClaims) {
11379
11406
  return parsePrReviewVerdictRows(text, itemIds, phase, reviewerClaims).parsed;
@@ -14438,7 +14465,7 @@ async function recordPrFeedbackStageA(directory, sessionID, revisionDigest, chec
14438
14465
  throw new Error(`BLOCKED: PR_FEEDBACK Stage A obligation ${obligation.id} requires exact validator contract provenance`);
14439
14466
  }
14440
14467
  }
14441
- const commandDigest = createHash11("sha256").update(`${check.obligationId ?? check.category}\x00${check.workingDirectory ?? "."}\x00${check.command.join("\x00")}`).digest("hex");
14468
+ const commandDigest = createHash12("sha256").update(`${check.obligationId ?? check.category}\x00${check.workingDirectory ?? "."}\x00${check.command.join("\x00")}`).digest("hex");
14442
14469
  if (commandDigests.has(commandDigest)) {
14443
14470
  throw new Error("BLOCKED: PR_FEEDBACK Stage A cannot reuse one command as multiple check receipts");
14444
14471
  }
@@ -15299,7 +15326,7 @@ function parseExactBoundPushIntent(command, armed) {
15299
15326
  return {
15300
15327
  ok: true,
15301
15328
  intent,
15302
- digest: createHash11("sha256").update(JSON.stringify(intent), "utf8").digest("hex")
15329
+ digest: createHash12("sha256").update(JSON.stringify(intent), "utf8").digest("hex")
15303
15330
  };
15304
15331
  }
15305
15332
  async function admitPrFeedbackPushAttempt(directory, sessionID, callID, intent, intentDigest) {
@@ -16057,7 +16084,7 @@ async function findOwnedPrReviewRunReservations(directory, sessionID, workflowIn
16057
16084
  return owned.sort();
16058
16085
  }
16059
16086
  function hashPrReviewFindingIds(ids) {
16060
- return createHash11("sha256").update([...new Set(ids)].sort().join("\x00"), "utf8").digest("hex");
16087
+ return createHash12("sha256").update([...new Set(ids)].sort().join("\x00"), "utf8").digest("hex");
16061
16088
  }
16062
16089
  async function readPrReviewRunReservation(directory, runId) {
16063
16090
  try {
@@ -16172,7 +16199,7 @@ async function readPrReviewFeedbackHandoffArtifact(directory, relativePath) {
16172
16199
  }
16173
16200
  return {
16174
16201
  artifact: parsed.data,
16175
- digest: createHash11("sha256").update(raw, "utf8").digest("hex")
16202
+ digest: createHash12("sha256").update(raw, "utf8").digest("hex")
16176
16203
  };
16177
16204
  }
16178
16205
  var PrReviewFindingProjectionSchema = exports_external.object({
@@ -16233,7 +16260,7 @@ function assertMatchingPrReviewFeedbackConsent(record, input) {
16233
16260
  }
16234
16261
  }
16235
16262
  function workflowIdentity(state) {
16236
- return state.workflowInstanceId ?? `legacy-${createHash11("sha256").update(`${state.sessionID}\x00${state.mode}\x00${state.activatedAt}`).digest("hex").slice(0, 32)}`;
16263
+ return state.workflowInstanceId ?? `legacy-${createHash12("sha256").update(`${state.sessionID}\x00${state.mode}\x00${state.activatedAt}`).digest("hex").slice(0, 32)}`;
16237
16264
  }
16238
16265
  function sameHandoffIds(left, right) {
16239
16266
  const normalizedLeft = [...new Set(left)].sort();
@@ -17968,7 +17995,7 @@ function parseCanonicalCandidateRows(text, fallbackFamily) {
17968
17995
  const rows = [];
17969
17996
  const issues = [];
17970
17997
  let headerFamily = null;
17971
- for (const [index, line] of normalizeCandidateArtifact(text, fallbackFamily).text.split(/\r?\n/).entries()) {
17998
+ for (const [index, line] of normalizeCandidateArtifactCached(text, fallbackFamily).text.split(/\r?\n/).entries()) {
17972
17999
  const fields = splitPipeFields(line).map((field) => field.trim());
17973
18000
  const detectedHeaderFamily = candidateHeaderFamily(fields);
17974
18001
  if (detectedHeaderFamily) {
@@ -18548,7 +18575,7 @@ function workflowArtifactHasContractMarker(directory, state, record, expectedMod
18548
18575
  function analyzePrReviewDiscoveryArtifact(text, expectedWorkflowLane, ownedWorkflowLanes = [expectedWorkflowLane], mode, acceptPartial = false) {
18549
18576
  const fallbackFamily = resolvePrReviewRowFamily(expectedWorkflowLane, mode);
18550
18577
  const issues = [];
18551
- const normalized = normalizeCandidateArtifact(text, fallbackFamily);
18578
+ const normalized = normalizeCandidateArtifactCached(text, fallbackFamily);
18552
18579
  const canonicalText = normalized.text;
18553
18580
  const repairKinds = normalized.repairKinds;
18554
18581
  let salvaged = repairKinds.length > 0;
@@ -19186,7 +19213,7 @@ ${USAGE}`;
19186
19213
  }
19187
19214
 
19188
19215
  // src/services/spec-drift-recovery.ts
19189
- import { createHash as createHash12 } from "crypto";
19216
+ import { createHash as createHash13 } from "crypto";
19190
19217
  import { mkdir as mkdir6, readFile as readFile7, unlink as unlink2 } from "fs/promises";
19191
19218
  import { dirname as dirname12 } from "path";
19192
19219
  var SPEC_DRIFT_RECOVERY_AGENT = "spec-drift-recovery";
@@ -19215,7 +19242,7 @@ function now() {
19215
19242
  return new Date().toISOString();
19216
19243
  }
19217
19244
  function sha2562(text) {
19218
- return createHash12("sha256").update(text, "utf-8").digest("hex");
19245
+ return createHash13("sha256").update(text, "utf-8").digest("hex");
19219
19246
  }
19220
19247
  function parseMarker(raw) {
19221
19248
  try {
@@ -19747,7 +19774,7 @@ ${USAGE2}`;
19747
19774
 
19748
19775
  // src/security/write-authority.ts
19749
19776
  import { AsyncLocalStorage } from "async_hooks";
19750
- import { createHash as createHash13, randomUUID as randomUUID5 } from "crypto";
19777
+ import { createHash as createHash14, randomUUID as randomUUID5 } from "crypto";
19751
19778
  import { existsSync as existsSync8, readFileSync as readFileSync7 } from "fs";
19752
19779
  import * as path16 from "path";
19753
19780
  var DEFAULT_TTL_MS = 30 * 60 * 1000;
@@ -19854,7 +19881,7 @@ function leastPrivilege(left, right) {
19854
19881
  return ORIGIN_RANK[left.origin] <= ORIGIN_RANK[right.origin] ? left : right;
19855
19882
  }
19856
19883
  function computeWriteApprovalHash(input) {
19857
- return createHash13("sha256").update(stableSerialize(input)).digest("hex");
19884
+ return createHash14("sha256").update(stableSerialize(input)).digest("hex");
19858
19885
  }
19859
19886
  function getCurrentWriteAuthority() {
19860
19887
  const extent = authorityStore.getStore();
@@ -23623,7 +23650,7 @@ var _internals22 = {
23623
23650
  };
23624
23651
 
23625
23652
  // src/failures/invocation-failure.ts
23626
- import { createHash as createHash15 } from "crypto";
23653
+ import { createHash as createHash16 } from "crypto";
23627
23654
 
23628
23655
  // src/utils/provider-error-classification.ts
23629
23656
  var TRANSIENT_STATUS_CODES = new Set([
@@ -23660,7 +23687,7 @@ function isQuotaError(signal) {
23660
23687
 
23661
23688
  // src/failures/action-identity.ts
23662
23689
  init_schema();
23663
- import { createHash as createHash14 } from "crypto";
23690
+ import { createHash as createHash15 } from "crypto";
23664
23691
  var MAX_STRING_INPUT = 512;
23665
23692
  var MAX_PUBLIC_FIELD_LENGTH = 128;
23666
23693
  var MAX_COLLECTION_ITEMS = 64;
@@ -23714,7 +23741,7 @@ function normalizeToolName2(tool2) {
23714
23741
  return tool2.trim().toLowerCase() || "unknown-tool";
23715
23742
  }
23716
23743
  function hashString(value) {
23717
- return createHash14("sha256").update(value).digest("hex");
23744
+ return createHash15("sha256").update(value).digest("hex");
23718
23745
  }
23719
23746
  function readRecord(value) {
23720
23747
  return typeof value === "object" && value !== null && !Array.isArray(value) ? value : undefined;
@@ -23982,7 +24009,7 @@ function boundedUtf8(value, maxBytes = MAX_DISPLAY_BYTES) {
23982
24009
  return buffer.subarray(0, maxBytes).toString("utf8").replace(/\uFFFD+$/g, "");
23983
24010
  }
23984
24011
  function hashValue(value) {
23985
- return createHash15("sha256").update(value).digest("hex");
24012
+ return createHash16("sha256").update(value).digest("hex");
23986
24013
  }
23987
24014
  function redactUrl(match) {
23988
24015
  try {
@@ -26258,7 +26285,7 @@ function planMerges(active, threshold, maxComparisons, maxMerges) {
26258
26285
  };
26259
26286
  }
26260
26287
  async function sweepActiveNearDuplicates(directory, options = {}) {
26261
- const { loadPluginConfigWithMeta: loadPluginConfigWithMeta2 } = await import("./index-j29nkq5d.js");
26288
+ const { loadPluginConfigWithMeta: loadPluginConfigWithMeta2 } = await import("./index-st47knj6.js");
26262
26289
  const { config } = loadPluginConfigWithMeta2(directory);
26263
26290
  const sweepConfig = config.learning?.dedup_sweep;
26264
26291
  if (sweepConfig?.enabled === false)
@@ -27382,7 +27409,7 @@ async function runCuratorPhase(directory, phase, agentsDispatched, config, knowl
27382
27409
  }
27383
27410
  if (config.skill_generation_enabled === true && skillCandidates.length > 0) {
27384
27411
  try {
27385
- const skillModule = await import("./skill-generator-g8wbjw6v.js");
27412
+ const skillModule = await import("./skill-generator-tbxgpc9x.js");
27386
27413
  for (const cand of skillCandidates) {
27387
27414
  if (cand.confidence < (config.min_skill_confidence ?? DEFAULT_SKILL_MIN_CONFIDENCE)) {
27388
27415
  continue;
@@ -27854,7 +27881,7 @@ async function applyCuratorKnowledgeUpdates(directory, recommendations, knowledg
27854
27881
  } catch {}
27855
27882
  }
27856
27883
  if (contradictedEntries.length > 0 && knowledgeConfig.contradiction_threshold_action === "quarantine") {
27857
- const { maybeQuarantineOnContradiction } = await import("./knowledge-escalator-3pjed4tq.js");
27884
+ const { maybeQuarantineOnContradiction } = await import("./knowledge-escalator-aq7gzhpd.js");
27858
27885
  for (const { id } of contradictedEntries) {
27859
27886
  try {
27860
27887
  await maybeQuarantineOnContradiction(directory, id, knowledgeConfig.contradiction_quarantine_threshold, knowledgeConfig.contradiction_quarantine_window_days);
@@ -28686,7 +28713,7 @@ async function runCuratorPostMortem(directory, options = {}) {
28686
28713
  warnings.push("Failed to collect knowledge summary.");
28687
28714
  }
28688
28715
  try {
28689
- const { getScanStatus } = await import("./scan-cursor-ahwkxa8j.js");
28716
+ const { getScanStatus } = await import("./scan-cursor-hc4v0c90.js");
28690
28717
  const scanStatus = await getScanStatus(directory);
28691
28718
  if (scanStatus.remaining_estimate > 0) {
28692
28719
  warnings.push(`Fair scan: reviewed ${knowledgeSummary.length} entries this sweep (generation ${scanStatus.generation}); ${scanStatus.remaining_estimate} more eligible entries will be visited in future curation sweeps.`);
@@ -28858,9 +28885,9 @@ var _internals27 = {
28858
28885
  verifyPostMortemKnowledgeActions,
28859
28886
  repairPostMortemActions,
28860
28887
  loadDefaultKnowledgeConfig: async (directory) => {
28861
- const { KnowledgeConfigSchema: KnowledgeConfigSchema2 } = await import("./schema-27sedbfk.js");
28888
+ const { KnowledgeConfigSchema: KnowledgeConfigSchema2 } = await import("./schema-w1hsvw1h.js");
28862
28889
  try {
28863
- const { loadPluginConfigWithMeta: loadPluginConfigWithMeta2 } = await import("./index-j29nkq5d.js");
28890
+ const { loadPluginConfigWithMeta: loadPluginConfigWithMeta2 } = await import("./index-st47knj6.js");
28864
28891
  const loaded = loadPluginConfigWithMeta2(directory);
28865
28892
  return KnowledgeConfigSchema2.parse(loaded.config.knowledge ?? {});
28866
28893
  } catch {
@@ -28868,11 +28895,11 @@ var _internals27 = {
28868
28895
  }
28869
28896
  },
28870
28897
  applyCuratorKnowledgeUpdates: async (directory, recommendations, knowledgeConfig, generation) => {
28871
- const { applyCuratorKnowledgeUpdates: applyCuratorKnowledgeUpdates2 } = await import("./curator-ssvd7evd.js");
28898
+ const { applyCuratorKnowledgeUpdates: applyCuratorKnowledgeUpdates2 } = await import("./curator-a4rbehfr.js");
28872
28899
  return applyCuratorKnowledgeUpdates2(directory, recommendations, knowledgeConfig, generation);
28873
28900
  },
28874
28901
  checkHivePromotions: async (entries, knowledgeConfig, directory) => {
28875
- const { checkHivePromotions } = await import("./hive-promoter-ghjbgsms.js");
28902
+ const { checkHivePromotions } = await import("./hive-promoter-y2daybf6.js");
28876
28903
  return checkHivePromotions(entries, knowledgeConfig, directory);
28877
28904
  },
28878
28905
  applyProposalTriage: async (directory, triage) => {
@@ -28881,7 +28908,7 @@ var _internals27 = {
28881
28908
  activateProposal,
28882
28909
  listSkills: listSkills2,
28883
28910
  sanitizeSlug
28884
- } = await import("./skill-generator-g8wbjw6v.js");
28911
+ } = await import("./skill-generator-tbxgpc9x.js");
28885
28912
  const result = {
28886
28913
  approved: [],
28887
28914
  rejected: [],
@@ -28923,7 +28950,7 @@ var _internals27 = {
28923
28950
  return result;
28924
28951
  },
28925
28952
  readPriorDriftReports: async (directory) => {
28926
- const { readPriorDriftReports } = await import("./curator-drift-jpdfwae9.js");
28953
+ const { readPriorDriftReports } = await import("./curator-drift-efmgp1v2.js");
28927
28954
  return readPriorDriftReports(directory);
28928
28955
  },
28929
28956
  readSwarmKnowledge: (directory) => readKnowledge(resolveSwarmKnowledgePath(directory))
@@ -28970,10 +28997,37 @@ function extractCurrentPhaseFromPlan(plan) {
28970
28997
  }
28971
28998
 
28972
28999
  // src/hooks/hive-promoter.ts
29000
+ init_constants();
28973
29001
  init_schema();
28974
- import { createHash as createHash16 } from "crypto";
29002
+ import { createHash as createHash17 } from "crypto";
28975
29003
  import path30 from "path";
28976
29004
 
29005
+ // src/hooks/cohort-cache.ts
29006
+ init_logger();
29007
+ async function ensureCohortIdCached(directory, sessionID) {
29008
+ if (!sessionID)
29009
+ return;
29010
+ const session = swarmState.agentSessions.get(sessionID);
29011
+ if (session?.cachedCohortId)
29012
+ return session.cachedCohortId;
29013
+ let identity;
29014
+ try {
29015
+ identity = await resolveCohortId(directory);
29016
+ } catch (err) {
29017
+ log("[cohort-cache] resolveCohortId failed (fail-open)", {
29018
+ sessionID,
29019
+ error: err instanceof Error ? err.message : String(err)
29020
+ });
29021
+ return;
29022
+ }
29023
+ const cohortId = identity?.cohortId;
29024
+ if (cohortId) {
29025
+ const s = ensureAgentSession(sessionID, swarmState.activeAgent.get(sessionID) ?? "architect");
29026
+ s.cachedCohortId = cohortId;
29027
+ }
29028
+ return cohortId;
29029
+ }
29030
+
28977
29031
  // src/hooks/hive-policy.ts
28978
29032
  init_knowledge_types();
28979
29033
  function evaluatePromotionPolicy(input) {
@@ -29387,9 +29441,9 @@ function buildLineage(args) {
29387
29441
  return lineage;
29388
29442
  }
29389
29443
  function lessonRevision(lesson) {
29390
- return createHash16("sha256").update(lesson).digest("hex").slice(0, 12);
29444
+ return createHash17("sha256").update(lesson).digest("hex").slice(0, 12);
29391
29445
  }
29392
- async function checkHivePromotions(swarmEntries, config, directory) {
29446
+ async function checkHivePromotions(swarmEntries, config, directory, sessionID) {
29393
29447
  const empty = {
29394
29448
  timestamp: new Date().toISOString(),
29395
29449
  new_promotions: 0,
@@ -29400,10 +29454,13 @@ async function checkHivePromotions(swarmEntries, config, directory) {
29400
29454
  if (config.hive_enabled === false) {
29401
29455
  return empty;
29402
29456
  }
29403
- const sourceCohort = await _internals30.resolveCohortId(directory);
29457
+ const activeSwarm = swarmEntries.filter((e) => isActiveStatus(e.status));
29458
+ if (activeSwarm.length === 0) {
29459
+ return empty;
29460
+ }
29461
+ const sourceCohort = await _internals30.resolveCohortId(directory, sessionID);
29404
29462
  const evidence2 = await _internals30.loadPromotionEvidence(directory, sourceCohort.cohortId);
29405
29463
  const diagnostics = [];
29406
- const activeSwarm = swarmEntries.filter((e) => isActiveStatus(e.status));
29407
29464
  const activeSwarmBigrams = activeSwarm.map((e) => typeof e.lesson === "string" ? wordBigrams(e.lesson) : new Set);
29408
29465
  const candidates = [];
29409
29466
  const rejectsOutside = [];
@@ -29699,22 +29756,71 @@ async function authorizeAndRecordHiveMerge(args) {
29699
29756
  authorizationBasis: basis
29700
29757
  });
29701
29758
  }
29759
+ var PROMOTER_WRITE_TOOL_NAMES = new Set(WRITE_TOOL_NAMES);
29760
+ var PROMOTION_CADENCE_FLOOR_MS = 60000;
29761
+ var MAX_PROMOTER_TRACKED_DIRECTORIES = 64;
29762
+ var lastPromotionRunAt = new Map;
29763
+ var curatorMigrationCheckedDirectories = new Set;
29764
+ function promoterGatingKey(directory) {
29765
+ return canonicalRootKey(directory);
29766
+ }
29767
+ function markPromotionRunAt(directory, now2) {
29768
+ const key = promoterGatingKey(directory);
29769
+ lastPromotionRunAt.delete(key);
29770
+ lastPromotionRunAt.set(key, now2);
29771
+ if (lastPromotionRunAt.size > MAX_PROMOTER_TRACKED_DIRECTORIES) {
29772
+ const oldest = lastPromotionRunAt.keys().next().value;
29773
+ if (oldest !== undefined && oldest !== key) {
29774
+ lastPromotionRunAt.delete(oldest);
29775
+ }
29776
+ }
29777
+ }
29702
29778
  var _internals30 = {
29703
29779
  readSwarmEntries: (directory) => readKnowledge(resolveSwarmKnowledgePath(directory)),
29704
29780
  checkHivePromotions,
29705
29781
  readCuratorSummary,
29706
29782
  appendCuratorRecommendation,
29707
- resolveCohortId,
29783
+ resolveCohortId: async (directory, sessionID) => {
29784
+ const cached = await ensureCohortIdCached(directory, sessionID);
29785
+ if (cached) {
29786
+ return { cohortId: cached, source: "path", degraded: true };
29787
+ }
29788
+ return resolveCohortId(directory);
29789
+ },
29708
29790
  transactHiveStore,
29709
29791
  validateLesson,
29710
29792
  authorizeCuration,
29711
29793
  loadPromotionEvidence: async (directory, canonicalCohortId) => loadPromotionEvidenceByEntry(directory, canonicalCohortId),
29712
- loadDefaultKnowledgeConfig: () => KnowledgeConfigSchema.parse({})
29794
+ loadDefaultKnowledgeConfig: () => KnowledgeConfigSchema.parse({}),
29795
+ now: () => Date.now(),
29796
+ resetPromoterGatingState: () => {
29797
+ lastPromotionRunAt.clear();
29798
+ curatorMigrationCheckedDirectories.clear();
29799
+ }
29713
29800
  };
29714
29801
  function createHivePromoterHook(directory, config) {
29715
- const hook = async (_input, _output) => {
29802
+ const hook = async (input, _output) => {
29803
+ const tool2 = input?.tool;
29804
+ if (typeof tool2 !== "string" || !PROMOTER_WRITE_TOOL_NAMES.has(tool2)) {
29805
+ return;
29806
+ }
29807
+ const sessionID = input?.sessionID;
29716
29808
  const swarmEntries = await _internals30.readSwarmEntries(directory);
29717
- const promotionSummary = await _internals30.checkHivePromotions(swarmEntries, config, directory);
29809
+ const hasActiveCandidates = swarmEntries.some((e) => isActiveStatus(e.status));
29810
+ if (!hasActiveCandidates) {
29811
+ if (!curatorMigrationCheckedDirectories.has(promoterGatingKey(directory))) {
29812
+ curatorMigrationCheckedDirectories.add(promoterGatingKey(directory));
29813
+ await _internals30.readCuratorSummary(directory);
29814
+ }
29815
+ return;
29816
+ }
29817
+ const now2 = _internals30.now();
29818
+ const lastRunAt = lastPromotionRunAt.get(promoterGatingKey(directory));
29819
+ if (lastRunAt !== undefined && now2 - lastRunAt < PROMOTION_CADENCE_FLOOR_MS) {
29820
+ return;
29821
+ }
29822
+ markPromotionRunAt(directory, now2);
29823
+ const promotionSummary = await _internals30.checkHivePromotions(swarmEntries, config, directory, typeof sessionID === "string" ? sessionID : undefined);
29718
29824
  const curatorSummary = await _internals30.readCuratorSummary(directory);
29719
29825
  if (!curatorSummary)
29720
29826
  return;
@@ -29976,7 +30082,7 @@ async function promoteFromSwarm(directory, lessonId, options, config) {
29976
30082
  }
29977
30083
 
29978
30084
  // src/hooks/knowledge-curator.ts
29979
- import { createHash as createHash17 } from "crypto";
30085
+ import { createHash as createHash18 } from "crypto";
29980
30086
  import { realpath as realpath4 } from "fs/promises";
29981
30087
  import * as path32 from "path";
29982
30088
 
@@ -30207,12 +30313,12 @@ function recordSeenRetroSection(key, value, timestamp) {
30207
30313
  capSeenRetroSections();
30208
30314
  }
30209
30315
  function hashContent(content) {
30210
- return createHash17("sha1").update(content).digest("hex");
30316
+ return createHash18("sha1").update(content).digest("hex");
30211
30317
  }
30212
30318
  async function loadConfigForPolicyCurator(directory) {
30213
- const { KnowledgeConfigSchema: KnowledgeConfigSchema2 } = await import("./schema-27sedbfk.js");
30319
+ const { KnowledgeConfigSchema: KnowledgeConfigSchema2 } = await import("./schema-w1hsvw1h.js");
30214
30320
  try {
30215
- const { loadPluginConfigWithMeta: loadPluginConfigWithMeta2 } = await import("./index-j29nkq5d.js");
30321
+ const { loadPluginConfigWithMeta: loadPluginConfigWithMeta2 } = await import("./index-st47knj6.js");
30216
30322
  const { config: loadedConfig } = loadPluginConfigWithMeta2(directory);
30217
30323
  return KnowledgeConfigSchema2.parse(loadedConfig.knowledge ?? {});
30218
30324
  } catch {
@@ -31250,7 +31356,7 @@ var _internals31 = {
31250
31356
  };
31251
31357
 
31252
31358
  // src/session/snapshot-coordination-init.ts
31253
- import { createHash as createHash18, randomUUID as randomUUID8 } from "crypto";
31359
+ import { createHash as createHash19, randomUUID as randomUUID8 } from "crypto";
31254
31360
  import { existsSync as existsSync17, readFileSync as readFileSync15, renameSync as renameSync6 } from "fs";
31255
31361
  init_warning_buffer();
31256
31362
 
@@ -31695,7 +31801,7 @@ function serializeAgentSession(s) {
31695
31801
  }
31696
31802
  async function writeSnapshot(directory, state) {
31697
31803
  try {
31698
- const { ensureSnapshotCoordinationReady } = await import("./snapshot-coordination-init-y6spakwm.js");
31804
+ const { ensureSnapshotCoordinationReady } = await import("./snapshot-coordination-init-vaf34wf0.js");
31699
31805
  await ensureSnapshotCoordinationReady(directory);
31700
31806
  const snapshot = {
31701
31807
  version: 3,
@@ -32085,7 +32191,7 @@ async function initializeSnapshotCoordination(directory) {
32085
32191
  if (source) {
32086
32192
  const candidate = await readSnapshotFileStrict(directory, source);
32087
32193
  const serialized = JSON.stringify(candidate);
32088
- const outcome = importSnapshotRowsOnce(directory, candidate, createHash18("sha256").update(serialized).digest("hex"), source);
32194
+ const outcome = importSnapshotRowsOnce(directory, candidate, createHash19("sha256").update(serialized).digest("hex"), source);
32089
32195
  snapshot = readSnapshotRows(directory);
32090
32196
  if (outcome === "imported" && source === "session/state.json") {
32091
32197
  legacyArchiveAttempted = true;
@@ -33363,7 +33469,7 @@ var MAX_RELATIONS_PER_MEMORY = 32;
33363
33469
  var RELATED_RECALL_FANOUT = 2;
33364
33470
  // src/memory/schema.ts
33365
33471
  init_zod();
33366
- import { createHash as createHash19 } from "crypto";
33472
+ import { createHash as createHash20 } from "crypto";
33367
33473
 
33368
33474
  // src/memory/pii.ts
33369
33475
  import * as os3 from "os";
@@ -33670,7 +33776,7 @@ function stableScopeKey(scope) {
33670
33776
  }
33671
33777
  function computeMemoryContentHash(recordLike) {
33672
33778
  const normalized = normalizeMemoryText(recordLike.text).toLowerCase();
33673
- return createHash19("sha256").update(`${stableScopeKey(recordLike.scope)}
33779
+ return createHash20("sha256").update(`${stableScopeKey(recordLike.scope)}
33674
33780
  ${recordLike.kind}
33675
33781
  ${normalized}`).digest("hex");
33676
33782
  }
@@ -34532,7 +34638,7 @@ function proposalSort(a, b) {
34532
34638
  }
34533
34639
 
34534
34640
  // src/memory/outcome-events.ts
34535
- import { createHash as createHash20, randomUUID as randomUUID9 } from "crypto";
34641
+ import { createHash as createHash21, randomUUID as randomUUID9 } from "crypto";
34536
34642
  function newOutcomeGeneration() {
34537
34643
  return randomUUID9();
34538
34644
  }
@@ -34665,7 +34771,7 @@ function dedupeAnchors(anchors) {
34665
34771
  return [...byKey.values()].sort((a, b) => compareText(a.file, b.file) || compareText(a.symbol ?? "", b.symbol ?? ""));
34666
34772
  }
34667
34773
  function hash(value) {
34668
- return createHash20("sha256").update(value).digest("hex").slice(0, 32);
34774
+ return createHash21("sha256").update(value).digest("hex").slice(0, 32);
34669
34775
  }
34670
34776
  function compareText(a, b) {
34671
34777
  return a < b ? -1 : a > b ? 1 : 0;
@@ -35551,7 +35657,7 @@ async function repairIncompleteJsonlTail(filePath) {
35551
35657
  import { mkdirSync as mkdirSync13 } from "fs";
35552
35658
 
35553
35659
  // src/memory/sqlite-provider.ts
35554
- import { createHash as createHash21, randomUUID as randomUUID11 } from "crypto";
35660
+ import { createHash as createHash22, randomUUID as randomUUID11 } from "crypto";
35555
35661
  import {
35556
35662
  existsSync as existsSync21,
35557
35663
  mkdirSync as mkdirSync12,
@@ -36216,7 +36322,7 @@ function toJsonl(values) {
36216
36322
  var EVENT_CHAIN_GENESIS = "GENESIS";
36217
36323
  var MEMORY_EVENTS_CHAIN_HEAD_KEY = "memory_events_chain_head";
36218
36324
  function memoryEventRowHash(row) {
36219
- return createHash21("sha256").update(stableCanonicalStringify({
36325
+ return createHash22("sha256").update(stableCanonicalStringify({
36220
36326
  id: row.id,
36221
36327
  operation: row.operation,
36222
36328
  target_id: row.target_id,
@@ -41990,7 +42096,7 @@ var _internals38 = {
41990
42096
  };
41991
42097
 
41992
42098
  // src/services/swarm-residue.ts
41993
- import { createHash as createHash22 } from "crypto";
42099
+ import { createHash as createHash23 } from "crypto";
41994
42100
  import * as fs16 from "fs";
41995
42101
  import * as path46 from "path";
41996
42102
  var RESIDUE_STALE_AGE_MS = 30 * 60000;
@@ -42044,7 +42150,7 @@ var _internals39 = {
42044
42150
  return targets;
42045
42151
  },
42046
42152
  sha256File: (absPath) => {
42047
- const hash2 = createHash22("sha256");
42153
+ const hash2 = createHash23("sha256");
42048
42154
  const fd = fs16.openSync(absPath, "r");
42049
42155
  try {
42050
42156
  const chunk = Buffer.alloc(1024 * 1024);
@@ -42875,9 +42981,9 @@ var _internals40 = {
42875
42981
  init_logger();
42876
42982
 
42877
42983
  // src/workflow/close-terminal.ts
42878
- import { createHash as createHash23 } from "crypto";
42984
+ import { createHash as createHash24 } from "crypto";
42879
42985
  function createCloseTransitionId(planEpoch, taskId, target) {
42880
- const digest2 = createHash23("sha256").update(JSON.stringify([planEpoch, taskId, target]), "utf8").digest("hex");
42986
+ const digest2 = createHash24("sha256").update(JSON.stringify([planEpoch, taskId, target]), "utf8").digest("hex");
42881
42987
  return `close-terminal:${digest2}`;
42882
42988
  }
42883
42989
  function findTask(plan, taskId) {
@@ -43487,7 +43593,8 @@ var ARCHIVE_ARTIFACTS = [
43487
43593
  "background-delegations.checkpoint.json",
43488
43594
  "background-delegations.manifest.json",
43489
43595
  "background-delegations-health.json",
43490
- "context-telemetry.jsonl"
43596
+ "context-telemetry.jsonl",
43597
+ "workspace-snapshot.digest"
43491
43598
  ];
43492
43599
  var ACTIVE_STATE_TO_CLEAN = [
43493
43600
  "plan.json",
@@ -43511,7 +43618,8 @@ var ACTIVE_STATE_TO_CLEAN = [
43511
43618
  "spec-staleness.json",
43512
43619
  "spec-snapshot.md",
43513
43620
  "swarm.db",
43514
- REPO_MEMORY_FILENAME
43621
+ REPO_MEMORY_FILENAME,
43622
+ "workspace-snapshot.digest"
43515
43623
  ];
43516
43624
  var TERMINAL_STATE_FILES = [
43517
43625
  "plan.json",
@@ -43921,7 +44029,7 @@ async function runFinalizeStage(ctx) {
43921
44029
  }
43922
44030
  }
43923
44031
  try {
43924
- const { CuratorConfigSchema: CCS } = await import("./schema-27sedbfk.js");
44032
+ const { CuratorConfigSchema: CCS } = await import("./schema-w1hsvw1h.js");
43925
44033
  const { config: pmLoadedConfig } = _internals42.loadPluginConfigWithMeta(ctx.directory);
43926
44034
  const curatorCfg = CCS.parse(pmLoadedConfig.curator ?? {});
43927
44035
  if (curatorCfg.enabled && curatorCfg.postmortem_enabled) {
@@ -44841,7 +44949,7 @@ var _internals42 = {
44841
44949
  closePlanTerminalState: reconcileCloseTerminalStateForPlan,
44842
44950
  endAgentSession,
44843
44951
  flushAndDrainTelemetry: async () => {
44844
- const { flushAndDrainTelemetry } = await import("./telemetry-9h1z2w9d.js");
44952
+ const { flushAndDrainTelemetry } = await import("./telemetry-8qn4eag5.js");
44845
44953
  return flushAndDrainTelemetry();
44846
44954
  },
44847
44955
  finalizeContextTelemetry: (directory) => {
@@ -46182,9 +46290,9 @@ var _internals46 = {
46182
46290
  loadPluginConfigWithMeta,
46183
46291
  loadCuratorDeps: async () => {
46184
46292
  const [{ CuratorConfigSchema }, curator, { createCuratorLLMDelegate: createCuratorLLMDelegate2 }] = await Promise.all([
46185
- import("./schema-27sedbfk.js"),
46186
- import("./curator-ssvd7evd.js"),
46187
- import("./curator-llm-factory-da5q3gg6.js")
46293
+ import("./schema-w1hsvw1h.js"),
46294
+ import("./curator-a4rbehfr.js"),
46295
+ import("./curator-llm-factory-cwg62ynw.js")
46188
46296
  ]);
46189
46297
  return { CuratorConfigSchema, curator, createCuratorLLMDelegate: createCuratorLLMDelegate2 };
46190
46298
  }
@@ -47235,7 +47343,7 @@ async function computeCurationDiagnostics(directory, entries2) {
47235
47343
  let scanCompleted = false;
47236
47344
  let scanRemaining = 0;
47237
47345
  try {
47238
- const { getScanStatus } = await import("./scan-cursor-ahwkxa8j.js");
47346
+ const { getScanStatus } = await import("./scan-cursor-hc4v0c90.js");
47239
47347
  const status = await getScanStatus(directory);
47240
47348
  scanGeneration = status.generation;
47241
47349
  scanCompleted = status.completed;
@@ -47243,19 +47351,19 @@ async function computeCurationDiagnostics(directory, entries2) {
47243
47351
  } catch {}
47244
47352
  let configMatch = null;
47245
47353
  try {
47246
- const { isLinked: isLinked2 } = await import("./knowledge-link-1zykfk1p.js");
47354
+ const { isLinked: isLinked2 } = await import("./knowledge-link-ps2v4s18.js");
47247
47355
  if (isLinked2(directory)) {
47248
- const { KnowledgeConfigSchema: KnowledgeConfigSchema2 } = await import("./schema-27sedbfk.js");
47356
+ const { KnowledgeConfigSchema: KnowledgeConfigSchema2 } = await import("./schema-w1hsvw1h.js");
47249
47357
  let config;
47250
47358
  try {
47251
- const { loadPluginConfigWithMeta: loadPluginConfigWithMeta2 } = await import("./index-j29nkq5d.js");
47359
+ const { loadPluginConfigWithMeta: loadPluginConfigWithMeta2 } = await import("./index-st47knj6.js");
47252
47360
  const loaded = loadPluginConfigWithMeta2(directory);
47253
47361
  config = KnowledgeConfigSchema2.parse(loaded.config.knowledge ?? {});
47254
47362
  } catch {
47255
47363
  config = KnowledgeConfigSchema2.parse({});
47256
47364
  }
47257
47365
  const { cohortConfigFingerprint: cohortConfigFingerprint2 } = await import("./config-fingerprint-v22xh5a2.js");
47258
- const { buildConfigFingerprintInput: buildConfigFingerprintInput2, readCohortConfigFingerprint } = await import("./curation-policy-jtzwz6bc.js");
47366
+ const { buildConfigFingerprintInput: buildConfigFingerprintInput2, readCohortConfigFingerprint } = await import("./curation-policy-gnpgc3z7.js");
47259
47367
  const currentFp = cohortConfigFingerprint2(buildConfigFingerprintInput2(config));
47260
47368
  const cohortFp = await readCohortConfigFingerprint(directory);
47261
47369
  configMatch = cohortFp === null ? null : currentFp === cohortFp;
@@ -48651,7 +48759,7 @@ async function handleDoctorCommand(directory, args) {
48651
48759
  const result = runConfigDoctor(config, directory);
48652
48760
  let output;
48653
48761
  if (enableAutoFix && result.hasAutoFixableIssues) {
48654
- const { runConfigDoctorWithFixes } = await import("./config-doctor-pjcjeh8f.js");
48762
+ const { runConfigDoctorWithFixes } = await import("./config-doctor-fy1aytwt.js");
48655
48763
  const fixResult = await runConfigDoctorWithFixes(directory, config, true, {
48656
48764
  applyLossy: true
48657
48765
  });
@@ -49594,7 +49702,7 @@ async function handleEvidenceCommand(directory, args) {
49594
49702
  return formatTaskEvidenceMarkdown(evidenceData);
49595
49703
  }
49596
49704
  async function handleEvidenceSummaryCommand(directory) {
49597
- const { buildEvidenceSummary } = await import("./evidence-summary-service-mw6tnsp9.js");
49705
+ const { buildEvidenceSummary } = await import("./evidence-summary-service-dvp1kbm4.js");
49598
49706
  const artifact = await buildEvidenceSummary(directory);
49599
49707
  if (!artifact) {
49600
49708
  return "No plan found. Run `/swarm plan` to check plan status.";
@@ -56788,7 +56896,7 @@ import * as path71 from "path";
56788
56896
  init_zod();
56789
56897
 
56790
56898
  // src/harness/hash.ts
56791
- import { createHash as createHash26 } from "crypto";
56899
+ import { createHash as createHash27 } from "crypto";
56792
56900
  function canonicalize(value, ancestors) {
56793
56901
  if (value === null || typeof value === "string" || typeof value === "boolean") {
56794
56902
  return value;
@@ -56836,7 +56944,7 @@ function canonicalJson2(value) {
56836
56944
  return serialized;
56837
56945
  }
56838
56946
  function sha2563(value) {
56839
- return createHash26("sha256").update(value).digest("hex");
56947
+ return createHash27("sha256").update(value).digest("hex");
56840
56948
  }
56841
56949
  function canonicalHash2(value) {
56842
56950
  return sha2563(canonicalJson2(value));
@@ -59545,7 +59653,7 @@ async function handleHistoryCommand(directory, _args) {
59545
59653
  }
59546
59654
  // src/knowledge/hive-quarantine.ts
59547
59655
  init_package();
59548
- import { createHash as createHash27, createHmac, randomBytes, randomUUID as randomUUID13 } from "crypto";
59656
+ import { createHash as createHash28, createHmac, randomBytes, randomUUID as randomUUID13 } from "crypto";
59549
59657
  import {
59550
59658
  chmod,
59551
59659
  copyFile as copyFile2,
@@ -59578,7 +59686,7 @@ function serializeCanonical(value) {
59578
59686
  return `{${entries2.map(([k, v]) => `${JSON.stringify(k)}:${serializeCanonical(v)}`).join(",")}}`;
59579
59687
  }
59580
59688
  function sha256Hex(content) {
59581
- return createHash27("sha256").update(content, "utf-8").digest("hex");
59689
+ return createHash28("sha256").update(content, "utf-8").digest("hex");
59582
59690
  }
59583
59691
  var QUARANTINE_SECRET_FILE = "hive-quarantine.key";
59584
59692
  async function readQuarantineSecret() {
@@ -61350,7 +61458,7 @@ async function handleKnowledgeRetryHardeningCommand(directory, args) {
61350
61458
  }
61351
61459
 
61352
61460
  // src/hooks/delegation-gate/worktree-recovery-authority.ts
61353
- import { createHash as createHash28, randomBytes as randomBytes2 } from "crypto";
61461
+ import { createHash as createHash29, randomBytes as randomBytes2 } from "crypto";
61354
61462
  import * as fs30 from "fs";
61355
61463
  import * as path75 from "path";
61356
61464
  var STORE_RELATIVE_PATH = path75.join(".swarm", "worktree-merge-recovery-v2.json");
@@ -61369,7 +61477,7 @@ function nowMs(input) {
61369
61477
  return input ?? Date.now();
61370
61478
  }
61371
61479
  function sha2564(input) {
61372
- return createHash28("sha256").update(input).digest("hex");
61480
+ return createHash29("sha256").update(input).digest("hex");
61373
61481
  }
61374
61482
  function storePath(directory) {
61375
61483
  return path75.join(directory, STORE_RELATIVE_PATH);
@@ -68315,12 +68423,12 @@ var workspaceCache = new Map;
68315
68423
 
68316
68424
  // src/tools/repo-graph/freshness.ts
68317
68425
  init_package();
68318
- import { createHash as createHash29 } from "crypto";
68426
+ import { createHash as createHash30 } from "crypto";
68319
68427
  import * as fsPromises3 from "fs/promises";
68320
68428
  import * as path82 from "path";
68321
68429
  var REPO_GRAPH_FINGERPRINT_FILENAME = "repo-graph.fingerprint.json";
68322
68430
  var FINGERPRINT_SCHEMA_VERSION = 1;
68323
- var EXTRACTOR_STAMP = createHash29("sha256").update(`${package_default.version}\x00${GRAPH_SCHEMA_VERSION}`).digest("hex");
68431
+ var EXTRACTOR_STAMP = createHash30("sha256").update(`${package_default.version}\x00${GRAPH_SCHEMA_VERSION}`).digest("hex");
68324
68432
  var MAX_FINGERPRINT_BYTES = 24 * 1024 * 1024;
68325
68433
  var MAX_FINGERPRINT_ENTRIES = 100256;
68326
68434
  var MAX_RELATIVE_PATH_LENGTH = 4096;
@@ -68343,7 +68451,7 @@ function normalizedExcludes(options) {
68343
68451
  return [...new Set((options?.excludeDirs ?? []).filter(Boolean))].sort((a, b) => a.localeCompare(b));
68344
68452
  }
68345
68453
  function exclusionStamp(options) {
68346
- return createHash29("sha256").update(JSON.stringify({
68454
+ return createHash30("sha256").update(JSON.stringify({
68347
68455
  excludeDirs: normalizedExcludes(options),
68348
68456
  followSymlinks: options?.followSymlinks ?? false
68349
68457
  })).digest("hex");
@@ -74841,7 +74949,7 @@ var DISPATCH_FRAMEWORK_MAP = {
74841
74949
  };
74842
74950
  async function detectTestFrameworkViaDispatch(cwd) {
74843
74951
  try {
74844
- const { pickBackend } = await import("./dispatch-591v13pp.js");
74952
+ const { pickBackend } = await import("./dispatch-tmb929w8.js");
74845
74953
  const backend = await pickBackend(cwd);
74846
74954
  if (!backend?.selectTestFramework)
74847
74955
  return "none";
@@ -74857,7 +74965,7 @@ async function buildTestCommandViaDispatch(framework, scope, files, coverage, ba
74857
74965
  if (framework === "none")
74858
74966
  return null;
74859
74967
  try {
74860
- const { pickBackend } = await import("./dispatch-591v13pp.js");
74968
+ const { pickBackend } = await import("./dispatch-tmb929w8.js");
74861
74969
  const backend = await pickBackend(baseDir);
74862
74970
  if (backend?.buildTestCommand) {
74863
74971
  const cmd = backend.buildTestCommand(framework, files, baseDir, {
@@ -74879,7 +74987,7 @@ async function parseTestOutputViaDispatch(framework, output, baseDir) {
74879
74987
  if (framework === "none")
74880
74988
  return null;
74881
74989
  try {
74882
- const { pickBackend } = await import("./dispatch-591v13pp.js");
74990
+ const { pickBackend } = await import("./dispatch-tmb929w8.js");
74883
74991
  const backend = await pickBackend(baseDir);
74884
74992
  if (!backend?.parseTestOutput)
74885
74993
  return null;
@@ -77986,7 +78094,7 @@ async function handleRecoverCommand(directory, args) {
77986
78094
  }
77987
78095
 
77988
78096
  // src/db/observability-event-store.ts
77989
- import { createHash as createHash30 } from "crypto";
78097
+ import { createHash as createHash31 } from "crypto";
77990
78098
  import { existsSync as existsSync54, readFileSync as readFileSync47, statSync as statSync27 } from "fs";
77991
78099
  import { join as join78 } from "path";
77992
78100
  var MAX_OBSERVABILITY_EVENT_ROWS = 50000;
@@ -78045,7 +78153,7 @@ function runRetentionIfOverCap(db) {
78045
78153
  db.run("DELETE FROM observability_event WHERE rowid IN (SELECT rowid FROM observability_event ORDER BY rowid ASC LIMIT ?)", [excess]);
78046
78154
  }
78047
78155
  function syntheticImportEventId(line) {
78048
- return createHash30("sha256").update(`${IMPORT_ID_NAMESPACE}\x00${line}`).digest("hex");
78156
+ return createHash31("sha256").update(`${IMPORT_ID_NAMESPACE}\x00${line}`).digest("hex");
78049
78157
  }
78050
78158
  function unparseableImportRow(line, reason) {
78051
78159
  return {
@@ -79907,7 +80015,7 @@ import * as fs49 from "fs";
79907
80015
  import * as path104 from "path";
79908
80016
 
79909
80017
  // src/review/diff-source.ts
79910
- import { createHash as createHash31 } from "crypto";
80018
+ import { createHash as createHash32 } from "crypto";
79911
80019
  import * as fs43 from "fs";
79912
80020
  import * as path98 from "path";
79913
80021
  init_git_executable();
@@ -80319,7 +80427,7 @@ function uniqueSkipCodes(skipReasons) {
80319
80427
  return [...new Set(skipReasons.map((item) => item.code))].sort();
80320
80428
  }
80321
80429
  function hashManifestPayload(payload) {
80322
- return createHash31("sha256").update(JSON.stringify(payload), "utf8").digest("hex");
80430
+ return createHash32("sha256").update(JSON.stringify(payload), "utf8").digest("hex");
80323
80431
  }
80324
80432
  function parseObjectFormat(stdout) {
80325
80433
  const objectFormat = stdout.trim();
@@ -80407,7 +80515,7 @@ function hashWorkingTreeIdentity(root, rawPath, budget) {
80407
80515
  if (fileBytes > budget.remainingBytes) {
80408
80516
  return deadlineExceeded(`working-tree content identity exceeded the ${WORKTREE_IDENTITY_TOTAL_BYTES}-byte aggregate cap`);
80409
80517
  }
80410
- const hash2 = createHash31("sha256");
80518
+ const hash2 = createHash32("sha256");
80411
80519
  const buffer = Buffer.alloc(64 * 1024);
80412
80520
  let offset = 0;
80413
80521
  while (offset < fileBytes) {
@@ -80987,8 +81095,8 @@ async function collectReviewDiff(options) {
80987
81095
  canonicalText,
80988
81096
  fileListFallback: fileListFallback ?? null
80989
81097
  });
80990
- const scopeHash = createHash31("sha256").update(hashPayload, "utf8").digest("hex");
80991
- const reviewContentHash = createHash31("sha256").update(JSON.stringify({
81098
+ const scopeHash = createHash32("sha256").update(hashPayload, "utf8").digest("hex");
81099
+ const reviewContentHash = createHash32("sha256").update(JSON.stringify({
80992
81100
  selector,
80993
81101
  canonicalText,
80994
81102
  fileListFallback: fileListFallback ?? null
@@ -81501,7 +81609,7 @@ function buildApprovedReceipt(opts) {
81501
81609
  init_schema();
81502
81610
 
81503
81611
  // src/review/finding-validator.ts
81504
- import { createHash as createHash33 } from "crypto";
81612
+ import { createHash as createHash34 } from "crypto";
81505
81613
  init_schema();
81506
81614
  var MAX_VALIDATOR_FALLBACK_MODELS = FALLBACK_MODELS_MAX;
81507
81615
  function canonicalFindingPayload(finding) {
@@ -81527,7 +81635,7 @@ function canonicalizeValidationCandidates(findings) {
81527
81635
  line_start: finding.line_start,
81528
81636
  line_end: finding.line_end
81529
81637
  };
81530
- const findingId = createHash33("sha256").update(canonicalFindingPayload(normalized), "utf8").digest("hex");
81638
+ const findingId = createHash34("sha256").update(canonicalFindingPayload(normalized), "utf8").digest("hex");
81531
81639
  const existing = candidates.get(findingId);
81532
81640
  if (existing) {
81533
81641
  existing.duplicate_count += "duplicate_count" in finding && finding.duplicate_count > 1 ? finding.duplicate_count : 1;
@@ -81813,7 +81921,7 @@ import * as path101 from "path";
81813
81921
  init_git_executable();
81814
81922
 
81815
81923
  // src/hooks/reviewer-scope-file-fingerprint.ts
81816
- import { createHash as createHash34 } from "crypto";
81924
+ import { createHash as createHash35 } from "crypto";
81817
81925
  import * as fs45 from "fs";
81818
81926
  import * as path100 from "path";
81819
81927
  var RETRYABLE_CAPTURE_FAILURE_CODES = new Set([
@@ -82099,7 +82207,7 @@ function captureReviewerScopeFileFingerprint(directory, file, options = {}) {
82099
82207
  retryable: true
82100
82208
  };
82101
82209
  }
82102
- const hash2 = createHash34("sha256");
82210
+ const hash2 = createHash35("sha256");
82103
82211
  const chunk = Buffer.alloc(REVIEWER_SCOPE_CAPTURE_CHUNK_BYTES);
82104
82212
  let totalBytes = 0;
82105
82213
  for (;; ) {
@@ -82619,11 +82727,11 @@ var _internals92 = {
82619
82727
  };
82620
82728
 
82621
82729
  // src/review/evidence.ts
82622
- import { createHash as createHash35 } from "crypto";
82730
+ import { createHash as createHash36 } from "crypto";
82623
82731
  import * as fs47 from "fs";
82624
82732
  import * as path102 from "path";
82625
82733
  function computeAutoReviewManifestHash(manifest) {
82626
- return createHash35("sha256").update(JSON.stringify({
82734
+ return createHash36("sha256").update(JSON.stringify({
82627
82735
  schema_version: manifest.schema_version,
82628
82736
  content_hash: manifest.content_hash,
82629
82737
  plan_requirements_hash: manifest.plan_requirements_hash,
@@ -82714,7 +82822,7 @@ async function computePlanRequirementsHash(directory) {
82714
82822
  return plan ? computeReviewPlanRequirementsHash(plan) : "plan:none";
82715
82823
  }
82716
82824
  function computeAutoReviewPolicyDigest(config) {
82717
- return createHash35("sha256").update(JSON.stringify({
82825
+ return createHash36("sha256").update(JSON.stringify({
82718
82826
  mode: config.final_review.mode,
82719
82827
  min_confidence: config.min_confidence,
82720
82828
  structured_findings: config.structured_findings,
@@ -82760,7 +82868,7 @@ async function loadReviewRequirementsPlan(directory) {
82760
82868
  return replayed.plan;
82761
82869
  }
82762
82870
  function computeReviewPlanRequirementsHash(plan) {
82763
- return createHash35("sha256").update(JSON.stringify({
82871
+ return createHash36("sha256").update(JSON.stringify({
82764
82872
  schema_version: plan.schema_version,
82765
82873
  title: plan.title,
82766
82874
  swarm: plan.swarm,
@@ -84780,7 +84888,7 @@ import {
84780
84888
  import * as path108 from "path";
84781
84889
 
84782
84890
  // src/services/skill-optimizer/store.ts
84783
- import { createHash as createHash36, randomUUID as randomUUID16 } from "crypto";
84891
+ import { createHash as createHash37, randomUUID as randomUUID16 } from "crypto";
84784
84892
  import {
84785
84893
  closeSync as closeSync20,
84786
84894
  existsSync as existsSync61,
@@ -84805,10 +84913,10 @@ function canonicalJson4(value) {
84805
84913
  return `{${entries2.map(([k, v]) => `${JSON.stringify(k)}:${canonicalJson4(v)}`).join(",")}}`;
84806
84914
  }
84807
84915
  function computeStateHash(value) {
84808
- return createHash36("sha256").update(canonicalJson4(value), "utf8").digest("hex");
84916
+ return createHash37("sha256").update(canonicalJson4(value), "utf8").digest("hex");
84809
84917
  }
84810
84918
  function computeContentHash2(content) {
84811
- return createHash36("sha256").update(content, "utf8").digest("hex");
84919
+ return createHash37("sha256").update(content, "utf8").digest("hex");
84812
84920
  }
84813
84921
  function computeEventHash(event) {
84814
84922
  return computeStateHash({
@@ -85563,7 +85671,7 @@ var evaluationV1 = Object.freeze(Object.assign((options) => evaluateCandidateV1(
85563
85671
  }));
85564
85672
 
85565
85673
  // src/security/protected-input-integrity.ts
85566
- import { createHash as createHash37 } from "crypto";
85674
+ import { createHash as createHash38 } from "crypto";
85567
85675
  import { lstat as lstat4, readdir as readdir8, readFile as readFile25, realpath as realpath8 } from "fs/promises";
85568
85676
  import * as path110 from "path";
85569
85677
  var LIMITS = {
@@ -85586,11 +85694,11 @@ async function snapshotProtectedTree(root) {
85586
85694
  const afterRead = await lstat4(canonicalRoot);
85587
85695
  if (`${afterRead.dev}:${afterRead.ino}:${afterRead.size}:${afterRead.mtimeMs}` !== `${rootStat.dev}:${rootStat.ino}:${rootStat.size}:${rootStat.mtimeMs}`)
85588
85696
  throw new Error("PROTECTED_INPUT_REPLACED_DURING_READ:root");
85589
- entries2.push(`f\x00.\x00${rootStat.size}\x00${rootStat.mode}\x00${createHash37("sha256").update(content).digest("hex")}`);
85697
+ entries2.push(`f\x00.\x00${rootStat.size}\x00${rootStat.mode}\x00${createHash38("sha256").update(content).digest("hex")}`);
85590
85698
  return Object.freeze({
85591
85699
  v: 1,
85592
85700
  root: canonicalRoot,
85593
- digest: createHash37("sha256").update(entries2[0]).digest("hex"),
85701
+ digest: createHash38("sha256").update(entries2[0]).digest("hex"),
85594
85702
  entries: Object.freeze(entries2)
85595
85703
  });
85596
85704
  }
@@ -85621,7 +85729,7 @@ async function snapshotProtectedTree(root) {
85621
85729
  byteCount += stat10.size;
85622
85730
  if (fileCount > LIMITS.files || byteCount > LIMITS.bytes || Date.now() - started > LIMITS.elapsedMs)
85623
85731
  throw new Error("PROTECTED_INPUT_INTEGRITY_BUDGET_EXCEEDED");
85624
- const contentHash = createHash37("sha256").update(await readFile25(absolute)).digest("hex");
85732
+ const contentHash = createHash38("sha256").update(await readFile25(absolute)).digest("hex");
85625
85733
  const afterRead = await lstat4(absolute);
85626
85734
  if (`${afterRead.dev}:${afterRead.ino}:${afterRead.size}:${afterRead.mtimeMs}` !== identityBefore)
85627
85735
  throw new Error(`PROTECTED_INPUT_REPLACED_DURING_READ:${relative28}`);
@@ -85632,7 +85740,7 @@ async function snapshotProtectedTree(root) {
85632
85740
  return Object.freeze({
85633
85741
  v: 1,
85634
85742
  root: canonicalRoot,
85635
- digest: createHash37("sha256").update(entries2.join(`
85743
+ digest: createHash38("sha256").update(entries2.join(`
85636
85744
  `)).digest("hex"),
85637
85745
  entries: Object.freeze(entries2)
85638
85746
  });
@@ -86285,7 +86393,7 @@ async function runValidationWithTransientRetry(input, candidateContent, baseline
86285
86393
  if (!input.dispatcher) {
86286
86394
  throw new Error("no evaluation dispatcher available (cannot run validation)");
86287
86395
  }
86288
- const { createModelEvaluationExecutor: createModelEvaluationExecutor2 } = await import("./runner-j3acybhs.js");
86396
+ const { createModelEvaluationExecutor: createModelEvaluationExecutor2 } = await import("./runner-7zqbp81n.js");
86289
86397
  const executor = createModelEvaluationExecutor2(input.dispatcher, input.sessionId);
86290
86398
  const result = await withProtectedSetIntegrity([evalInputRoot, ...protectedRoots(input.directory)], () => _internals102.evaluateCandidateV1({
86291
86399
  projectRoot: input.directory,
@@ -87003,7 +87111,7 @@ async function countConsensusReportFiles(directory) {
87003
87111
  }
87004
87112
 
87005
87113
  // src/turbo/lean/state.ts
87006
- import { createHash as createHash38 } from "crypto";
87114
+ import { createHash as createHash39 } from "crypto";
87007
87115
  import * as fs53 from "fs";
87008
87116
  import * as path116 from "path";
87009
87117
  init_logger();
@@ -87096,7 +87204,7 @@ function readLegacyPersisted(directory) {
87096
87204
  const raw = fs53.readFileSync(filePath, "utf-8");
87097
87205
  return {
87098
87206
  persisted: parsePersistedJson(raw),
87099
- sourceDigest: createHash38("sha256").update(raw).digest("hex")
87207
+ sourceDigest: createHash39("sha256").update(raw).digest("hex")
87100
87208
  };
87101
87209
  }
87102
87210
  function seedProjectionBestEffort(directory, persisted) {
@@ -88926,7 +89034,7 @@ function buildDetailedHelp(commandName, entry) {
88926
89034
  async function handleHelpCommand(ctx) {
88927
89035
  const targetCommand = ctx.args.join(" ");
88928
89036
  if (!targetCommand) {
88929
- const { buildHelpText } = await import("./index-crjx4sx0.js");
89037
+ const { buildHelpText } = await import("./index-nrdj94za.js");
88930
89038
  return buildHelpText();
88931
89039
  }
88932
89040
  const tokens = targetCommand.split(/\s+/);
@@ -88940,7 +89048,7 @@ async function handleHelpCommand(ctx) {
88940
89048
  > Note: \`/swarm ${resolved.key}\` is a deprecated alias for \`/swarm ${aliasTarget}\`.` : detailed;
88941
89049
  }
88942
89050
  const similar = _internals105.findSimilarCommands(targetCommand);
88943
- const { buildHelpText: fullHelp } = await import("./index-crjx4sx0.js");
89051
+ const { buildHelpText: fullHelp } = await import("./index-nrdj94za.js");
88944
89052
  if (similar.length > 0) {
88945
89053
  return `Command '/swarm ${targetCommand}' not found.
88946
89054
 
@@ -89245,7 +89353,7 @@ var COMMAND_REGISTRY = {
89245
89353
  },
89246
89354
  "guardrail explain": {
89247
89355
  handler: async (ctx) => {
89248
- const { handleGuardrailExplain } = await import("./guardrail-explain-eva1yrtf.js");
89356
+ const { handleGuardrailExplain } = await import("./guardrail-explain-zskpzgsr.js");
89249
89357
  return handleGuardrailExplain(ctx.directory, ctx.args);
89250
89358
  },
89251
89359
  description: "Dry-run: show what the guardrails would do to a command or write target (executes nothing)",
@@ -89255,7 +89363,7 @@ var COMMAND_REGISTRY = {
89255
89363
  },
89256
89364
  "guardrail reset": {
89257
89365
  handler: async (ctx) => {
89258
- const { handleGuardrailReset } = await import("./guardrail-reset-ea1g3g7d.js");
89366
+ const { handleGuardrailReset } = await import("./guardrail-reset-84ydxdg3.js");
89259
89367
  return handleGuardrailReset(ctx.args, ctx.sessionID);
89260
89368
  },
89261
89369
  description: "Reset one exact active invocation/action circuit after repair",
@@ -89276,7 +89384,7 @@ var COMMAND_REGISTRY = {
89276
89384
  },
89277
89385
  "guardrail-log": {
89278
89386
  handler: async (ctx) => {
89279
- const { handleGuardrailLog } = await import("./guardrail-log-kzq2sktb.js");
89387
+ const { handleGuardrailLog } = await import("./guardrail-log-qhw3knjt.js");
89280
89388
  return handleGuardrailLog(ctx.directory, ctx.args);
89281
89389
  },
89282
89390
  description: "Read the guardrail decision log (use --blocks-only for blocks)",
@@ -95322,7 +95430,7 @@ function getDisplayFinalPromptPressure() {
95322
95430
  async function rehydratePrSubscriptions(sessionID, directory) {
95323
95431
  const map = new Map;
95324
95432
  try {
95325
- const { listActive: listActive2 } = await import("./pr-subscriptions-fzy3ks1k.js");
95433
+ const { listActive: listActive2 } = await import("./pr-subscriptions-8974hwa0.js");
95326
95434
  const records = await listActive2(directory);
95327
95435
  for (const record of records) {
95328
95436
  if (record.sessionID !== sessionID)
@@ -95768,7 +95876,7 @@ function isLaneOwnedByCurrentSession(branchName, expectedSessionId) {
95768
95876
  return extracted === expectedSessionId;
95769
95877
  }
95770
95878
  async function inspectStandardWorktreeCollisionOwnership(identity) {
95771
- const collisionOwnership = await import("./worktree-collision-ownership-pmpnftkd.js");
95879
+ const collisionOwnership = await import("./worktree-collision-ownership-r3jdke7h.js");
95772
95880
  return collisionOwnership.inspectStandardWorktreeCollisionOwnership(identity);
95773
95881
  }
95774
95882
  async function runRecoveryGit(directory, args, timeoutMs = 15000) {
@@ -96181,7 +96289,7 @@ async function precreateStandardWorktreeSession(args) {
96181
96289
  const laneProfile = computeLaneRuntimeProfile(worktreeConfig.runtime_isolation, laneIndex, handle.worktreePath);
96182
96290
  if (laneProfile) {
96183
96291
  try {
96184
- const { writeLaneProfileToDiskReal } = await import("./core-v11pd1yk.js");
96292
+ const { writeLaneProfileToDiskReal } = await import("./core-1d9vqbt4.js");
96185
96293
  await writeLaneProfileToDiskReal(handle.worktreePath, laneProfile.laneIndex, laneProfile.envOverrides);
96186
96294
  } catch {}
96187
96295
  }
@@ -96309,7 +96417,7 @@ async function preserveBackgroundWorktreeOwnershipForCallId(callID) {
96309
96417
  }
96310
96418
  const session = Buffer.from(dispatch.handle.sessionId, "utf8").toString("base64url");
96311
96419
  const lane = Buffer.from(dispatch.handle.id, "utf8").toString("base64url");
96312
- const callDigest = createHash39("sha256").update(callID).digest("hex").slice(0, 12);
96420
+ const callDigest = createHash40("sha256").update(callID).digest("hex").slice(0, 12);
96313
96421
  const tag = `swarm-preserved-owner/${session}/${lane}/${callDigest}`;
96314
96422
  let tagProc;
96315
96423
  try {
@@ -97115,7 +97223,7 @@ async function finishStandardWorktreeDispatch(directory, dispatch, config, callI
97115
97223
  }
97116
97224
  clearWorktreeMergeStatus(statusKey);
97117
97225
  try {
97118
- const { removeLaneProfileFromDiskReal } = await import("./core-v11pd1yk.js");
97226
+ const { removeLaneProfileFromDiskReal } = await import("./core-1d9vqbt4.js");
97119
97227
  await removeLaneProfileFromDiskReal(dispatch.handle.worktreePath, dispatch.laneIndex);
97120
97228
  } catch {}
97121
97229
  const state = serializationStateBySessionID.get(dispatch.parentSessionID);