opencode-swarm 7.177.1 → 7.178.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/binaries/win32-arm64/swarm-sandbox-runner.exe +0 -0
- package/binaries/win32-x64/swarm-sandbox-runner.exe +0 -0
- package/dist/agents/architect.d.ts +8 -0
- package/dist/cli/{capability-probe-pdwwz8gs.js → capability-probe-8k8ebeyp.js} +2 -2
- package/dist/cli/{coder-settlement-c0kysest.js → coder-settlement-m03dfyec.js} +13 -13
- package/dist/cli/{config-doctor-bqwse4pd.js → config-doctor-x8b260sh.js} +4 -4
- package/dist/cli/{core-e6vtme4x.js → core-2d0xcyby.js} +4 -4
- package/dist/cli/{curation-policy-d8s9w1z8.js → curation-policy-7am15ht9.js} +5 -5
- package/dist/cli/{curator-2xb1d80j.js → curator-5kfkqzc9.js} +41 -41
- package/dist/cli/{curator-drift-4m984tvy.js → curator-drift-d93pwt8h.js} +5 -5
- package/dist/cli/curator-llm-factory-rgdb2ee5.js +72 -0
- package/dist/cli/{evidence-summary-service-9yxm6jkq.js → evidence-summary-service-959pwbwb.js} +20 -20
- package/dist/cli/{gate-evidence-43bnst3v.js → gate-evidence-66kjx6zj.js} +8 -8
- package/dist/cli/guardrail-explain-rre9ntq3.js +73 -0
- package/dist/cli/{guardrail-log-j7cj3rjy.js → guardrail-log-t0ydqz5s.js} +9 -9
- package/dist/cli/{guardrail-reset-jcsyfvf4.js → guardrail-reset-6gad352a.js} +41 -41
- package/dist/cli/hive-promoter-zgnagx67.js +87 -0
- package/dist/cli/{index-tbswvz8s.js → index-0pmh1kks.js} +2 -2
- package/dist/cli/{index-fnq5ac3f.js → index-1hgqs8j8.js} +5 -5
- package/dist/cli/{index-bc4x76z7.js → index-1jcy4gc6.js} +41 -41
- package/dist/cli/{index-epsy1rh1.js → index-1qnykdaw.js} +43 -43
- package/dist/cli/{index-7c24bb1r.js → index-1zrrerev.js} +2 -2
- package/dist/cli/{index-5d2avnj9.js → index-2b0ktpbf.js} +2 -2
- package/dist/cli/{index-67amf4my.js → index-2e6txjp7.js} +3 -3
- package/dist/cli/{index-634pjhe4.js → index-2pyba37z.js} +7 -7
- package/dist/cli/{index-7nsvszwn.js → index-3pzwsesm.js} +2 -2
- package/dist/cli/{index-bqmxxbrw.js → index-4e4zsj2g.js} +7 -7
- package/dist/cli/{index-fpbcxykc.js → index-6b295cas.js} +87 -1
- package/dist/cli/{index-1042jnb9.js → index-6e8fpjdg.js} +7 -3
- package/dist/cli/{index-822hhbkc.js → index-7kty6f59.js} +9 -9
- package/dist/cli/{index-k6bjkqw8.js → index-7n4dtzk4.js} +1 -1
- package/dist/cli/{index-yzjaj53h.js → index-9rwhas09.js} +1 -1
- package/dist/cli/{index-yrs4wwfq.js → index-b50qevsm.js} +4 -4
- package/dist/cli/{index-v2he8xfj.js → index-bb148vht.js} +2 -2
- package/dist/cli/{index-hp5eet6g.js → index-byfrearz.js} +4 -4
- package/dist/cli/{index-fnw6zfh0.js → index-eq1n57tg.js} +1 -1
- package/dist/cli/{index-4ygb35m1.js → index-h0kyy9rd.js} +95 -229
- package/dist/cli/{index-eefz8ghz.js → index-h4nh6s8b.js} +1 -1
- package/dist/cli/{index-j82xdrqp.js → index-j7w16s92.js} +4 -4
- package/dist/cli/{index-t6q73twc.js → index-kj599831.js} +2 -2
- package/dist/cli/{index-drgt81xf.js → index-ksq6cqg0.js} +14 -7
- package/dist/cli/{index-tj0sdxg9.js → index-kz9pcqn9.js} +2 -2
- package/dist/cli/{index-n7nzwz0q.js → index-m2n1rhgv.js} +8 -0
- package/dist/cli/{index-yhaxn5r7.js → index-ne9zamcs.js} +9 -9
- package/dist/cli/{index-vfp9hjgv.js → index-nrfjjqm4.js} +1 -1
- package/dist/cli/{index-xnednxvm.js → index-nzekzzs2.js} +4 -4
- package/dist/cli/{index-2jtmevrr.js → index-pk97v7b8.js} +6 -6
- package/dist/cli/{index-7ntcak58.js → index-pyxs697r.js} +34 -9
- package/dist/cli/{index-m0cdjvtv.js → index-qbs49vge.js} +30 -2
- package/dist/cli/{index-qgf5xexz.js → index-r78kphsr.js} +4 -4
- package/dist/cli/{index-exhm2ztr.js → index-s4bkey0q.js} +1 -1
- package/dist/cli/{index-en0p0hqp.js → index-t8dqe4ns.js} +1 -1
- package/dist/cli/{index-t2nf57mv.js → index-w1b5qqnp.js} +2 -2
- package/dist/cli/{index-yepxmq4f.js → index-wajcx84s.js} +3418 -2893
- package/dist/cli/{index-1bq6hkw5.js → index-whjrhatw.js} +1 -1
- package/dist/cli/{index-76qm2c2y.js → index-wvghb3x6.js} +4 -4
- package/dist/cli/{index-fgv6qp10.js → index-x1m1nnry.js} +37 -6
- package/dist/cli/{index-k330631a.js → index-x54339yd.js} +5 -5
- package/dist/cli/{index-cv191ybt.js → index-xr3eye3f.js} +8 -8
- package/dist/cli/{index-wemtrnch.js → index-xr9n0vjv.js} +2 -2
- package/dist/cli/{index-eya03h5m.js → index-yew23624.js} +7 -7
- package/dist/cli/{index-e48h8m73.js → index-zv3j0v08.js} +9 -5
- package/dist/cli/index.js +42 -42
- package/dist/cli/{knowledge-escalator-j4jcpver.js → knowledge-escalator-5r6mww64.js} +13 -13
- package/dist/cli/{knowledge-events-fcpzfp2m.js → knowledge-events-typjw0sd.js} +11 -11
- package/dist/cli/{knowledge-link-9z3fha35.js → knowledge-link-mvykydxg.js} +4 -4
- package/dist/cli/{knowledge-store-6evy197p.js → knowledge-store-9qcf3emn.js} +5 -5
- package/dist/cli/{knowledge-validator-s28b1ddg.js → knowledge-validator-k6ydsxzy.js} +7 -7
- package/dist/cli/{mcp-9kqsnehc.js → mcp-tedxsgey.js} +48 -7
- package/dist/cli/mcp.d.ts +9 -0
- package/dist/cli/{model-preflight-1pp1a4yf.js → model-preflight-kh9dwts2.js} +1 -1
- package/dist/cli/{pending-delegations-e15f26e0.js → pending-delegations-d20fnrzv.js} +12 -12
- package/dist/cli/{pr-subscriptions-mqv51zvm.js → pr-subscriptions-awwhg139.js} +12 -12
- package/dist/cli/{pr-workflow-gate-fj31btdv.js → pr-workflow-gate-ke79bb9c.js} +41 -41
- package/dist/cli/{runner-yhfmejzb.js → runner-y3sydwtj.js} +5 -5
- package/dist/cli/{scan-cursor-tpnq7e56.js → scan-cursor-16s6dp7f.js} +6 -6
- package/dist/cli/{schema-1wwcyaxp.js → schema-nqjp43vq.js} +4 -2
- package/dist/cli/{scope-persistence-332nvn9b.js → scope-persistence-8z1hwdr2.js} +21 -17
- package/dist/cli/{server-19bpfaps.js → server-x16hp9aq.js} +2062 -741
- package/dist/cli/{skill-generator-gn1k4yxj.js → skill-generator-xadg43ph.js} +15 -15
- package/dist/cli/{snapshot-coordination-init-6ztt4v99.js → snapshot-coordination-init-3yyzb2c4.js} +41 -41
- package/dist/cli/{telemetry-w774xb8g.js → telemetry-c9wv2cfw.js} +1 -1
- package/dist/cli/{workspace-snapshot-9gqna7gq.js → workspace-snapshot-rfnn80dg.js} +3 -3
- package/dist/cli/{worktree-collision-ownership-q2ydb0ph.js → worktree-collision-ownership-drqhmmtd.js} +13 -13
- package/dist/cli/{worktree-isolation-fsqe1qdv.js → worktree-isolation-aebdyb1m.js} +41 -41
- package/dist/commands/dashboard.d.ts +15 -0
- package/dist/commands/registry.d.ts +7 -0
- package/dist/config/plan-schema.d.ts +23 -0
- package/dist/config/schema.d.ts +16 -0
- package/dist/dashboard/assets.d.ts +12 -0
- package/dist/dashboard/index.d.ts +74 -0
- package/dist/dashboard/server.d.ts +94 -0
- package/dist/dashboard/views.d.ts +131 -0
- package/dist/evidence/phase-participation.d.ts +3 -2
- package/dist/hooks/delegation-gate.d.ts +1 -1
- package/dist/hooks/extractors.d.ts +5 -1
- package/dist/hooks/index.d.ts +1 -1
- package/dist/hooks/tool-summarizer.d.ts +7 -2
- package/dist/index.js +676 -513
- package/dist/mcp/adapters/knowledge-add.d.ts +19 -0
- package/dist/mcp/adapters/receipt-status.d.ts +3 -0
- package/dist/mcp/adapters/scope-validation.d.ts +3 -0
- package/dist/mcp/registry.d.ts +26 -14
- package/dist/mcp/server.d.ts +5 -0
- package/dist/mcp/write-receipts.d.ts +168 -0
- package/dist/memory/index.d.ts +1 -0
- package/dist/memory/memory-family-migration.d.ts +35 -3
- package/dist/plan/ledger.d.ts +14 -0
- package/dist/plan/manager.d.ts +0 -2
- package/dist/plan/parallel-verdict.d.ts +28 -14
- package/dist/scope/scope-persistence.d.ts +41 -0
- package/dist/summaries/index.d.ts +1 -1
- package/dist/summaries/manager.d.ts +27 -1
- package/dist/tools/index.d.ts +2 -0
- package/dist/tools/knowledge-receipt-status.d.ts +8 -0
- package/dist/tools/manifest.d.ts +2 -0
- package/dist/tools/plan-conflict-check.d.ts +7 -6
- package/dist/tools/scope-validate.d.ts +55 -0
- package/dist/tools/tool-metadata.d.ts +8 -0
- package/dist/utils/path-security.d.ts +21 -0
- package/opencode-swarm.schema.json +14 -0
- package/package.json +1 -1
- package/dist/cli/curator-llm-factory-fywmb8jh.js +0 -72
- package/dist/cli/guardrail-explain-gm69b76w.js +0 -73
- package/dist/cli/hive-promoter-hc0r0z9h.js +0 -87
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
validateSwarmPath
|
|
4
|
-
} from "./index-
|
|
4
|
+
} from "./index-s4bkey0q.js";
|
|
5
5
|
import {
|
|
6
6
|
bunSpawn
|
|
7
7
|
} from "./index-2s7dvzff.js";
|
|
8
8
|
import {
|
|
9
9
|
atomicWriteSwarmFileSync
|
|
10
|
-
} from "./index-
|
|
10
|
+
} from "./index-ne9zamcs.js";
|
|
11
11
|
import {
|
|
12
12
|
canonicalRootKeyFresh
|
|
13
13
|
} from "./index-1xnse449.js";
|
|
@@ -22,7 +22,7 @@ import {
|
|
|
22
22
|
import {
|
|
23
23
|
SWARM_WORKTREE_DIR_NAME,
|
|
24
24
|
init_constants
|
|
25
|
-
} from "./index-
|
|
25
|
+
} from "./index-m2n1rhgv.js";
|
|
26
26
|
import {
|
|
27
27
|
init_logger,
|
|
28
28
|
log
|
|
@@ -244,7 +244,7 @@ var _internals2 = {
|
|
|
244
244
|
symlinkSync: fs2.symlinkSync
|
|
245
245
|
},
|
|
246
246
|
writeScopeToDisk: async (directory, taskId, files) => {
|
|
247
|
-
const { writeScopeToDisk: realWrite } = await import("./scope-persistence-
|
|
247
|
+
const { writeScopeToDisk: realWrite } = await import("./scope-persistence-8z1hwdr2.js");
|
|
248
248
|
return realWrite(directory, taskId, files);
|
|
249
249
|
},
|
|
250
250
|
writeLaneProfileToDisk: async (_worktreePath, _laneIndex, _envOverrides) => {
|
|
@@ -14,14 +14,14 @@ import {
|
|
|
14
14
|
detectWindowsWrites,
|
|
15
15
|
getSharedClassifierGuardrailBlock,
|
|
16
16
|
resolveWriteTargets
|
|
17
|
-
} from "./index-
|
|
17
|
+
} from "./index-wajcx84s.js";
|
|
18
18
|
import {
|
|
19
19
|
checkFileAuthority,
|
|
20
20
|
classifyFile,
|
|
21
21
|
isInDeclaredScope,
|
|
22
22
|
redactPath,
|
|
23
23
|
redactShellCommand
|
|
24
|
-
} from "./index-
|
|
24
|
+
} from "./index-x1m1nnry.js";
|
|
25
25
|
|
|
26
26
|
// src/services/guardrail-explain-service.ts
|
|
27
27
|
import path from "path";
|
|
@@ -2,31 +2,32 @@
|
|
|
2
2
|
import {
|
|
3
3
|
derivePlanId,
|
|
4
4
|
derivePlanIdentityHash
|
|
5
|
-
} from "./index-
|
|
5
|
+
} from "./index-whjrhatw.js";
|
|
6
6
|
import {
|
|
7
7
|
getProjectDb,
|
|
8
8
|
projectDbExists,
|
|
9
9
|
withImmediateTransaction,
|
|
10
10
|
withProjectDbReadOnly
|
|
11
|
-
} from "./index-
|
|
11
|
+
} from "./index-nzekzzs2.js";
|
|
12
12
|
import {
|
|
13
13
|
assertProjectRoot,
|
|
14
14
|
withEvidenceLock
|
|
15
|
-
} from "./index-
|
|
15
|
+
} from "./index-kz9pcqn9.js";
|
|
16
16
|
import {
|
|
17
17
|
emit
|
|
18
|
-
} from "./index-
|
|
18
|
+
} from "./index-pk97v7b8.js";
|
|
19
19
|
import {
|
|
20
20
|
ExecutionProfileSchema,
|
|
21
21
|
PlanSchema,
|
|
22
22
|
TaskStatusSchema,
|
|
23
23
|
init_loader,
|
|
24
|
-
loadPluginConfig
|
|
25
|
-
|
|
24
|
+
loadPluginConfig,
|
|
25
|
+
normalizeCurrentPhaseInPlace
|
|
26
|
+
} from "./index-qbs49vge.js";
|
|
26
27
|
import {
|
|
27
28
|
init_package,
|
|
28
29
|
package_default
|
|
29
|
-
} from "./index-
|
|
30
|
+
} from "./index-zv3j0v08.js";
|
|
30
31
|
import {
|
|
31
32
|
criticalWarn,
|
|
32
33
|
init_logger,
|
|
@@ -1747,6 +1748,12 @@ async function replayFromLedgerWithStatus(directory, _options) {
|
|
|
1747
1748
|
return { plan, truncated, badSuffix };
|
|
1748
1749
|
}
|
|
1749
1750
|
function reconstructPlanFromEvents(directory, events) {
|
|
1751
|
+
const plan = reconstructPlanFromEventsUnnormalized(directory, events);
|
|
1752
|
+
if (plan)
|
|
1753
|
+
normalizeCurrentPhaseInPlace(plan);
|
|
1754
|
+
return plan;
|
|
1755
|
+
}
|
|
1756
|
+
function reconstructPlanFromEventsUnnormalized(directory, events) {
|
|
1750
1757
|
const targetPlanId = events[0].plan_id;
|
|
1751
1758
|
const relevantEvents = events.filter((e) => e.plan_id === targetPlanId);
|
|
1752
1759
|
{
|
|
@@ -4,10 +4,10 @@ import {
|
|
|
4
4
|
} from "./index-7g4c7s5r.js";
|
|
5
5
|
import {
|
|
6
6
|
emit
|
|
7
|
-
} from "./index-
|
|
7
|
+
} from "./index-pk97v7b8.js";
|
|
8
8
|
import {
|
|
9
9
|
atomicWriteFileAnyRoot
|
|
10
|
-
} from "./index-
|
|
10
|
+
} from "./index-ne9zamcs.js";
|
|
11
11
|
import {
|
|
12
12
|
init_logger,
|
|
13
13
|
warn
|
|
@@ -509,6 +509,10 @@ var init_tool_metadata = __esm(() => {
|
|
|
509
509
|
description: "declare file scope for next coder delegation",
|
|
510
510
|
agents: ["architect"]
|
|
511
511
|
},
|
|
512
|
+
scope_validate: {
|
|
513
|
+
description: "validate shell writes against an inline file scope",
|
|
514
|
+
agents: ["architect"]
|
|
515
|
+
},
|
|
512
516
|
knowledge_query: {
|
|
513
517
|
description: "query swarm or hive knowledge with optional filters",
|
|
514
518
|
agents: ["architect", "skill_improver", "spec_writer"]
|
|
@@ -777,6 +781,10 @@ var init_tool_metadata = __esm(() => {
|
|
|
777
781
|
"test_engineer"
|
|
778
782
|
]
|
|
779
783
|
},
|
|
784
|
+
knowledge_receipt_status: {
|
|
785
|
+
description: "receipt status",
|
|
786
|
+
agents: ["architect"]
|
|
787
|
+
},
|
|
780
788
|
knowledge_archive: {
|
|
781
789
|
description: "archive (default), quarantine, or purge a swarm or hive knowledge entry by ID with an immutable audit tombstone; purge requires an admin flag",
|
|
782
790
|
agents: ["architect"]
|
|
@@ -229,12 +229,12 @@ var SWARM_TEMP_GRAMMARS = [
|
|
|
229
229
|
"src/evidence/task-file.ts (pre-#2035; migrated-to=src/evidence/task-file.ts:atomicWriteFile)",
|
|
230
230
|
"src/scope/scope-persistence.ts (pre-#2035; migrated-to=src/scope/scope-persistence.ts:atomicWrite)",
|
|
231
231
|
"src/scope/scope-persistence.ts (pre-#2035; migrated-to=src/scope/scope-persistence.ts:atomicWriteSync)",
|
|
232
|
-
"src/plan/manager.ts:
|
|
233
|
-
"src/plan/manager.ts:
|
|
234
|
-
"src/plan/manager.ts:
|
|
232
|
+
"src/plan/manager.ts:662",
|
|
233
|
+
"src/plan/manager.ts:1988",
|
|
234
|
+
"src/plan/manager.ts:2042",
|
|
235
235
|
"src/review/evidence.ts:175",
|
|
236
236
|
"src/turbo/lean/evidence.ts:182",
|
|
237
|
-
"src/summaries/manager.ts:
|
|
237
|
+
"src/summaries/manager.ts:163",
|
|
238
238
|
"src/evidence/manager.ts:288",
|
|
239
239
|
"src/evidence/manager.ts:456",
|
|
240
240
|
"src/tools/sast-baseline.ts:199",
|
|
@@ -247,7 +247,7 @@ var SWARM_TEMP_GRAMMARS = [
|
|
|
247
247
|
"src/evidence/phase-participation.ts (pre-#2035; migrated-to=src/evidence/phase-participation.ts:atomicWriteBytes)",
|
|
248
248
|
"src/turbo/lean/integration.ts:428",
|
|
249
249
|
"src/turbo/lean/reviewer.ts:403",
|
|
250
|
-
"src/plan/ledger.ts:
|
|
250
|
+
"src/plan/ledger.ts:1463",
|
|
251
251
|
"src/services/synonym-map.ts:389",
|
|
252
252
|
"src/services/skill-optimizer/store.ts:340",
|
|
253
253
|
"src/services/skill-optimizer/store.ts:503",
|
|
@@ -361,7 +361,7 @@ var SWARM_TEMP_GRAMMARS = [
|
|
|
361
361
|
token: "instance",
|
|
362
362
|
quarantineEligible: true,
|
|
363
363
|
parsesTarget: true,
|
|
364
|
-
producers: ["src/plan/manager.ts:
|
|
364
|
+
producers: ["src/plan/manager.ts:2390", "src/plan/manager.ts:2424"],
|
|
365
365
|
note: "plan-durability (invariant 5) fd-write paths; grammars registered, writers unchanged in this PR"
|
|
366
366
|
},
|
|
367
367
|
{
|
|
@@ -427,8 +427,8 @@ var SWARM_TEMP_GRAMMARS = [
|
|
|
427
427
|
"src/hooks/skill-usage-log.ts:1675",
|
|
428
428
|
"src/hooks/skill-usage-pending.ts:817",
|
|
429
429
|
"src/parallel/file-locks.ts:113",
|
|
430
|
-
"src/plan/ledger.ts:
|
|
431
|
-
"src/plan/ledger.ts:
|
|
430
|
+
"src/plan/ledger.ts:607",
|
|
431
|
+
"src/plan/ledger.ts:1777"
|
|
432
432
|
],
|
|
433
433
|
note: "constant-name temps: reported when stale, never auto-quarantined. file-locks meta sidecars live under the scanner-skipped .swarm/locks/ subtree; the ledger reconcile temp embeds instance tokens but its .tmp-suffix shape maps here (conservatively report-only)"
|
|
434
434
|
}
|
|
@@ -726,4 +726,4 @@ async function atomicWriteFileAnyRoot(targetPath, content, options) {
|
|
|
726
726
|
writeAtomicSync(targetPath, content, { ...options, contained: false });
|
|
727
727
|
}
|
|
728
728
|
|
|
729
|
-
export { wasObservedToExist, readCachedTextFile, readCachedParsedFile, invalidateCachedArtifact, resetSwarmArtifactCache, matchTempGrammar, parseTargetBasename, RECENT_WRITE_WINDOW_MS, wasRecentlyWrittenByThisProcess, atomicWriteSwarmFile, atomicWriteSwarmFileSync, atomicWriteFileAnyRoot };
|
|
729
|
+
export { wasObservedToExist, readCachedTextFile, readCachedParsedFile, invalidateCachedArtifact, resetSwarmArtifactCache, matchTempGrammar, parseTargetBasename, assertSwarmContainedTarget, RECENT_WRITE_WINDOW_MS, wasRecentlyWrittenByThisProcess, atomicWriteSwarmFile, atomicWriteSwarmFileSync, atomicWriteFileAnyRoot };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
import {
|
|
3
|
-
loadDatabaseCtor
|
|
4
|
-
} from "./index-rdm3px0g.js";
|
|
5
2
|
import {
|
|
6
3
|
canonicalExistingFilesystemPath
|
|
7
4
|
} from "./index-ry16d01s.js";
|
|
5
|
+
import {
|
|
6
|
+
loadDatabaseCtor
|
|
7
|
+
} from "./index-rdm3px0g.js";
|
|
8
8
|
import {
|
|
9
9
|
atomicWriteSwarmFileSync
|
|
10
|
-
} from "./index-
|
|
10
|
+
} from "./index-ne9zamcs.js";
|
|
11
11
|
import {
|
|
12
12
|
canonicalRootKeyFresh,
|
|
13
13
|
lexicalRootAliasKey
|
|
@@ -236,7 +236,7 @@ var CATALOG_SOURCE = [
|
|
|
236
236
|
category: "delegation",
|
|
237
237
|
severity: "info",
|
|
238
238
|
privacyClass: "pseudonymous",
|
|
239
|
-
producer: "src/index.ts:
|
|
239
|
+
producer: "src/index.ts:869",
|
|
240
240
|
consumers: CONSUMER_COST_CORRECTION,
|
|
241
241
|
retentionOwnerIssue: ISSUE_COST_RETENTION,
|
|
242
242
|
requiredWorkflowIds: REQUIRE_SESSION_AND_TASK,
|
|
@@ -249,7 +249,7 @@ var CATALOG_SOURCE = [
|
|
|
249
249
|
category: "delegation",
|
|
250
250
|
severity: "info",
|
|
251
251
|
privacyClass: "pseudonymous",
|
|
252
|
-
producer: "src/index.ts:
|
|
252
|
+
producer: "src/index.ts:1886",
|
|
253
253
|
consumers: NO_CONSUMERS,
|
|
254
254
|
futureOwnerIssue: ISSUE_SINK,
|
|
255
255
|
retentionOwnerIssue: ISSUE_COST_RETENTION,
|
|
@@ -263,7 +263,7 @@ var CATALOG_SOURCE = [
|
|
|
263
263
|
category: "delegation",
|
|
264
264
|
severity: "notice",
|
|
265
265
|
privacyClass: "pseudonymous",
|
|
266
|
-
producer: "src/index.ts:
|
|
266
|
+
producer: "src/index.ts:1906",
|
|
267
267
|
consumers: CONSUMER_COST_JOIN,
|
|
268
268
|
retentionOwnerIssue: ISSUE_COST_RETENTION,
|
|
269
269
|
requiredWorkflowIds: REQUIRE_SESSION,
|
|
@@ -735,7 +735,7 @@ var CATALOG_SOURCE = [
|
|
|
735
735
|
category: "plan",
|
|
736
736
|
severity: "notice",
|
|
737
737
|
privacyClass: "operational",
|
|
738
|
-
producer: "src/plan/manager.ts:
|
|
738
|
+
producer: "src/plan/manager.ts:359",
|
|
739
739
|
consumers: NO_CONSUMERS,
|
|
740
740
|
futureOwnerIssue: ISSUE_SINK,
|
|
741
741
|
retentionOwnerIssue: ISSUE_PLAN_EVIDENCE_RETENTION,
|
|
@@ -748,7 +748,7 @@ var CATALOG_SOURCE = [
|
|
|
748
748
|
category: "plan",
|
|
749
749
|
severity: "warning",
|
|
750
750
|
privacyClass: "sensitive",
|
|
751
|
-
producer: "src/plan/manager.ts:
|
|
751
|
+
producer: "src/plan/manager.ts:2065",
|
|
752
752
|
consumers: NO_CONSUMERS,
|
|
753
753
|
futureOwnerIssue: ISSUE_SINK,
|
|
754
754
|
retentionOwnerIssue: ISSUE_PLAN_EVIDENCE_RETENTION,
|
|
@@ -761,7 +761,7 @@ var CATALOG_SOURCE = [
|
|
|
761
761
|
category: "plan",
|
|
762
762
|
severity: "error",
|
|
763
763
|
privacyClass: "sensitive",
|
|
764
|
-
producer: "src/plan/ledger.ts:
|
|
764
|
+
producer: "src/plan/ledger.ts:1609",
|
|
765
765
|
consumers: NO_CONSUMERS,
|
|
766
766
|
futureOwnerIssue: ISSUE_SINK,
|
|
767
767
|
retentionOwnerIssue: ISSUE_PLAN_EVIDENCE_RETENTION,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
computePlanStructureHash
|
|
4
|
-
} from "./index-
|
|
4
|
+
} from "./index-ksq6cqg0.js";
|
|
5
5
|
import {
|
|
6
6
|
appendCoreEventSync
|
|
7
|
-
} from "./index-
|
|
7
|
+
} from "./index-w1b5qqnp.js";
|
|
8
8
|
import {
|
|
9
9
|
deleteCoordinationState,
|
|
10
10
|
derivePlanId,
|
|
@@ -13,31 +13,31 @@ import {
|
|
|
13
13
|
transitionCoordinationState,
|
|
14
14
|
transitionCoordinationStateWithinTransaction,
|
|
15
15
|
withCoordinationTransaction
|
|
16
|
-
} from "./index-
|
|
16
|
+
} from "./index-whjrhatw.js";
|
|
17
17
|
import {
|
|
18
18
|
getProjectDb
|
|
19
|
-
} from "./index-
|
|
19
|
+
} from "./index-nzekzzs2.js";
|
|
20
20
|
import {
|
|
21
21
|
canonicalExistingFilesystemPath,
|
|
22
22
|
legacyCanonicalExistingFilesystemPath
|
|
23
23
|
} from "./index-ry16d01s.js";
|
|
24
24
|
import {
|
|
25
25
|
assertProjectRoot
|
|
26
|
-
} from "./index-
|
|
26
|
+
} from "./index-kz9pcqn9.js";
|
|
27
27
|
import {
|
|
28
28
|
require_proper_lockfile
|
|
29
29
|
} from "./index-7g4c7s5r.js";
|
|
30
30
|
import {
|
|
31
31
|
atomicWriteSwarmFile,
|
|
32
32
|
atomicWriteSwarmFileSync
|
|
33
|
-
} from "./index-
|
|
33
|
+
} from "./index-ne9zamcs.js";
|
|
34
34
|
import {
|
|
35
35
|
PlanSchema
|
|
36
|
-
} from "./index-
|
|
36
|
+
} from "./index-qbs49vge.js";
|
|
37
37
|
import {
|
|
38
38
|
init_path_identity,
|
|
39
39
|
unsafePathTextReason
|
|
40
|
-
} from "./index-
|
|
40
|
+
} from "./index-9rwhas09.js";
|
|
41
41
|
import {
|
|
42
42
|
__toESM
|
|
43
43
|
} from "./index-a76rekgs.js";
|
|
@@ -1179,6 +1179,31 @@ function readScopeBindingFromDisk(input) {
|
|
|
1179
1179
|
});
|
|
1180
1180
|
return resolved.status === "found" ? resolved.binding : null;
|
|
1181
1181
|
}
|
|
1182
|
+
function readDeclaredScopeFilesFromBindings(input) {
|
|
1183
|
+
if (!isSafeTaskId(input.taskId))
|
|
1184
|
+
return null;
|
|
1185
|
+
const set = input.bindingSet !== undefined ? input.bindingSet : readAuthoritativeScopeBindingSet(input.directory);
|
|
1186
|
+
if (set === null)
|
|
1187
|
+
return null;
|
|
1188
|
+
const planId = derivePlanId(input.plan);
|
|
1189
|
+
const structureHash = computePlanStructureHash(input.plan);
|
|
1190
|
+
const now = Date.now();
|
|
1191
|
+
const candidates = set.filter((binding) => binding.taskId === input.taskId && binding.planId === planId && binding.planStructureHash === structureHash && binding.lifecycleState === "live" && binding.expiresAt > now);
|
|
1192
|
+
if (candidates.length < 1)
|
|
1193
|
+
return null;
|
|
1194
|
+
const first = [...candidates[0].files].sort().join(`
|
|
1195
|
+
`);
|
|
1196
|
+
const agreeing = candidates.every((candidate) => [...candidate.files].sort().join(`
|
|
1197
|
+
`) === first);
|
|
1198
|
+
if (!agreeing)
|
|
1199
|
+
return null;
|
|
1200
|
+
const files = candidates[0].files;
|
|
1201
|
+
return Array.isArray(files) && files.length > 0 ? files : null;
|
|
1202
|
+
}
|
|
1203
|
+
function readAuthoritativeScopeBindingSet(directory) {
|
|
1204
|
+
const set = readAllAuthoritativeScopeBindings(directory);
|
|
1205
|
+
return set.ok ? set.value : null;
|
|
1206
|
+
}
|
|
1182
1207
|
function resolveScopeBindingFromDisk(input) {
|
|
1183
1208
|
if (!isSafeTaskId(input.taskId))
|
|
1184
1209
|
return { status: "not_declared" };
|
|
@@ -2015,4 +2040,4 @@ function resolveScopeWithFallbacks(input) {
|
|
|
2015
2040
|
return null;
|
|
2016
2041
|
}
|
|
2017
2042
|
|
|
2018
|
-
export { MAX_PENDING_SCOPE_BINDINGS, canonicalWorkspaceIdentity, clearScopeBindings, writeScopeToDisk, writeScopeBindingToDisk, persistAndRegisterScopeBinding, readScopeBindingFromDisk, resolveScopeBindingFromDisk, clearScopeBindingFromDisk, tombstoneScopeBinding, refreshScopeBindingLease, claimScopeBindingForChildDurably, replaceExistingScopeDeclaration, flushScopeBindingMaintenance, pruneScopeBindingTombstones, resolveAuthorizedScopeBinding, resolveAuthorizedScopeBindingDetailed, resolveAuthorizedScopeBindingForSession, resolveAuthorizedScopeBindingForSessionDetailed, resolveAuthorizedPrFeedbackScopeBindingFromDisk, _scopePersistenceInternals, readScopeFromDisk, readPlanScope, clearScopeForTask, clearAllScopes, resolveScopeWithFallbacks };
|
|
2043
|
+
export { MAX_PENDING_SCOPE_BINDINGS, canonicalWorkspaceIdentity, normalizeScopeFiles, clearScopeBindings, writeScopeToDisk, writeScopeBindingToDisk, persistAndRegisterScopeBinding, readScopeBindingFromDisk, readDeclaredScopeFilesFromBindings, readAuthoritativeScopeBindingSet, resolveScopeBindingFromDisk, clearScopeBindingFromDisk, tombstoneScopeBinding, refreshScopeBindingLease, claimScopeBindingForChildDurably, replaceExistingScopeDeclaration, flushScopeBindingMaintenance, pruneScopeBindingTombstones, resolveAuthorizedScopeBinding, resolveAuthorizedScopeBindingDetailed, resolveAuthorizedScopeBindingForSession, resolveAuthorizedScopeBindingForSessionDetailed, resolveAuthorizedPrFeedbackScopeBindingFromDisk, _scopePersistenceInternals, readScopeFromDisk, readPlanScope, clearScopeForTask, clearAllScopes, resolveScopeWithFallbacks };
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
PluginConfigSchema,
|
|
15
15
|
init_schema,
|
|
16
16
|
resolveExternalSkillsConfig
|
|
17
|
-
} from "./index-
|
|
17
|
+
} from "./index-zv3j0v08.js";
|
|
18
18
|
import {
|
|
19
19
|
exports_external,
|
|
20
20
|
init_zod
|
|
@@ -872,5 +872,33 @@ var PlanSchema = exports_external.object({
|
|
|
872
872
|
specHash: exports_external.string().optional(),
|
|
873
873
|
execution_profile: ExecutionProfileSchema.optional()
|
|
874
874
|
});
|
|
875
|
+
function isPhaseStatusTerminal(status) {
|
|
876
|
+
return status === "complete" || status === "completed" || status === "closed";
|
|
877
|
+
}
|
|
878
|
+
function isPhaseEffectivelyTerminal(phase) {
|
|
879
|
+
if (isPhaseStatusTerminal(phase.status))
|
|
880
|
+
return true;
|
|
881
|
+
const tasks = phase.tasks ?? [];
|
|
882
|
+
return tasks.length > 0 && tasks.every((task) => task.status === "completed" || task.status === "closed");
|
|
883
|
+
}
|
|
884
|
+
function resolveActivePhaseId(plan) {
|
|
885
|
+
const cursor = plan.current_phase;
|
|
886
|
+
if (cursor !== undefined) {
|
|
887
|
+
const cursorPhase = plan.phases.find((phase) => phase.id === cursor);
|
|
888
|
+
if (cursorPhase && !isPhaseEffectivelyTerminal(cursorPhase)) {
|
|
889
|
+
return cursorPhase.id;
|
|
890
|
+
}
|
|
891
|
+
}
|
|
892
|
+
const firstNonTerminal = plan.phases.find((phase) => !isPhaseEffectivelyTerminal(phase));
|
|
893
|
+
if (firstNonTerminal)
|
|
894
|
+
return firstNonTerminal.id;
|
|
895
|
+
return plan.phases[plan.phases.length - 1]?.id ?? 1;
|
|
896
|
+
}
|
|
897
|
+
function normalizeCurrentPhaseInPlace(plan) {
|
|
898
|
+
plan.current_phase = resolveActivePhaseId(plan);
|
|
899
|
+
}
|
|
900
|
+
function getCurrentPhase(plan) {
|
|
901
|
+
return resolveActivePhaseId(plan);
|
|
902
|
+
}
|
|
875
903
|
|
|
876
|
-
export { loadPluginConfig, loadPluginConfigWithMeta, loadGateOverrides, resetConfigAdvisoryDedup, getSafeDefaultConfigLoadResult, loadPluginConfigWithMetaAsync, loadAgentPrompt, exports_loader, init_loader, ExecutionProfileSchema, TaskStatusSchema, TaskSizeSchema, PhaseStatusSchema, MigrationStatusSchema, TaskSchema, PhaseSchema, PlanSchema };
|
|
904
|
+
export { loadPluginConfig, loadPluginConfigWithMeta, loadGateOverrides, resetConfigAdvisoryDedup, getSafeDefaultConfigLoadResult, loadPluginConfigWithMetaAsync, loadAgentPrompt, exports_loader, init_loader, ExecutionProfileSchema, TaskStatusSchema, TaskSizeSchema, PhaseStatusSchema, MigrationStatusSchema, TaskSchema, PhaseSchema, PlanSchema, resolveActivePhaseId, normalizeCurrentPhaseInPlace, getCurrentPhase };
|
|
@@ -5,18 +5,18 @@ import {
|
|
|
5
5
|
import {
|
|
6
6
|
effectiveRetrievalOutcomes,
|
|
7
7
|
readAuthoritativeKnowledgeCounterRollups
|
|
8
|
-
} from "./index-
|
|
8
|
+
} from "./index-xr3eye3f.js";
|
|
9
9
|
import {
|
|
10
10
|
ALLOWED_SKILL_PATH_PREFIXES,
|
|
11
11
|
validateSkillPath
|
|
12
|
-
} from "./index-
|
|
12
|
+
} from "./index-b50qevsm.js";
|
|
13
13
|
import {
|
|
14
14
|
computeOutcomeSignal,
|
|
15
15
|
readKnowledge,
|
|
16
16
|
resolveHiveKnowledgePath,
|
|
17
17
|
resolveSwarmKnowledgePath,
|
|
18
18
|
transactKnowledge
|
|
19
|
-
} from "./index-
|
|
19
|
+
} from "./index-2pyba37z.js";
|
|
20
20
|
import {
|
|
21
21
|
appendCappedJsonl,
|
|
22
22
|
resolveRetentionCap
|
|
@@ -24,7 +24,7 @@ import {
|
|
|
24
24
|
import {
|
|
25
25
|
atomicWriteFileAnyRoot,
|
|
26
26
|
atomicWriteSwarmFile
|
|
27
|
-
} from "./index-
|
|
27
|
+
} from "./index-ne9zamcs.js";
|
|
28
28
|
import {
|
|
29
29
|
canonicalRootKeyFresh
|
|
30
30
|
} from "./index-1xnse449.js";
|