chainlesschain 0.143.0 → 0.152.0

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 (227) hide show
  1. package/package.json +1 -1
  2. package/src/commands/a2a.js +196 -28
  3. package/src/commands/activitypub.js +364 -27
  4. package/src/commands/agent-network.js +217 -0
  5. package/src/commands/agent.js +587 -103
  6. package/src/commands/audit.js +206 -0
  7. package/src/commands/automation.js +201 -0
  8. package/src/commands/bi.js +355 -27
  9. package/src/commands/bm25.js +111 -27
  10. package/src/commands/browse.js +403 -29
  11. package/src/commands/ccron.js +128 -28
  12. package/src/commands/chat.js +207 -0
  13. package/src/commands/codegen.js +207 -0
  14. package/src/commands/collab.js +211 -0
  15. package/src/commands/compliance.js +824 -34
  16. package/src/commands/compt.js +127 -29
  17. package/src/commands/consol.js +8 -2
  18. package/src/commands/cowork.js +783 -34
  19. package/src/commands/crosschain.js +182 -28
  20. package/src/commands/dao.js +182 -28
  21. package/src/commands/dbevo.js +227 -0
  22. package/src/commands/dev.js +207 -0
  23. package/src/commands/did-v2.js +217 -0
  24. package/src/commands/did.js +221 -0
  25. package/src/commands/dlp.js +385 -27
  26. package/src/commands/economy.js +205 -50
  27. package/src/commands/evolution.js +203 -50
  28. package/src/commands/evomap.js +387 -27
  29. package/src/commands/export.js +213 -0
  30. package/src/commands/federation.js +209 -0
  31. package/src/commands/fflag.js +74 -22
  32. package/src/commands/fusion.js +205 -0
  33. package/src/commands/git.js +177 -37
  34. package/src/commands/governance.js +209 -0
  35. package/src/commands/hardening.js +209 -0
  36. package/src/commands/hmemory.js +204 -50
  37. package/src/commands/hook.js +209 -0
  38. package/src/commands/import.js +209 -0
  39. package/src/commands/incentive.js +209 -0
  40. package/src/commands/inference.js +170 -34
  41. package/src/commands/infra.js +203 -0
  42. package/src/commands/instinct.js +209 -0
  43. package/src/commands/ipfs.js +207 -0
  44. package/src/commands/itbudget.js +149 -33
  45. package/src/commands/kg.js +206 -0
  46. package/src/commands/llm.js +217 -0
  47. package/src/commands/lowcode.js +195 -38
  48. package/src/commands/marketplace.js +206 -0
  49. package/src/commands/matrix.js +386 -27
  50. package/src/commands/mcp.js +217 -0
  51. package/src/commands/mcpscaf.js +145 -33
  52. package/src/commands/meminj.js +145 -33
  53. package/src/commands/memory.js +209 -0
  54. package/src/commands/multimodal.js +203 -0
  55. package/src/commands/nlprog.js +225 -0
  56. package/src/commands/nostr.js +387 -27
  57. package/src/commands/note.js +205 -0
  58. package/src/commands/ops.js +219 -0
  59. package/src/commands/orchestrate.js +217 -0
  60. package/src/commands/orchgov.js +144 -33
  61. package/src/commands/org.js +209 -0
  62. package/src/commands/p2p.js +209 -0
  63. package/src/commands/pdfp.js +109 -27
  64. package/src/commands/perception.js +209 -0
  65. package/src/commands/perf.js +169 -32
  66. package/src/commands/perm.js +144 -33
  67. package/src/commands/permmem.js +203 -0
  68. package/src/commands/pipeline.js +207 -52
  69. package/src/commands/planmode.js +141 -32
  70. package/src/commands/plugin-ecosystem.js +209 -0
  71. package/src/commands/pqc.js +213 -0
  72. package/src/commands/privacy.js +203 -0
  73. package/src/commands/promcomp.js +111 -27
  74. package/src/commands/quantization.js +207 -0
  75. package/src/commands/rcache.js +205 -0
  76. package/src/commands/recommend.js +410 -34
  77. package/src/commands/reputation.js +208 -0
  78. package/src/commands/runtime.js +205 -0
  79. package/src/commands/sandbox.js +206 -0
  80. package/src/commands/scim.js +209 -0
  81. package/src/commands/seshhook.js +145 -33
  82. package/src/commands/seshsearch.js +141 -33
  83. package/src/commands/seshtail.js +144 -33
  84. package/src/commands/seshu.js +152 -33
  85. package/src/commands/session.js +209 -0
  86. package/src/commands/sganal.js +123 -29
  87. package/src/commands/siem.js +201 -34
  88. package/src/commands/skill.js +207 -0
  89. package/src/commands/sla.js +212 -0
  90. package/src/commands/slotfill.js +146 -33
  91. package/src/commands/social.js +358 -32
  92. package/src/commands/sso.js +209 -0
  93. package/src/commands/stress.js +206 -0
  94. package/src/commands/svccont.js +145 -33
  95. package/src/commands/sync.js +209 -0
  96. package/src/commands/tech.js +209 -0
  97. package/src/commands/tenant.js +217 -0
  98. package/src/commands/terraform.js +206 -0
  99. package/src/commands/tms.js +171 -33
  100. package/src/commands/tokens.js +209 -0
  101. package/src/commands/topiccls.js +146 -33
  102. package/src/commands/trust.js +217 -0
  103. package/src/commands/uprof.js +141 -32
  104. package/src/commands/vcheck.js +122 -28
  105. package/src/commands/wallet.js +209 -0
  106. package/src/commands/webfetch.js +141 -32
  107. package/src/commands/workflow.js +203 -0
  108. package/src/commands/zkp.js +184 -28
  109. package/src/index.js +180 -0
  110. package/src/lib/a2a-protocol.js +319 -51
  111. package/src/lib/activitypub-bridge.js +622 -50
  112. package/src/lib/agent-economy.js +304 -51
  113. package/src/lib/agent-network.js +341 -0
  114. package/src/lib/aiops.js +346 -0
  115. package/src/lib/app-builder.js +279 -46
  116. package/src/lib/audit-logger.js +321 -0
  117. package/src/lib/automation-engine.js +335 -0
  118. package/src/lib/autonomous-agent.js +284 -48
  119. package/src/lib/autonomous-developer.js +332 -0
  120. package/src/lib/bi-engine.js +616 -49
  121. package/src/lib/bm25-search.js +301 -49
  122. package/src/lib/browser-automation.js +630 -49
  123. package/src/lib/chat-core.js +336 -0
  124. package/src/lib/claude-code-bridge.js +341 -0
  125. package/src/lib/code-agent.js +339 -0
  126. package/src/lib/collaboration-governance.js +334 -0
  127. package/src/lib/community-governance.js +346 -0
  128. package/src/lib/compliance-framework-reporter.js +305 -51
  129. package/src/lib/compliance-manager.js +330 -0
  130. package/src/lib/compression-telemetry.js +301 -49
  131. package/src/lib/content-recommendation.js +351 -0
  132. package/src/lib/content-recommender.js +317 -52
  133. package/src/lib/cowork-cron.js +298 -49
  134. package/src/lib/cowork-learning.js +333 -0
  135. package/src/lib/cowork-share.js +338 -0
  136. package/src/lib/cowork-task-runner.js +308 -51
  137. package/src/lib/cowork-workflow.js +327 -0
  138. package/src/lib/cross-chain.js +311 -51
  139. package/src/lib/dao-governance.js +280 -46
  140. package/src/lib/dbevo.js +351 -0
  141. package/src/lib/decentral-infra.js +330 -0
  142. package/src/lib/did-manager.js +341 -0
  143. package/src/lib/did-v2-manager.js +341 -0
  144. package/src/lib/dlp-engine.js +626 -49
  145. package/src/lib/evolution-system.js +278 -47
  146. package/src/lib/evomap-governance.js +334 -0
  147. package/src/lib/evomap-manager.js +280 -46
  148. package/src/lib/execution-backend.js +294 -48
  149. package/src/lib/feature-flags.js +294 -49
  150. package/src/lib/federation-hardening.js +340 -0
  151. package/src/lib/git-integration.js +285 -47
  152. package/src/lib/hardening-manager.js +341 -0
  153. package/src/lib/hierarchical-memory.js +284 -48
  154. package/src/lib/hook-manager.js +341 -0
  155. package/src/lib/inference-network.js +308 -51
  156. package/src/lib/instinct-manager.js +346 -0
  157. package/src/lib/ipfs-storage.js +334 -0
  158. package/src/lib/iteration-budget.js +302 -50
  159. package/src/lib/knowledge-exporter.js +341 -0
  160. package/src/lib/knowledge-graph.js +333 -0
  161. package/src/lib/knowledge-importer.js +341 -0
  162. package/src/lib/llm-providers.js +346 -0
  163. package/src/lib/matrix-bridge.js +620 -47
  164. package/src/lib/mcp-registry.js +346 -0
  165. package/src/lib/mcp-scaffold.js +318 -54
  166. package/src/lib/memory-injection.js +288 -49
  167. package/src/lib/memory-manager.js +336 -0
  168. package/src/lib/multimodal.js +330 -0
  169. package/src/lib/nl-programming.js +341 -0
  170. package/src/lib/nostr-bridge.js +622 -49
  171. package/src/lib/note-versioning.js +339 -0
  172. package/src/lib/orchestrator.js +293 -48
  173. package/src/lib/org-manager.js +336 -0
  174. package/src/lib/p2p-manager.js +341 -0
  175. package/src/lib/pdf-parser.js +298 -49
  176. package/src/lib/perception.js +346 -0
  177. package/src/lib/perf-tuning.js +309 -50
  178. package/src/lib/permanent-memory.js +327 -0
  179. package/src/lib/permission-engine.js +287 -49
  180. package/src/lib/pipeline-orchestrator.js +289 -49
  181. package/src/lib/plan-mode.js +298 -51
  182. package/src/lib/plugin-ecosystem.js +346 -0
  183. package/src/lib/pqc-manager.js +346 -0
  184. package/src/lib/privacy-computing.js +335 -0
  185. package/src/lib/protocol-fusion.js +338 -0
  186. package/src/lib/quantization.js +337 -0
  187. package/src/lib/reputation-optimizer.js +340 -0
  188. package/src/lib/response-cache.js +333 -0
  189. package/src/lib/sandbox-v2.js +327 -0
  190. package/src/lib/scim-manager.js +346 -0
  191. package/src/lib/service-container.js +313 -52
  192. package/src/lib/session-consolidator.js +296 -49
  193. package/src/lib/session-hooks.js +312 -53
  194. package/src/lib/session-manager.js +334 -0
  195. package/src/lib/session-search.js +304 -51
  196. package/src/lib/session-tail.js +288 -49
  197. package/src/lib/session-usage.js +298 -52
  198. package/src/lib/siem-exporter.js +298 -51
  199. package/src/lib/skill-loader.js +334 -0
  200. package/src/lib/skill-marketplace.js +345 -0
  201. package/src/lib/sla-manager.js +341 -0
  202. package/src/lib/slot-filler.js +303 -51
  203. package/src/lib/social-graph-analytics.js +295 -49
  204. package/src/lib/social-graph.js +272 -49
  205. package/src/lib/social-manager.js +330 -0
  206. package/src/lib/sso-manager.js +340 -0
  207. package/src/lib/stress-tester.js +342 -0
  208. package/src/lib/sub-agent-registry.js +302 -53
  209. package/src/lib/sync-manager.js +336 -0
  210. package/src/lib/task-model-selector.js +302 -50
  211. package/src/lib/tech-learning-engine.js +341 -0
  212. package/src/lib/tenant-saas.js +341 -0
  213. package/src/lib/terraform-manager.js +333 -0
  214. package/src/lib/threat-intel.js +330 -0
  215. package/src/lib/todo-manager.js +281 -47
  216. package/src/lib/token-incentive.js +341 -0
  217. package/src/lib/token-tracker.js +336 -0
  218. package/src/lib/topic-classifier.js +297 -49
  219. package/src/lib/trust-security.js +343 -0
  220. package/src/lib/ueba.js +340 -0
  221. package/src/lib/universal-runtime.js +330 -0
  222. package/src/lib/user-profile.js +294 -50
  223. package/src/lib/version-checker.js +304 -50
  224. package/src/lib/wallet-manager.js +336 -0
  225. package/src/lib/web-fetch.js +292 -51
  226. package/src/lib/workflow-engine.js +330 -0
  227. package/src/lib/zkp-engine.js +286 -49
