opencode-swarm 7.125.0 → 7.125.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.
Files changed (47) hide show
  1. package/.opencode/skills/swarm-pr-feedback/SKILL.md +11 -127
  2. package/.opencode/skills/swarm-pr-feedback/references/bot-claim-verification.md +71 -0
  3. package/.opencode/skills/swarm-pr-feedback/references/operational-gotchas.md +49 -0
  4. package/.opencode/skills/swarm-pr-review/SKILL.md +6 -346
  5. package/.opencode/skills/swarm-pr-review/references/parser-dry-run.md +235 -0
  6. package/.opencode/skills/swarm-pr-review/references/prompt-templates.md +103 -0
  7. package/.opencode/skills/writing-tests/SKILL.md +4 -123
  8. package/.opencode/skills/writing-tests/references/mock-and-seam-inventory.md +43 -0
  9. package/dist/cli/{config-doctor-be9sxqx8.js → config-doctor-g3m2q646.js} +2 -2
  10. package/dist/cli/{curation-policy-52kt6d7t.js → curation-policy-vgbx8530.js} +2 -2
  11. package/dist/cli/{curator-llm-factory-frde1955.js → curator-llm-factory-7pvqy94w.js} +13 -13
  12. package/dist/cli/{curator-hbst8nbc.js → curator-xk4g1nx2.js} +13 -13
  13. package/dist/cli/{evidence-summary-service-9hq7n9k9.js → evidence-summary-service-v4h2w487.js} +1 -1
  14. package/dist/cli/{guardrail-explain-112kqmbc.js → guardrail-explain-wfk16bpr.js} +14 -14
  15. package/dist/cli/{guardrail-log-c8zcab91.js → guardrail-log-5zz9xx6z.js} +3 -3
  16. package/dist/cli/{hive-promoter-448xs2tp.js → hive-promoter-njwc5rt0.js} +13 -13
  17. package/dist/cli/{index-kt0awv1n.js → index-3k8pg467.js} +1 -1
  18. package/dist/cli/{index-n6chz2g8.js → index-83rwq7pb.js} +1 -1
  19. package/dist/cli/{index-xattnmyb.js → index-8yvqkbw7.js} +3 -1
  20. package/dist/cli/{index-99ed0h32.js → index-93cq8t5b.js} +5 -5
  21. package/dist/cli/{index-9hbwa5x1.js → index-cz6fv84h.js} +15 -15
  22. package/dist/cli/{index-amspa811.js → index-dsf1yv4s.js} +119 -44
  23. package/dist/cli/{index-4rzzzjtg.js → index-fs02c7tz.js} +277 -16
  24. package/dist/cli/{index-dx2c2wjt.js → index-ghteqdy1.js} +2 -2
  25. package/dist/cli/{index-67hqr2zv.js → index-kvrk3h8p.js} +1 -1
  26. package/dist/cli/{index-09vd53pz.js → index-kws8zn6y.js} +1 -1
  27. package/dist/cli/{index-7j3sm7h8.js → index-mhhmecsw.js} +2 -2
  28. package/dist/cli/{index-yt1v62pv.js → index-mwdcvh0e.js} +4 -4
  29. package/dist/cli/{index-6vfvc36k.js → index-pbjenws7.js} +1 -1
  30. package/dist/cli/{index-958hf0yr.js → index-rpg8qqjs.js} +2 -2
  31. package/dist/cli/{index-vtwqjr4z.js → index-tn3shyqj.js} +3 -3
  32. package/dist/cli/{index-jh6s75f6.js → index-txragda9.js} +1 -1
  33. package/dist/cli/{index-0y6tmm9v.js → index-z4sc6yxc.js} +1 -1
  34. package/dist/cli/index.js +13 -13
  35. package/dist/cli/{knowledge-escalator-htafbhxg.js → knowledge-escalator-jtyykzqc.js} +3 -3
  36. package/dist/cli/{knowledge-events-havw8c4t.js → knowledge-events-qhr97sy9.js} +1 -1
  37. package/dist/cli/{knowledge-store-hqngpt2v.js → knowledge-store-332x3pjv.js} +1 -1
  38. package/dist/cli/{knowledge-validator-g7mpnazh.js → knowledge-validator-3t8tgzsz.js} +4 -4
  39. package/dist/cli/{scan-cursor-sx7cvh8v.js → scan-cursor-q21c9k9q.js} +2 -2
  40. package/dist/cli/{schema-2418eqy3.js → schema-y2d7j2jk.js} +1 -1
  41. package/dist/cli/{skill-generator-zggy797r.js → skill-generator-3gkxx98d.js} +5 -5
  42. package/dist/commands/close.d.ts +4 -2
  43. package/dist/config/schema.d.ts +4 -0
  44. package/dist/evidence/documents-retention.d.ts +116 -0
  45. package/dist/evidence/manager.d.ts +17 -0
  46. package/dist/index.js +374 -366
  47. package/package.json +1 -1
