moflo 4.8.30 → 4.8.32

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 (390) hide show
  1. package/.claude/guidance/shipped/moflo.md +13 -35
  2. package/bin/generate-code-map.mjs +1 -1
  3. package/bin/index-guidance.mjs +1 -1
  4. package/bin/index-tests.mjs +1 -1
  5. package/bin/setup-project.mjs +1 -1
  6. package/package.json +6 -7
  7. package/src/@claude-flow/cli/dist/src/commands/doctor.js +1107 -1244
  8. package/src/@claude-flow/cli/package.json +1 -1
  9. package/.claude/agents/browser/browser-agent.yaml +0 -182
  10. package/.claude/agents/database-specialist.yaml +0 -21
  11. package/.claude/agents/index.yaml +0 -17
  12. package/.claude/agents/project-coordinator.yaml +0 -15
  13. package/.claude/agents/python-specialist.yaml +0 -21
  14. package/.claude/agents/security-auditor.yaml +0 -20
  15. package/.claude/agents/typescript-specialist.yaml +0 -21
  16. package/.claude/checkpoints/1767754460.json +0 -8
  17. package/.claude/config/v3-dependency-optimization.json +0 -266
  18. package/.claude/config/v3-performance-targets.json +0 -251
  19. package/.claude/guidance/moflo-bootstrap.md +0 -129
  20. package/.claude/mcp.json +0 -13
  21. package/.claude/settings.json +0 -351
  22. package/.claude/settings.local.json +0 -18
  23. package/.claude/skills/agentdb-advanced/SKILL.md +0 -550
  24. package/.claude/skills/agentdb-learning/SKILL.md +0 -545
  25. package/.claude/skills/agentdb-memory-patterns/SKILL.md +0 -339
  26. package/.claude/skills/agentdb-optimization/SKILL.md +0 -509
  27. package/.claude/skills/agentdb-vector-search/SKILL.md +0 -339
  28. package/.claude/skills/browser/SKILL.md +0 -204
  29. package/.claude/skills/fl/SKILL.md +0 -583
  30. package/.claude/skills/flo/SKILL.md +0 -583
  31. package/.claude/skills/github-code-review/SKILL.md +0 -1140
  32. package/.claude/skills/github-multi-repo/SKILL.md +0 -874
  33. package/.claude/skills/github-project-management/SKILL.md +0 -1277
  34. package/.claude/skills/github-release-management/SKILL.md +0 -1081
  35. package/.claude/skills/github-workflow-automation/SKILL.md +0 -1065
  36. package/.claude/skills/hive-mind-advanced/SKILL.md +0 -712
  37. package/.claude/skills/hooks-automation/SKILL.md +0 -1201
  38. package/.claude/skills/pair-programming/SKILL.md +0 -1202
  39. package/.claude/skills/performance-analysis/SKILL.md +0 -563
  40. package/.claude/skills/reasoningbank-agentdb/SKILL.md +0 -446
  41. package/.claude/skills/reasoningbank-intelligence/SKILL.md +0 -201
  42. package/.claude/skills/skill-builder/SKILL.md +0 -910
  43. package/.claude/skills/sparc-methodology/SKILL.md +0 -1115
  44. package/.claude/skills/stream-chain/SKILL.md +0 -563
  45. package/.claude/skills/swarm-advanced/SKILL.md +0 -973
  46. package/.claude/skills/swarm-orchestration/SKILL.md +0 -179
  47. package/.claude/skills/v3-cli-modernization/SKILL.md +0 -872
  48. package/.claude/skills/v3-core-implementation/SKILL.md +0 -797
  49. package/.claude/skills/v3-ddd-architecture/SKILL.md +0 -442
  50. package/.claude/skills/v3-integration-deep/SKILL.md +0 -241
  51. package/.claude/skills/v3-mcp-optimization/SKILL.md +0 -777
  52. package/.claude/skills/v3-memory-unification/SKILL.md +0 -174
  53. package/.claude/skills/v3-performance-optimization/SKILL.md +0 -390
  54. package/.claude/skills/v3-security-overhaul/SKILL.md +0 -82
  55. package/.claude/skills/v3-swarm-coordination/SKILL.md +0 -340
  56. package/.claude/skills/verification-quality/SKILL.md +0 -649
  57. package/.claude/skills/worker-benchmarks/skill.md +0 -135
  58. package/.claude/skills/worker-integration/skill.md +0 -154
  59. package/.claude/workflow-state.json +0 -9
  60. package/src/@claude-flow/cli/dist/src/appliance/gguf-engine.d.ts +0 -91
  61. package/src/@claude-flow/cli/dist/src/appliance/ruvllm-bridge.d.ts +0 -102
  62. package/src/@claude-flow/cli/dist/src/appliance/rvfa-builder.d.ts +0 -44
  63. package/src/@claude-flow/cli/dist/src/appliance/rvfa-distribution.d.ts +0 -97
  64. package/src/@claude-flow/cli/dist/src/appliance/rvfa-format.d.ts +0 -111
  65. package/src/@claude-flow/cli/dist/src/appliance/rvfa-runner.d.ts +0 -69
  66. package/src/@claude-flow/cli/dist/src/appliance/rvfa-signing.d.ts +0 -123
  67. package/src/@claude-flow/cli/dist/src/benchmarks/pretrain/index.d.ts +0 -58
  68. package/src/@claude-flow/cli/dist/src/commands/agent.d.ts +0 -8
  69. package/src/@claude-flow/cli/dist/src/commands/analyze.d.ts +0 -19
  70. package/src/@claude-flow/cli/dist/src/commands/appliance-advanced.d.ts +0 -9
  71. package/src/@claude-flow/cli/dist/src/commands/appliance.d.ts +0 -8
  72. package/src/@claude-flow/cli/dist/src/commands/benchmark.d.ts +0 -10
  73. package/src/@claude-flow/cli/dist/src/commands/claims.d.ts +0 -10
  74. package/src/@claude-flow/cli/dist/src/commands/completions.d.ts +0 -10
  75. package/src/@claude-flow/cli/dist/src/commands/config.d.ts +0 -8
  76. package/src/@claude-flow/cli/dist/src/commands/daemon.d.ts +0 -8
  77. package/src/@claude-flow/cli/dist/src/commands/deployment.d.ts +0 -10
  78. package/src/@claude-flow/cli/dist/src/commands/diagnose.d.ts +0 -16
  79. package/src/@claude-flow/cli/dist/src/commands/doctor.d.ts +0 -10
  80. package/src/@claude-flow/cli/dist/src/commands/embeddings.d.ts +0 -18
  81. package/src/@claude-flow/cli/dist/src/commands/gate.d.ts +0 -23
  82. package/src/@claude-flow/cli/dist/src/commands/github.d.ts +0 -12
  83. package/src/@claude-flow/cli/dist/src/commands/guidance.d.ts +0 -8
  84. package/src/@claude-flow/cli/dist/src/commands/hive-mind.d.ts +0 -11
  85. package/src/@claude-flow/cli/dist/src/commands/hooks.d.ts +0 -8
  86. package/src/@claude-flow/cli/dist/src/commands/index.d.ts +0 -115
  87. package/src/@claude-flow/cli/dist/src/commands/init.d.ts +0 -8
  88. package/src/@claude-flow/cli/dist/src/commands/issues.d.ts +0 -21
  89. package/src/@claude-flow/cli/dist/src/commands/mcp.d.ts +0 -11
  90. package/src/@claude-flow/cli/dist/src/commands/memory.d.ts +0 -8
  91. package/src/@claude-flow/cli/dist/src/commands/migrate.d.ts +0 -8
  92. package/src/@claude-flow/cli/dist/src/commands/neural.d.ts +0 -10
  93. package/src/@claude-flow/cli/dist/src/commands/orc.d.ts +0 -21
  94. package/src/@claude-flow/cli/dist/src/commands/performance.d.ts +0 -10
  95. package/src/@claude-flow/cli/dist/src/commands/plugins.d.ts +0 -11
  96. package/src/@claude-flow/cli/dist/src/commands/process.d.ts +0 -10
  97. package/src/@claude-flow/cli/dist/src/commands/progress.d.ts +0 -11
  98. package/src/@claude-flow/cli/dist/src/commands/providers.d.ts +0 -10
  99. package/src/@claude-flow/cli/dist/src/commands/route.d.ts +0 -16
  100. package/src/@claude-flow/cli/dist/src/commands/ruvector/backup.d.ts +0 -11
  101. package/src/@claude-flow/cli/dist/src/commands/ruvector/benchmark.d.ts +0 -11
  102. package/src/@claude-flow/cli/dist/src/commands/ruvector/import.d.ts +0 -18
  103. package/src/@claude-flow/cli/dist/src/commands/ruvector/index.d.ts +0 -29
  104. package/src/@claude-flow/cli/dist/src/commands/ruvector/init.d.ts +0 -11
  105. package/src/@claude-flow/cli/dist/src/commands/ruvector/migrate.d.ts +0 -11
  106. package/src/@claude-flow/cli/dist/src/commands/ruvector/optimize.d.ts +0 -11
  107. package/src/@claude-flow/cli/dist/src/commands/ruvector/setup.d.ts +0 -18
  108. package/src/@claude-flow/cli/dist/src/commands/ruvector/status.d.ts +0 -11
  109. package/src/@claude-flow/cli/dist/src/commands/security.d.ts +0 -10
  110. package/src/@claude-flow/cli/dist/src/commands/session.d.ts +0 -8
  111. package/src/@claude-flow/cli/dist/src/commands/start.d.ts +0 -8
  112. package/src/@claude-flow/cli/dist/src/commands/status.d.ts +0 -8
  113. package/src/@claude-flow/cli/dist/src/commands/swarm.d.ts +0 -8
  114. package/src/@claude-flow/cli/dist/src/commands/task.d.ts +0 -8
  115. package/src/@claude-flow/cli/dist/src/commands/transfer-store.d.ts +0 -13
  116. package/src/@claude-flow/cli/dist/src/commands/update.d.ts +0 -8
  117. package/src/@claude-flow/cli/dist/src/commands/workflow.d.ts +0 -8
  118. package/src/@claude-flow/cli/dist/src/config/moflo-config.d.ts +0 -93
  119. package/src/@claude-flow/cli/dist/src/config-adapter.d.ts +0 -15
  120. package/src/@claude-flow/cli/dist/src/index.d.ts +0 -81
  121. package/src/@claude-flow/cli/dist/src/infrastructure/in-memory-repositories.d.ts +0 -68
  122. package/src/@claude-flow/cli/dist/src/init/claudemd-generator.d.ts +0 -30
  123. package/src/@claude-flow/cli/dist/src/init/executor.d.ts +0 -41
  124. package/src/@claude-flow/cli/dist/src/init/helpers-generator.d.ts +0 -51
  125. package/src/@claude-flow/cli/dist/src/init/index.d.ts +0 -13
  126. package/src/@claude-flow/cli/dist/src/init/mcp-generator.d.ts +0 -29
  127. package/src/@claude-flow/cli/dist/src/init/moflo-init.d.ts +0 -31
  128. package/src/@claude-flow/cli/dist/src/init/settings-generator.d.ts +0 -14
  129. package/src/@claude-flow/cli/dist/src/init/statusline-generator.d.ts +0 -28
  130. package/src/@claude-flow/cli/dist/src/init/types.d.ts +0 -285
  131. package/src/@claude-flow/cli/dist/src/mcp-client.d.ts +0 -92
  132. package/src/@claude-flow/cli/dist/src/mcp-server.d.ts +0 -161
  133. package/src/@claude-flow/cli/dist/src/mcp-tools/agent-tools.d.ts +0 -9
  134. package/src/@claude-flow/cli/dist/src/mcp-tools/agentdb-tools.d.ts +0 -30
  135. package/src/@claude-flow/cli/dist/src/mcp-tools/analyze-tools.d.ts +0 -38
  136. package/src/@claude-flow/cli/dist/src/mcp-tools/auto-install.d.ts +0 -83
  137. package/src/@claude-flow/cli/dist/src/mcp-tools/browser-tools.d.ts +0 -13
  138. package/src/@claude-flow/cli/dist/src/mcp-tools/claims-tools.d.ts +0 -12
  139. package/src/@claude-flow/cli/dist/src/mcp-tools/config-tools.d.ts +0 -8
  140. package/src/@claude-flow/cli/dist/src/mcp-tools/coordination-tools.d.ts +0 -13
  141. package/src/@claude-flow/cli/dist/src/mcp-tools/daa-tools.d.ts +0 -13
  142. package/src/@claude-flow/cli/dist/src/mcp-tools/embeddings-tools.d.ts +0 -9
  143. package/src/@claude-flow/cli/dist/src/mcp-tools/github-tools.d.ts +0 -13
  144. package/src/@claude-flow/cli/dist/src/mcp-tools/hive-mind-tools.d.ts +0 -8
  145. package/src/@claude-flow/cli/dist/src/mcp-tools/hooks-tools.d.ts +0 -44
  146. package/src/@claude-flow/cli/dist/src/mcp-tools/index.d.ts +0 -23
  147. package/src/@claude-flow/cli/dist/src/mcp-tools/memory-tools.d.ts +0 -14
  148. package/src/@claude-flow/cli/dist/src/mcp-tools/neural-tools.d.ts +0 -16
  149. package/src/@claude-flow/cli/dist/src/mcp-tools/performance-tools.d.ts +0 -16
  150. package/src/@claude-flow/cli/dist/src/mcp-tools/progress-tools.d.ts +0 -14
  151. package/src/@claude-flow/cli/dist/src/mcp-tools/security-tools.d.ts +0 -18
  152. package/src/@claude-flow/cli/dist/src/mcp-tools/session-tools.d.ts +0 -8
  153. package/src/@claude-flow/cli/dist/src/mcp-tools/swarm-tools.d.ts +0 -8
  154. package/src/@claude-flow/cli/dist/src/mcp-tools/system-tools.d.ts +0 -13
  155. package/src/@claude-flow/cli/dist/src/mcp-tools/task-tools.d.ts +0 -8
  156. package/src/@claude-flow/cli/dist/src/mcp-tools/terminal-tools.d.ts +0 -13
  157. package/src/@claude-flow/cli/dist/src/mcp-tools/transfer-tools.d.ts +0 -14
  158. package/src/@claude-flow/cli/dist/src/mcp-tools/types.d.ts +0 -31
  159. package/src/@claude-flow/cli/dist/src/mcp-tools/workflow-tools.d.ts +0 -8
  160. package/src/@claude-flow/cli/dist/src/memory/ewc-consolidation.d.ts +0 -271
  161. package/src/@claude-flow/cli/dist/src/memory/intelligence.d.ts +0 -285
  162. package/src/@claude-flow/cli/dist/src/memory/memory-bridge.d.ts +0 -413
  163. package/src/@claude-flow/cli/dist/src/memory/memory-initializer.d.ts +0 -405
  164. package/src/@claude-flow/cli/dist/src/memory/sona-optimizer.d.ts +0 -227
  165. package/src/@claude-flow/cli/dist/src/output.d.ts +0 -133
  166. package/src/@claude-flow/cli/dist/src/parser.d.ts +0 -51
  167. package/src/@claude-flow/cli/dist/src/plugins/manager.d.ts +0 -133
  168. package/src/@claude-flow/cli/dist/src/plugins/store/discovery.d.ts +0 -88
  169. package/src/@claude-flow/cli/dist/src/plugins/store/index.d.ts +0 -76
  170. package/src/@claude-flow/cli/dist/src/plugins/store/search.d.ts +0 -46
  171. package/src/@claude-flow/cli/dist/src/plugins/store/types.d.ts +0 -274
  172. package/src/@claude-flow/cli/dist/src/plugins/tests/demo-plugin-store.d.ts +0 -7
  173. package/src/@claude-flow/cli/dist/src/plugins/tests/standalone-test.d.ts +0 -12
  174. package/src/@claude-flow/cli/dist/src/plugins/tests/test-plugin-store.d.ts +0 -7
  175. package/src/@claude-flow/cli/dist/src/production/circuit-breaker.d.ts +0 -101
  176. package/src/@claude-flow/cli/dist/src/production/error-handler.d.ts +0 -92
  177. package/src/@claude-flow/cli/dist/src/production/index.d.ts +0 -23
  178. package/src/@claude-flow/cli/dist/src/production/monitoring.d.ts +0 -161
  179. package/src/@claude-flow/cli/dist/src/production/rate-limiter.d.ts +0 -80
  180. package/src/@claude-flow/cli/dist/src/production/retry.d.ts +0 -48
  181. package/src/@claude-flow/cli/dist/src/prompt.d.ts +0 -44
  182. package/src/@claude-flow/cli/dist/src/runtime/headless.d.ts +0 -60
  183. package/src/@claude-flow/cli/dist/src/ruvector/ast-analyzer.d.ts +0 -67
  184. package/src/@claude-flow/cli/dist/src/ruvector/coverage-router.d.ts +0 -160
  185. package/src/@claude-flow/cli/dist/src/ruvector/coverage-tools.d.ts +0 -33
  186. package/src/@claude-flow/cli/dist/src/ruvector/diff-classifier.d.ts +0 -175
  187. package/src/@claude-flow/cli/dist/src/ruvector/enhanced-model-router.d.ts +0 -146
  188. package/src/@claude-flow/cli/dist/src/ruvector/flash-attention.d.ts +0 -195
  189. package/src/@claude-flow/cli/dist/src/ruvector/graph-analyzer.d.ts +0 -187
  190. package/src/@claude-flow/cli/dist/src/ruvector/index.d.ts +0 -34
  191. package/src/@claude-flow/cli/dist/src/ruvector/lora-adapter.d.ts +0 -218
  192. package/src/@claude-flow/cli/dist/src/ruvector/model-router.d.ts +0 -220
  193. package/src/@claude-flow/cli/dist/src/ruvector/moe-router.d.ts +0 -206
  194. package/src/@claude-flow/cli/dist/src/ruvector/q-learning-router.d.ts +0 -211
  195. package/src/@claude-flow/cli/dist/src/ruvector/semantic-router.d.ts +0 -77
  196. package/src/@claude-flow/cli/dist/src/ruvector/vector-db.d.ts +0 -69
  197. package/src/@claude-flow/cli/dist/src/services/agent-router.d.ts +0 -63
  198. package/src/@claude-flow/cli/dist/src/services/agentic-flow-bridge.d.ts +0 -50
  199. package/src/@claude-flow/cli/dist/src/services/claim-service.d.ts +0 -204
  200. package/src/@claude-flow/cli/dist/src/services/container-worker-pool.d.ts +0 -197
  201. package/src/@claude-flow/cli/dist/src/services/daemon-lock.d.ts +0 -60
  202. package/src/@claude-flow/cli/dist/src/services/headless-worker-executor.d.ts +0 -304
  203. package/src/@claude-flow/cli/dist/src/services/index.d.ts +0 -13
  204. package/src/@claude-flow/cli/dist/src/services/learning-service.d.ts +0 -161
  205. package/src/@claude-flow/cli/dist/src/services/moflo-require.d.ts +0 -34
  206. package/src/@claude-flow/cli/dist/src/services/registry-api.d.ts +0 -58
  207. package/src/@claude-flow/cli/dist/src/services/ruvector-training.d.ts +0 -214
  208. package/src/@claude-flow/cli/dist/src/services/worker-daemon.d.ts +0 -225
  209. package/src/@claude-flow/cli/dist/src/services/worker-queue.d.ts +0 -194
  210. package/src/@claude-flow/cli/dist/src/services/workflow-gate.d.ts +0 -88
  211. package/src/@claude-flow/cli/dist/src/suggest.d.ts +0 -53
  212. package/src/@claude-flow/cli/dist/src/transfer/anonymization/index.d.ts +0 -25
  213. package/src/@claude-flow/cli/dist/src/transfer/deploy-seraphine.d.ts +0 -13
  214. package/src/@claude-flow/cli/dist/src/transfer/export.d.ts +0 -25
  215. package/src/@claude-flow/cli/dist/src/transfer/index.d.ts +0 -12
  216. package/src/@claude-flow/cli/dist/src/transfer/ipfs/client.d.ts +0 -109
  217. package/src/@claude-flow/cli/dist/src/transfer/ipfs/upload.d.ts +0 -95
  218. package/src/@claude-flow/cli/dist/src/transfer/models/seraphine.d.ts +0 -72
  219. package/src/@claude-flow/cli/dist/src/transfer/serialization/cfp.d.ts +0 -49
  220. package/src/@claude-flow/cli/dist/src/transfer/storage/gcs.d.ts +0 -82
  221. package/src/@claude-flow/cli/dist/src/transfer/storage/index.d.ts +0 -6
  222. package/src/@claude-flow/cli/dist/src/transfer/store/discovery.d.ts +0 -84
  223. package/src/@claude-flow/cli/dist/src/transfer/store/download.d.ts +0 -70
  224. package/src/@claude-flow/cli/dist/src/transfer/store/index.d.ts +0 -84
  225. package/src/@claude-flow/cli/dist/src/transfer/store/publish.d.ts +0 -76
  226. package/src/@claude-flow/cli/dist/src/transfer/store/registry.d.ts +0 -58
  227. package/src/@claude-flow/cli/dist/src/transfer/store/search.d.ts +0 -54
  228. package/src/@claude-flow/cli/dist/src/transfer/store/tests/standalone-test.d.ts +0 -12
  229. package/src/@claude-flow/cli/dist/src/transfer/store/types.d.ts +0 -193
  230. package/src/@claude-flow/cli/dist/src/transfer/test-seraphine.d.ts +0 -6
  231. package/src/@claude-flow/cli/dist/src/transfer/tests/test-store.d.ts +0 -7
  232. package/src/@claude-flow/cli/dist/src/transfer/types.d.ts +0 -245
  233. package/src/@claude-flow/cli/dist/src/types.d.ts +0 -198
  234. package/src/@claude-flow/cli/dist/src/update/checker.d.ts +0 -34
  235. package/src/@claude-flow/cli/dist/src/update/executor.d.ts +0 -32
  236. package/src/@claude-flow/cli/dist/src/update/index.d.ts +0 -33
  237. package/src/@claude-flow/cli/dist/src/update/rate-limiter.d.ts +0 -20
  238. package/src/@claude-flow/cli/dist/src/update/validator.d.ts +0 -17
  239. package/src/@claude-flow/guidance/dist/adversarial.d.ts +0 -284
  240. package/src/@claude-flow/guidance/dist/analyzer.d.ts +0 -530
  241. package/src/@claude-flow/guidance/dist/artifacts.d.ts +0 -283
  242. package/src/@claude-flow/guidance/dist/authority.d.ts +0 -290
  243. package/src/@claude-flow/guidance/dist/capabilities.d.ts +0 -209
  244. package/src/@claude-flow/guidance/dist/coherence.d.ts +0 -233
  245. package/src/@claude-flow/guidance/dist/compiler.d.ts +0 -87
  246. package/src/@claude-flow/guidance/dist/conformance-kit.d.ts +0 -225
  247. package/src/@claude-flow/guidance/dist/continue-gate.d.ts +0 -214
  248. package/src/@claude-flow/guidance/dist/crypto-utils.d.ts +0 -17
  249. package/src/@claude-flow/guidance/dist/evolution.d.ts +0 -282
  250. package/src/@claude-flow/guidance/dist/gates.d.ts +0 -79
  251. package/src/@claude-flow/guidance/dist/gateway.d.ts +0 -206
  252. package/src/@claude-flow/guidance/dist/generators.d.ts +0 -153
  253. package/src/@claude-flow/guidance/dist/headless.d.ts +0 -177
  254. package/src/@claude-flow/guidance/dist/hooks.d.ts +0 -109
  255. package/src/@claude-flow/guidance/dist/index.d.ts +0 -205
  256. package/src/@claude-flow/guidance/dist/ledger.d.ts +0 -162
  257. package/src/@claude-flow/guidance/dist/manifest-validator.d.ts +0 -289
  258. package/src/@claude-flow/guidance/dist/memory-gate.d.ts +0 -222
  259. package/src/@claude-flow/guidance/dist/meta-governance.d.ts +0 -265
  260. package/src/@claude-flow/guidance/dist/optimizer.d.ts +0 -104
  261. package/src/@claude-flow/guidance/dist/persistence.d.ts +0 -189
  262. package/src/@claude-flow/guidance/dist/proof.d.ts +0 -185
  263. package/src/@claude-flow/guidance/dist/retriever.d.ts +0 -116
  264. package/src/@claude-flow/guidance/dist/ruvbot-integration.d.ts +0 -370
  265. package/src/@claude-flow/guidance/dist/temporal.d.ts +0 -426
  266. package/src/@claude-flow/guidance/dist/trust.d.ts +0 -283
  267. package/src/@claude-flow/guidance/dist/truth-anchors.d.ts +0 -276
  268. package/src/@claude-flow/guidance/dist/types.d.ts +0 -378
  269. package/src/@claude-flow/guidance/dist/uncertainty.d.ts +0 -372
  270. package/src/@claude-flow/guidance/dist/wasm-kernel.d.ts +0 -48
  271. package/src/@claude-flow/memory/dist/agent-memory-scope.d.ts +0 -131
  272. package/src/@claude-flow/memory/dist/agent-memory-scope.test.d.ts +0 -8
  273. package/src/@claude-flow/memory/dist/agentdb-adapter.d.ts +0 -165
  274. package/src/@claude-flow/memory/dist/agentdb-backend.d.ts +0 -212
  275. package/src/@claude-flow/memory/dist/agentdb-backend.test.d.ts +0 -7
  276. package/src/@claude-flow/memory/dist/application/commands/delete-memory.command.d.ts +0 -65
  277. package/src/@claude-flow/memory/dist/application/commands/store-memory.command.d.ts +0 -48
  278. package/src/@claude-flow/memory/dist/application/index.d.ts +0 -12
  279. package/src/@claude-flow/memory/dist/application/queries/search-memory.query.d.ts +0 -72
  280. package/src/@claude-flow/memory/dist/application/services/memory-application-service.d.ts +0 -121
  281. package/src/@claude-flow/memory/dist/auto-memory-bridge.d.ts +0 -226
  282. package/src/@claude-flow/memory/dist/auto-memory-bridge.test.d.ts +0 -8
  283. package/src/@claude-flow/memory/dist/benchmark.test.d.ts +0 -2
  284. package/src/@claude-flow/memory/dist/cache-manager.d.ts +0 -134
  285. package/src/@claude-flow/memory/dist/controller-registry.d.ts +0 -216
  286. package/src/@claude-flow/memory/dist/controller-registry.test.d.ts +0 -14
  287. package/src/@claude-flow/memory/dist/database-provider.d.ts +0 -87
  288. package/src/@claude-flow/memory/dist/database-provider.test.d.ts +0 -7
  289. package/src/@claude-flow/memory/dist/domain/entities/memory-entry.d.ts +0 -143
  290. package/src/@claude-flow/memory/dist/domain/index.d.ts +0 -11
  291. package/src/@claude-flow/memory/dist/domain/repositories/memory-repository.interface.d.ts +0 -102
  292. package/src/@claude-flow/memory/dist/domain/services/memory-domain-service.d.ts +0 -105
  293. package/src/@claude-flow/memory/dist/hnsw-index.d.ts +0 -111
  294. package/src/@claude-flow/memory/dist/hnsw-lite.d.ts +0 -23
  295. package/src/@claude-flow/memory/dist/hybrid-backend.d.ts +0 -245
  296. package/src/@claude-flow/memory/dist/hybrid-backend.test.d.ts +0 -8
  297. package/src/@claude-flow/memory/dist/index.d.ts +0 -204
  298. package/src/@claude-flow/memory/dist/infrastructure/index.d.ts +0 -17
  299. package/src/@claude-flow/memory/dist/infrastructure/repositories/hybrid-memory-repository.d.ts +0 -66
  300. package/src/@claude-flow/memory/dist/learning-bridge.d.ts +0 -137
  301. package/src/@claude-flow/memory/dist/learning-bridge.test.d.ts +0 -8
  302. package/src/@claude-flow/memory/dist/memory-graph.d.ts +0 -100
  303. package/src/@claude-flow/memory/dist/memory-graph.test.d.ts +0 -8
  304. package/src/@claude-flow/memory/dist/migration.d.ts +0 -68
  305. package/src/@claude-flow/memory/dist/persistent-sona.d.ts +0 -144
  306. package/src/@claude-flow/memory/dist/query-builder.d.ts +0 -211
  307. package/src/@claude-flow/memory/dist/rvf-backend.d.ts +0 -51
  308. package/src/@claude-flow/memory/dist/rvf-learning-store.d.ts +0 -139
  309. package/src/@claude-flow/memory/dist/rvf-migration.d.ts +0 -45
  310. package/src/@claude-flow/memory/dist/sqlite-backend.d.ts +0 -121
  311. package/src/@claude-flow/memory/dist/sqljs-backend.d.ts +0 -127
  312. package/src/@claude-flow/memory/dist/types.d.ts +0 -484
  313. package/src/@claude-flow/shared/dist/core/config/defaults.d.ts +0 -41
  314. package/src/@claude-flow/shared/dist/core/config/index.d.ts +0 -8
  315. package/src/@claude-flow/shared/dist/core/config/loader.d.ts +0 -45
  316. package/src/@claude-flow/shared/dist/core/config/schema.d.ts +0 -1134
  317. package/src/@claude-flow/shared/dist/core/config/validator.d.ts +0 -92
  318. package/src/@claude-flow/shared/dist/core/event-bus.d.ts +0 -31
  319. package/src/@claude-flow/shared/dist/core/index.d.ts +0 -15
  320. package/src/@claude-flow/shared/dist/core/interfaces/agent.interface.d.ts +0 -200
  321. package/src/@claude-flow/shared/dist/core/interfaces/coordinator.interface.d.ts +0 -310
  322. package/src/@claude-flow/shared/dist/core/interfaces/event.interface.d.ts +0 -224
  323. package/src/@claude-flow/shared/dist/core/interfaces/index.d.ts +0 -10
  324. package/src/@claude-flow/shared/dist/core/interfaces/memory.interface.d.ts +0 -298
  325. package/src/@claude-flow/shared/dist/core/interfaces/task.interface.d.ts +0 -185
  326. package/src/@claude-flow/shared/dist/core/orchestrator/event-coordinator.d.ts +0 -35
  327. package/src/@claude-flow/shared/dist/core/orchestrator/health-monitor.d.ts +0 -60
  328. package/src/@claude-flow/shared/dist/core/orchestrator/index.d.ts +0 -46
  329. package/src/@claude-flow/shared/dist/core/orchestrator/lifecycle-manager.d.ts +0 -56
  330. package/src/@claude-flow/shared/dist/core/orchestrator/session-manager.d.ts +0 -83
  331. package/src/@claude-flow/shared/dist/core/orchestrator/task-manager.d.ts +0 -49
  332. package/src/@claude-flow/shared/dist/events/domain-events.d.ts +0 -282
  333. package/src/@claude-flow/shared/dist/events/event-store.d.ts +0 -126
  334. package/src/@claude-flow/shared/dist/events/event-store.test.d.ts +0 -8
  335. package/src/@claude-flow/shared/dist/events/example-usage.d.ts +0 -10
  336. package/src/@claude-flow/shared/dist/events/index.d.ts +0 -21
  337. package/src/@claude-flow/shared/dist/events/projections.d.ts +0 -177
  338. package/src/@claude-flow/shared/dist/events/rvf-event-log.d.ts +0 -82
  339. package/src/@claude-flow/shared/dist/events/state-reconstructor.d.ts +0 -101
  340. package/src/@claude-flow/shared/dist/events.d.ts +0 -80
  341. package/src/@claude-flow/shared/dist/hooks/example-usage.d.ts +0 -42
  342. package/src/@claude-flow/shared/dist/hooks/executor.d.ts +0 -100
  343. package/src/@claude-flow/shared/dist/hooks/hooks.test.d.ts +0 -9
  344. package/src/@claude-flow/shared/dist/hooks/index.d.ts +0 -52
  345. package/src/@claude-flow/shared/dist/hooks/registry.d.ts +0 -133
  346. package/src/@claude-flow/shared/dist/hooks/safety/bash-safety.d.ts +0 -105
  347. package/src/@claude-flow/shared/dist/hooks/safety/file-organization.d.ts +0 -144
  348. package/src/@claude-flow/shared/dist/hooks/safety/git-commit.d.ts +0 -158
  349. package/src/@claude-flow/shared/dist/hooks/safety/index.d.ts +0 -17
  350. package/src/@claude-flow/shared/dist/hooks/session-hooks.d.ts +0 -234
  351. package/src/@claude-flow/shared/dist/hooks/task-hooks.d.ts +0 -163
  352. package/src/@claude-flow/shared/dist/hooks/types.d.ts +0 -267
  353. package/src/@claude-flow/shared/dist/hooks/verify-exports.test.d.ts +0 -9
  354. package/src/@claude-flow/shared/dist/index.d.ts +0 -20
  355. package/src/@claude-flow/shared/dist/mcp/connection-pool.d.ts +0 -98
  356. package/src/@claude-flow/shared/dist/mcp/index.d.ts +0 -69
  357. package/src/@claude-flow/shared/dist/mcp/server.d.ts +0 -166
  358. package/src/@claude-flow/shared/dist/mcp/session-manager.d.ts +0 -136
  359. package/src/@claude-flow/shared/dist/mcp/tool-registry.d.ts +0 -178
  360. package/src/@claude-flow/shared/dist/mcp/transport/http.d.ts +0 -104
  361. package/src/@claude-flow/shared/dist/mcp/transport/index.d.ts +0 -102
  362. package/src/@claude-flow/shared/dist/mcp/transport/stdio.d.ts +0 -104
  363. package/src/@claude-flow/shared/dist/mcp/transport/websocket.d.ts +0 -133
  364. package/src/@claude-flow/shared/dist/mcp/types.d.ts +0 -438
  365. package/src/@claude-flow/shared/dist/plugin-interface.d.ts +0 -544
  366. package/src/@claude-flow/shared/dist/plugin-loader.d.ts +0 -139
  367. package/src/@claude-flow/shared/dist/plugin-registry.d.ts +0 -183
  368. package/src/@claude-flow/shared/dist/plugins/index.d.ts +0 -10
  369. package/src/@claude-flow/shared/dist/plugins/official/hive-mind-plugin.d.ts +0 -106
  370. package/src/@claude-flow/shared/dist/plugins/official/index.d.ts +0 -10
  371. package/src/@claude-flow/shared/dist/plugins/official/maestro-plugin.d.ts +0 -121
  372. package/src/@claude-flow/shared/dist/plugins/types.d.ts +0 -93
  373. package/src/@claude-flow/shared/dist/resilience/bulkhead.d.ts +0 -105
  374. package/src/@claude-flow/shared/dist/resilience/circuit-breaker.d.ts +0 -132
  375. package/src/@claude-flow/shared/dist/resilience/index.d.ts +0 -19
  376. package/src/@claude-flow/shared/dist/resilience/rate-limiter.d.ts +0 -168
  377. package/src/@claude-flow/shared/dist/resilience/retry.d.ts +0 -91
  378. package/src/@claude-flow/shared/dist/security/index.d.ts +0 -10
  379. package/src/@claude-flow/shared/dist/security/input-validation.d.ts +0 -73
  380. package/src/@claude-flow/shared/dist/security/secure-random.d.ts +0 -92
  381. package/src/@claude-flow/shared/dist/services/index.d.ts +0 -7
  382. package/src/@claude-flow/shared/dist/services/v3-progress.service.d.ts +0 -124
  383. package/src/@claude-flow/shared/dist/types/agent.types.d.ts +0 -137
  384. package/src/@claude-flow/shared/dist/types/index.d.ts +0 -11
  385. package/src/@claude-flow/shared/dist/types/mcp.types.d.ts +0 -266
  386. package/src/@claude-flow/shared/dist/types/memory.types.d.ts +0 -236
  387. package/src/@claude-flow/shared/dist/types/swarm.types.d.ts +0 -186
  388. package/src/@claude-flow/shared/dist/types/task.types.d.ts +0 -178
  389. package/src/@claude-flow/shared/dist/types.d.ts +0 -197
  390. package/src/@claude-flow/shared/dist/utils/secure-logger.d.ts +0 -69