@@ -405,38 +405,205 @@ export function registerSiemCommand(program) {
405
405
 
406
406
  function _registerSiemExporterV2Commands(parent) {
407
407
  const L = async () => await import("../lib/siem-exporter.js");
408
- parent.command("enums-v2").description("Show V2 enums (target maturity + export lifecycle)")
409
- .action(async () => { const m = await L(); console.log(JSON.stringify({ targetMaturity: m.SIEM_TARGET_MATURITY_V2, exportLifecycle: m.SIEM_EXPORT_LIFECYCLE_V2 }, null, 2)); });
410
- parent.command("config-v2").description("Show V2 config thresholds")
411
- .action(async () => { const m = await L(); console.log(JSON.stringify({ maxActiveSiemTargetsPerOperator: m.getMaxActiveSiemTargetsPerOperatorV2(), maxPendingSiemExportsPerTarget: m.getMaxPendingSiemExportsPerTargetV2(), siemTargetIdleMs: m.getSiemTargetIdleMsV2(), siemExportStuckMs: m.getSiemExportStuckMsV2() }, null, 2)); });
412
- parent.command("set-max-active-targets-v2 <n>").description("Set max active targets per operator")
413
- .action(async (n) => { const m = await L(); m.setMaxActiveSiemTargetsPerOperatorV2(Number(n)); console.log("ok"); });
414
- parent.command("set-max-pending-exports-v2 <n>").description("Set max pending exports per target")
415
- .action(async (n) => { const m = await L(); m.setMaxPendingSiemExportsPerTargetV2(Number(n)); console.log("ok"); });
416
- parent.command("set-target-idle-ms-v2 <n>").description("Set target idle threshold (ms)")
417
- .action(async (n) => { const m = await L(); m.setSiemTargetIdleMsV2(Number(n)); console.log("ok"); });
418
- parent.command("set-export-stuck-ms-v2 <n>").description("Set export stuck threshold (ms)")
419
- .action(async (n) => { const m = await L(); m.setSiemExportStuckMsV2(Number(n)); console.log("ok"); });
420
- parent.command("register-target-v2 <id> <operator>").description("Register V2 SIEM target")
421
- .option("--kind <k>", "Target kind").action(async (id, operator, o) => { const m = await L(); console.log(JSON.stringify(m.registerSiemTargetV2({ id, operator, kind: o.kind }), null, 2)); });
422
- parent.command("activate-target-v2 <id>").description("Activate target").action(async (id) => { const m = await L(); console.log(JSON.stringify(m.activateSiemTargetV2(id), null, 2)); });
423
- parent.command("degrade-target-v2 <id>").description("Degrade target").action(async (id) => { const m = await L(); console.log(JSON.stringify(m.degradeSiemTargetV2(id), null, 2)); });
424
- parent.command("retire-target-v2 <id>").description("Retire target (terminal)").action(async (id) => { const m = await L(); console.log(JSON.stringify(m.retireSiemTargetV2(id), null, 2)); });
425
- parent.command("touch-target-v2 <id>").description("Touch target lastTouchedAt").action(async (id) => { const m = await L(); console.log(JSON.stringify(m.touchSiemTargetV2(id), null, 2)); });
426
- parent.command("get-target-v2 <id>").description("Get V2 target").action(async (id) => { const m = await L(); console.log(JSON.stringify(m.getSiemTargetV2(id), null, 2)); });
427
- parent.command("list-targets-v2").description("List V2 targets").action(async () => { const m = await L(); console.log(JSON.stringify(m.listSiemTargetsV2(), null, 2)); });
428
- parent.command("create-export-v2 <id> <targetId>").description("Create V2 export (queued)")
429
- .option("--format <f>", "Format", "json").action(async (id, targetId, o) => { const m = await L(); console.log(JSON.stringify(m.createSiemExportV2({ id, targetId, format: o.format }), null, 2)); });
430
- parent.command("start-export-v2 <id>").description("Start export").action(async (id) => { const m = await L(); console.log(JSON.stringify(m.startSiemExportV2(id), null, 2)); });
431
- parent.command("deliver-export-v2 <id>").description("Deliver export").action(async (id) => { const m = await L(); console.log(JSON.stringify(m.deliverSiemExportV2(id), null, 2)); });
432
- parent.command("fail-export-v2 <id> [reason]").description("Fail export").action(async (id, reason) => { const m = await L(); console.log(JSON.stringify(m.failSiemExportV2(id, reason), null, 2)); });
433
- parent.command("cancel-export-v2 <id> [reason]").description("Cancel export").action(async (id, reason) => { const m = await L(); console.log(JSON.stringify(m.cancelSiemExportV2(id, reason), null, 2)); });
434
- parent.command("get-export-v2 <id>").description("Get V2 export").action(async (id) => { const m = await L(); console.log(JSON.stringify(m.getSiemExportV2(id), null, 2)); });
435
- parent.command("list-exports-v2").description("List V2 exports").action(async () => { const m = await L(); console.log(JSON.stringify(m.listSiemExportsV2(), null, 2)); });
436
- parent.command("auto-degrade-idle-v2").description("Auto-degrade idle targets")
437
- .action(async () => { const m = await L(); console.log(JSON.stringify(m.autoDegradeIdleSiemTargetsV2(), null, 2)); });
438
- parent.command("auto-fail-stuck-v2").description("Auto-fail stuck sending exports")
439
- .action(async () => { const m = await L(); console.log(JSON.stringify(m.autoFailStuckSiemExportsV2(), null, 2)); });
440
- parent.command("gov-stats-v2").description("V2 governance aggregate stats")
441
- .action(async () => { const m = await L(); console.log(JSON.stringify(m.getSiemExporterGovStatsV2(), null, 2)); });
408
+ parent
409
+ .command("enums-v2")
410
+ .description("Show V2 enums (target maturity + export lifecycle)")
411
+ .action(async () => {
412
+ const m = await L();
413
+ console.log(
414
+ JSON.stringify(
415
+ {
416
+ targetMaturity: m.SIEM_TARGET_MATURITY_V2,
417
+ exportLifecycle: m.SIEM_EXPORT_LIFECYCLE_V2,
418
+ },
419
+ null,
420
+ 2,
421
+ ),
422
+ );
423
+ });
424
+ parent
425
+ .command("config-v2")
426
+ .description("Show V2 config thresholds")
427
+ .action(async () => {
428
+ const m = await L();
429
+ console.log(
430
+ JSON.stringify(
431
+ {
432
+ maxActiveSiemTargetsPerOperator:
433
+ m.getMaxActiveSiemTargetsPerOperatorV2(),
434
+ maxPendingSiemExportsPerTarget:
435
+ m.getMaxPendingSiemExportsPerTargetV2(),
436
+ siemTargetIdleMs: m.getSiemTargetIdleMsV2(),
437
+ siemExportStuckMs: m.getSiemExportStuckMsV2(),
438
+ },
439
+ null,
440
+ 2,
441
+ ),
442
+ );
443
+ });
444
+ parent
445
+ .command("set-max-active-targets-v2 <n>")
446
+ .description("Set max active targets per operator")
447
+ .action(async (n) => {
448
+ const m = await L();
449
+ m.setMaxActiveSiemTargetsPerOperatorV2(Number(n));
450
+ console.log("ok");
451
+ });
452
+ parent
453
+ .command("set-max-pending-exports-v2 <n>")
454
+ .description("Set max pending exports per target")
455
+ .action(async (n) => {
456
+ const m = await L();
457
+ m.setMaxPendingSiemExportsPerTargetV2(Number(n));
458
+ console.log("ok");
459
+ });
460
+ parent
461
+ .command("set-target-idle-ms-v2 <n>")
462
+ .description("Set target idle threshold (ms)")
463
+ .action(async (n) => {
464
+ const m = await L();
465
+ m.setSiemTargetIdleMsV2(Number(n));
466
+ console.log("ok");
467
+ });
468
+ parent
469
+ .command("set-export-stuck-ms-v2 <n>")
470
+ .description("Set export stuck threshold (ms)")
471
+ .action(async (n) => {
472
+ const m = await L();
473
+ m.setSiemExportStuckMsV2(Number(n));
474
+ console.log("ok");
475
+ });
476
+ parent
477
+ .command("register-target-v2 <id> <operator>")
478
+ .description("Register V2 SIEM target")
479
+ .option("--kind <k>", "Target kind")
480
+ .action(async (id, operator, o) => {
481
+ const m = await L();
482
+ console.log(
483
+ JSON.stringify(
484
+ m.registerSiemTargetV2({ id, operator, kind: o.kind }),
485
+ null,
486
+ 2,
487
+ ),
488
+ );
489
+ });
490
+ parent
491
+ .command("activate-target-v2 <id>")
492
+ .description("Activate target")
493
+ .action(async (id) => {
494
+ const m = await L();
495
+ console.log(JSON.stringify(m.activateSiemTargetV2(id), null, 2));
496
+ });
497
+ parent
498
+ .command("degrade-target-v2 <id>")
499
+ .description("Degrade target")
500
+ .action(async (id) => {
501
+ const m = await L();
502
+ console.log(JSON.stringify(m.degradeSiemTargetV2(id), null, 2));
503
+ });
504
+ parent
505
+ .command("retire-target-v2 <id>")
506
+ .description("Retire target (terminal)")
507
+ .action(async (id) => {
508
+ const m = await L();
509
+ console.log(JSON.stringify(m.retireSiemTargetV2(id), null, 2));
510
+ });
511
+ parent
512
+ .command("touch-target-v2 <id>")
513
+ .description("Touch target lastTouchedAt")
514
+ .action(async (id) => {
515
+ const m = await L();
516
+ console.log(JSON.stringify(m.touchSiemTargetV2(id), null, 2));
517
+ });
518
+ parent
519
+ .command("get-target-v2 <id>")
520
+ .description("Get V2 target")
521
+ .action(async (id) => {
522
+ const m = await L();
523
+ console.log(JSON.stringify(m.getSiemTargetV2(id), null, 2));
524
+ });
525
+ parent
526
+ .command("list-targets-v2")
527
+ .description("List V2 targets")
528
+ .action(async () => {
529
+ const m = await L();
530
+ console.log(JSON.stringify(m.listSiemTargetsV2(), null, 2));
531
+ });
532
+ parent
533
+ .command("create-export-v2 <id> <targetId>")
534
+ .description("Create V2 export (queued)")
535
+ .option("--format <f>", "Format", "json")
536
+ .action(async (id, targetId, o) => {
537
+ const m = await L();
538
+ console.log(
539
+ JSON.stringify(
540
+ m.createSiemExportV2({ id, targetId, format: o.format }),
541
+ null,
542
+ 2,
543
+ ),
544
+ );
545
+ });
546
+ parent
547
+ .command("start-export-v2 <id>")
548
+ .description("Start export")
549
+ .action(async (id) => {
550
+ const m = await L();
551
+ console.log(JSON.stringify(m.startSiemExportV2(id), null, 2));
552
+ });
553
+ parent
554
+ .command("deliver-export-v2 <id>")
555
+ .description("Deliver export")
556
+ .action(async (id) => {
557
+ const m = await L();
558
+ console.log(JSON.stringify(m.deliverSiemExportV2(id), null, 2));
559
+ });
560
+ parent
561
+ .command("fail-export-v2 <id> [reason]")
562
+ .description("Fail export")
563
+ .action(async (id, reason) => {
564
+ const m = await L();
565
+ console.log(JSON.stringify(m.failSiemExportV2(id, reason), null, 2));
566
+ });
567
+ parent
568
+ .command("cancel-export-v2 <id> [reason]")
569
+ .description("Cancel export")
570
+ .action(async (id, reason) => {
571
+ const m = await L();
572
+ console.log(JSON.stringify(m.cancelSiemExportV2(id, reason), null, 2));
573
+ });
574
+ parent
575
+ .command("get-export-v2 <id>")
576
+ .description("Get V2 export")
577
+ .action(async (id) => {
578
+ const m = await L();
579
+ console.log(JSON.stringify(m.getSiemExportV2(id), null, 2));
580
+ });
581
+ parent
582
+ .command("list-exports-v2")
583
+ .description("List V2 exports")
584
+ .action(async () => {
585
+ const m = await L();
586
+ console.log(JSON.stringify(m.listSiemExportsV2(), null, 2));
587
+ });
588
+ parent
589
+ .command("auto-degrade-idle-v2")
590
+ .description("Auto-degrade idle targets")
591
+ .action(async () => {
592
+ const m = await L();
593
+ console.log(JSON.stringify(m.autoDegradeIdleSiemTargetsV2(), null, 2));
594
+ });
595
+ parent
596
+ .command("auto-fail-stuck-v2")
597
+ .description("Auto-fail stuck sending exports")
598
+ .action(async () => {
599
+ const m = await L();
600
+ console.log(JSON.stringify(m.autoFailStuckSiemExportsV2(), null, 2));
601
+ });
602
+ parent
603
+ .command("gov-stats-v2")
604
+ .description("V2 governance aggregate stats")
605
+ .action(async () => {
606
+ const m = await L();
607
+ console.log(JSON.stringify(m.getSiemExporterGovStatsV2(), null, 2));
608
+ });
442
609
  }
@@ -962,3 +962,210 @@ export function registerSkillCommand(program) {
962
962
  .description("Auto-fail stuck V2 executions")
963
963
  .action(() => out(autoFailStuckExecutionsV2()));
964
964
  }
965
+
966
+ // === Iter24 V2 governance overlay ===
967
+ export function registerSklgovV2Commands(program) {
968
+ const parent = program.commands.find((c) => c.name() === "skill");
969
+ if (!parent) return;
970
+ const L = async () => await import("../lib/skill-loader.js");
971
+ parent
972
+ .command("sklgov-enums-v2")
973
+ .description("Show V2 enums")
974
+ .action(async () => {
975
+ const m = await L();
976
+ console.log(
977
+ JSON.stringify(
978
+ {
979
+ profileMaturity: m.SKLGOV_PROFILE_MATURITY_V2,
980
+ loadLifecycle: m.SKLGOV_LOAD_LIFECYCLE_V2,
981
+ },
982
+ null,
983
+ 2,
984
+ ),
985
+ );
986
+ });
987
+ parent
988
+ .command("sklgov-config-v2")
989
+ .description("Show V2 config")
990
+ .action(async () => {
991
+ const m = await L();
992
+ console.log(
993
+ JSON.stringify(
994
+ {
995
+ maxActive: m.getMaxActiveSklgovProfilesPerOwnerV2(),
996
+ maxPending: m.getMaxPendingSklgovLoadsPerProfileV2(),
997
+ idleMs: m.getSklgovProfileIdleMsV2(),
998
+ stuckMs: m.getSklgovLoadStuckMsV2(),
999
+ },
1000
+ null,
1001
+ 2,
1002
+ ),
1003
+ );
1004
+ });
1005
+ parent
1006
+ .command("sklgov-set-max-active-v2 <n>")
1007
+ .description("Set max active")
1008
+ .action(async (n) => {
1009
+ (await L()).setMaxActiveSklgovProfilesPerOwnerV2(Number(n));
1010
+ console.log("ok");
1011
+ });
1012
+ parent
1013
+ .command("sklgov-set-max-pending-v2 <n>")
1014
+ .description("Set max pending")
1015
+ .action(async (n) => {
1016
+ (await L()).setMaxPendingSklgovLoadsPerProfileV2(Number(n));
1017
+ console.log("ok");
1018
+ });
1019
+ parent
1020
+ .command("sklgov-set-idle-ms-v2 <n>")
1021
+ .description("Set idle threshold ms")
1022
+ .action(async (n) => {
1023
+ (await L()).setSklgovProfileIdleMsV2(Number(n));
1024
+ console.log("ok");
1025
+ });
1026
+ parent
1027
+ .command("sklgov-set-stuck-ms-v2 <n>")
1028
+ .description("Set stuck threshold ms")
1029
+ .action(async (n) => {
1030
+ (await L()).setSklgovLoadStuckMsV2(Number(n));
1031
+ console.log("ok");
1032
+ });
1033
+ parent
1034
+ .command("sklgov-register-v2 <id> <owner>")
1035
+ .description("Register V2 profile")
1036
+ .option("--source <v>", "source")
1037
+ .action(async (id, owner, o) => {
1038
+ const m = await L();
1039
+ console.log(
1040
+ JSON.stringify(
1041
+ m.registerSklgovProfileV2({ id, owner, source: o.source }),
1042
+ null,
1043
+ 2,
1044
+ ),
1045
+ );
1046
+ });
1047
+ parent
1048
+ .command("sklgov-activate-v2 <id>")
1049
+ .description("Activate profile")
1050
+ .action(async (id) => {
1051
+ console.log(
1052
+ JSON.stringify((await L()).activateSklgovProfileV2(id), null, 2),
1053
+ );
1054
+ });
1055
+ parent
1056
+ .command("sklgov-stale-v2 <id>")
1057
+ .description("Stale profile")
1058
+ .action(async (id) => {
1059
+ console.log(
1060
+ JSON.stringify((await L()).staleSklgovProfileV2(id), null, 2),
1061
+ );
1062
+ });
1063
+ parent
1064
+ .command("sklgov-archive-v2 <id>")
1065
+ .description("Archive profile")
1066
+ .action(async (id) => {
1067
+ console.log(
1068
+ JSON.stringify((await L()).archiveSklgovProfileV2(id), null, 2),
1069
+ );
1070
+ });
1071
+ parent
1072
+ .command("sklgov-touch-v2 <id>")
1073
+ .description("Touch profile")
1074
+ .action(async (id) => {
1075
+ console.log(
1076
+ JSON.stringify((await L()).touchSklgovProfileV2(id), null, 2),
1077
+ );
1078
+ });
1079
+ parent
1080
+ .command("sklgov-get-v2 <id>")
1081
+ .description("Get profile")
1082
+ .action(async (id) => {
1083
+ console.log(JSON.stringify((await L()).getSklgovProfileV2(id), null, 2));
1084
+ });
1085
+ parent
1086
+ .command("sklgov-list-v2")
1087
+ .description("List profiles")
1088
+ .action(async () => {
1089
+ console.log(JSON.stringify((await L()).listSklgovProfilesV2(), null, 2));
1090
+ });
1091
+ parent
1092
+ .command("sklgov-create-load-v2 <id> <profileId>")
1093
+ .description("Create load")
1094
+ .option("--skillId <v>", "skillId")
1095
+ .action(async (id, profileId, o) => {
1096
+ const m = await L();
1097
+ console.log(
1098
+ JSON.stringify(
1099
+ m.createSklgovLoadV2({ id, profileId, skillId: o.skillId }),
1100
+ null,
1101
+ 2,
1102
+ ),
1103
+ );
1104
+ });
1105
+ parent
1106
+ .command("sklgov-loading-load-v2 <id>")
1107
+ .description("Mark load as loading")
1108
+ .action(async (id) => {
1109
+ console.log(JSON.stringify((await L()).loadingSklgovLoadV2(id), null, 2));
1110
+ });
1111
+ parent
1112
+ .command("sklgov-complete-load-v2 <id>")
1113
+ .description("Complete load")
1114
+ .action(async (id) => {
1115
+ console.log(
1116
+ JSON.stringify((await L()).completeLoadSklgovV2(id), null, 2),
1117
+ );
1118
+ });
1119
+ parent
1120
+ .command("sklgov-fail-load-v2 <id> [reason]")
1121
+ .description("Fail load")
1122
+ .action(async (id, reason) => {
1123
+ console.log(
1124
+ JSON.stringify((await L()).failSklgovLoadV2(id, reason), null, 2),
1125
+ );
1126
+ });
1127
+ parent
1128
+ .command("sklgov-cancel-load-v2 <id> [reason]")
1129
+ .description("Cancel load")
1130
+ .action(async (id, reason) => {
1131
+ console.log(
1132
+ JSON.stringify((await L()).cancelSklgovLoadV2(id, reason), null, 2),
1133
+ );
1134
+ });
1135
+ parent
1136
+ .command("sklgov-get-load-v2 <id>")
1137
+ .description("Get load")
1138
+ .action(async (id) => {
1139
+ console.log(JSON.stringify((await L()).getSklgovLoadV2(id), null, 2));
1140
+ });
1141
+ parent
1142
+ .command("sklgov-list-loads-v2")
1143
+ .description("List loads")
1144
+ .action(async () => {
1145
+ console.log(JSON.stringify((await L()).listSklgovLoadsV2(), null, 2));
1146
+ });
1147
+ parent
1148
+ .command("sklgov-auto-stale-idle-v2")
1149
+ .description("Auto-stale idle")
1150
+ .action(async () => {
1151
+ console.log(
1152
+ JSON.stringify((await L()).autoStaleIdleSklgovProfilesV2(), null, 2),
1153
+ );
1154
+ });
1155
+ parent
1156
+ .command("sklgov-auto-fail-stuck-v2")
1157
+ .description("Auto-fail stuck loads")
1158
+ .action(async () => {
1159
+ console.log(
1160
+ JSON.stringify((await L()).autoFailStuckSklgovLoadsV2(), null, 2),
1161
+ );
1162
+ });
1163
+ parent
1164
+ .command("sklgov-gov-stats-v2")
1165
+ .description("V2 gov stats")
1166
+ .action(async () => {
1167
+ console.log(
1168
+ JSON.stringify((await L()).getSkillLoaderGovStatsV2(), null, 2),
1169
+ );
1170
+ });
1171
+ }
@@ -609,3 +609,215 @@ export function registerSlaCommand(program) {
609
609
  console.log(JSON.stringify(getSLAStatsV2(), null, 2));
610
610
  });