@@ -0,0 +1,103 @@
1
+ # Reviewer Prompt Template
2
+
3
+ Use this template when dispatching reviewer subagents:
4
+
5
+ ```text
6
+ You are the independent reviewer. Validate only the candidates assigned below.
7
+ Do not search for new issues except where needed to validate reachability or mitigation.
8
+ Do not trust explorer severity.
9
+
10
+ Context pack summary:
11
+ - scope: ...
12
+ - obligations: ...
13
+ - impact cone: ...
14
+ - deterministic signals: ...
15
+ - relevant Swarm artifacts / knowledge: ...
16
+ - base_ref: <commit SHA of base branch>
17
+ - head_ref: <commit SHA of PR head branch>
18
+
19
+ Candidates:
20
+ - ...
21
+
22
+ For each candidate, return:
23
+ [REVIEWED] | candidate_id | CONFIRMED/DISPROVED/UNVERIFIED/PRE_EXISTING | evidence_type | final_severity | introduced_by_pr | file:line | rationale | falsification_probe | reviewer_id
24
+
25
+ You must check caller context, reachability, schema/middleware/framework mitigations, state-machine constraints, test coverage, PR-introducedness, and severity.
26
+
27
+ IMPORTANT: If a finding claims behavior is "new" or "introduced by the PR", you MUST read the equivalent code on the base branch (git show <base_ref>:<file>) to verify it was not present before. A reviewer claim of "this is new" is invalid without base-branch evidence. Do not compare the new code to an idealized baseline — compare it to what actually existed on the base branch at the time of the PR.
28
+ ```
29
+
30
+ ---
31
+
32
+ # Critic Prompt Template
33
+
34
+ Use this template when dispatching critic subagents:
35
+
36
+ ```text
37
+ You are the adversarial critic. Challenge only reviewer-confirmed findings assigned below.
38
+ Your goal is to reduce false positives, severity inflation, and non-actionable reports.
39
+
40
+ For each finding, challenge:
41
+ - whether evidence proves the claim,
42
+ - whether the path is reachable,
43
+ - whether mitigations apply,
44
+ - whether severity is inflated,
45
+ - whether it is PR-introduced,
46
+ - whether suggested fixes are safe/actionable,
47
+ - whether related files were missed,
48
+ - whether multiple findings should be grouped.
49
+
50
+ Return:
51
+ [CRITIC] | finding_id | UPHELD/DOWNGRADED/DISPROVED/NEEDS_MORE_EVIDENCE | final_severity | reason | required_report_change
52
+
53
+ REQUIRED FINAL LINE — your final line MUST be exactly the row above (no variations, no labeled fields, no placeholders):
54
+ [CRITIC] | finding_id | UPHELD/DOWNGRADED/DISPROVED/NEEDS_MORE_EVIDENCE | final_severity | reason | required_report_change
55
+
56
+ A response without this exact row is treated as a planning preamble and re-dispatched. Do not output only a planning or investigation message.
57
+ ```
58
+
59
+ ---
60
+
61
+ # Explorer Prompt Template
62
+
63
+ Use this template when dispatching base explorer or micro-lane agents:
64
+
65
+ ```text
66
+ You are an explorer. Optimize for recall, not final judgment.
67
+ Return candidates only. Do not use CONFIRMED, DISPROVED, or PRE_EXISTING.
68
+
69
+ Lane:
70
+ Scope:
71
+ base_ref:
72
+ head_ref:
73
+ Obligations:
74
+ Changed files/hunks:
75
+ Impact cone:
76
+ Relevant deterministic signals:
77
+ Relevant Swarm artifacts / knowledge:
78
+ Checklist:
79
+
80
+ You must inspect or mark unavailable:
81
+ 1. changed hunk,
82
+ 2. caller/consumer,
83
+ 3. callee/dependency,
84
+ 4. sibling implementation or prior pattern,
85
+ 5. nearest test or missing-test location,
86
+ 6. deterministic signals,
87
+ 7. Swarm artifacts/knowledge,
88
+ 8. the exact `base_sha...pr_head_sha` merge-base range and both endpoint revisions.
89
+
90
+ Return:
91
+ [CANDIDATE] | candidate_id | lane | severity | category | file:line | claim | evidence_summary | impact_context | confidence
92
+ Emit the marker-bearing header once, then unprefixed data rows.
93
+ For a clean micro-lane, emit `[CLEAN] | micro_lane | coverage_scope | evidence`.
94
+ For a clean base lane, emit `[CLEAN] | workflow_lane | coverage_scope | evidence`.
95
+ ```
96
+
97
+ The orchestrator extracts candidates from the full lane artifact via
98
+ `parse_lane_candidates` as the primary mechanism. The `[CANDIDATE]` row
99
+ format above is a fallback convention for environments where the parser is
100
+ unavailable. Explorers should still emit structured records regardless of
101
+ whether the parser is present.
102
+
103
+ Do not let speed degrade validation quality.
@@ -619,44 +619,6 @@ authority checks:
619
619
 