@@ -1,426 +0,0 @@
1
- /**
2
- * Temporal Assertions and Validity Windows
3
- *
4
- * Bitemporal semantics for knowledge: distinguishes *assertion time* (when
5
- * something was recorded) from *validity time* (when the fact is/was/will be
6
- * true in the real world).
7
- *
8
- * The system tracks two independent timelines:
9
- * - Assertion time: when the assertion was recorded and when it was retracted
10
- * - Validity time: when the fact becomes true (validFrom) and stops being true
11
- * (validUntil)
12
- *
13
- * Every assertion carries `validFrom`, `validUntil`, `assertedAt`, and
14
- * `supersededBy` fields. Status is computed dynamically from the current clock
15
- * and the assertion's lifecycle flags (retraction, supersession, expiration).
16
- *
17
- * TemporalStore:
18
- * - Creates assertions with explicit validity windows
19
- * - Retrieves assertions active at any point in time (past, present, future)
20
- * - Supports supersession chains (old fact replaced by new fact)
21
- * - Soft-delete via retraction (preserves full history)
22
- * - Conflict detection: finds multiple active assertions in the same namespace
23
- * - Export/import for persistence
24
- *
25
- * TemporalReasoner:
26
- * - High-level queries: whatWasTrue, whatIsTrue, whatWillBeTrue
27
- * - Change detection since a given timestamp
28
- * - Conflict detection at a point in time
29
- * - Forward projection of assertion validity
30
- *
31
- * @module @claude-flow/guidance/temporal
32
- */
33
- /**
34
- * Computed lifecycle status of a temporal assertion.
35
- *
36
- * - future: the validity window has not yet opened (validFrom > now)
37
- * - active: the assertion is currently valid (validFrom <= now < validUntil)
38
- * - expired: the validity window has closed (validUntil <= now)
39
- * - superseded: replaced by a newer assertion
40
- * - retracted: explicitly withdrawn (soft-deleted, history preserved)
41
- */
42
- export type TemporalStatus = 'future' | 'active' | 'expired' | 'superseded' | 'retracted';
43
- /**
44
- * The temporal window describing when a fact is valid and when it was recorded.
45
- */
46
- export interface ValidityWindow {
47
- /** Unix timestamp (ms) when the fact becomes true in the real world */
48
- validFrom: number;
49
- /** Unix timestamp (ms) when the fact stops being true, or null for indefinite */
50
- validUntil: number | null;
51
- /** Unix timestamp (ms) when the assertion was recorded in the system */
52
- assertedAt: number;
53
- /** Unix timestamp (ms) when the assertion was retracted, or null if still standing */
54
- retractedAt: number | null;
55
- }
56
- /**
57
- * A single temporal assertion: a claim with an explicit validity window,
58
- * supersession chain, confidence, and provenance metadata.
59
- */
60
- export interface TemporalAssertion {
61
- /** Unique assertion identifier (UUID v4) */
62
- id: string;
63
- /** The claim being asserted, in natural language */
64
- claim: string;
65
- /** Namespace for grouping related assertions */
66
- namespace: string;
67
- /** The temporal validity window */
68
- window: ValidityWindow;
69
- /** Computed lifecycle status (derived from window + retraction + supersession) */
70
- status: TemporalStatus;
71
- /** ID of the assertion that replaced this one, or null */
72
- supersededBy: string | null;
73
- /** ID of the assertion that this one replaces, or null */
74
- supersedes: string | null;
75
- /** Confidence in the assertion (0.0 - 1.0) */
76
- confidence: number;
77
- /** Who or what made this assertion */
78
- source: string;
79
- /** Searchable tags */
80
- tags: string[];
81
- /** Arbitrary metadata */
82
- metadata: Record<string, unknown>;
83
- }
84
- /**
85
- * Query options for filtering temporal assertions.
86
- */
87
- export interface TemporalQuery {
88
- /** Filter by namespace */
89
- namespace?: string;
90
- /** Return only assertions active at this point in time */
91
- pointInTime?: number;
92
- /** Filter by status (any match) */
93
- status?: TemporalStatus[];
94
- /** Filter by source */
95
- source?: string;
96
- /** Filter by tags (all must be present) */
97
- tags?: string[];
98
- }
99
- /**
100
- * Configuration for the TemporalStore.
101
- */
102
- export interface TemporalConfig {
103
- /** Maximum number of assertions to store (default 100000) */
104
- maxAssertions: number;
105
- /** Interval (ms) for auto-expire status checks (default 60000) */
106
- autoExpireCheckIntervalMs: number;
107
- }
108
- /**
109
- * A full timeline for an assertion: its predecessors and successors in the
110
- * supersession chain.
111
- */
112
- export interface TemporalTimeline {
113
- /** The assertion at the center of the timeline */
114
- assertion: TemporalAssertion;
115
- /** Assertions that were replaced leading up to this one (oldest first) */
116
- predecessors: TemporalAssertion[];
117
- /** Assertions that replaced this one (newest last) */
118
- successors: TemporalAssertion[];
119
- }
120
- /**
121
- * A detected change in the temporal store since a given timestamp.
122
- */
123
- export interface TemporalChange {
124
- /** The assertion that changed */
125
- assertion: TemporalAssertion;
126
- /** The kind of change */
127
- changeType: 'asserted' | 'superseded' | 'retracted' | 'expired';
128
- /** When the change occurred (assertion time, retraction time, etc.) */
129
- changedAt: number;
130
- }
131
- /**
132
- * Optional parameters when creating a new assertion.
133
- */
134
- export interface AssertOptions {
135
- /** Custom assertion ID (default: auto-generated UUID) */
136
- id?: string;
137
- /** Confidence in the assertion (0.0 - 1.0, default 1.0) */
138
- confidence?: number;
139
- /** Who or what is making this assertion (default 'system') */
140
- source?: string;
141
- /** Searchable tags */
142
- tags?: string[];
143
- /** Arbitrary metadata */
144
- metadata?: Record<string, unknown>;
145
- }
146
- /**
147
- * Serializable representation for export/import.
148
- */
149
- export interface SerializedTemporalStore {
150
- /** All assertions */
151
- assertions: TemporalAssertion[];
152
- /** When the export was created */
153
- createdAt: string;
154
- /** Schema version */
155
- version: number;
156
- }
157
- /**
158
- * In-memory store for temporal assertions with bitemporal semantics.
159
- *
160
- * Assertions are indexed by ID and support supersession chains, retraction,
161
- * temporal queries (what was active at time T), and conflict detection.
162
- * Status is computed dynamically from the assertion's window and lifecycle
163
- * flags; callers never set status directly.
164
- */
165
- export declare class TemporalStore {
166
- private readonly config;
167
- private readonly assertions;
168
- constructor(config?: Partial<TemporalConfig>);
169
- /**
170
- * Create a new temporal assertion.
171
- *
172
- * Records a claim with an explicit validity window. The assertion's status
173
- * is computed automatically from the window and the current time.
174
- *
175
- * @param claim - The fact being asserted
176
- * @param namespace - Grouping namespace
177
- * @param window - Validity window (validFrom and validUntil)
178
- * @param opts - Optional parameters (confidence, source, tags, metadata)
179
- * @returns The newly created TemporalAssertion
180
- */
181
- assert(claim: string, namespace: string, window: {
182
- validFrom: number;
183
- validUntil: number | null;
184
- }, opts?: AssertOptions): TemporalAssertion;
185
- /**
186
- * Retrieve an assertion by ID.
187
- *
188
- * The returned assertion has its status recomputed against the current time.
189
- *
190
- * @param id - The assertion ID
191
- * @returns The assertion, or undefined if not found
192
- */
193
- get(id: string): TemporalAssertion | undefined;
194
- /**
195
- * Get all assertions that were active at a specific point in time.
196
- *
197
- * An assertion is considered "active at time T" if:
198
- * - Its validity window contains T (validFrom <= T and (validUntil is null or T < validUntil))
199
- * - It has not been retracted
200
- * - It has not been superseded
201
- *
202
- * @param pointInTime - The reference time (ms epoch)
203
- * @param namespace - Optional namespace filter
204
- * @returns Active assertions at the specified time
205
- */
206
- getActiveAt(pointInTime: number, namespace?: string): TemporalAssertion[];
207
- /**
208
- * Get all assertions active right now.
209
- *
210
- * Convenience wrapper around `getActiveAt(Date.now())`.
211
- *
212
- * @param namespace - Optional namespace filter
213
- * @returns Currently active assertions
214
- */
215
- getCurrentTruth(namespace?: string): TemporalAssertion[];
216
- /**
217
- * Get the full history of a claim: all assertions (past and present) that
218
- * share the same claim text and namespace, regardless of status.
219
- *
220
- * Results are ordered by assertedAt ascending (oldest first), giving a
221
- * timeline of how the claim evolved.
222
- *
223
- * @param claim - The claim text to search for
224
- * @param namespace - The namespace to search in
225
- * @returns All matching assertions, oldest first
226
- */
227
- getHistory(claim: string, namespace: string): TemporalAssertion[];
228
- /**
229
- * Query assertions with multiple optional filters.
230
- *
231
- * All specified filters are ANDed together. Results are ordered by
232
- * assertedAt descending (newest first).
233
- *
234
- * @param opts - Query filter options
235
- * @returns Matching assertions
236
- */
237
- query(opts?: TemporalQuery): TemporalAssertion[];
238
- /**
239
- * Supersede an existing assertion with a new one.
240
- *
241
- * Marks the old assertion as superseded and creates a new assertion that
242
- * declares it replaces the old one. The supersession chain is bidirectional:
243
- * oldAssertion.supersededBy = newAssertion.id
244
- * newAssertion.supersedes = oldAssertion.id
245
- *
246
- * @param oldId - ID of the assertion to supersede
247
- * @param newClaim - The replacement claim text
248
- * @param newWindow - The validity window for the replacement
249
- * @param opts - Optional parameters for the new assertion
250
- * @returns The new assertion, or undefined if the old one was not found
251
- */
252
- supersede(oldId: string, newClaim: string, newWindow: {
253
- validFrom: number;
254
- validUntil: number | null;
255
- }, opts?: AssertOptions): TemporalAssertion | undefined;
256
- /**
257
- * Retract an assertion (soft delete).
258
- *
259
- * The assertion is marked with a retractedAt timestamp and its status
260
- * becomes 'retracted'. The assertion remains in the store for historical
261
- * queries but is excluded from active truth queries.
262
- *
263
- * @param id - The assertion to retract
264
- * @param _reason - Optional reason for retraction (stored in metadata)
265
- * @returns The retracted assertion, or undefined if not found
266
- */
267
- retract(id: string, _reason?: string): TemporalAssertion | undefined;
268
- /**
269
- * Get the full supersession timeline for an assertion.
270
- *
271
- * Follows the supersedes/supersededBy chain in both directions to build
272
- * the complete lineage: all predecessors (oldest first) and all successors
273
- * (newest last). Handles cycles by tracking visited IDs.
274
- *
275
- * @param id - The assertion to build a timeline for
276
- * @returns The timeline, or undefined if not found
277
- */
278
- getTimeline(id: string): TemporalTimeline | undefined;
279
- /**
280
- * Detect conflicting assertions: multiple assertions active at the same
281
- * time in the same namespace.
282
- *
283
- * Returns groups of assertions that are simultaneously active, which may
284
- * indicate contradictions that need resolution.
285
- *
286
- * @param namespace - The namespace to check
287
- * @param pointInTime - The reference time (defaults to now)
288
- * @returns Array of assertions that are concurrently active (empty if no conflicts)
289
- */
290
- reconcile(namespace: string, pointInTime?: number): TemporalAssertion[];
291
- /**
292
- * Export all assertions for persistence.
293
- *
294
- * @returns Serializable store representation
295
- */
296
- exportAssertions(): SerializedTemporalStore;
297
- /**
298
- * Import previously exported assertions, replacing all current contents.
299
- *
300
- * @param data - Serialized store data
301
- * @throws If the version is unsupported
302
- */
303
- importAssertions(data: SerializedTemporalStore): void;
304
- /**
305
- * Remove expired assertions whose validity ended before the given timestamp.
306
- *
307
- * Only assertions with status 'expired' and validUntil before the cutoff
308
- * are removed. Retracted and superseded assertions are preserved for
309
- * historical traceability.
310
- *
311
- * @param beforeTimestamp - Remove assertions that expired before this time
312
- * @returns Number of assertions pruned
313
- */
314
- pruneExpired(beforeTimestamp: number): number;
315
- /**
316
- * Get the number of stored assertions.
317
- */
318
- get size(): number;
319
- /**
320
- * Get the current configuration.
321
- */
322
- getConfig(): TemporalConfig;
323
- /**
324
- * Remove all assertions from the store.
325
- */
326
- clear(): void;
327
- /**
328
- * Enforce the maximum assertion capacity by pruning the oldest expired
329
- * assertions first.
330
- */
331
- private enforceCapacity;
332
- }
333
- /**
334
- * High-level temporal reasoning over a TemporalStore.
335
- *
336
- * Provides semantic queries like "what was true at time T", "what will be
337
- * true at time T", change detection, conflict detection, and forward
338
- * projection of assertion validity.
339
- */
340
- export declare class TemporalReasoner {
341
- private readonly store;
342
- constructor(store: TemporalStore);
343
- /**
344
- * What was true at a past point in time?
345
- *
346
- * Returns all assertions that were active (valid, not retracted, not
347
- * superseded) at the specified historical moment.
348
- *
349
- * @param namespace - The namespace to query
350
- * @param pointInTime - The historical moment (ms epoch)
351
- * @returns Assertions that were active at that time
352
- */
353
- whatWasTrue(namespace: string, pointInTime: number): TemporalAssertion[];
354
- /**
355
- * What is true right now?
356
- *
357
- * Returns all currently active assertions in the given namespace.
358
- *
359
- * @param namespace - The namespace to query
360
- * @returns Currently active assertions
361
- */
362
- whatIsTrue(namespace: string): TemporalAssertion[];
363
- /**
364
- * What will be true at a future point in time?
365
- *
366
- * Returns assertions whose validity window includes the specified future
367
- * time and that have not been retracted or superseded.
368
- *
369
- * @param namespace - The namespace to query
370
- * @param futureTime - The future moment (ms epoch)
371
- * @returns Assertions that will be active at that time
372
- */
373
- whatWillBeTrue(namespace: string, futureTime: number): TemporalAssertion[];
374
- /**
375
- * Detect changes in a namespace since a given timestamp.
376
- *
377
- * Returns a list of changes ordered by their change time, including:
378
- * - New assertions created after the timestamp
379
- * - Assertions superseded after the timestamp
380
- * - Assertions retracted after the timestamp
381
- * - Assertions that expired after the timestamp
382
- *
383
- * @param namespace - The namespace to check
384
- * @param sinceTimestamp - Only include changes after this time (ms epoch)
385
- * @returns List of detected changes
386
- */
387
- hasChanged(namespace: string, sinceTimestamp: number): TemporalChange[];
388
- /**
389
- * Detect conflicting (contradictory) assertions active at the same time
390
- * in the same namespace.
391
- *
392
- * Returns all concurrently active assertions if there are two or more.
393
- * An empty array means no conflicts.
394
- *
395
- * @param namespace - The namespace to check
396
- * @param pointInTime - The reference time (defaults to now)
397
- * @returns Conflicting assertions, or empty if no conflicts
398
- */
399
- conflictsAt(namespace: string, pointInTime?: number): TemporalAssertion[];
400
- /**
401
- * Project an assertion forward: will it still be valid at a future time?
402
- *
403
- * Checks whether the assertion's validity window includes the future
404
- * timestamp and the assertion has not been retracted or superseded.
405
- *
406
- * @param assertionId - The assertion to project
407
- * @param futureTimestamp - The future time to check (ms epoch)
408
- * @returns true if the assertion will be active at the future time
409
- */
410
- projectForward(assertionId: string, futureTimestamp: number): boolean;
411
- }
412
- /**
413
- * Create a TemporalStore with optional configuration.
414
- *
415
- * @param config - Partial configuration; unspecified values use defaults
416
- * @returns A fresh TemporalStore
417
- */
418
- export declare function createTemporalStore(config?: Partial<TemporalConfig>): TemporalStore;
419
- /**
420
- * Create a TemporalReasoner backed by the given store.
421
- *
422
- * @param store - The TemporalStore to reason over
423
- * @returns A fresh TemporalReasoner
424
- */
425
- export declare function createTemporalReasoner(store: TemporalStore): TemporalReasoner;
426
- //# sourceMappingURL=temporal.d.ts.map
@@ -1,283 +0,0 @@
1
- /**
2
- * Trust Score Accumulation System
3
- *
4
- * Builds trust gradients from gate outcomes over time. Sits alongside the
5
- * CoherenceScheduler (coherence.ts) but tracks a separate dimension:
6
- * accumulated trust from successful/failed gate evaluations.
7
- *
8
- * TrustAccumulator:
9
- * - Maintains a running trust score per agent (0.0 to 1.0)
10
- * - Accumulates trust from gate outcomes (allow, deny, warn)
11
- * - Applies exponential decay toward the initial value when idle
12
- * - Maps trust scores to privilege tiers (trusted, standard, probation, untrusted)
13
- *
14
- * TrustLedger:
15
- * - Records every trust score change with full context
16
- * - Supports export/import for persistence
17
- * - Querying by agent or threshold
18
- *
19
- * Trust-based rate limiting:
20
- * - Adjusts rate limits proportionally to accumulated trust
21
- *
22
- * @module @claude-flow/guidance/trust
23
- */
24
- /**
25
- * Privilege tier derived from an agent's accumulated trust score.
26
- */
27
- export type TrustTier = 'trusted' | 'standard' | 'probation' | 'untrusted';
28
- /**
29
- * Gate decision outcomes that affect trust accumulation.
30
- */
31
- export type GateOutcome = 'allow' | 'deny' | 'warn';
32
- /**
33
- * Configuration for the TrustAccumulator.
34
- */
35
- export interface TrustConfig {
36
- /** Starting trust score for new agents (0.0 - 1.0) */
37
- initialTrust: number;
38
- /** Trust increase on an 'allow' gate outcome */
39
- allowDelta: number;
40
- /** Trust decrease on a 'deny' gate outcome */
41
- denyDelta: number;
42
- /** Trust decrease on a 'warn' gate outcome */
43
- warnDelta: number;
44
- /** Exponential decay rate (0.0 - 1.0). Higher = faster decay toward initial */
45
- decayRate: number;
46
- /** Minimum elapsed time (ms) before decay is applied */
47
- decayIntervalMs: number;
48
- }
49
- /**
50
- * A single trust change record in the ledger.
51
- */
52
- export interface TrustRecord {
53
- /** Agent whose trust changed */
54
- agentId: string;
55
- /** Trust score before the change */
56
- previousScore: number;
57
- /** Trust score after the change */
58
- newScore: number;
59
- /** The signed delta applied */
60
- delta: number;
61
- /** Human-readable reason for the change */
62
- reason: string;
63
- /** Unix timestamp (ms) of the change */
64
- timestamp: number;
65
- /** Gate decision that triggered this change, if any */
66
- gateDecision?: GateOutcome;
67
- }
68
- /**
69
- * Point-in-time snapshot of an agent's trust state.
70
- */
71
- export interface TrustSnapshot {
72
- /** Agent identifier */
73
- agentId: string;
74
- /** Current trust score */
75
- score: number;
76
- /** Current privilege tier */
77
- tier: TrustTier;
78
- /** Total gate events processed for this agent */
79
- totalEvents: number;
80
- /** Timestamp of the most recent trust change */
81
- lastUpdated: number;
82
- }
83
- /**
84
- * Maintains running trust scores per agent, accumulates trust from gate
85
- * outcomes, applies time-based exponential decay, and maps scores to
86
- * privilege tiers.
87
- */
88
- export declare class TrustAccumulator {
89
- private readonly config;
90
- private readonly agents;
91
- constructor(config?: Partial<TrustConfig>);
92
- /**
93
- * Record a gate outcome for an agent, adjusting their trust score.
94
- *
95
- * - 'allow' increases trust by `allowDelta`
96
- * - 'deny' decreases trust by `denyDelta` (negative value)
97
- * - 'warn' decreases trust by `warnDelta` (negative value)
98
- *
99
- * Before applying the delta, exponential decay is applied if enough
100
- * time has elapsed since the last update.
101
- *
102
- * Returns the trust record describing the change.
103
- */
104
- recordOutcome(agentId: string, outcome: GateOutcome, reason: string): TrustRecord;
105
- /**
106
- * Get the current trust score for an agent.
107
- * Returns the configured initial trust if the agent is unknown.
108
- */
109
- getScore(agentId: string): number;
110
- /**
111
- * Determine the privilege tier for an agent based on their trust score.
112
- *
113
- * - >= 0.8: 'trusted' (expanded privileges, higher rate limits)
114
- * - >= 0.5: 'standard' (normal operation)
115
- * - >= 0.3: 'probation' (restricted tools, lower rate limits)
116
- * - < 0.3: 'untrusted' (read-only, must earn trust back)
117
- */
118
- getTier(agentId: string): TrustTier;
119
- /**
120
- * Get a full snapshot of an agent's trust state.
121
- */
122
- getSnapshot(agentId: string): TrustSnapshot;
123
- /**
124
- * Get snapshots for all tracked agents.
125
- */
126
- getAllSnapshots(): TrustSnapshot[];
127
- /**
128
- * Get a trust-adjusted rate limit for an agent.
129
- *
130
- * Multipliers by tier:
131
- * - trusted: 2x base limit
132
- * - standard: 1x base limit
133
- * - probation: 0.5x base limit
134
- * - untrusted: 0.1x base limit
135
- */
136
- getTrustBasedRateLimit(agentId: string, baseLimit: number): number;
137
- /**
138
- * Manually set an agent's trust score (e.g., from persistence restore).
139
- * Clamps to [0, 1].
140
- */
141
- setScore(agentId: string, score: number): void;
142
- /**
143
- * Remove an agent from tracking entirely.
144
- */
145
- removeAgent(agentId: string): boolean;
146
- /**
147
- * Get the number of tracked agents.
148
- */
149
- get agentCount(): number;
150
- /**
151
- * Get all tracked agent IDs.
152
- */
153
- getAgentIds(): string[];
154
- /**
155
- * Get the current configuration.
156
- */
157
- getConfig(): TrustConfig;
158
- /**
159
- * Reset all tracked agents.
160
- */
161
- clear(): void;
162
- private getOrCreateState;
163
- /**
164
- * Apply exponential decay toward the initial trust value.
165
- *
166
- * The decay formula moves the score toward `initialTrust` by a fraction
167
- * proportional to the number of decay intervals elapsed:
168
- *
169
- * score = score + (initialTrust - score) * (1 - (1 - decayRate)^intervals)
170
- *
171
- * This ensures idle agents gradually return to the baseline.
172
- */
173
- private applyDecay;
174
- }
175
- /**
176
- * Records all trust score changes with full context. Supports persistence
177
- * via export/import and querying by agent or threshold.
178
- */
179
- export declare class TrustLedger {
180
- private records;
181
- private static readonly MAX_RECORDS;
182
- /**
183
- * Append a trust record to the ledger.
184
- */
185
- record(entry: TrustRecord): void;
186
- /**
187
- * Get the full trust history for a specific agent, ordered chronologically.
188
- */
189
- getHistoryForAgent(agentId: string): TrustRecord[];
190
- /**
191
- * Get all agents whose most recent score is below the given threshold.
192
- * Returns one record per agent (the most recent).
193
- */
194
- getAgentsBelowThreshold(threshold: number): TrustRecord[];
195
- /**
196
- * Get all agents whose most recent score is at or above the given threshold.
197
- * Returns one record per agent (the most recent).
198
- */
199
- getAgentsAboveThreshold(threshold: number): TrustRecord[];
200
- /**
201
- * Get records within a time range.
202
- */
203
- getRecordsInRange(startMs: number, endMs: number): TrustRecord[];
204
- /**
205
- * Get the most recent N records.
206
- */
207
- getRecentRecords(count: number): TrustRecord[];
208
- /**
209
- * Get the total number of records.
210
- */
211
- get recordCount(): number;
212
- /**
213
- * Export all records for persistence.
214
- */
215
- exportRecords(): TrustRecord[];
216
- /**
217
- * Import records from persistence. Appends to existing records.
218
- */
219
- importRecords(records: TrustRecord[]): void;
220
- /**
221
- * Clear all records.
222
- */
223
- clear(): void;
224
- }
225
- /**
226
- * Combines TrustAccumulator and TrustLedger into a single coordinated
227
- * system. Gate outcomes are accumulated and automatically logged.
228
- */
229
- export declare class TrustSystem {
230
- readonly accumulator: TrustAccumulator;
231
- readonly ledger: TrustLedger;
232
- constructor(config?: Partial<TrustConfig>);
233
- /**
234
- * Record a gate outcome, update the accumulator, and log to the ledger.
235
- */
236
- recordOutcome(agentId: string, outcome: GateOutcome, reason: string): TrustRecord;
237
- /**
238
- * Get the current trust score for an agent.
239
- */
240
- getScore(agentId: string): number;
241
- /**
242
- * Get the current privilege tier for an agent.
243
- */
244
- getTier(agentId: string): TrustTier;
245
- /**
246
- * Get a trust-adjusted rate limit for an agent.
247
- */
248
- getTrustBasedRateLimit(agentId: string, baseLimit: number): number;
249
- /**
250
- * Get a full snapshot of an agent's trust state.
251
- */
252
- getSnapshot(agentId: string): TrustSnapshot;
253
- /**
254
- * Get snapshots for all tracked agents.
255
- */
256
- getAllSnapshots(): TrustSnapshot[];
257
- }
258
- /**
259
- * Compute a trust-adjusted rate limit from a score and base limit.
260
- *
261
- * This is a stateless utility for cases where you have a trust score
262
- * but no TrustAccumulator instance.
263
- *
264
- * Multipliers by tier:
265
- * - trusted (>= 0.8): 2x
266
- * - standard (>= 0.5): 1x
267
- * - probation (>= 0.3): 0.5x
268
- * - untrusted (< 0.3): 0.1x
269
- */
270
- export declare function getTrustBasedRateLimit(score: number, baseLimit: number): number;
271
- /**
272
- * Create a TrustAccumulator with optional configuration.
273
- */
274
- export declare function createTrustAccumulator(config?: Partial<TrustConfig>): TrustAccumulator;
275
- /**
276
- * Create an empty TrustLedger.
277
- */
278
- export declare function createTrustLedger(): TrustLedger;
279
- /**
280
- * Create a coordinated TrustSystem (accumulator + ledger).
281
- */
282
- export declare function createTrustSystem(config?: Partial<TrustConfig>): TrustSystem;
283
- //# sourceMappingURL=trust.d.ts.map