611
611
  }
612
+
613
+ // === Iter16 V2 governance overlay ===
614
+ export function registerSlagovV2Commands(program) {
615
+ const parent = program.commands.find((c) => c.name() === "sla");
616
+ if (!parent) return;
617
+ const L = async () => await import("../lib/sla-manager.js");
618
+ parent
619
+ .command("slagov-enums-v2")
620
+ .description("Show V2 enums (slagov maturity + measurement lifecycle)")
621
+ .action(async () => {
622
+ const m = await L();
623
+ console.log(
624
+ JSON.stringify(
625
+ {
626
+ profileMaturity: m.SLAGOV_PROFILE_MATURITY_V2,
627
+ measurementLifecycle: m.SLAGOV_MEASUREMENT_LIFECYCLE_V2,
628
+ },
629
+ null,
630
+ 2,
631
+ ),
632
+ );
633
+ });
634
+ parent
635
+ .command("slagov-config-v2")
636
+ .description("Show V2 config thresholds")
637
+ .action(async () => {
638
+ const m = await L();
639
+ console.log(
640
+ JSON.stringify(
641
+ {
642
+ maxActive: m.getMaxActiveSlagovProfilesPerOwnerV2(),
643
+ maxPending: m.getMaxPendingSlagovMeasurementsPerProfileV2(),
644
+ idleMs: m.getSlagovProfileIdleMsV2(),
645
+ stuckMs: m.getSlagovMeasurementStuckMsV2(),
646
+ },
647
+ null,
648
+ 2,
649
+ ),
650
+ );
651
+ });
652
+ parent
653
+ .command("slagov-set-max-active-v2 <n>")
654
+ .description("Set max active profiles per owner")
655
+ .action(async (n) => {
656
+ const m = await L();
657
+ m.setMaxActiveSlagovProfilesPerOwnerV2(Number(n));
658
+ console.log("ok");
659
+ });
660
+ parent
661
+ .command("slagov-set-max-pending-v2 <n>")
662
+ .description("Set max pending measurements per profile")
663
+ .action(async (n) => {
664
+ const m = await L();
665
+ m.setMaxPendingSlagovMeasurementsPerProfileV2(Number(n));
666
+ console.log("ok");
667
+ });
668
+ parent
669
+ .command("slagov-set-idle-ms-v2 <n>")
670
+ .description("Set profile idle threshold (ms)")
671
+ .action(async (n) => {
672
+ const m = await L();
673
+ m.setSlagovProfileIdleMsV2(Number(n));
674
+ console.log("ok");
675
+ });
676
+ parent
677
+ .command("slagov-set-stuck-ms-v2 <n>")
678
+ .description("Set measurement stuck threshold (ms)")
679
+ .action(async (n) => {
680
+ const m = await L();
681
+ m.setSlagovMeasurementStuckMsV2(Number(n));
682
+ console.log("ok");
683
+ });
684
+ parent
685
+ .command("slagov-register-v2 <id> <owner>")
686
+ .description("Register V2 slagov profile")
687
+ .option("--tier <v>", "tier")
688
+ .action(async (id, owner, o) => {
689
+ const m = await L();
690
+ console.log(
691
+ JSON.stringify(
692
+ m.registerSlagovProfileV2({ id, owner, tier: o.tier }),
693
+ null,
694
+ 2,
695
+ ),
696
+ );
697
+ });
698
+ parent
699
+ .command("slagov-activate-v2 <id>")
700
+ .description("Activate profile")
701
+ .action(async (id) => {
702
+ const m = await L();
703
+ console.log(JSON.stringify(m.activateSlagovProfileV2(id), null, 2));
704
+ });
705
+ parent
706
+ .command("slagov-breach-v2 <id>")
707
+ .description("Breach profile")
708
+ .action(async (id) => {
709
+ const m = await L();
710
+ console.log(JSON.stringify(m.breachSlagovProfileV2(id), null, 2));
711
+ });
712
+ parent
713
+ .command("slagov-archive-v2 <id>")
714
+ .description("Archive profile (terminal)")
715
+ .action(async (id) => {
716
+ const m = await L();
717
+ console.log(JSON.stringify(m.archiveSlagovProfileV2(id), null, 2));
718
+ });
719
+ parent
720
+ .command("slagov-touch-v2 <id>")
721
+ .description("Touch profile")
722
+ .action(async (id) => {
723
+ const m = await L();
724
+ console.log(JSON.stringify(m.touchSlagovProfileV2(id), null, 2));
725
+ });
726
+ parent
727
+ .command("slagov-get-v2 <id>")
728
+ .description("Get profile")
729
+ .action(async (id) => {
730
+ const m = await L();
731
+ console.log(JSON.stringify(m.getSlagovProfileV2(id), null, 2));
732
+ });
733
+ parent
734
+ .command("slagov-list-v2")
735
+ .description("List profiles")
736
+ .action(async () => {
737
+ const m = await L();
738
+ console.log(JSON.stringify(m.listSlagovProfilesV2(), null, 2));
739
+ });
740
+ parent
741
+ .command("slagov-create-measurement-v2 <id> <profileId>")
742
+ .description("Create measurement (queued)")
743
+ .option("--metric <v>", "metric")
744
+ .action(async (id, profileId, o) => {
745
+ const m = await L();
746
+ console.log(
747
+ JSON.stringify(
748
+ m.createSlagovMeasurementV2({ id, profileId, metric: o.metric }),
749
+ null,
750
+ 2,
751
+ ),
752
+ );
753
+ });
754
+ parent
755
+ .command("slagov-measuring-measurement-v2 <id>")
756
+ .description("Mark measurement as measuring")
757
+ .action(async (id) => {
758
+ const m = await L();
759
+ console.log(JSON.stringify(m.measuringSlagovMeasurementV2(id), null, 2));
760
+ });
761
+ parent
762
+ .command("slagov-complete-measurement-v2 <id>")
763
+ .description("Complete measurement")
764
+ .action(async (id) => {
765
+ const m = await L();
766
+ console.log(JSON.stringify(m.completeMeasurementSlagovV2(id), null, 2));
767
+ });
768
+ parent
769
+ .command("slagov-fail-measurement-v2 <id> [reason]")
770
+ .description("Fail measurement")
771
+ .action(async (id, reason) => {
772
+ const m = await L();
773
+ console.log(
774
+ JSON.stringify(m.failSlagovMeasurementV2(id, reason), null, 2),
775
+ );
776
+ });
777
+ parent
778
+ .command("slagov-cancel-measurement-v2 <id> [reason]")
779
+ .description("Cancel measurement")
780
+ .action(async (id, reason) => {
781
+ const m = await L();
782
+ console.log(
783
+ JSON.stringify(m.cancelSlagovMeasurementV2(id, reason), null, 2),
784
+ );
785
+ });
786
+ parent
787
+ .command("slagov-get-measurement-v2 <id>")
788
+ .description("Get measurement")
789
+ .action(async (id) => {
790
+ const m = await L();
791
+ console.log(JSON.stringify(m.getSlagovMeasurementV2(id), null, 2));
792
+ });
793
+ parent
794
+ .command("slagov-list-measurements-v2")
795
+ .description("List measurements")
796
+ .action(async () => {
797
+ const m = await L();
798
+ console.log(JSON.stringify(m.listSlagovMeasurementsV2(), null, 2));
799
+ });
800
+ parent
801
+ .command("slagov-auto-breach-idle-v2")
802
+ .description("Auto-breach idle profiles")
803
+ .action(async () => {
804
+ const m = await L();
805
+ console.log(JSON.stringify(m.autoBreachIdleSlagovProfilesV2(), null, 2));
806
+ });
807
+ parent
808
+ .command("slagov-auto-fail-stuck-v2")
809
+ .description("Auto-fail stuck measurements")
810
+ .action(async () => {
811
+ const m = await L();
812
+ console.log(
813
+ JSON.stringify(m.autoFailStuckSlagovMeasurementsV2(), null, 2),
814
+ );
815
+ });
816
+ parent
817
+ .command("slagov-gov-stats-v2")
818
+ .description("V2 gov aggregate stats")
819
+ .action(async () => {
820
+ const m = await L();
821
+ console.log(JSON.stringify(m.getSlaManagerGovStatsV2(), null, 2));
822
+ });
823
+ }