620
620
  For the full splitting protocol (describe-block extraction, shared helper management, pure-function extraction, mock isolation verification, cascading-split detection), read `file:.swarm/bundled-skills/test-file-split/SKILL.md`.
621
621
 
622
- ### Checking file length
623
-
624
- ```bash
625
- # Check a single file
626
- wc -l tests/unit/scripts/my-test.test.ts
627
-
628
- # Find all test files exceeding 400 lines (early warning threshold)
629
- find tests/ -name "*.test.ts" -exec wc -l {} \; | sort -rn | awk '$1 > 400'
630
- ```
631
-
632
- ### Splitting pattern
633
-
634
- When a test file approaches or exceeds 500 lines, split it by extracting cohesive `describe()` blocks into a new file with a descriptive suffix:
635
-
636
- 1. **Identify natural boundaries.** Group `describe()` blocks by functional area (e.g., SHA resolution, validation, merge logic).
637
- 2. **Create the new file** with a descriptive suffix: `<module>-<area>.test.ts` (e.g., `release-notes-fragments-sha.test.ts`, `release-notes-fragments-validation.test.ts`).
638
- 3. **Move shared imports and helpers.** Either:
639
- - Duplicate shared imports in both files (simple, for small overlap), OR
640
- - Extract shared test helpers to a utility module (e.g., `tests/helpers/<module>-shared.ts`) and import from both files (preferred for complex shared setup).
641
- 4. **Extract testable pure functions.** If the source module has inline validation logic (e.g., `isValidPrNumber`), extract it as an exported pure function so both test files can target it independently.
642
- 5. **Verify both files are under 500 lines.**
643
- 6. **Run both files independently AND co-run** to verify no mock isolation breakage:
644
- ```bash
645
- bun --smol test tests/unit/scripts/release-notes-fragments.test.ts --timeout 60000
646
- bun --smol test tests/unit/scripts/release-notes-fragments-sha.test.ts --timeout 60000
647
- bun --smol test tests/unit/scripts/release-notes-fragments*.test.ts --timeout 60000
648
- ```
649
-
650
- ### When to split vs refactor
651
-
652
- - **Split** when there are natural `describe()` boundaries (e.g., one file per functional area).
653
- - **Refactor** when the file is a single monolithic test with no clear boundaries — consolidate test logic instead.
654
- - **Warning:** If a previously split file exceeds 500 lines again, the test suite is structurally too large. Reorganize by module rather than continuing to split.
655
-
656
- ### Reference
657
-
658
- See PR #1762 for a real-world example: `release-notes-fragments.test.ts` was split into `release-notes-fragments.test.ts` (379 lines) + `release-notes-fragments-sha.test.ts` (261 lines).
659
-
660
622
  ## Cross-Entry Invariants (config maps)
661
623
 
662
624
  When you modify any entry of a "map of agents/tools/roles" in `src/config/constants.ts` (`AGENT_TOOL_MAP`, `DEFAULT_MODELS`, `QA_AGENTS`, `PIPELINE_AGENTS`, etc.) or tool-name registration in `src/tools/tool-names.ts`, there are tests that assert **parity across sibling entries**, not just shape of one entry.
@@ -847,50 +809,7 @@ try {
847
809
 
848
810
  ## Running Tests
849
811
 
850
- ### bash (Linux / macOS)
851
-
852
- ```bash
853
- # Single file
854
- bun test src/hooks/scope-guard.test.ts
855
-
856
- # Batch directory (safe for dirs without mock conflicts)
857
- bun --smol test tests/unit/hooks --timeout 30000
858
-
859
- # Per-file loop (required for tools/services/agents — prevents mock poisoning)
860
- for f in tests/unit/tools/*.test.ts; do bun --smol test "$f" --timeout 30000; done
861
-
862
- # CI-equivalent run for batch steps (step 2: cli; step 3: commands + config)
863
- bun --smol test tests/unit/cli --timeout 120000
864
- bun --smol test tests/unit/commands tests/unit/config --timeout 120000
865
- ```
866
-
867
- ### PowerShell (Windows)
868
-
869
- ```powershell
870
- # Single file
871
- bun test src/hooks/scope-guard.test.ts
872
-
873
- # Batch directory (safe for dirs without mock conflicts)
874
- bun --smol test tests/unit/hooks --timeout 30000
875
-
876
- # Per-file loop (required for tools/services/agents — prevents mock poisoning)
877
- Get-ChildItem tests/unit/tools/*.test.ts | ForEach-Object { bun --smol test $_.FullName --timeout 30000 }
878
-
879
- # CI-equivalent run for batch steps (step 2: cli; step 3: commands + config)
880
- bun --smol test tests/unit/cli --timeout 120000
881
- bun --smol test tests/unit/commands tests/unit/config --timeout 120000
882
-
883
- # Capture output to file (avoids truncation when output is large)
884
- bun --smol test tests/unit/agents --timeout 60000 | Out-File "$env:TEMP\test_out.txt"; Get-Content "$env:TEMP\test_out.txt" | Select-Object -Last 50
885
- ```
886
-
887
- **Note:** `for f in ...; do` bash syntax is invalid in PowerShell. Use `Get-ChildItem | ForEach-Object` instead. `Select-String -Last N` is also invalid — use `Select-Object -Last N`.
888
-
889
- **Warning:** Running `bun --smol test tests/unit/tools` as a single batch will cause mock poisoning failures. Always use the per-file loop for the per-file-isolation steps (1a, 1b, 4-6: tools, services, agents, etc.).
890
-
891
- The `--smol` flag reduces Bun's memory footprint. Use it when running large directories (50+ files).
892
-
893
- The `--timeout 120000` flag sets per-test timeout to 120 seconds. Individual tests should complete in under 5 seconds. If a test needs more than 10 seconds, it's doing too much — split it or mock the slow dependency.
812
+ For the full test execution commands (bash and PowerShell per-file isolation loops, CI integration), read `file:.swarm/bundled-skills/running-tests/SKILL.md`. The key principle: always run one test file per process (`bun --smol test <file> --timeout 30000`) to prevent `mock.module` cross-contamination.
894
813
 
895
814
  ## Before Submitting
896
815
 
@@ -905,44 +824,6 @@ The `--timeout 120000` flag sets per-test timeout to 120 seconds. Individual tes
905
824
 
906
825
  Pre-existing and flaky failures are tracked in the per-platform quarantine ledgers (`scripts/ci/quarantined-tests.txt`, `quarantined-tests-macos.txt`, `quarantined-tests-windows.txt`), not in this skill. To confirm a failure is pre-existing, reproduce it in a clean worktree on `origin/main` (see the worktree verify protocol in `running-tests`).
907
826
 
908
- ## Known Cross-module mock.module Locations
909
-
910
- The following directories contain test files that use cross-module `mock.module` (permitted under two-tier convention):
911
-
912
- - `tests/unit/commands/` — mocks tools, hooks, services, state
913
- - `tests/unit/hooks/` — mocks knowledge-store, knowledge-validator, knowledge-reader, telemetry, utils
914
- - `tests/unit/tools/` — mocks Node built-ins (fs, child_process), sast-baseline, build/discovery
915
- - `tests/unit/services/` — mocks path-security
916
- - `tests/unit/config/` — mocks node:fs/promises
917
- - `tests/unit/background/` — mocks utils, event-bus, evidence-summary-service
918
- - `tests/unit/council/` — mocks node:fs
919
- - `tests/unit/plan/` — mocks spec-hash
920
- - `tests/unit/mutation/` — mocks node:child_process
921
- - `tests/unit/git/` — mocks node:child_process
922
- - `tests/integration/` — mocks co-change-analyzer, knowledge-store
923
- - `src/__tests__/` — mocks plan/manager, preflight-service, telemetry
924
- - `src/hooks/` — mocks logger, event-bus
925
- - `src/tools/__tests__/` — mocks test-impact/analyzer, build/discovery, path-security
926
- - `src/mutation/__tests__/` — mocks state
927
- - `src/agents/` — mocks node:fs/promises
928
- - `src/background/` — mocks vulnerability trigger
929
-
930
- ## Dead-code _internals Seams
931
-
932
- The following source modules export `_internals` but have no test consumers (as of this writing). They are harmless but may be removed in future cleanup:
933
-
934
- - `src/tools/secretscan.ts`
935
- - `src/tools/knowledge-recall.ts`
936
- - `src/tools/lint.ts`
937
- - `src/tools/sast-scan.ts`
938
- - `src/tools/sast-baseline.ts`
939
- - `src/mutation/gate.ts`
940
- - `src/mutation/equivalence.ts`
941
- - `src/mutation/engine.ts`
942
- - `src/db/qa-gate-profile.ts`
943
- - `src/config/schema.ts`
944
- - `src/config/index.ts`
945
- - `src/commands/registry.ts`
946
- - `src/background/manager.ts`
947
- - `src/background/event-bus.ts`
948
- - `src/agents/critic.ts`
827
+ ## Mock and Seam Inventories
828
+
829
+ For the current cross-module `mock.module` location inventory and dead-code `_internals` seam inventory, read `references/mock-and-seam-inventory.md`.
@@ -0,0 +1,43 @@
1
+ # Mock and Seam Inventory
2
+
3
+ ## Known Cross-module mock.module Locations
4
+
5
+ The following directories contain test files that use cross-module `mock.module` (permitted under two-tier convention):
6
+
7
+ - `tests/unit/commands/` — mocks tools, hooks, services, state
8
+ - `tests/unit/hooks/` — mocks knowledge-store, knowledge-validator, knowledge-reader, telemetry, utils
9
+ - `tests/unit/tools/` — mocks Node built-ins (fs, child_process), sast-baseline, build/discovery
10
+ - `tests/unit/services/` — mocks path-security
11
+ - `tests/unit/config/` — mocks node:fs/promises
12
+ - `tests/unit/background/` — mocks utils, event-bus, evidence-summary-service
13
+ - `tests/unit/council/` — mocks node:fs
14
+ - `tests/unit/plan/` — mocks spec-hash
15
+ - `tests/unit/mutation/` — mocks node:child_process
16
+ - `tests/unit/git/` — mocks node:child_process
17
+ - `tests/integration/` — mocks co-change-analyzer, knowledge-store
18
+ - `src/__tests__/` — mocks plan/manager, preflight-service, telemetry
19
+ - `src/hooks/` — mocks logger, event-bus
20
+ - `src/tools/__tests__/` — mocks test-impact/analyzer, build/discovery, path-security
21
+ - `src/mutation/__tests__/` — mocks state
22
+ - `src/agents/` — mocks node:fs/promises
23
+ - `src/background/` — mocks vulnerability trigger
24
+
25
+ ## Dead-code _internals Seams
26
+
27
+ The following source modules export `_internals` but have no test consumers (as of this writing). They are harmless but may be removed in future cleanup:
28
+
29
+ - `src/tools/secretscan.ts`
30
+ - `src/tools/knowledge-recall.ts`
31
+ - `src/tools/lint.ts`
32
+ - `src/tools/sast-scan.ts`
33
+ - `src/tools/sast-baseline.ts`
34
+ - `src/mutation/gate.ts`
35
+ - `src/mutation/equivalence.ts`
36
+ - `src/mutation/engine.ts`
37
+ - `src/db/qa-gate-profile.ts`
38
+ - `src/config/schema.ts`
39
+ - `src/config/index.ts`
40
+ - `src/commands/registry.ts`
41
+ - `src/background/manager.ts`
42
+ - `src/background/event-bus.ts`
43
+ - `src/agents/critic.ts`
@@ -12,8 +12,8 @@ import {
12
12
  shouldRunOnStartup,
13
13
  writeBackupArtifact,
14
14
  writeDoctorArtifact
15
- } from "./index-0y6tmm9v.js";
16
- import"./index-xattnmyb.js";
15
+ } from "./index-z4sc6yxc.js";
16
+ import"./index-8yvqkbw7.js";
17
17
  import"./index-bk5tah7q.js";
18
18
  import"./index-z6xqpmqg.js";
19
19
  import"./index-zjygnfay.js";
@@ -4,9 +4,9 @@ import {
4
4
  authorizeCuration,
5
5
  buildConfigFingerprintInput,
6
6
  readCohortConfigFingerprint
7
- } from "./index-67hqr2zv.js";
7
+ } from "./index-kvrk3h8p.js";
8
8
  import"./index-rtry5xyf.js";
9
- import"./index-n6chz2g8.js";
9
+ import"./index-83rwq7pb.js";
10
10
  import"./index-ae75rja9.js";
11
11
  import"./index-q27bajqb.js";
12
12
  import"./index-zgwm4ryv.js";
@@ -1,31 +1,31 @@
1
1
  // @bun
2
2
  import {
3
3
  createCuratorLLMDelegate
4
- } from "./index-amspa811.js";
5
- import"./index-6vfvc36k.js";
6
- import"./index-0y6tmm9v.js";
7
- import"./index-4rzzzjtg.js";
4
+ } from "./index-dsf1yv4s.js";
5
+ import"./index-pbjenws7.js";
6
+ import"./index-z4sc6yxc.js";
7
+ import"./index-fs02c7tz.js";
8
8
  import"./index-4905hd2m.js";
9
9
  import"./index-134d35c1.js";
10
10
  import"./index-6n2jpz7x.js";
11
- import"./index-vtwqjr4z.js";
12
- import"./index-99ed0h32.js";
13
- import"./index-09vd53pz.js";
11
+ import"./index-tn3shyqj.js";
12
+ import"./index-93cq8t5b.js";
13
+ import"./index-kws8zn6y.js";
14
14
  import"./index-vxv732ex.js";
15
15
  import"./index-c8s9a3zh.js";
16
16
  import"./index-s9mj4rb9.js";
17
17
  import"./index-23zsx7dm.js";
18
- import"./index-dx2c2wjt.js";
19
- import"./index-67hqr2zv.js";
18
+ import"./index-ghteqdy1.js";
19
+ import"./index-kvrk3h8p.js";
20
20
  import"./index-rtry5xyf.js";
21
- import"./index-yt1v62pv.js";
22
- import"./index-n6chz2g8.js";
21
+ import"./index-mwdcvh0e.js";
22
+ import"./index-83rwq7pb.js";
23
23
  import"./index-ae75rja9.js";
24
24
  import"./index-q27bajqb.js";
25
- import"./index-kt0awv1n.js";
25
+ import"./index-3k8pg467.js";
26
26
  import"./index-k5jrywpr.js";
27
27
  import"./index-n832052r.js";
28
- import"./index-xattnmyb.js";
28
+ import"./index-8yvqkbw7.js";
29
29
  import"./index-bk5tah7q.js";
30
30
  import"./index-8fwhhayc.js";
31
31
  import"./index-q1exe2b3.js";
@@ -14,31 +14,31 @@ import {
14
14
  runCuratorInit,
15
15
  runCuratorPhase,
16
16
  writeCuratorSummary
17
- } from "./index-amspa811.js";
18
- import"./index-6vfvc36k.js";
19
- import"./index-0y6tmm9v.js";
20
- import"./index-4rzzzjtg.js";
17
+ } from "./index-dsf1yv4s.js";
18
+ import"./index-pbjenws7.js";
19
+ import"./index-z4sc6yxc.js";
20
+ import"./index-fs02c7tz.js";
21
21
  import"./index-4905hd2m.js";
22
22
  import"./index-134d35c1.js";
23
23
  import"./index-6n2jpz7x.js";
24
- import"./index-vtwqjr4z.js";
25
- import"./index-99ed0h32.js";
26
- import"./index-09vd53pz.js";
24
+ import"./index-tn3shyqj.js";
25
+ import"./index-93cq8t5b.js";
26
+ import"./index-kws8zn6y.js";
27
27
  import"./index-vxv732ex.js";
28
28
  import"./index-c8s9a3zh.js";
29
29
  import"./index-s9mj4rb9.js";
30
30
  import"./index-23zsx7dm.js";
31
- import"./index-dx2c2wjt.js";
32
- import"./index-67hqr2zv.js";
31
+ import"./index-ghteqdy1.js";
32
+ import"./index-kvrk3h8p.js";
33
33
  import"./index-rtry5xyf.js";
34
- import"./index-yt1v62pv.js";
35
- import"./index-n6chz2g8.js";
34
+ import"./index-mwdcvh0e.js";
35
+ import"./index-83rwq7pb.js";
36
36
  import"./index-ae75rja9.js";
37
37
  import"./index-q27bajqb.js";
38
- import"./index-kt0awv1n.js";
38
+ import"./index-3k8pg467.js";
39
39
  import"./index-k5jrywpr.js";
40
40
  import"./index-n832052r.js";
41
- import"./index-xattnmyb.js";
41
+ import"./index-8yvqkbw7.js";
42
42
  import"./index-bk5tah7q.js";
43
43
  import"./index-8fwhhayc.js";
44
44
  import"./index-q1exe2b3.js";
@@ -6,7 +6,7 @@ import {
6
6
  loadPlanJsonOnly,
7
7
  mergeDurableGateEntriesFromEvidence,
8
8
  readDurableGateEvidence
9
- } from "./index-4rzzzjtg.js";
9
+ } from "./index-fs02c7tz.js";
10
10
  import"./index-s9mj4rb9.js";
11
11
  import"./index-k5jrywpr.js";
12
12
  import"./index-n832052r.js";
@@ -1,32 +1,32 @@
1
1
  // @bun
2
2
  import {
3
3
  handleGuardrailExplain
4
- } from "./index-7j3sm7h8.js";
5
- import"./index-amspa811.js";
6
- import"./index-6vfvc36k.js";
7
- import"./index-0y6tmm9v.js";
8
- import"./index-4rzzzjtg.js";
4
+ } from "./index-mhhmecsw.js";
5
+ import"./index-dsf1yv4s.js";
6
+ import"./index-pbjenws7.js";
7
+ import"./index-z4sc6yxc.js";
8
+ import"./index-fs02c7tz.js";
9
9
  import"./index-4905hd2m.js";
10
10
  import"./index-134d35c1.js";
11
11
  import"./index-6n2jpz7x.js";
12
- import"./index-vtwqjr4z.js";
13
- import"./index-99ed0h32.js";
14
- import"./index-09vd53pz.js";
12
+ import"./index-tn3shyqj.js";
13
+ import"./index-93cq8t5b.js";
14
+ import"./index-kws8zn6y.js";
15
15
  import"./index-vxv732ex.js";
16
16
  import"./index-c8s9a3zh.js";
17
17
  import"./index-s9mj4rb9.js";
18
18
  import"./index-23zsx7dm.js";
19
- import"./index-dx2c2wjt.js";
20
- import"./index-67hqr2zv.js";
19
+ import"./index-ghteqdy1.js";
20
+ import"./index-kvrk3h8p.js";
21
21
  import"./index-rtry5xyf.js";
22
- import"./index-yt1v62pv.js";
23
- import"./index-n6chz2g8.js";
22
+ import"./index-mwdcvh0e.js";
23
+ import"./index-83rwq7pb.js";
24
24
  import"./index-ae75rja9.js";
25
25
  import"./index-q27bajqb.js";
26
- import"./index-kt0awv1n.js";
26
+ import"./index-3k8pg467.js";
27
27
  import"./index-k5jrywpr.js";
28
28
  import"./index-n832052r.js";
29
- import"./index-xattnmyb.js";
29
+ import"./index-8yvqkbw7.js";
30
30
  import"./index-bk5tah7q.js";
31
31
  import"./index-8fwhhayc.js";
32
32
  import"./index-q1exe2b3.js";
@@ -1,9 +1,9 @@
1
1
  // @bun
2
2
  import {
3
3
  handleGuardrailLog
4
- } from "./index-jh6s75f6.js";
5
- import"./index-6vfvc36k.js";
6
- import"./index-xattnmyb.js";
4
+ } from "./index-txragda9.js";
5
+ import"./index-pbjenws7.js";
6
+ import"./index-8yvqkbw7.js";
7
7
  import"./index-bk5tah7q.js";
8
8
  import"./index-z6xqpmqg.js";
9
9
  import"./index-zjygnfay.js";
@@ -7,33 +7,33 @@ import {
7
7
  isHiveEligible,
8
8
  promoteFromSwarm,
9
9
  promoteToHive
10
- } from "./index-amspa811.js";
11
- import"./index-6vfvc36k.js";
12
- import"./index-0y6tmm9v.js";
13
- import"./index-4rzzzjtg.js";
10
+ } from "./index-dsf1yv4s.js";
11
+ import"./index-pbjenws7.js";
12
+ import"./index-z4sc6yxc.js";
13
+ import"./index-fs02c7tz.js";
14
14
  import"./index-4905hd2m.js";
15
15
  import"./index-134d35c1.js";
16
16
  import"./index-6n2jpz7x.js";
17
- import"./index-vtwqjr4z.js";
18
- import"./index-99ed0h32.js";
19
- import"./index-09vd53pz.js";
17
+ import"./index-tn3shyqj.js";
18
+ import"./index-93cq8t5b.js";
19
+ import"./index-kws8zn6y.js";
20
20
  import"./index-vxv732ex.js";
21
21
  import"./index-c8s9a3zh.js";
22
22
  import"./index-s9mj4rb9.js";
23
23
  import"./index-23zsx7dm.js";
24
- import"./index-dx2c2wjt.js";
25
- import"./index-67hqr2zv.js";
24
+ import"./index-ghteqdy1.js";
25
+ import"./index-kvrk3h8p.js";
26
26
  import"./index-rtry5xyf.js";
27
27
  import {
28
28
  resolveHiveKnowledgePath
29
- } from "./index-yt1v62pv.js";
30
- import"./index-n6chz2g8.js";
29
+ } from "./index-mwdcvh0e.js";
30
+ import"./index-83rwq7pb.js";
31
31
  import"./index-ae75rja9.js";
32
32
  import"./index-q27bajqb.js";
33
- import"./index-kt0awv1n.js";
33
+ import"./index-3k8pg467.js";
34
34
  import"./index-k5jrywpr.js";
35
35
  import"./index-n832052r.js";
36
- import"./index-xattnmyb.js";
36
+ import"./index-8yvqkbw7.js";
37
37
  import"./index-bk5tah7q.js";
38
38
  import"./index-8fwhhayc.js";
39
39
  import"./index-q1exe2b3.js";
@@ -8,7 +8,7 @@ import {
8
8
  init_constants,
9
9
  init_schema,
10
10
  resolveExternalSkillsConfig
11
- } from "./index-xattnmyb.js";
11
+ } from "./index-8yvqkbw7.js";
12
12
  import {
13
13
  advisoryWarn,
14
14
  init_warning_buffer
@@ -608,7 +608,7 @@ async function applyKnowledgeVerdictFeedback(directory, options) {
608
608
  deltas.push({ id, delta });
609
609
  }
610
610
  if (deltas.length > 0) {
611
- const { bumpKnowledgeConfidenceBatch } = await import("./knowledge-store-hqngpt2v.js");
611
+ const { bumpKnowledgeConfidenceBatch } = await import("./knowledge-store-332x3pjv.js");
612
612
  await bumpKnowledgeConfidenceBatch(directory, deltas, options?.floorOptions);
613
613
  }
614
614
  return {
@@ -1220,7 +1220,9 @@ var init_schema = __esm(() => {
1220
1220
  enabled: exports_external.boolean().default(true),
1221
1221
  max_age_days: exports_external.number().min(1).max(365).default(90),
1222
1222
  max_bundles: exports_external.number().min(10).max(1e4).default(1000),
1223
- auto_archive: exports_external.boolean().default(false)
1223
+ auto_archive: exports_external.boolean().default(false),
1224
+ cache_max_bytes: exports_external.number().min(512).max(50 * 1024 * 1024).optional(),
1225
+ cache_max_records: exports_external.number().min(10).max(1e5).optional()
1224
1226
  });
1225
1227
  GateFeatureSchema = exports_external.object({
1226
1228
  enabled: exports_external.boolean().default(true)
@@ -6,13 +6,13 @@ import {
6
6
  resolveSwarmKnowledgePath,
7
7
  transactKnowledge,
8
8
  wordBigrams
9
- } from "./index-yt1v62pv.js";
9
+ } from "./index-mwdcvh0e.js";
10
10
  import {
11
11
  countEntryContradictionsInWindow,
12
12
  countEntryViolationsInWindow,
13
13
  readKnowledgeEvents,
14
14
  recordKnowledgeEvent
15
- } from "./index-n6chz2g8.js";
15
+ } from "./index-83rwq7pb.js";
16
16
  import {
17
17
  init_knowledge_types,
18
18
  isActiveStatus
@@ -190,11 +190,11 @@ async function maybeQuarantineOnContradiction(directory, entryId, threshold, win
190
190
  alreadyInactive: true
191
191
  };
192
192
  }
193
- const { quarantineEntry } = await import("./knowledge-validator-g7mpnazh.js");
193
+ const { quarantineEntry } = await import("./knowledge-validator-3t8tgzsz.js");
194
194
  let policyConfig;
195
195
  try {
196
- const { KnowledgeConfigSchema } = await import("./schema-2418eqy3.js");
197
- const { loadPluginConfigWithMeta } = await import("./index-958hf0yr.js");
196
+ const { KnowledgeConfigSchema } = await import("./schema-y2d7j2jk.js");
197
+ const { loadPluginConfigWithMeta } = await import("./index-rpg8qqjs.js");
198
198
  const { config: loadedConfig } = loadPluginConfigWithMeta(directory);
199
199
  policyConfig = KnowledgeConfigSchema.parse(loadedConfig.knowledge ?? {});
200
200
  } catch {
@@ -1,10 +1,10 @@
1
1
  // @bun
2
2
  import {
3
3
  handleGuardrailExplain
4
- } from "./index-7j3sm7h8.js";
4
+ } from "./index-mhhmecsw.js";
5
5
  import {
6
6
  handleGuardrailLog
7
- } from "./index-jh6s75f6.js";
7
+ } from "./index-txragda9.js";
8
8
  import {
9
9
  COMMAND_REGISTRY,
10
10
  SWARM_COMMAND_TOOL_ALLOWLIST,
@@ -83,28 +83,28 @@ import {
83
83
  handleWriteRetroCommand,
84
84
  normalizeSwarmCommandInput,
85
85
  resolveCommand
86
- } from "./index-amspa811.js";
87
- import"./index-6vfvc36k.js";
88
- import"./index-0y6tmm9v.js";
89
- import"./index-4rzzzjtg.js";
86
+ } from "./index-dsf1yv4s.js";
87
+ import"./index-pbjenws7.js";
88
+ import"./index-z4sc6yxc.js";
89
+ import"./index-fs02c7tz.js";
90
90
  import"./index-4905hd2m.js";
91
91
  import"./index-134d35c1.js";
92
92
  import"./index-6n2jpz7x.js";
93
- import"./index-vtwqjr4z.js";
94
- import"./index-99ed0h32.js";
95
- import"./index-09vd53pz.js";
93
+ import"./index-tn3shyqj.js";
94
+ import"./index-93cq8t5b.js";
95
+ import"./index-kws8zn6y.js";
96
96
  import"./index-vxv732ex.js";
97
97
  import"./index-c8s9a3zh.js";
98
98
  import"./index-s9mj4rb9.js";
99
99
  import"./index-23zsx7dm.js";
100
- import"./index-dx2c2wjt.js";
101
- import"./index-67hqr2zv.js";
100
+ import"./index-ghteqdy1.js";
101
+ import"./index-kvrk3h8p.js";
102
102
  import"./index-rtry5xyf.js";
103
- import"./index-yt1v62pv.js";
104
- import"./index-n6chz2g8.js";
103
+ import"./index-mwdcvh0e.js";
104
+ import"./index-83rwq7pb.js";
105
105
  import"./index-ae75rja9.js";
106
106
  import"./index-q27bajqb.js";
107
- import"./index-kt0awv1n.js";
107
+ import"./index-3k8pg467.js";
108
108
  import"./index-k5jrywpr.js";
109
109
  import"./index-n832052r.js";
110
110
  import {
@@ -113,7 +113,7 @@ import {
113
113
  init_constants,
114
114
  init_schema,
115
115
  stripKnownSwarmPrefix
116
- } from "./index-xattnmyb.js";
116
+ } from "./index-8yvqkbw7.js";
117
117
  import"./index-bk5tah7q.js";
118
118
  import"./index-8fwhhayc.js";
119
119
  import"./index-q1exe2b3.js";