claude-flow 2.7.0 → 2.7.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +42 -0
- package/README.md +83 -22
- package/bin/claude-flow +1 -1
- package/dist/src/cli/commands/memory.js +64 -1
- package/dist/src/cli/commands/memory.js.map +1 -1
- package/dist/src/cli/help-formatter.js +3 -5
- package/dist/src/cli/help-formatter.js.map +1 -1
- package/dist/src/cli/simple-cli.js +104 -0
- package/dist/src/cli/simple-cli.js.map +1 -1
- package/dist/src/cli/validation-helper.js.map +1 -1
- package/dist/src/core/version.js +1 -1
- package/dist/src/core/version.js.map +1 -1
- package/dist/src/mcp/mcp-server.js +261 -3
- package/dist/src/mcp/mcp-server.js.map +1 -1
- package/dist/src/memory/agentdb-adapter.js +214 -0
- package/dist/src/memory/agentdb-adapter.js.map +1 -0
- package/dist/src/memory/backends/agentdb.js +234 -0
- package/dist/src/memory/backends/agentdb.js.map +1 -0
- package/dist/src/memory/index.js +11 -2
- package/dist/src/memory/index.js.map +1 -1
- package/dist/src/memory/migration/legacy-bridge.js +222 -0
- package/dist/src/memory/migration/legacy-bridge.js.map +1 -0
- package/dist/src/memory/swarm-memory.js +421 -340
- package/dist/src/memory/swarm-memory.js.map +1 -1
- package/dist/src/utils/metrics-reader.js +41 -29
- package/dist/src/utils/metrics-reader.js.map +1 -1
- package/docs/.claude-flow/metrics/performance.json +80 -2
- package/docs/.claude-flow/metrics/task-metrics.json +3 -3
- package/docs/INDEX.md +37 -12
- package/docs/README.md +92 -4
- package/docs/agentdb/AGENT3_FINAL_REPORT.md +643 -0
- package/docs/agentdb/AGENT3_SUMMARY.md +354 -0
- package/docs/agentdb/AGENTDB_INTEGRATION_PLAN.md +1258 -0
- package/docs/agentdb/BACKWARD_COMPATIBILITY_GUARANTEE.md +421 -0
- package/docs/agentdb/OPTIMIZATION_REPORT.md +360 -0
- package/docs/agentdb/PRODUCTION_READINESS.md +499 -0
- package/docs/agentdb/PUBLISHING_CHECKLIST.md +364 -0
- package/docs/agentdb/README.md +58 -0
- package/docs/agentdb/SWARM_COORDINATION.md +393 -0
- package/docs/agentdb/SWARM_IMPLEMENTATION_COMPLETE.md +538 -0
- package/docs/agentdb/agentdb-integration-summary.md +331 -0
- package/docs/agentdb/benchmarks/baseline-report.json +75 -0
- package/docs/development/AGENT1_COMPLETION_REPORT.md +466 -0
- package/docs/development/README.md +22 -0
- package/docs/fixes/PATTERN_FIX_CONFIRMATION.md +513 -0
- package/docs/fixes/PATTERN_PERSISTENCE_FIX.md +328 -0
- package/docs/fixes/README.md +33 -0
- package/docs/guides/README.md +29 -0
- package/docs/{skills-tutorial.md → guides/skills-tutorial.md} +2 -2
- package/docs/integrations/agentic-flow/INTEGRATION-TEST-v1.7.1.md +419 -0
- package/docs/integrations/agentic-flow/MIGRATION_v1.7.0.md +381 -0
- package/docs/integrations/agentic-flow/README.md +229 -0
- package/docs/integrations/agentic-flow/RELEASE-v1.7.0.md +348 -0
- package/docs/integrations/agentic-flow/RELEASE-v1.7.1.md +547 -0
- package/docs/integrations/agentic-flow/VERIFICATION-v1.7.4.md +556 -0
- package/docs/performance/README.md +31 -0
- package/docs/releases/ALPHA_TAG_UPDATE.md +150 -0
- package/docs/releases/README.md +25 -0
- package/docs/{RELEASE-NOTES-v2.7.0-alpha.10.md → releases/v2.7.0-alpha.10/RELEASE-NOTES-v2.7.0-alpha.10.md} +1 -1
- package/docs/releases/v2.7.1/RELEASE_SUMMARY_v2.7.1.md +340 -0
- package/docs/releases/v2.7.1/RELEASE_v2.7.1.md +244 -0
- package/docs/validation/DOCKER_VERIFICATION_REPORT.md +371 -0
- package/docs/validation/README.md +25 -0
- package/docs/validation/REGRESSION_ANALYSIS_v2.7.1.md +357 -0
- package/package.json +4 -3
- package/scripts/fix-agentdb-imports.sh +18 -0
- package/scripts/run-docker-regression.sh +101 -0
- package/scripts/verify-agentdb-integration.sh +220 -0
- package/src/cli/commands/memory.ts +95 -1
- package/src/mcp/mcp-server.js +302 -2
- package/src/memory/README-AGENTDB.md +366 -0
- package/src/memory/agentdb-adapter.js +373 -0
- package/src/memory/backends/agentdb.js +360 -0
- package/src/memory/index.js +32 -3
- package/src/memory/migration/legacy-bridge.js +330 -0
- package/dist/agents/agent-loader.d.ts +0 -103
- package/dist/agents/agent-loader.d.ts.map +0 -1
- package/dist/agents/agent-loader.js +0 -220
- package/dist/agents/agent-loader.js.map +0 -1
- package/dist/agents/agent-manager.d.ts +0 -191
- package/dist/agents/agent-manager.d.ts.map +0 -1
- package/dist/agents/agent-manager.js +0 -1405
- package/dist/agents/agent-manager.js.map +0 -1
- package/dist/api/claude-api-errors.d.ts +0 -115
- package/dist/api/claude-api-errors.d.ts.map +0 -1
- package/dist/api/claude-api-errors.js +0 -198
- package/dist/api/claude-api-errors.js.map +0 -1
- package/dist/api/claude-client.d.ts +0 -197
- package/dist/api/claude-client.d.ts.map +0 -1
- package/dist/api/claude-client.js +0 -525
- package/dist/api/claude-client.js.map +0 -1
- package/dist/cli/cli-core.d.ts +0 -52
- package/dist/cli/cli-core.d.ts.map +0 -1
- package/dist/cli/cli-core.js +0 -264
- package/dist/cli/cli-core.js.map +0 -1
- package/dist/cli/command-registry.d.ts +0 -10
- package/dist/cli/command-registry.d.ts.map +0 -1
- package/dist/cli/command-registry.js +0 -1126
- package/dist/cli/command-registry.js.map +0 -1
- package/dist/cli/commander-fix.d.ts +0 -4
- package/dist/cli/commander-fix.d.ts.map +0 -1
- package/dist/cli/commander-fix.js +0 -6
- package/dist/cli/commander-fix.js.map +0 -1
- package/dist/cli/commands/agent.d.ts +0 -6
- package/dist/cli/commands/agent.d.ts.map +0 -1
- package/dist/cli/commands/agent.js +0 -382
- package/dist/cli/commands/agent.js.map +0 -1
- package/dist/cli/commands/config.d.ts +0 -4
- package/dist/cli/commands/config.d.ts.map +0 -1
- package/dist/cli/commands/config.js +0 -88
- package/dist/cli/commands/config.js.map +0 -1
- package/dist/cli/commands/enterprise.d.ts +0 -3
- package/dist/cli/commands/enterprise.d.ts.map +0 -1
- package/dist/cli/commands/enterprise.js +0 -1506
- package/dist/cli/commands/enterprise.js.map +0 -1
- package/dist/cli/commands/help.d.ts +0 -6
- package/dist/cli/commands/help.d.ts.map +0 -1
- package/dist/cli/commands/help.js +0 -936
- package/dist/cli/commands/help.js.map +0 -1
- package/dist/cli/commands/hive-mind/index.d.ts +0 -18
- package/dist/cli/commands/hive-mind/index.d.ts.map +0 -1
- package/dist/cli/commands/hive-mind/index.js +0 -30
- package/dist/cli/commands/hive-mind/index.js.map +0 -1
- package/dist/cli/commands/hive-mind/init.d.ts +0 -9
- package/dist/cli/commands/hive-mind/init.d.ts.map +0 -1
- package/dist/cli/commands/hive-mind/init.js +0 -68
- package/dist/cli/commands/hive-mind/init.js.map +0 -1
- package/dist/cli/commands/hive-mind/pause.d.ts +0 -8
- package/dist/cli/commands/hive-mind/pause.d.ts.map +0 -1
- package/dist/cli/commands/hive-mind/pause.js +0 -81
- package/dist/cli/commands/hive-mind/pause.js.map +0 -1
- package/dist/cli/commands/hive-mind/ps.d.ts +0 -8
- package/dist/cli/commands/hive-mind/ps.d.ts.map +0 -1
- package/dist/cli/commands/hive-mind/ps.js +0 -120
- package/dist/cli/commands/hive-mind/ps.js.map +0 -1
- package/dist/cli/commands/hive-mind/resume.d.ts +0 -8
- package/dist/cli/commands/hive-mind/resume.d.ts.map +0 -1
- package/dist/cli/commands/hive-mind/resume.js +0 -62
- package/dist/cli/commands/hive-mind/resume.js.map +0 -1
- package/dist/cli/commands/hive-mind/spawn.d.ts +0 -9
- package/dist/cli/commands/hive-mind/spawn.d.ts.map +0 -1
- package/dist/cli/commands/hive-mind/spawn.js +0 -174
- package/dist/cli/commands/hive-mind/spawn.js.map +0 -1
- package/dist/cli/commands/hive-mind/status.d.ts +0 -9
- package/dist/cli/commands/hive-mind/status.d.ts.map +0 -1
- package/dist/cli/commands/hive-mind/status.js +0 -204
- package/dist/cli/commands/hive-mind/status.js.map +0 -1
- package/dist/cli/commands/hive-mind/stop.d.ts +0 -8
- package/dist/cli/commands/hive-mind/stop.d.ts.map +0 -1
- package/dist/cli/commands/hive-mind/stop.js +0 -125
- package/dist/cli/commands/hive-mind/stop.js.map +0 -1
- package/dist/cli/commands/hive-mind/task.d.ts +0 -9
- package/dist/cli/commands/hive-mind/task.d.ts.map +0 -1
- package/dist/cli/commands/hive-mind/task.js +0 -294
- package/dist/cli/commands/hive-mind/task.js.map +0 -1
- package/dist/cli/commands/hive-mind/wizard.d.ts +0 -9
- package/dist/cli/commands/hive-mind/wizard.d.ts.map +0 -1
- package/dist/cli/commands/hive-mind/wizard.js +0 -531
- package/dist/cli/commands/hive-mind/wizard.js.map +0 -1
- package/dist/cli/commands/hive.d.ts +0 -6
- package/dist/cli/commands/hive.d.ts.map +0 -1
- package/dist/cli/commands/hive.js +0 -409
- package/dist/cli/commands/hive.js.map +0 -1
- package/dist/cli/commands/index.d.ts +0 -3
- package/dist/cli/commands/index.d.ts.map +0 -1
- package/dist/cli/commands/index.js +0 -2624
- package/dist/cli/commands/index.js.map +0 -1
- package/dist/cli/commands/mcp.d.ts +0 -5
- package/dist/cli/commands/mcp.d.ts.map +0 -1
- package/dist/cli/commands/mcp.js +0 -169
- package/dist/cli/commands/mcp.js.map +0 -1
- package/dist/cli/commands/memory.d.ts +0 -26
- package/dist/cli/commands/memory.d.ts.map +0 -1
- package/dist/cli/commands/memory.js +0 -225
- package/dist/cli/commands/memory.js.map +0 -1
- package/dist/cli/commands/migrate.d.ts +0 -5
- package/dist/cli/commands/migrate.d.ts.map +0 -1
- package/dist/cli/commands/migrate.js +0 -139
- package/dist/cli/commands/migrate.js.map +0 -1
- package/dist/cli/commands/monitor.d.ts +0 -5
- package/dist/cli/commands/monitor.d.ts.map +0 -1
- package/dist/cli/commands/monitor.js +0 -493
- package/dist/cli/commands/monitor.js.map +0 -1
- package/dist/cli/commands/session.d.ts +0 -5
- package/dist/cli/commands/session.d.ts.map +0 -1
- package/dist/cli/commands/session.js +0 -548
- package/dist/cli/commands/session.js.map +0 -1
- package/dist/cli/commands/sparc.d.ts +0 -3
- package/dist/cli/commands/sparc.d.ts.map +0 -1
- package/dist/cli/commands/sparc.js +0 -472
- package/dist/cli/commands/sparc.js.map +0 -1
- package/dist/cli/commands/start/event-emitter.d.ts +0 -13
- package/dist/cli/commands/start/event-emitter.d.ts.map +0 -1
- package/dist/cli/commands/start/event-emitter.js +0 -35
- package/dist/cli/commands/start/event-emitter.js.map +0 -1
- package/dist/cli/commands/start/index.d.ts +0 -10
- package/dist/cli/commands/start/index.d.ts.map +0 -1
- package/dist/cli/commands/start/index.js +0 -9
- package/dist/cli/commands/start/index.js.map +0 -1
- package/dist/cli/commands/start/process-manager.d.ts +0 -31
- package/dist/cli/commands/start/process-manager.d.ts.map +0 -1
- package/dist/cli/commands/start/process-manager.js +0 -283
- package/dist/cli/commands/start/process-manager.js.map +0 -1
- package/dist/cli/commands/start/process-ui-simple.d.ts +0 -29
- package/dist/cli/commands/start/process-ui-simple.d.ts.map +0 -1
- package/dist/cli/commands/start/process-ui-simple.js +0 -334
- package/dist/cli/commands/start/process-ui-simple.js.map +0 -1
- package/dist/cli/commands/start/process-ui.d.ts +0 -5
- package/dist/cli/commands/start/process-ui.d.ts.map +0 -1
- package/dist/cli/commands/start/process-ui.js +0 -5
- package/dist/cli/commands/start/process-ui.js.map +0 -1
- package/dist/cli/commands/start/start-command.d.ts +0 -2
- package/dist/cli/commands/start/start-command.d.ts.map +0 -1
- package/dist/cli/commands/start/start-command.js +0 -462
- package/dist/cli/commands/start/start-command.js.map +0 -1
- package/dist/cli/commands/start/system-monitor.d.ts +0 -25
- package/dist/cli/commands/start/system-monitor.d.ts.map +0 -1
- package/dist/cli/commands/start/system-monitor.js +0 -265
- package/dist/cli/commands/start/system-monitor.js.map +0 -1
- package/dist/cli/commands/start/types.d.ts +0 -64
- package/dist/cli/commands/start/types.d.ts.map +0 -1
- package/dist/cli/commands/start/types.js +0 -22
- package/dist/cli/commands/start/types.js.map +0 -1
- package/dist/cli/commands/start.d.ts +0 -6
- package/dist/cli/commands/start.d.ts.map +0 -1
- package/dist/cli/commands/start.js +0 -6
- package/dist/cli/commands/start.js.map +0 -1
- package/dist/cli/commands/status.d.ts +0 -2
- package/dist/cli/commands/status.d.ts.map +0 -1
- package/dist/cli/commands/status.js +0 -304
- package/dist/cli/commands/status.js.map +0 -1
- package/dist/cli/commands/swarm.d.ts +0 -6
- package/dist/cli/commands/swarm.d.ts.map +0 -1
- package/dist/cli/commands/swarm.js +0 -465
- package/dist/cli/commands/swarm.js.map +0 -1
- package/dist/cli/commands/task.d.ts +0 -2
- package/dist/cli/commands/task.d.ts.map +0 -1
- package/dist/cli/commands/task.js +0 -75
- package/dist/cli/commands/task.js.map +0 -1
- package/dist/cli/commands/workflow.d.ts +0 -2
- package/dist/cli/commands/workflow.d.ts.map +0 -1
- package/dist/cli/commands/workflow.js +0 -624
- package/dist/cli/commands/workflow.js.map +0 -1
- package/dist/cli/completion.d.ts +0 -19
- package/dist/cli/completion.d.ts.map +0 -1
- package/dist/cli/completion.js +0 -545
- package/dist/cli/completion.js.map +0 -1
- package/dist/cli/formatter.d.ts +0 -69
- package/dist/cli/formatter.d.ts.map +0 -1
- package/dist/cli/formatter.js +0 -277
- package/dist/cli/formatter.js.map +0 -1
- package/dist/cli/help-formatter.d.ts +0 -49
- package/dist/cli/help-formatter.d.ts.map +0 -1
- package/dist/cli/help-formatter.js +0 -108
- package/dist/cli/help-formatter.js.map +0 -1
- package/dist/cli/help-text.d.ts +0 -25
- package/dist/cli/help-text.d.ts.map +0 -1
- package/dist/cli/help-text.js +0 -1051
- package/dist/cli/help-text.js.map +0 -1
- package/dist/cli/index-remote.d.ts +0 -7
- package/dist/cli/index-remote.d.ts.map +0 -1
- package/dist/cli/index-remote.js +0 -125
- package/dist/cli/index-remote.js.map +0 -1
- package/dist/cli/index.d.ts +0 -7
- package/dist/cli/index.d.ts.map +0 -1
- package/dist/cli/index.js +0 -189
- package/dist/cli/index.js.map +0 -1
- package/dist/cli/node-compat.d.ts +0 -81
- package/dist/cli/node-compat.d.ts.map +0 -1
- package/dist/cli/node-compat.js +0 -229
- package/dist/cli/node-compat.js.map +0 -1
- package/dist/cli/repl.d.ts +0 -5
- package/dist/cli/repl.d.ts.map +0 -1
- package/dist/cli/repl.js +0 -949
- package/dist/cli/repl.js.map +0 -1
- package/dist/cli/runtime-detector.d.ts +0 -128
- package/dist/cli/runtime-detector.d.ts.map +0 -1
- package/dist/cli/runtime-detector.js +0 -267
- package/dist/cli/runtime-detector.js.map +0 -1
- package/dist/cli/simple-cli.d.ts +0 -7
- package/dist/cli/simple-cli.d.ts.map +0 -1
- package/dist/cli/simple-cli.js +0 -3085
- package/dist/cli/simple-cli.js.map +0 -1
- package/dist/cli/simple-commands/agent.d.ts +0 -6
- package/dist/cli/simple-commands/agent.d.ts.map +0 -1
- package/dist/cli/simple-commands/agent.js +0 -128
- package/dist/cli/simple-commands/agent.js.map +0 -1
- package/dist/cli/simple-commands/analysis.d.ts +0 -2
- package/dist/cli/simple-commands/analysis.d.ts.map +0 -1
- package/dist/cli/simple-commands/analysis.js +0 -473
- package/dist/cli/simple-commands/analysis.js.map +0 -1
- package/dist/cli/simple-commands/automation-executor.d.ts +0 -188
- package/dist/cli/simple-commands/automation-executor.d.ts.map +0 -1
- package/dist/cli/simple-commands/automation-executor.js +0 -1383
- package/dist/cli/simple-commands/automation-executor.js.map +0 -1
- package/dist/cli/simple-commands/automation.d.ts +0 -2
- package/dist/cli/simple-commands/automation.d.ts.map +0 -1
- package/dist/cli/simple-commands/automation.js +0 -531
- package/dist/cli/simple-commands/automation.js.map +0 -1
- package/dist/cli/simple-commands/batch-manager.d.ts +0 -2
- package/dist/cli/simple-commands/batch-manager.d.ts.map +0 -1
- package/dist/cli/simple-commands/batch-manager.js +0 -290
- package/dist/cli/simple-commands/batch-manager.js.map +0 -1
- package/dist/cli/simple-commands/claude-telemetry.d.ts +0 -14
- package/dist/cli/simple-commands/claude-telemetry.d.ts.map +0 -1
- package/dist/cli/simple-commands/claude-telemetry.js +0 -263
- package/dist/cli/simple-commands/claude-telemetry.js.map +0 -1
- package/dist/cli/simple-commands/config.d.ts +0 -6
- package/dist/cli/simple-commands/config.d.ts.map +0 -1
- package/dist/cli/simple-commands/config.js +0 -116
- package/dist/cli/simple-commands/config.js.map +0 -1
- package/dist/cli/simple-commands/coordination.d.ts +0 -2
- package/dist/cli/simple-commands/coordination.d.ts.map +0 -1
- package/dist/cli/simple-commands/coordination.js +0 -249
- package/dist/cli/simple-commands/coordination.js.map +0 -1
- package/dist/cli/simple-commands/env-template.d.ts +0 -42
- package/dist/cli/simple-commands/env-template.d.ts.map +0 -1
- package/dist/cli/simple-commands/env-template.js +0 -183
- package/dist/cli/simple-commands/env-template.js.map +0 -1
- package/dist/cli/simple-commands/fix-hook-variables.d.ts +0 -16
- package/dist/cli/simple-commands/fix-hook-variables.d.ts.map +0 -1
- package/dist/cli/simple-commands/fix-hook-variables.js +0 -320
- package/dist/cli/simple-commands/fix-hook-variables.js.map +0 -1
- package/dist/cli/simple-commands/github/init.d.ts +0 -6
- package/dist/cli/simple-commands/github/init.d.ts.map +0 -1
- package/dist/cli/simple-commands/github/init.js +0 -506
- package/dist/cli/simple-commands/github/init.js.map +0 -1
- package/dist/cli/simple-commands/github.d.ts +0 -3
- package/dist/cli/simple-commands/github.d.ts.map +0 -1
- package/dist/cli/simple-commands/github.js +0 -356
- package/dist/cli/simple-commands/github.js.map +0 -1
- package/dist/cli/simple-commands/goal.d.ts +0 -3
- package/dist/cli/simple-commands/goal.d.ts.map +0 -1
- package/dist/cli/simple-commands/goal.js +0 -136
- package/dist/cli/simple-commands/goal.js.map +0 -1
- package/dist/cli/simple-commands/hive-mind/auto-save-middleware.d.ts +0 -68
- package/dist/cli/simple-commands/hive-mind/auto-save-middleware.d.ts.map +0 -1
- package/dist/cli/simple-commands/hive-mind/auto-save-middleware.js +0 -264
- package/dist/cli/simple-commands/hive-mind/auto-save-middleware.js.map +0 -1
- package/dist/cli/simple-commands/hive-mind/communication.d.ts +0 -176
- package/dist/cli/simple-commands/hive-mind/communication.d.ts.map +0 -1
- package/dist/cli/simple-commands/hive-mind/communication.js +0 -611
- package/dist/cli/simple-commands/hive-mind/communication.js.map +0 -1
- package/dist/cli/simple-commands/hive-mind/core.d.ts +0 -306
- package/dist/cli/simple-commands/hive-mind/core.d.ts.map +0 -1
- package/dist/cli/simple-commands/hive-mind/core.js +0 -839
- package/dist/cli/simple-commands/hive-mind/core.js.map +0 -1
- package/dist/cli/simple-commands/hive-mind/db-optimizer.d.ts +0 -32
- package/dist/cli/simple-commands/hive-mind/db-optimizer.d.ts.map +0 -1
- package/dist/cli/simple-commands/hive-mind/db-optimizer.js +0 -702
- package/dist/cli/simple-commands/hive-mind/db-optimizer.js.map +0 -1
- package/dist/cli/simple-commands/hive-mind/mcp-wrapper.d.ts +0 -270
- package/dist/cli/simple-commands/hive-mind/mcp-wrapper.d.ts.map +0 -1
- package/dist/cli/simple-commands/hive-mind/mcp-wrapper.js +0 -1211
- package/dist/cli/simple-commands/hive-mind/mcp-wrapper.js.map +0 -1
- package/dist/cli/simple-commands/hive-mind/memory.d.ts +0 -334
- package/dist/cli/simple-commands/hive-mind/memory.d.ts.map +0 -1
- package/dist/cli/simple-commands/hive-mind/memory.js +0 -1068
- package/dist/cli/simple-commands/hive-mind/memory.js.map +0 -1
- package/dist/cli/simple-commands/hive-mind/metrics-reader.js +0 -274
- package/dist/cli/simple-commands/hive-mind/metrics-reader.js.map +0 -1
- package/dist/cli/simple-commands/hive-mind/performance-optimizer.d.ts +0 -256
- package/dist/cli/simple-commands/hive-mind/performance-optimizer.d.ts.map +0 -1
- package/dist/cli/simple-commands/hive-mind/performance-optimizer.js +0 -520
- package/dist/cli/simple-commands/hive-mind/performance-optimizer.js.map +0 -1
- package/dist/cli/simple-commands/hive-mind/queen.d.ts +0 -235
- package/dist/cli/simple-commands/hive-mind/queen.d.ts.map +0 -1
- package/dist/cli/simple-commands/hive-mind/queen.js +0 -697
- package/dist/cli/simple-commands/hive-mind/queen.js.map +0 -1
- package/dist/cli/simple-commands/hive-mind/session-manager.d.ts +0 -140
- package/dist/cli/simple-commands/hive-mind/session-manager.d.ts.map +0 -1
- package/dist/cli/simple-commands/hive-mind/session-manager.js +0 -1000
- package/dist/cli/simple-commands/hive-mind/session-manager.js.map +0 -1
- package/dist/cli/simple-commands/hive-mind-optimize.d.ts +0 -6
- package/dist/cli/simple-commands/hive-mind-optimize.d.ts.map +0 -1
- package/dist/cli/simple-commands/hive-mind-optimize.js +0 -317
- package/dist/cli/simple-commands/hive-mind-optimize.js.map +0 -1
- package/dist/cli/simple-commands/hive-mind.d.ts +0 -22
- package/dist/cli/simple-commands/hive-mind.d.ts.map +0 -1
- package/dist/cli/simple-commands/hive-mind.js +0 -2722
- package/dist/cli/simple-commands/hive-mind.js.map +0 -1
- package/dist/cli/simple-commands/hook-safety.d.ts +0 -177
- package/dist/cli/simple-commands/hook-safety.d.ts.map +0 -1
- package/dist/cli/simple-commands/hook-safety.js +0 -590
- package/dist/cli/simple-commands/hook-safety.js.map +0 -1
- package/dist/cli/simple-commands/hooks.d.ts +0 -3
- package/dist/cli/simple-commands/hooks.d.ts.map +0 -1
- package/dist/cli/simple-commands/hooks.js +0 -1298
- package/dist/cli/simple-commands/hooks.js.map +0 -1
- package/dist/cli/simple-commands/init/agent-copier.d.ts +0 -65
- package/dist/cli/simple-commands/init/agent-copier.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/agent-copier.js +0 -320
- package/dist/cli/simple-commands/init/agent-copier.js.map +0 -1
- package/dist/cli/simple-commands/init/batch-init.d.ts +0 -137
- package/dist/cli/simple-commands/init/batch-init.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/batch-init.js +0 -558
- package/dist/cli/simple-commands/init/batch-init.js.map +0 -1
- package/dist/cli/simple-commands/init/claude-commands/claude-flow-commands.d.ts +0 -2
- package/dist/cli/simple-commands/init/claude-commands/claude-flow-commands.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/claude-commands/claude-flow-commands.js +0 -433
- package/dist/cli/simple-commands/init/claude-commands/claude-flow-commands.js.map +0 -1
- package/dist/cli/simple-commands/init/claude-commands/optimized-claude-flow-commands.d.ts +0 -2
- package/dist/cli/simple-commands/init/claude-commands/optimized-claude-flow-commands.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/claude-commands/optimized-claude-flow-commands.js +0 -871
- package/dist/cli/simple-commands/init/claude-commands/optimized-claude-flow-commands.js.map +0 -1
- package/dist/cli/simple-commands/init/claude-commands/optimized-slash-commands.d.ts +0 -2
- package/dist/cli/simple-commands/init/claude-commands/optimized-slash-commands.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/claude-commands/optimized-slash-commands.js +0 -332
- package/dist/cli/simple-commands/init/claude-commands/optimized-slash-commands.js.map +0 -1
- package/dist/cli/simple-commands/init/claude-commands/optimized-sparc-commands.d.ts +0 -3
- package/dist/cli/simple-commands/init/claude-commands/optimized-sparc-commands.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/claude-commands/optimized-sparc-commands.js +0 -488
- package/dist/cli/simple-commands/init/claude-commands/optimized-sparc-commands.js.map +0 -1
- package/dist/cli/simple-commands/init/claude-commands/slash-commands.d.ts +0 -2
- package/dist/cli/simple-commands/init/claude-commands/slash-commands.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/claude-commands/slash-commands.js +0 -51
- package/dist/cli/simple-commands/init/claude-commands/slash-commands.js.map +0 -1
- package/dist/cli/simple-commands/init/claude-commands/sparc-commands.d.ts +0 -3
- package/dist/cli/simple-commands/init/claude-commands/sparc-commands.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/claude-commands/sparc-commands.js +0 -288
- package/dist/cli/simple-commands/init/claude-commands/sparc-commands.js.map +0 -1
- package/dist/cli/simple-commands/init/copy-revised-templates.d.ts +0 -29
- package/dist/cli/simple-commands/init/copy-revised-templates.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/copy-revised-templates.js +0 -166
- package/dist/cli/simple-commands/init/copy-revised-templates.js.map +0 -1
- package/dist/cli/simple-commands/init/executable-wrapper.d.ts +0 -2
- package/dist/cli/simple-commands/init/executable-wrapper.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/executable-wrapper.js +0 -116
- package/dist/cli/simple-commands/init/executable-wrapper.js.map +0 -1
- package/dist/cli/simple-commands/init/gitignore-updater.d.ts +0 -23
- package/dist/cli/simple-commands/init/gitignore-updater.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/gitignore-updater.js +0 -128
- package/dist/cli/simple-commands/init/gitignore-updater.js.map +0 -1
- package/dist/cli/simple-commands/init/help.d.ts +0 -2
- package/dist/cli/simple-commands/init/help.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/help.js +0 -131
- package/dist/cli/simple-commands/init/help.js.map +0 -1
- package/dist/cli/simple-commands/init/hive-mind-init.d.ts +0 -152
- package/dist/cli/simple-commands/init/hive-mind-init.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/hive-mind-init.js +0 -699
- package/dist/cli/simple-commands/init/hive-mind-init.js.map +0 -1
- package/dist/cli/simple-commands/init/index.d.ts +0 -2
- package/dist/cli/simple-commands/init/index.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/index.js +0 -1784
- package/dist/cli/simple-commands/init/index.js.map +0 -1
- package/dist/cli/simple-commands/init/performance-monitor.d.ts +0 -73
- package/dist/cli/simple-commands/init/performance-monitor.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/performance-monitor.js +0 -277
- package/dist/cli/simple-commands/init/performance-monitor.js.map +0 -1
- package/dist/cli/simple-commands/init/rollback/backup-manager.d.ts +0 -95
- package/dist/cli/simple-commands/init/rollback/backup-manager.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/rollback/backup-manager.js +0 -486
- package/dist/cli/simple-commands/init/rollback/backup-manager.js.map +0 -1
- package/dist/cli/simple-commands/init/rollback/index.d.ts +0 -114
- package/dist/cli/simple-commands/init/rollback/index.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/rollback/index.js +0 -353
- package/dist/cli/simple-commands/init/rollback/index.js.map +0 -1
- package/dist/cli/simple-commands/init/rollback/recovery-manager.d.ts +0 -161
- package/dist/cli/simple-commands/init/rollback/recovery-manager.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/rollback/recovery-manager.js +0 -686
- package/dist/cli/simple-commands/init/rollback/recovery-manager.js.map +0 -1
- package/dist/cli/simple-commands/init/rollback/rollback-executor.d.ts +0 -112
- package/dist/cli/simple-commands/init/rollback/rollback-executor.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/rollback/rollback-executor.js +0 -480
- package/dist/cli/simple-commands/init/rollback/rollback-executor.js.map +0 -1
- package/dist/cli/simple-commands/init/rollback/state-tracker.d.ts +0 -121
- package/dist/cli/simple-commands/init/rollback/state-tracker.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/rollback/state-tracker.js +0 -432
- package/dist/cli/simple-commands/init/rollback/state-tracker.js.map +0 -1
- package/dist/cli/simple-commands/init/skills-copier.d.ts +0 -41
- package/dist/cli/simple-commands/init/skills-copier.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/skills-copier.js +0 -192
- package/dist/cli/simple-commands/init/skills-copier.js.map +0 -1
- package/dist/cli/simple-commands/init/sparc/roo-readme.d.ts +0 -2
- package/dist/cli/simple-commands/init/sparc/roo-readme.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/sparc/roo-readme.js +0 -61
- package/dist/cli/simple-commands/init/sparc/roo-readme.js.map +0 -1
- package/dist/cli/simple-commands/init/sparc/roomodes-config.d.ts +0 -2
- package/dist/cli/simple-commands/init/sparc/roomodes-config.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/sparc/roomodes-config.js +0 -80
- package/dist/cli/simple-commands/init/sparc/roomodes-config.js.map +0 -1
- package/dist/cli/simple-commands/init/sparc/workflows.d.ts +0 -2
- package/dist/cli/simple-commands/init/sparc/workflows.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/sparc/workflows.js +0 -36
- package/dist/cli/simple-commands/init/sparc/workflows.js.map +0 -1
- package/dist/cli/simple-commands/init/sparc-structure.d.ts +0 -2
- package/dist/cli/simple-commands/init/sparc-structure.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/sparc-structure.js +0 -63
- package/dist/cli/simple-commands/init/sparc-structure.js.map +0 -1
- package/dist/cli/simple-commands/init/template-copier.d.ts +0 -27
- package/dist/cli/simple-commands/init/template-copier.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/template-copier.js +0 -538
- package/dist/cli/simple-commands/init/template-copier.js.map +0 -1
- package/dist/cli/simple-commands/init/templates/claude-md.d.ts +0 -6
- package/dist/cli/simple-commands/init/templates/claude-md.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/templates/claude-md.js +0 -1097
- package/dist/cli/simple-commands/init/templates/claude-md.js.map +0 -1
- package/dist/cli/simple-commands/init/templates/coordination-md.d.ts +0 -4
- package/dist/cli/simple-commands/init/templates/coordination-md.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/templates/coordination-md.js +0 -338
- package/dist/cli/simple-commands/init/templates/coordination-md.js.map +0 -1
- package/dist/cli/simple-commands/init/templates/enhanced-templates.d.ts +0 -21
- package/dist/cli/simple-commands/init/templates/enhanced-templates.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/templates/enhanced-templates.js +0 -2304
- package/dist/cli/simple-commands/init/templates/enhanced-templates.js.map +0 -1
- package/dist/cli/simple-commands/init/templates/memory-bank-md.d.ts +0 -4
- package/dist/cli/simple-commands/init/templates/memory-bank-md.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/templates/memory-bank-md.js +0 -257
- package/dist/cli/simple-commands/init/templates/memory-bank-md.js.map +0 -1
- package/dist/cli/simple-commands/init/templates/readme-files.d.ts +0 -3
- package/dist/cli/simple-commands/init/templates/readme-files.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/templates/readme-files.js +0 -71
- package/dist/cli/simple-commands/init/templates/readme-files.js.map +0 -1
- package/dist/cli/simple-commands/init/templates/sparc-modes.d.ts +0 -30
- package/dist/cli/simple-commands/init/templates/sparc-modes.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/templates/sparc-modes.js +0 -1375
- package/dist/cli/simple-commands/init/templates/sparc-modes.js.map +0 -1
- package/dist/cli/simple-commands/init/templates/verification-claude-md.d.ts +0 -3
- package/dist/cli/simple-commands/init/templates/verification-claude-md.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/templates/verification-claude-md.js +0 -432
- package/dist/cli/simple-commands/init/templates/verification-claude-md.js.map +0 -1
- package/dist/cli/simple-commands/init/validation/config-validator.d.ts +0 -63
- package/dist/cli/simple-commands/init/validation/config-validator.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/validation/config-validator.js +0 -308
- package/dist/cli/simple-commands/init/validation/config-validator.js.map +0 -1
- package/dist/cli/simple-commands/init/validation/health-checker.d.ts +0 -117
- package/dist/cli/simple-commands/init/validation/health-checker.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/validation/health-checker.js +0 -539
- package/dist/cli/simple-commands/init/validation/health-checker.js.map +0 -1
- package/dist/cli/simple-commands/init/validation/index.d.ts +0 -55
- package/dist/cli/simple-commands/init/validation/index.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/validation/index.js +0 -347
- package/dist/cli/simple-commands/init/validation/index.js.map +0 -1
- package/dist/cli/simple-commands/init/validation/mode-validator.d.ts +0 -76
- package/dist/cli/simple-commands/init/validation/mode-validator.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/validation/mode-validator.js +0 -343
- package/dist/cli/simple-commands/init/validation/mode-validator.js.map +0 -1
- package/dist/cli/simple-commands/init/validation/post-init-validator.d.ts +0 -62
- package/dist/cli/simple-commands/init/validation/post-init-validator.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/validation/post-init-validator.js +0 -349
- package/dist/cli/simple-commands/init/validation/post-init-validator.js.map +0 -1
- package/dist/cli/simple-commands/init/validation/pre-init-validator.d.ts +0 -86
- package/dist/cli/simple-commands/init/validation/pre-init-validator.d.ts.map +0 -1
- package/dist/cli/simple-commands/init/validation/pre-init-validator.js +0 -260
- package/dist/cli/simple-commands/init/validation/pre-init-validator.js.map +0 -1
- package/dist/cli/simple-commands/inject-memory-protocol.d.ts +0 -34
- package/dist/cli/simple-commands/inject-memory-protocol.d.ts.map +0 -1
- package/dist/cli/simple-commands/inject-memory-protocol.js +0 -229
- package/dist/cli/simple-commands/inject-memory-protocol.js.map +0 -1
- package/dist/cli/simple-commands/mcp.d.ts +0 -2
- package/dist/cli/simple-commands/mcp.d.ts.map +0 -1
- package/dist/cli/simple-commands/mcp.js +0 -369
- package/dist/cli/simple-commands/mcp.js.map +0 -1
- package/dist/cli/simple-commands/memory-consolidation.d.ts +0 -73
- package/dist/cli/simple-commands/memory-consolidation.d.ts.map +0 -1
- package/dist/cli/simple-commands/memory-consolidation.js +0 -537
- package/dist/cli/simple-commands/memory-consolidation.js.map +0 -1
- package/dist/cli/simple-commands/memory.d.ts +0 -2
- package/dist/cli/simple-commands/memory.d.ts.map +0 -1
- package/dist/cli/simple-commands/memory.js +0 -778
- package/dist/cli/simple-commands/memory.js.map +0 -1
- package/dist/cli/simple-commands/migrate-hooks.d.ts +0 -10
- package/dist/cli/simple-commands/migrate-hooks.d.ts.map +0 -1
- package/dist/cli/simple-commands/migrate-hooks.js +0 -57
- package/dist/cli/simple-commands/migrate-hooks.js.map +0 -1
- package/dist/cli/simple-commands/monitor.d.ts +0 -3
- package/dist/cli/simple-commands/monitor.d.ts.map +0 -1
- package/dist/cli/simple-commands/monitor.js +0 -366
- package/dist/cli/simple-commands/monitor.js.map +0 -1
- package/dist/cli/simple-commands/neural.d.ts +0 -3
- package/dist/cli/simple-commands/neural.d.ts.map +0 -1
- package/dist/cli/simple-commands/neural.js +0 -137
- package/dist/cli/simple-commands/neural.js.map +0 -1
- package/dist/cli/simple-commands/pair.d.ts +0 -3
- package/dist/cli/simple-commands/pair.d.ts.map +0 -1
- package/dist/cli/simple-commands/pair.js +0 -735
- package/dist/cli/simple-commands/pair.js.map +0 -1
- package/dist/cli/simple-commands/performance-hooks.d.ts +0 -20
- package/dist/cli/simple-commands/performance-hooks.d.ts.map +0 -1
- package/dist/cli/simple-commands/performance-hooks.js +0 -127
- package/dist/cli/simple-commands/performance-hooks.js.map +0 -1
- package/dist/cli/simple-commands/performance-metrics.d.ts +0 -153
- package/dist/cli/simple-commands/performance-metrics.d.ts.map +0 -1
- package/dist/cli/simple-commands/performance-metrics.js +0 -759
- package/dist/cli/simple-commands/performance-metrics.js.map +0 -1
- package/dist/cli/simple-commands/process-ui-enhanced.d.ts +0 -55
- package/dist/cli/simple-commands/process-ui-enhanced.d.ts.map +0 -1
- package/dist/cli/simple-commands/process-ui-enhanced.js +0 -680
- package/dist/cli/simple-commands/process-ui-enhanced.js.map +0 -1
- package/dist/cli/simple-commands/proxy.d.ts +0 -5
- package/dist/cli/simple-commands/proxy.d.ts.map +0 -1
- package/dist/cli/simple-commands/proxy.js +0 -346
- package/dist/cli/simple-commands/proxy.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/architect.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/architect.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/architect.js +0 -126
- package/dist/cli/simple-commands/sparc-modes/architect.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/ask.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/ask.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/ask.js +0 -127
- package/dist/cli/simple-commands/sparc-modes/ask.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/code.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/code.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/code.js +0 -149
- package/dist/cli/simple-commands/sparc-modes/code.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/debug.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/debug.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/debug.js +0 -113
- package/dist/cli/simple-commands/sparc-modes/debug.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/devops.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/devops.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/devops.js +0 -138
- package/dist/cli/simple-commands/sparc-modes/devops.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/docs-writer.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/docs-writer.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/docs-writer.js +0 -39
- package/dist/cli/simple-commands/sparc-modes/docs-writer.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/generic.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/generic.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/generic.js +0 -35
- package/dist/cli/simple-commands/sparc-modes/generic.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/index.d.ts +0 -17
- package/dist/cli/simple-commands/sparc-modes/index.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/index.js +0 -196
- package/dist/cli/simple-commands/sparc-modes/index.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/integration.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/integration.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/integration.js +0 -56
- package/dist/cli/simple-commands/sparc-modes/integration.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/mcp.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/mcp.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/mcp.js +0 -39
- package/dist/cli/simple-commands/sparc-modes/mcp.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/monitoring.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/monitoring.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/monitoring.js +0 -39
- package/dist/cli/simple-commands/sparc-modes/monitoring.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/optimization.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/optimization.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/optimization.js +0 -39
- package/dist/cli/simple-commands/sparc-modes/optimization.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/security-review.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/security-review.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/security-review.js +0 -131
- package/dist/cli/simple-commands/sparc-modes/security-review.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/sparc-orchestrator.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/sparc-orchestrator.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/sparc-orchestrator.js +0 -168
- package/dist/cli/simple-commands/sparc-modes/sparc-orchestrator.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/spec-pseudocode.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/spec-pseudocode.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/spec-pseudocode.js +0 -39
- package/dist/cli/simple-commands/sparc-modes/spec-pseudocode.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/supabase-admin.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/supabase-admin.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/supabase-admin.js +0 -150
- package/dist/cli/simple-commands/sparc-modes/supabase-admin.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/swarm.d.ts +0 -81
- package/dist/cli/simple-commands/sparc-modes/swarm.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/swarm.js +0 -428
- package/dist/cli/simple-commands/sparc-modes/swarm.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/tdd.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/tdd.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/tdd.js +0 -113
- package/dist/cli/simple-commands/sparc-modes/tdd.js.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/tutorial.d.ts +0 -2
- package/dist/cli/simple-commands/sparc-modes/tutorial.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc-modes/tutorial.js +0 -278
- package/dist/cli/simple-commands/sparc-modes/tutorial.js.map +0 -1
- package/dist/cli/simple-commands/sparc.d.ts +0 -2
- package/dist/cli/simple-commands/sparc.d.ts.map +0 -1
- package/dist/cli/simple-commands/sparc.js +0 -477
- package/dist/cli/simple-commands/sparc.js.map +0 -1
- package/dist/cli/simple-commands/start-ui.d.ts +0 -2
- package/dist/cli/simple-commands/start-ui.d.ts.map +0 -1
- package/dist/cli/simple-commands/start-ui.js +0 -135
- package/dist/cli/simple-commands/start-ui.js.map +0 -1
- package/dist/cli/simple-commands/start-wrapper.d.ts +0 -2
- package/dist/cli/simple-commands/start-wrapper.d.ts.map +0 -1
- package/dist/cli/simple-commands/start-wrapper.js +0 -264
- package/dist/cli/simple-commands/start-wrapper.js.map +0 -1
- package/dist/cli/simple-commands/start.d.ts +0 -2
- package/dist/cli/simple-commands/start.d.ts.map +0 -1
- package/dist/cli/simple-commands/start.js +0 -3
- package/dist/cli/simple-commands/start.js.map +0 -1
- package/dist/cli/simple-commands/status.d.ts +0 -2
- package/dist/cli/simple-commands/status.d.ts.map +0 -1
- package/dist/cli/simple-commands/status.js +0 -292
- package/dist/cli/simple-commands/status.js.map +0 -1
- package/dist/cli/simple-commands/stream-chain.d.ts +0 -7
- package/dist/cli/simple-commands/stream-chain.d.ts.map +0 -1
- package/dist/cli/simple-commands/stream-chain.js +0 -433
- package/dist/cli/simple-commands/stream-chain.js.map +0 -1
- package/dist/cli/simple-commands/stream-processor.d.ts +0 -32
- package/dist/cli/simple-commands/stream-processor.d.ts.map +0 -1
- package/dist/cli/simple-commands/stream-processor.js +0 -318
- package/dist/cli/simple-commands/stream-processor.js.map +0 -1
- package/dist/cli/simple-commands/swarm-executor.d.ts +0 -68
- package/dist/cli/simple-commands/swarm-executor.d.ts.map +0 -1
- package/dist/cli/simple-commands/swarm-executor.js +0 -218
- package/dist/cli/simple-commands/swarm-executor.js.map +0 -1
- package/dist/cli/simple-commands/swarm-metrics-integration.d.ts +0 -69
- package/dist/cli/simple-commands/swarm-metrics-integration.d.ts.map +0 -1
- package/dist/cli/simple-commands/swarm-metrics-integration.js +0 -294
- package/dist/cli/simple-commands/swarm-metrics-integration.js.map +0 -1
- package/dist/cli/simple-commands/swarm-webui-integration.d.ts +0 -68
- package/dist/cli/simple-commands/swarm-webui-integration.d.ts.map +0 -1
- package/dist/cli/simple-commands/swarm-webui-integration.js +0 -265
- package/dist/cli/simple-commands/swarm-webui-integration.js.map +0 -1
- package/dist/cli/simple-commands/swarm.d.ts +0 -2
- package/dist/cli/simple-commands/swarm.d.ts.map +0 -1
- package/dist/cli/simple-commands/swarm.js +0 -2104
- package/dist/cli/simple-commands/swarm.js.map +0 -1
- package/dist/cli/simple-commands/task.d.ts +0 -2
- package/dist/cli/simple-commands/task.d.ts.map +0 -1
- package/dist/cli/simple-commands/task.js +0 -250
- package/dist/cli/simple-commands/task.js.map +0 -1
- package/dist/cli/simple-commands/token-tracker.d.ts +0 -73
- package/dist/cli/simple-commands/token-tracker.d.ts.map +0 -1
- package/dist/cli/simple-commands/token-tracker.js +0 -319
- package/dist/cli/simple-commands/token-tracker.js.map +0 -1
- package/dist/cli/simple-commands/training-pipeline.d.ts +0 -166
- package/dist/cli/simple-commands/training-pipeline.d.ts.map +0 -1
- package/dist/cli/simple-commands/training-pipeline.js +0 -760
- package/dist/cli/simple-commands/training-pipeline.js.map +0 -1
- package/dist/cli/simple-commands/training.d.ts +0 -2
- package/dist/cli/simple-commands/training.d.ts.map +0 -1
- package/dist/cli/simple-commands/training.js +0 -240
- package/dist/cli/simple-commands/training.js.map +0 -1
- package/dist/cli/simple-commands/verification-training-integration.d.ts +0 -181
- package/dist/cli/simple-commands/verification-training-integration.d.ts.map +0 -1
- package/dist/cli/simple-commands/verification-training-integration.js +0 -561
- package/dist/cli/simple-commands/verification-training-integration.js.map +0 -1
- package/dist/cli/simple-commands/verification.d.ts +0 -10
- package/dist/cli/simple-commands/verification.d.ts.map +0 -1
- package/dist/cli/simple-commands/verification.js +0 -476
- package/dist/cli/simple-commands/verification.js.map +0 -1
- package/dist/cli/simple-commands/web-server.d.ts +0 -152
- package/dist/cli/simple-commands/web-server.d.ts.map +0 -1
- package/dist/cli/simple-commands/web-server.js +0 -816
- package/dist/cli/simple-commands/web-server.js.map +0 -1
- package/dist/cli/utils/interactive-detector.d.ts +0 -25
- package/dist/cli/utils/interactive-detector.d.ts.map +0 -1
- package/dist/cli/utils/interactive-detector.js +0 -129
- package/dist/cli/utils/interactive-detector.js.map +0 -1
- package/dist/cli/utils/safe-interactive.d.ts +0 -30
- package/dist/cli/utils/safe-interactive.d.ts.map +0 -1
- package/dist/cli/utils/safe-interactive.js +0 -134
- package/dist/cli/utils/safe-interactive.js.map +0 -1
- package/dist/cli/utils.d.ts +0 -75
- package/dist/cli/utils.d.ts.map +0 -1
- package/dist/cli/utils.js +0 -567
- package/dist/cli/utils.js.map +0 -1
- package/dist/config/config-manager.d.ts +0 -212
- package/dist/config/config-manager.d.ts.map +0 -1
- package/dist/config/config-manager.js +0 -550
- package/dist/config/config-manager.js.map +0 -1
- package/dist/constants/agent-types.d.ts +0 -57
- package/dist/constants/agent-types.d.ts.map +0 -1
- package/dist/constants/agent-types.js +0 -57
- package/dist/constants/agent-types.js.map +0 -1
- package/dist/coordination/advanced-scheduler.d.ts +0 -121
- package/dist/coordination/advanced-scheduler.d.ts.map +0 -1
- package/dist/coordination/advanced-scheduler.js +0 -382
- package/dist/coordination/advanced-scheduler.js.map +0 -1
- package/dist/coordination/background-executor.d.ts +0 -69
- package/dist/coordination/background-executor.d.ts.map +0 -1
- package/dist/coordination/background-executor.js +0 -363
- package/dist/coordination/background-executor.js.map +0 -1
- package/dist/coordination/circuit-breaker.d.ts +0 -124
- package/dist/coordination/circuit-breaker.d.ts.map +0 -1
- package/dist/coordination/circuit-breaker.js +0 -301
- package/dist/coordination/circuit-breaker.js.map +0 -1
- package/dist/coordination/conflict-resolution.d.ts +0 -133
- package/dist/coordination/conflict-resolution.d.ts.map +0 -1
- package/dist/coordination/conflict-resolution.js +0 -360
- package/dist/coordination/conflict-resolution.js.map +0 -1
- package/dist/coordination/dependency-graph.d.ts +0 -78
- package/dist/coordination/dependency-graph.d.ts.map +0 -1
- package/dist/coordination/dependency-graph.js +0 -387
- package/dist/coordination/dependency-graph.js.map +0 -1
- package/dist/coordination/manager.d.ts +0 -66
- package/dist/coordination/manager.d.ts.map +0 -1
- package/dist/coordination/manager.js +0 -354
- package/dist/coordination/manager.js.map +0 -1
- package/dist/coordination/messaging.d.ts +0 -37
- package/dist/coordination/messaging.d.ts.map +0 -1
- package/dist/coordination/messaging.js +0 -219
- package/dist/coordination/messaging.js.map +0 -1
- package/dist/coordination/metrics.d.ts +0 -153
- package/dist/coordination/metrics.d.ts.map +0 -1
- package/dist/coordination/metrics.js +0 -436
- package/dist/coordination/metrics.js.map +0 -1
- package/dist/coordination/resources.d.ts +0 -36
- package/dist/coordination/resources.d.ts.map +0 -1
- package/dist/coordination/resources.js +0 -254
- package/dist/coordination/resources.js.map +0 -1
- package/dist/coordination/scheduler.d.ts +0 -48
- package/dist/coordination/scheduler.d.ts.map +0 -1
- package/dist/coordination/scheduler.js +0 -308
- package/dist/coordination/scheduler.js.map +0 -1
- package/dist/coordination/swarm-coordinator.d.ts +0 -116
- package/dist/coordination/swarm-coordinator.d.ts.map +0 -1
- package/dist/coordination/swarm-coordinator.js +0 -563
- package/dist/coordination/swarm-coordinator.js.map +0 -1
- package/dist/coordination/swarm-monitor.d.ts +0 -101
- package/dist/coordination/swarm-monitor.d.ts.map +0 -1
- package/dist/coordination/swarm-monitor.js +0 -340
- package/dist/coordination/swarm-monitor.js.map +0 -1
- package/dist/coordination/work-stealing.d.ts +0 -44
- package/dist/coordination/work-stealing.d.ts.map +0 -1
- package/dist/coordination/work-stealing.js +0 -158
- package/dist/coordination/work-stealing.js.map +0 -1
- package/dist/core/config.d.ts +0 -243
- package/dist/core/config.d.ts.map +0 -1
- package/dist/core/config.js +0 -1125
- package/dist/core/config.js.map +0 -1
- package/dist/core/event-bus.d.ts +0 -63
- package/dist/core/event-bus.d.ts.map +0 -1
- package/dist/core/event-bus.js +0 -153
- package/dist/core/event-bus.js.map +0 -1
- package/dist/core/json-persistence.d.ts +0 -55
- package/dist/core/json-persistence.d.ts.map +0 -1
- package/dist/core/json-persistence.js +0 -111
- package/dist/core/json-persistence.js.map +0 -1
- package/dist/core/logger.d.ts +0 -62
- package/dist/core/logger.d.ts.map +0 -1
- package/dist/core/logger.js +0 -252
- package/dist/core/logger.js.map +0 -1
- package/dist/core/orchestrator-fixed.d.ts +0 -81
- package/dist/core/orchestrator-fixed.d.ts.map +0 -1
- package/dist/core/orchestrator-fixed.js +0 -213
- package/dist/core/orchestrator-fixed.js.map +0 -1
- package/dist/core/orchestrator.d.ts +0 -141
- package/dist/core/orchestrator.d.ts.map +0 -1
- package/dist/core/orchestrator.js +0 -1166
- package/dist/core/orchestrator.js.map +0 -1
- package/dist/core/version.d.ts +0 -10
- package/dist/core/version.d.ts.map +0 -1
- package/dist/core/version.js +0 -36
- package/dist/core/version.js.map +0 -1
- package/dist/enterprise/analytics-manager.d.ts +0 -489
- package/dist/enterprise/analytics-manager.d.ts.map +0 -1
- package/dist/enterprise/analytics-manager.js +0 -956
- package/dist/enterprise/analytics-manager.js.map +0 -1
- package/dist/enterprise/audit-manager.d.ts +0 -459
- package/dist/enterprise/audit-manager.d.ts.map +0 -1
- package/dist/enterprise/audit-manager.js +0 -1014
- package/dist/enterprise/audit-manager.js.map +0 -1
- package/dist/enterprise/cloud-manager.d.ts +0 -435
- package/dist/enterprise/cloud-manager.d.ts.map +0 -1
- package/dist/enterprise/cloud-manager.js +0 -789
- package/dist/enterprise/cloud-manager.js.map +0 -1
- package/dist/enterprise/deployment-manager.d.ts +0 -328
- package/dist/enterprise/deployment-manager.d.ts.map +0 -1
- package/dist/enterprise/deployment-manager.js +0 -830
- package/dist/enterprise/deployment-manager.js.map +0 -1
- package/dist/enterprise/project-manager.d.ts +0 -228
- package/dist/enterprise/project-manager.d.ts.map +0 -1
- package/dist/enterprise/project-manager.js +0 -537
- package/dist/enterprise/project-manager.js.map +0 -1
- package/dist/enterprise/security-manager.d.ts +0 -422
- package/dist/enterprise/security-manager.d.ts.map +0 -1
- package/dist/enterprise/security-manager.js +0 -910
- package/dist/enterprise/security-manager.js.map +0 -1
- package/dist/execution/agent-executor.d.ts +0 -80
- package/dist/execution/agent-executor.d.ts.map +0 -1
- package/dist/execution/agent-executor.js +0 -220
- package/dist/execution/agent-executor.js.map +0 -1
- package/dist/execution/provider-manager.d.ts +0 -65
- package/dist/execution/provider-manager.d.ts.map +0 -1
- package/dist/execution/provider-manager.js +0 -144
- package/dist/execution/provider-manager.js.map +0 -1
- package/dist/hive-mind/core/Agent.d.ts +0 -137
- package/dist/hive-mind/core/Agent.d.ts.map +0 -1
- package/dist/hive-mind/core/Agent.js +0 -567
- package/dist/hive-mind/core/Agent.js.map +0 -1
- package/dist/hive-mind/core/Communication.d.ts +0 -116
- package/dist/hive-mind/core/Communication.d.ts.map +0 -1
- package/dist/hive-mind/core/Communication.js +0 -407
- package/dist/hive-mind/core/Communication.js.map +0 -1
- package/dist/hive-mind/core/DatabaseManager.d.ts +0 -99
- package/dist/hive-mind/core/DatabaseManager.d.ts.map +0 -1
- package/dist/hive-mind/core/DatabaseManager.js +0 -648
- package/dist/hive-mind/core/DatabaseManager.js.map +0 -1
- package/dist/hive-mind/core/HiveMind.d.ts +0 -90
- package/dist/hive-mind/core/HiveMind.d.ts.map +0 -1
- package/dist/hive-mind/core/HiveMind.js +0 -455
- package/dist/hive-mind/core/HiveMind.js.map +0 -1
- package/dist/hive-mind/core/Memory.d.ts +0 -235
- package/dist/hive-mind/core/Memory.d.ts.map +0 -1
- package/dist/hive-mind/core/Memory.js +0 -1192
- package/dist/hive-mind/core/Memory.js.map +0 -1
- package/dist/hive-mind/core/Queen.d.ts +0 -115
- package/dist/hive-mind/core/Queen.d.ts.map +0 -1
- package/dist/hive-mind/core/Queen.js +0 -649
- package/dist/hive-mind/core/Queen.js.map +0 -1
- package/dist/hive-mind/integration/ConsensusEngine.d.ts +0 -117
- package/dist/hive-mind/integration/ConsensusEngine.d.ts.map +0 -1
- package/dist/hive-mind/integration/ConsensusEngine.js +0 -478
- package/dist/hive-mind/integration/ConsensusEngine.js.map +0 -1
- package/dist/hive-mind/integration/MCPToolWrapper.d.ts +0 -172
- package/dist/hive-mind/integration/MCPToolWrapper.d.ts.map +0 -1
- package/dist/hive-mind/integration/MCPToolWrapper.js +0 -217
- package/dist/hive-mind/integration/MCPToolWrapper.js.map +0 -1
- package/dist/hive-mind/integration/SwarmOrchestrator.d.ts +0 -172
- package/dist/hive-mind/integration/SwarmOrchestrator.d.ts.map +0 -1
- package/dist/hive-mind/integration/SwarmOrchestrator.js +0 -748
- package/dist/hive-mind/integration/SwarmOrchestrator.js.map +0 -1
- package/dist/hive-mind/types.d.ts +0 -314
- package/dist/hive-mind/types.d.ts.map +0 -1
- package/dist/hive-mind/types.js +0 -7
- package/dist/hive-mind/types.js.map +0 -1
- package/dist/mcp/auth.d.ts +0 -80
- package/dist/mcp/auth.d.ts.map +0 -1
- package/dist/mcp/auth.js +0 -350
- package/dist/mcp/auth.js.map +0 -1
- package/dist/mcp/claude-flow-tools.d.ts +0 -13
- package/dist/mcp/claude-flow-tools.d.ts.map +0 -1
- package/dist/mcp/claude-flow-tools.js +0 -1398
- package/dist/mcp/claude-flow-tools.js.map +0 -1
- package/dist/mcp/load-balancer.d.ts +0 -88
- package/dist/mcp/load-balancer.d.ts.map +0 -1
- package/dist/mcp/load-balancer.js +0 -393
- package/dist/mcp/load-balancer.js.map +0 -1
- package/dist/mcp/router.d.ts +0 -54
- package/dist/mcp/router.d.ts.map +0 -1
- package/dist/mcp/router.js +0 -204
- package/dist/mcp/router.js.map +0 -1
- package/dist/mcp/ruv-swarm-tools.d.ts +0 -58
- package/dist/mcp/ruv-swarm-tools.d.ts.map +0 -1
- package/dist/mcp/ruv-swarm-tools.js +0 -568
- package/dist/mcp/ruv-swarm-tools.js.map +0 -1
- package/dist/mcp/server.d.ts +0 -75
- package/dist/mcp/server.d.ts.map +0 -1
- package/dist/mcp/server.js +0 -538
- package/dist/mcp/server.js.map +0 -1
- package/dist/mcp/session-manager.d.ts +0 -60
- package/dist/mcp/session-manager.d.ts.map +0 -1
- package/dist/mcp/session-manager.js +0 -323
- package/dist/mcp/session-manager.js.map +0 -1
- package/dist/mcp/swarm-tools.d.ts +0 -87
- package/dist/mcp/swarm-tools.d.ts.map +0 -1
- package/dist/mcp/swarm-tools.js +0 -731
- package/dist/mcp/swarm-tools.js.map +0 -1
- package/dist/mcp/tools.d.ts +0 -145
- package/dist/mcp/tools.d.ts.map +0 -1
- package/dist/mcp/tools.js +0 -434
- package/dist/mcp/tools.js.map +0 -1
- package/dist/mcp/transports/base.d.ts +0 -22
- package/dist/mcp/transports/base.d.ts.map +0 -1
- package/dist/mcp/transports/base.js +0 -5
- package/dist/mcp/transports/base.js.map +0 -1
- package/dist/mcp/transports/http.d.ts +0 -48
- package/dist/mcp/transports/http.d.ts.map +0 -1
- package/dist/mcp/transports/http.js +0 -400
- package/dist/mcp/transports/http.js.map +0 -1
- package/dist/mcp/transports/stdio.d.ts +0 -37
- package/dist/mcp/transports/stdio.d.ts.map +0 -1
- package/dist/mcp/transports/stdio.js +0 -206
- package/dist/mcp/transports/stdio.js.map +0 -1
- package/dist/memory/advanced-serializer.d.ts +0 -159
- package/dist/memory/advanced-serializer.d.ts.map +0 -1
- package/dist/memory/advanced-serializer.js +0 -564
- package/dist/memory/advanced-serializer.js.map +0 -1
- package/dist/memory/backends/base.d.ts +0 -21
- package/dist/memory/backends/base.d.ts.map +0 -1
- package/dist/memory/backends/base.js +0 -5
- package/dist/memory/backends/base.js.map +0 -1
- package/dist/memory/backends/markdown.d.ts +0 -35
- package/dist/memory/backends/markdown.d.ts.map +0 -1
- package/dist/memory/backends/markdown.js +0 -223
- package/dist/memory/backends/markdown.js.map +0 -1
- package/dist/memory/backends/sqlite.d.ts +0 -33
- package/dist/memory/backends/sqlite.d.ts.map +0 -1
- package/dist/memory/backends/sqlite.js +0 -291
- package/dist/memory/backends/sqlite.js.map +0 -1
- package/dist/memory/cache.d.ts +0 -65
- package/dist/memory/cache.d.ts.map +0 -1
- package/dist/memory/cache.js +0 -188
- package/dist/memory/cache.js.map +0 -1
- package/dist/memory/distributed-memory.d.ts +0 -188
- package/dist/memory/distributed-memory.d.ts.map +0 -1
- package/dist/memory/distributed-memory.js +0 -710
- package/dist/memory/distributed-memory.js.map +0 -1
- package/dist/memory/enhanced-session-serializer.d.ts +0 -115
- package/dist/memory/enhanced-session-serializer.d.ts.map +0 -1
- package/dist/memory/enhanced-session-serializer.js +0 -478
- package/dist/memory/enhanced-session-serializer.js.map +0 -1
- package/dist/memory/fallback-store.d.ts +0 -28
- package/dist/memory/fallback-store.d.ts.map +0 -1
- package/dist/memory/fallback-store.js +0 -101
- package/dist/memory/fallback-store.js.map +0 -1
- package/dist/memory/in-memory-store.d.ts +0 -37
- package/dist/memory/in-memory-store.d.ts.map +0 -1
- package/dist/memory/in-memory-store.js +0 -174
- package/dist/memory/in-memory-store.js.map +0 -1
- package/dist/memory/indexer.d.ts +0 -52
- package/dist/memory/indexer.d.ts.map +0 -1
- package/dist/memory/indexer.js +0 -191
- package/dist/memory/indexer.js.map +0 -1
- package/dist/memory/manager.d.ts +0 -58
- package/dist/memory/manager.d.ts.map +0 -1
- package/dist/memory/manager.js +0 -423
- package/dist/memory/manager.js.map +0 -1
- package/dist/memory/sqlite-store.d.ts +0 -34
- package/dist/memory/sqlite-store.d.ts.map +0 -1
- package/dist/memory/sqlite-store.js +0 -268
- package/dist/memory/sqlite-store.js.map +0 -1
- package/dist/memory/sqlite-wrapper.d.ts +0 -38
- package/dist/memory/sqlite-wrapper.d.ts.map +0 -1
- package/dist/memory/sqlite-wrapper.js +0 -152
- package/dist/memory/sqlite-wrapper.js.map +0 -1
- package/dist/memory/swarm-memory.d.ts +0 -91
- package/dist/memory/swarm-memory.d.ts.map +0 -1
- package/dist/memory/swarm-memory.js +0 -454
- package/dist/memory/swarm-memory.js.map +0 -1
- package/dist/memory/unified-memory-manager.d.ts +0 -116
- package/dist/memory/unified-memory-manager.d.ts.map +0 -1
- package/dist/memory/unified-memory-manager.js +0 -397
- package/dist/memory/unified-memory-manager.js.map +0 -1
- package/dist/migration/logger.d.ts +0 -26
- package/dist/migration/logger.d.ts.map +0 -1
- package/dist/migration/logger.js +0 -145
- package/dist/migration/logger.js.map +0 -1
- package/dist/migration/migration-analyzer.d.ts +0 -18
- package/dist/migration/migration-analyzer.d.ts.map +0 -1
- package/dist/migration/migration-analyzer.js +0 -284
- package/dist/migration/migration-analyzer.js.map +0 -1
- package/dist/migration/migration-runner.d.ts +0 -26
- package/dist/migration/migration-runner.d.ts.map +0 -1
- package/dist/migration/migration-runner.js +0 -505
- package/dist/migration/migration-runner.js.map +0 -1
- package/dist/migration/migration-validator.d.ts +0 -17
- package/dist/migration/migration-validator.d.ts.map +0 -1
- package/dist/migration/migration-validator.js +0 -309
- package/dist/migration/migration-validator.js.map +0 -1
- package/dist/migration/progress-reporter.d.ts +0 -28
- package/dist/migration/progress-reporter.d.ts.map +0 -1
- package/dist/migration/progress-reporter.js +0 -163
- package/dist/migration/progress-reporter.js.map +0 -1
- package/dist/migration/rollback-manager.d.ts +0 -24
- package/dist/migration/rollback-manager.d.ts.map +0 -1
- package/dist/migration/rollback-manager.js +0 -351
- package/dist/migration/rollback-manager.js.map +0 -1
- package/dist/migration/types.d.ts +0 -103
- package/dist/migration/types.d.ts.map +0 -1
- package/dist/migration/types.js +0 -6
- package/dist/migration/types.js.map +0 -1
- package/dist/reasoningbank/reasoningbank-adapter.d.ts +0 -93
- package/dist/reasoningbank/reasoningbank-adapter.d.ts.map +0 -1
- package/dist/reasoningbank/reasoningbank-adapter.js +0 -365
- package/dist/reasoningbank/reasoningbank-adapter.js.map +0 -1
- package/dist/sdk/query-control.d.ts +0 -131
- package/dist/sdk/query-control.d.ts.map +0 -1
- package/dist/sdk/query-control.js +0 -363
- package/dist/sdk/query-control.js.map +0 -1
- package/dist/sdk/session-forking.d.ts +0 -109
- package/dist/sdk/session-forking.d.ts.map +0 -1
- package/dist/sdk/session-forking.js +0 -275
- package/dist/sdk/session-forking.js.map +0 -1
- package/dist/swarm/types.d.ts +0 -578
- package/dist/swarm/types.d.ts.map +0 -1
- package/dist/swarm/types.js +0 -54
- package/dist/swarm/types.js.map +0 -1
- package/dist/terminal/adapters/base.d.ts +0 -40
- package/dist/terminal/adapters/base.d.ts.map +0 -1
- package/dist/terminal/adapters/base.js +0 -5
- package/dist/terminal/adapters/base.js.map +0 -1
- package/dist/terminal/adapters/native.d.ts +0 -19
- package/dist/terminal/adapters/native.d.ts.map +0 -1
- package/dist/terminal/adapters/native.js +0 -414
- package/dist/terminal/adapters/native.js.map +0 -1
- package/dist/terminal/adapters/vscode.d.ts +0 -23
- package/dist/terminal/adapters/vscode.d.ts.map +0 -1
- package/dist/terminal/adapters/vscode.js +0 -267
- package/dist/terminal/adapters/vscode.js.map +0 -1
- package/dist/terminal/manager.d.ts +0 -59
- package/dist/terminal/manager.d.ts.map +0 -1
- package/dist/terminal/manager.js +0 -235
- package/dist/terminal/manager.js.map +0 -1
- package/dist/terminal/pool.d.ts +0 -32
- package/dist/terminal/pool.d.ts.map +0 -1
- package/dist/terminal/pool.js +0 -208
- package/dist/terminal/pool.js.map +0 -1
- package/dist/terminal/session.d.ts +0 -41
- package/dist/terminal/session.d.ts.map +0 -1
- package/dist/terminal/session.js +0 -210
- package/dist/terminal/session.js.map +0 -1
- package/dist/utils/error-handler.d.ts +0 -14
- package/dist/utils/error-handler.d.ts.map +0 -1
- package/dist/utils/error-handler.js +0 -29
- package/dist/utils/error-handler.js.map +0 -1
- package/dist/utils/errors.d.ts +0 -121
- package/dist/utils/errors.d.ts.map +0 -1
- package/dist/utils/errors.js +0 -194
- package/dist/utils/errors.js.map +0 -1
- package/dist/utils/formatters.d.ts +0 -15
- package/dist/utils/formatters.d.ts.map +0 -1
- package/dist/utils/formatters.js +0 -75
- package/dist/utils/formatters.js.map +0 -1
- package/dist/utils/helpers.d.ts +0 -134
- package/dist/utils/helpers.d.ts.map +0 -1
- package/dist/utils/helpers.js +0 -444
- package/dist/utils/helpers.js.map +0 -1
- package/dist/utils/key-redactor.d.ts +0 -46
- package/dist/utils/key-redactor.d.ts.map +0 -1
- package/dist/utils/key-redactor.js +0 -153
- package/dist/utils/key-redactor.js.map +0 -1
- package/dist/utils/metrics-reader.d.ts +0 -67
- package/dist/utils/metrics-reader.d.ts.map +0 -1
- package/dist/utils/metrics-reader.js +0 -201
- package/dist/utils/metrics-reader.js.map +0 -1
- package/dist/utils/npx-isolated-cache.d.ts +0 -17
- package/dist/utils/npx-isolated-cache.d.ts.map +0 -1
- package/dist/utils/npx-isolated-cache.js +0 -140
- package/dist/utils/npx-isolated-cache.js.map +0 -1
- package/dist/utils/project-root.d.ts +0 -35
- package/dist/utils/project-root.d.ts.map +0 -1
- package/dist/utils/project-root.js +0 -115
- package/dist/utils/project-root.js.map +0 -1
- package/dist/utils/type-guards.d.ts +0 -117
- package/dist/utils/type-guards.d.ts.map +0 -1
- package/dist/utils/type-guards.js +0 -166
- package/dist/utils/type-guards.js.map +0 -1
- package/dist/utils/types.d.ts +0 -568
- package/dist/utils/types.d.ts.map +0 -1
- package/dist/utils/types.js +0 -37
- package/dist/utils/types.js.map +0 -1
- /package/docs/{COMMANDS_TO_SKILLS_MIGRATION.md → development/COMMANDS_TO_SKILLS_MIGRATION.md} +0 -0
- /package/docs/{FINAL_INIT_STRUCTURE.md → development/FINAL_INIT_STRUCTURE.md} +0 -0
- /package/docs/{CLI-MEMORY-COMMANDS-WORKING.md → fixes/CLI-MEMORY-COMMANDS-WORKING.md} +0 -0
- /package/docs/{PERFORMANCE-JSON-IMPROVEMENTS.md → performance/PERFORMANCE-JSON-IMPROVEMENTS.md} +0 -0
- /package/docs/{PERFORMANCE-METRICS-GUIDE.md → performance/PERFORMANCE-METRICS-GUIDE.md} +0 -0
- /package/docs/{RELEASE-NOTES-v2.7.0-alpha.9.md → releases/v2.7.0-alpha.9/RELEASE-NOTES-v2.7.0-alpha.9.md} +0 -0
|
@@ -1,956 +0,0 @@
|
|
|
1
|
-
import { EventEmitter } from 'events';
|
|
2
|
-
import { writeFile, readFile, mkdir, readdir } from 'fs/promises';
|
|
3
|
-
import { join } from 'path';
|
|
4
|
-
import { Logger } from '../core/logger.js';
|
|
5
|
-
import { ConfigManager } from '../core/config.js';
|
|
6
|
-
export class AnalyticsManager extends EventEmitter {
|
|
7
|
-
metrics = new Map();
|
|
8
|
-
dashboards = new Map();
|
|
9
|
-
insights = new Map();
|
|
10
|
-
models = new Map();
|
|
11
|
-
reports = new Map();
|
|
12
|
-
analyticsPath;
|
|
13
|
-
logger;
|
|
14
|
-
config;
|
|
15
|
-
configuration;
|
|
16
|
-
constructor(analyticsPath = './analytics', logger, config) {
|
|
17
|
-
super();
|
|
18
|
-
this.analyticsPath = analyticsPath;
|
|
19
|
-
this.logger = logger || new Logger({ level: 'info', format: 'text', destination: 'console' });
|
|
20
|
-
this.config = config || ConfigManager.getInstance();
|
|
21
|
-
this.configuration = this.getDefaultConfiguration();
|
|
22
|
-
}
|
|
23
|
-
async initialize() {
|
|
24
|
-
try {
|
|
25
|
-
await mkdir(this.analyticsPath, { recursive: true });
|
|
26
|
-
await mkdir(join(this.analyticsPath, 'metrics'), { recursive: true });
|
|
27
|
-
await mkdir(join(this.analyticsPath, 'dashboards'), { recursive: true });
|
|
28
|
-
await mkdir(join(this.analyticsPath, 'insights'), { recursive: true });
|
|
29
|
-
await mkdir(join(this.analyticsPath, 'models'), { recursive: true });
|
|
30
|
-
await mkdir(join(this.analyticsPath, 'reports'), { recursive: true });
|
|
31
|
-
await this.loadConfigurations();
|
|
32
|
-
await this.initializeDefaultDashboards();
|
|
33
|
-
await this.startMetricsCollection();
|
|
34
|
-
this.logger.info('Analytics Manager initialized successfully');
|
|
35
|
-
}
|
|
36
|
-
catch (error) {
|
|
37
|
-
this.logger.error('Failed to initialize Analytics Manager', { error });
|
|
38
|
-
throw error;
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
async recordMetric(metric) {
|
|
42
|
-
const fullMetric = {
|
|
43
|
-
id: `metric-${Date.now()}-${Math.random().toString(36).substr(2, 9)}`,
|
|
44
|
-
timestamp: new Date(),
|
|
45
|
-
...metric,
|
|
46
|
-
};
|
|
47
|
-
const key = `${metric.category}-${metric.name}`;
|
|
48
|
-
if (!this.metrics.has(key)) {
|
|
49
|
-
this.metrics.set(key, []);
|
|
50
|
-
}
|
|
51
|
-
const metricArray = this.metrics.get(key);
|
|
52
|
-
metricArray.push(fullMetric);
|
|
53
|
-
// Keep only recent metrics in memory (configurable retention)
|
|
54
|
-
const retentionPeriod = 24 * 60 * 60 * 1000; // 24 hours
|
|
55
|
-
const cutoff = Date.now() - retentionPeriod;
|
|
56
|
-
const filteredMetrics = metricArray.filter((m) => m.timestamp.getTime() > cutoff);
|
|
57
|
-
this.metrics.set(key, filteredMetrics);
|
|
58
|
-
// Persist to disk for longer-term storage
|
|
59
|
-
await this.persistMetric(fullMetric);
|
|
60
|
-
this.emit('metric:recorded', fullMetric);
|
|
61
|
-
// Check for anomalies and generate insights
|
|
62
|
-
await this.checkForAnomalies(key, fullMetric);
|
|
63
|
-
}
|
|
64
|
-
async queryMetrics(query) {
|
|
65
|
-
const results = {};
|
|
66
|
-
for (const metricName of query.metrics) {
|
|
67
|
-
const key = metricName.includes('-') ? metricName : `*-${metricName}`;
|
|
68
|
-
const matchingKeys = Array.from(this.metrics.keys()).filter((k) => key === '*' || k.includes(key.replace('*-', '')) || k === key);
|
|
69
|
-
let allMetrics = [];
|
|
70
|
-
for (const k of matchingKeys) {
|
|
71
|
-
const keyMetrics = this.metrics.get(k) || [];
|
|
72
|
-
allMetrics.push(...keyMetrics);
|
|
73
|
-
}
|
|
74
|
-
// Filter by time range
|
|
75
|
-
allMetrics = allMetrics.filter((m) => m.timestamp >= query.timeRange.start && m.timestamp <= query.timeRange.end);
|
|
76
|
-
// Apply filters
|
|
77
|
-
if (query.filters) {
|
|
78
|
-
for (const [field, value] of Object.entries(query.filters)) {
|
|
79
|
-
allMetrics = allMetrics.filter((m) => {
|
|
80
|
-
if (field === 'tags') {
|
|
81
|
-
return Object.entries(value).every(([k, v]) => m.tags[k] === v);
|
|
82
|
-
}
|
|
83
|
-
return m[field] === value;
|
|
84
|
-
});
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
// Group by if specified
|
|
88
|
-
if (query.groupBy && query.groupBy.length > 0) {
|
|
89
|
-
const grouped = this.groupMetrics(allMetrics, query.groupBy);
|
|
90
|
-
for (const [group, metrics] of Object.entries(grouped)) {
|
|
91
|
-
const aggregated = this.aggregateMetrics(metrics, query.aggregation || 'avg');
|
|
92
|
-
results[`${metricName}-${group}`] = aggregated;
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
else {
|
|
96
|
-
const aggregated = this.aggregateMetrics(allMetrics, query.aggregation || 'avg');
|
|
97
|
-
results[metricName] = aggregated;
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
return results;
|
|
101
|
-
}
|
|
102
|
-
async createDashboard(dashboardData) {
|
|
103
|
-
const dashboard = {
|
|
104
|
-
id: `dashboard-${Date.now()}-${Math.random().toString(36).substr(2, 9)}`,
|
|
105
|
-
name: dashboardData.name,
|
|
106
|
-
description: dashboardData.description,
|
|
107
|
-
type: dashboardData.type,
|
|
108
|
-
widgets: dashboardData.widgets.map((widget, index) => ({
|
|
109
|
-
id: `widget-${Date.now()}-${index}`,
|
|
110
|
-
...widget,
|
|
111
|
-
})),
|
|
112
|
-
layout: {
|
|
113
|
-
columns: 12,
|
|
114
|
-
rows: 8,
|
|
115
|
-
grid: true,
|
|
116
|
-
responsive: true,
|
|
117
|
-
},
|
|
118
|
-
permissions: {
|
|
119
|
-
viewers: [],
|
|
120
|
-
editors: [],
|
|
121
|
-
public: false,
|
|
122
|
-
...dashboardData.permissions,
|
|
123
|
-
},
|
|
124
|
-
schedule: {
|
|
125
|
-
autoRefresh: true,
|
|
126
|
-
refreshInterval: 30,
|
|
127
|
-
},
|
|
128
|
-
filters: [],
|
|
129
|
-
createdAt: new Date(),
|
|
130
|
-
updatedAt: new Date(),
|
|
131
|
-
createdBy: 'system',
|
|
132
|
-
};
|
|
133
|
-
this.dashboards.set(dashboard.id, dashboard);
|
|
134
|
-
await this.saveDashboard(dashboard);
|
|
135
|
-
this.emit('dashboard:created', dashboard);
|
|
136
|
-
this.logger.info(`Dashboard created: ${dashboard.name} (${dashboard.id})`);
|
|
137
|
-
return dashboard;
|
|
138
|
-
}
|
|
139
|
-
async generateInsights(scope = {}) {
|
|
140
|
-
const insights = [];
|
|
141
|
-
// Default time range: last 24 hours
|
|
142
|
-
const timeRange = scope.timeRange || {
|
|
143
|
-
start: new Date(Date.now() - 24 * 60 * 60 * 1000),
|
|
144
|
-
end: new Date(),
|
|
145
|
-
};
|
|
146
|
-
// Anomaly detection
|
|
147
|
-
const anomalies = await this.detectAnomalies(timeRange, scope.metrics);
|
|
148
|
-
insights.push(...anomalies);
|
|
149
|
-
// Trend analysis
|
|
150
|
-
const trends = await this.analyzeTrends(timeRange, scope.metrics);
|
|
151
|
-
insights.push(...trends);
|
|
152
|
-
// Performance insights
|
|
153
|
-
const performance = await this.analyzePerformance(timeRange);
|
|
154
|
-
insights.push(...performance);
|
|
155
|
-
// Usage insights
|
|
156
|
-
const usage = await this.analyzeUsage(timeRange);
|
|
157
|
-
insights.push(...usage);
|
|
158
|
-
// Cost optimization insights
|
|
159
|
-
const costOptimizations = await this.analyzeCostOptimization(timeRange);
|
|
160
|
-
insights.push(...costOptimizations);
|
|
161
|
-
// Store insights
|
|
162
|
-
for (const insight of insights) {
|
|
163
|
-
this.insights.set(insight.id, insight);
|
|
164
|
-
await this.saveInsight(insight);
|
|
165
|
-
}
|
|
166
|
-
this.emit('insights:generated', { insights, scope });
|
|
167
|
-
this.logger.info(`Generated ${insights.length} insights`);
|
|
168
|
-
return insights;
|
|
169
|
-
}
|
|
170
|
-
async trainPredictiveModel(modelConfig) {
|
|
171
|
-
const model = {
|
|
172
|
-
id: `model-${Date.now()}-${Math.random().toString(36).substr(2, 9)}`,
|
|
173
|
-
name: modelConfig.name,
|
|
174
|
-
description: modelConfig.description,
|
|
175
|
-
type: modelConfig.type,
|
|
176
|
-
algorithm: modelConfig.algorithm,
|
|
177
|
-
features: modelConfig.features,
|
|
178
|
-
target: modelConfig.target,
|
|
179
|
-
accuracy: 0,
|
|
180
|
-
confidence: 0,
|
|
181
|
-
trainedAt: new Date(),
|
|
182
|
-
trainingData: {
|
|
183
|
-
samples: 0,
|
|
184
|
-
features: modelConfig.features.length,
|
|
185
|
-
timeRange: modelConfig.trainingPeriod,
|
|
186
|
-
},
|
|
187
|
-
performance: {
|
|
188
|
-
precision: 0,
|
|
189
|
-
recall: 0,
|
|
190
|
-
f1Score: 0,
|
|
191
|
-
},
|
|
192
|
-
predictions: [],
|
|
193
|
-
status: 'training',
|
|
194
|
-
};
|
|
195
|
-
try {
|
|
196
|
-
// Collect training data
|
|
197
|
-
const trainingData = await this.collectTrainingData(model);
|
|
198
|
-
// Train the model (simplified implementation)
|
|
199
|
-
const trained = await this.executeModelTraining(model, trainingData);
|
|
200
|
-
Object.assign(model, trained);
|
|
201
|
-
model.status = 'ready';
|
|
202
|
-
this.models.set(model.id, model);
|
|
203
|
-
await this.saveModel(model);
|
|
204
|
-
this.emit('model:trained', model);
|
|
205
|
-
this.logger.info(`Predictive model trained: ${model.name} (${model.id}) - Accuracy: ${model.accuracy}%`);
|
|
206
|
-
}
|
|
207
|
-
catch (error) {
|
|
208
|
-
model.status = 'error';
|
|
209
|
-
this.logger.error(`Model training failed: ${model.name}`, { error });
|
|
210
|
-
throw error;
|
|
211
|
-
}
|
|
212
|
-
return model;
|
|
213
|
-
}
|
|
214
|
-
async makePrediction(modelId, input) {
|
|
215
|
-
const model = this.models.get(modelId);
|
|
216
|
-
if (!model) {
|
|
217
|
-
throw new Error(`Model not found: ${modelId}`);
|
|
218
|
-
}
|
|
219
|
-
if (model.status !== 'ready') {
|
|
220
|
-
throw new Error(`Model is not ready for predictions: ${model.status}`);
|
|
221
|
-
}
|
|
222
|
-
// Simple prediction logic (would be replaced with actual ML inference)
|
|
223
|
-
const prediction = await this.executePrediction(model, input);
|
|
224
|
-
const result = {
|
|
225
|
-
id: `prediction-${Date.now()}-${Math.random().toString(36).substr(2, 9)}`,
|
|
226
|
-
modelId,
|
|
227
|
-
input,
|
|
228
|
-
prediction: prediction.value,
|
|
229
|
-
confidence: prediction.confidence,
|
|
230
|
-
timestamp: new Date(),
|
|
231
|
-
};
|
|
232
|
-
model.predictions.push(result);
|
|
233
|
-
model.lastPrediction = new Date();
|
|
234
|
-
await this.saveModel(model);
|
|
235
|
-
this.emit('prediction:made', { model, result });
|
|
236
|
-
this.logger.debug(`Prediction made: ${modelId} - ${JSON.stringify(result.prediction)}`);
|
|
237
|
-
return result;
|
|
238
|
-
}
|
|
239
|
-
async getPerformanceMetrics(timeRange) {
|
|
240
|
-
const range = timeRange || {
|
|
241
|
-
start: new Date(Date.now() - 60 * 60 * 1000), // Last hour
|
|
242
|
-
end: new Date(),
|
|
243
|
-
};
|
|
244
|
-
const systemMetrics = await this.queryMetrics({
|
|
245
|
-
metrics: ['cpu-usage', 'memory-usage', 'disk-usage', 'network-io'],
|
|
246
|
-
timeRange: range,
|
|
247
|
-
aggregation: 'avg',
|
|
248
|
-
});
|
|
249
|
-
const appMetrics = await this.queryMetrics({
|
|
250
|
-
metrics: ['response-time', 'request-rate', 'error-rate', 'uptime'],
|
|
251
|
-
timeRange: range,
|
|
252
|
-
aggregation: 'avg',
|
|
253
|
-
});
|
|
254
|
-
const dbMetrics = await this.queryMetrics({
|
|
255
|
-
metrics: ['db-connections', 'query-time', 'db-size'],
|
|
256
|
-
timeRange: range,
|
|
257
|
-
aggregation: 'avg',
|
|
258
|
-
});
|
|
259
|
-
// Construct performance metrics (simplified)
|
|
260
|
-
return {
|
|
261
|
-
system: {
|
|
262
|
-
cpu: {
|
|
263
|
-
usage: this.getLatestValue(systemMetrics['cpu-usage']) || 0,
|
|
264
|
-
cores: 8, // Would be detected from system
|
|
265
|
-
loadAverage: [1.2, 1.5, 1.8], // Would be collected from system
|
|
266
|
-
},
|
|
267
|
-
memory: {
|
|
268
|
-
used: this.getLatestValue(systemMetrics['memory-usage']) || 0,
|
|
269
|
-
free: 4000000000, // Would be calculated
|
|
270
|
-
total: 8000000000,
|
|
271
|
-
usage: 50,
|
|
272
|
-
},
|
|
273
|
-
disk: {
|
|
274
|
-
used: this.getLatestValue(systemMetrics['disk-usage']) || 0,
|
|
275
|
-
free: 100000000000,
|
|
276
|
-
total: 500000000000,
|
|
277
|
-
usage: 20,
|
|
278
|
-
iops: 1000,
|
|
279
|
-
},
|
|
280
|
-
network: {
|
|
281
|
-
bytesIn: 1000000,
|
|
282
|
-
bytesOut: 2000000,
|
|
283
|
-
packetsIn: 5000,
|
|
284
|
-
packetsOut: 6000,
|
|
285
|
-
errors: 5,
|
|
286
|
-
},
|
|
287
|
-
},
|
|
288
|
-
application: {
|
|
289
|
-
responseTime: {
|
|
290
|
-
avg: this.getLatestValue(appMetrics['response-time']) || 0,
|
|
291
|
-
p50: 150,
|
|
292
|
-
p95: 500,
|
|
293
|
-
p99: 1000,
|
|
294
|
-
},
|
|
295
|
-
throughput: {
|
|
296
|
-
requestsPerSecond: this.getLatestValue(appMetrics['request-rate']) || 0,
|
|
297
|
-
transactionsPerSecond: 50,
|
|
298
|
-
},
|
|
299
|
-
errors: {
|
|
300
|
-
rate: this.getLatestValue(appMetrics['error-rate']) || 0,
|
|
301
|
-
count: 10,
|
|
302
|
-
types: { '500': 5, '404': 3, '400': 2 },
|
|
303
|
-
},
|
|
304
|
-
availability: {
|
|
305
|
-
uptime: this.getLatestValue(appMetrics['uptime']) || 0,
|
|
306
|
-
sla: 99.9,
|
|
307
|
-
incidents: 2,
|
|
308
|
-
},
|
|
309
|
-
},
|
|
310
|
-
database: {
|
|
311
|
-
connections: {
|
|
312
|
-
active: 25,
|
|
313
|
-
idle: 75,
|
|
314
|
-
max: 100,
|
|
315
|
-
},
|
|
316
|
-
queries: {
|
|
317
|
-
avgExecutionTime: this.getLatestValue(dbMetrics['query-time']) || 0,
|
|
318
|
-
slowQueries: 5,
|
|
319
|
-
deadlocks: 0,
|
|
320
|
-
},
|
|
321
|
-
storage: {
|
|
322
|
-
size: this.getLatestValue(dbMetrics['db-size']) || 0,
|
|
323
|
-
growth: 1000000, // bytes per day
|
|
324
|
-
fragmentation: 5,
|
|
325
|
-
},
|
|
326
|
-
},
|
|
327
|
-
infrastructure: {
|
|
328
|
-
containers: {
|
|
329
|
-
running: 12,
|
|
330
|
-
stopped: 2,
|
|
331
|
-
restarts: 3,
|
|
332
|
-
},
|
|
333
|
-
services: {
|
|
334
|
-
healthy: 15,
|
|
335
|
-
unhealthy: 1,
|
|
336
|
-
degraded: 0,
|
|
337
|
-
},
|
|
338
|
-
},
|
|
339
|
-
};
|
|
340
|
-
}
|
|
341
|
-
async getUsageMetrics(timeRange) {
|
|
342
|
-
const range = timeRange || {
|
|
343
|
-
start: new Date(Date.now() - 24 * 60 * 60 * 1000), // Last 24 hours
|
|
344
|
-
end: new Date(),
|
|
345
|
-
};
|
|
346
|
-
const usageData = await this.queryMetrics({
|
|
347
|
-
metrics: ['active-users', 'sessions', 'api-calls', 'feature-usage'],
|
|
348
|
-
timeRange: range,
|
|
349
|
-
aggregation: 'sum',
|
|
350
|
-
});
|
|
351
|
-
return {
|
|
352
|
-
users: {
|
|
353
|
-
total: 10000,
|
|
354
|
-
active: this.getLatestValue(usageData['active-users']) || 0,
|
|
355
|
-
new: 50,
|
|
356
|
-
returning: 1500,
|
|
357
|
-
churn: 25,
|
|
358
|
-
},
|
|
359
|
-
sessions: {
|
|
360
|
-
total: this.getLatestValue(usageData['sessions']) || 0,
|
|
361
|
-
duration: {
|
|
362
|
-
avg: 15 * 60, // 15 minutes
|
|
363
|
-
median: 12 * 60,
|
|
364
|
-
},
|
|
365
|
-
bounceRate: 25,
|
|
366
|
-
pagesPerSession: 4.5,
|
|
367
|
-
},
|
|
368
|
-
features: {
|
|
369
|
-
adoption: {
|
|
370
|
-
dashboard: { users: 800, usage: 5000, retention: 85 },
|
|
371
|
-
reports: { users: 600, usage: 2000, retention: 70 },
|
|
372
|
-
analytics: { users: 400, usage: 1500, retention: 60 },
|
|
373
|
-
},
|
|
374
|
-
mostUsed: ['dashboard', 'reports', 'search'],
|
|
375
|
-
leastUsed: ['advanced-filters', 'export', 'integrations'],
|
|
376
|
-
},
|
|
377
|
-
api: {
|
|
378
|
-
calls: this.getLatestValue(usageData['api-calls']) || 0,
|
|
379
|
-
uniqueConsumers: 150,
|
|
380
|
-
avgResponseTime: 250,
|
|
381
|
-
errorRate: 2.5,
|
|
382
|
-
rateLimits: {
|
|
383
|
-
hit: 5,
|
|
384
|
-
consumed: 75,
|
|
385
|
-
},
|
|
386
|
-
},
|
|
387
|
-
content: {
|
|
388
|
-
created: 100,
|
|
389
|
-
modified: 250,
|
|
390
|
-
deleted: 25,
|
|
391
|
-
views: 5000,
|
|
392
|
-
},
|
|
393
|
-
};
|
|
394
|
-
}
|
|
395
|
-
async getBusinessMetrics(timeRange) {
|
|
396
|
-
// This would integrate with business systems (CRM, billing, etc.)
|
|
397
|
-
return {
|
|
398
|
-
revenue: {
|
|
399
|
-
total: 1000000,
|
|
400
|
-
recurring: 800000,
|
|
401
|
-
growth: 15,
|
|
402
|
-
arpu: 100,
|
|
403
|
-
ltv: 2400,
|
|
404
|
-
},
|
|
405
|
-
customers: {
|
|
406
|
-
total: 500,
|
|
407
|
-
new: 25,
|
|
408
|
-
retained: 450,
|
|
409
|
-
churned: 10,
|
|
410
|
-
satisfaction: 4.2,
|
|
411
|
-
},
|
|
412
|
-
conversion: {
|
|
413
|
-
leads: 1000,
|
|
414
|
-
qualified: 400,
|
|
415
|
-
opportunities: 200,
|
|
416
|
-
closed: 50,
|
|
417
|
-
rate: 5,
|
|
418
|
-
},
|
|
419
|
-
support: {
|
|
420
|
-
tickets: 150,
|
|
421
|
-
resolved: 140,
|
|
422
|
-
avgResolutionTime: 4 * 60 * 60, // 4 hours
|
|
423
|
-
satisfaction: 4.5,
|
|
424
|
-
},
|
|
425
|
-
};
|
|
426
|
-
}
|
|
427
|
-
// Private helper methods
|
|
428
|
-
getDefaultConfiguration() {
|
|
429
|
-
return {
|
|
430
|
-
collection: {
|
|
431
|
-
enabled: true,
|
|
432
|
-
samplingRate: 1.0,
|
|
433
|
-
batchSize: 1000,
|
|
434
|
-
flushInterval: 60000,
|
|
435
|
-
},
|
|
436
|
-
storage: {
|
|
437
|
-
retention: {
|
|
438
|
-
raw: '7d',
|
|
439
|
-
aggregated: '90d',
|
|
440
|
-
summary: '1y',
|
|
441
|
-
},
|
|
442
|
-
compression: true,
|
|
443
|
-
encryption: false,
|
|
444
|
-
},
|
|
445
|
-
processing: {
|
|
446
|
-
realTime: true,
|
|
447
|
-
batchProcessing: true,
|
|
448
|
-
aggregationIntervals: ['1m', '5m', '1h', '1d'],
|
|
449
|
-
},
|
|
450
|
-
alerts: {
|
|
451
|
-
enabled: true,
|
|
452
|
-
channels: ['email', 'slack'],
|
|
453
|
-
escalation: {
|
|
454
|
-
levels: 3,
|
|
455
|
-
intervals: [5, 15, 30], // minutes
|
|
456
|
-
},
|
|
457
|
-
},
|
|
458
|
-
privacy: {
|
|
459
|
-
anonymization: true,
|
|
460
|
-
gdprCompliant: true,
|
|
461
|
-
dataMinimization: true,
|
|
462
|
-
},
|
|
463
|
-
integrations: {},
|
|
464
|
-
};
|
|
465
|
-
}
|
|
466
|
-
async loadConfigurations() {
|
|
467
|
-
try {
|
|
468
|
-
// Load dashboards
|
|
469
|
-
const dashboardFiles = await readdir(join(this.analyticsPath, 'dashboards'));
|
|
470
|
-
for (const file of dashboardFiles.filter((f) => f.endsWith('.json'))) {
|
|
471
|
-
const content = await readFile(join(this.analyticsPath, 'dashboards', file), 'utf-8');
|
|
472
|
-
const dashboard = JSON.parse(content);
|
|
473
|
-
this.dashboards.set(dashboard.id, dashboard);
|
|
474
|
-
}
|
|
475
|
-
// Load insights
|
|
476
|
-
const insightFiles = await readdir(join(this.analyticsPath, 'insights'));
|
|
477
|
-
for (const file of insightFiles.filter((f) => f.endsWith('.json'))) {
|
|
478
|
-
const content = await readFile(join(this.analyticsPath, 'insights', file), 'utf-8');
|
|
479
|
-
const insight = JSON.parse(content);
|
|
480
|
-
this.insights.set(insight.id, insight);
|
|
481
|
-
}
|
|
482
|
-
// Load models
|
|
483
|
-
const modelFiles = await readdir(join(this.analyticsPath, 'models'));
|
|
484
|
-
for (const file of modelFiles.filter((f) => f.endsWith('.json'))) {
|
|
485
|
-
const content = await readFile(join(this.analyticsPath, 'models', file), 'utf-8');
|
|
486
|
-
const model = JSON.parse(content);
|
|
487
|
-
this.models.set(model.id, model);
|
|
488
|
-
}
|
|
489
|
-
this.logger.info(`Loaded ${this.dashboards.size} dashboards, ${this.insights.size} insights, ${this.models.size} models`);
|
|
490
|
-
}
|
|
491
|
-
catch (error) {
|
|
492
|
-
this.logger.warn('Failed to load some analytics configurations', { error });
|
|
493
|
-
}
|
|
494
|
-
}
|
|
495
|
-
async initializeDefaultDashboards() {
|
|
496
|
-
const defaultDashboards = [
|
|
497
|
-
{
|
|
498
|
-
name: 'System Performance',
|
|
499
|
-
description: 'Real-time system performance metrics',
|
|
500
|
-
type: 'operational',
|
|
501
|
-
widgets: [
|
|
502
|
-
{
|
|
503
|
-
title: 'CPU Usage',
|
|
504
|
-
type: 'gauge',
|
|
505
|
-
size: 'medium',
|
|
506
|
-
position: { x: 0, y: 0, width: 6, height: 3 },
|
|
507
|
-
dataSource: {
|
|
508
|
-
query: 'cpu-usage',
|
|
509
|
-
metrics: ['cpu-usage'],
|
|
510
|
-
aggregation: 'avg',
|
|
511
|
-
timeRange: '1h',
|
|
512
|
-
groupBy: [],
|
|
513
|
-
},
|
|
514
|
-
visualization: {
|
|
515
|
-
chartType: 'gauge',
|
|
516
|
-
options: { max: 100, unit: '%' },
|
|
517
|
-
thresholds: { warning: 70, critical: 90 },
|
|
518
|
-
},
|
|
519
|
-
alerts: { enabled: true, conditions: [] },
|
|
520
|
-
},
|
|
521
|
-
{
|
|
522
|
-
title: 'Memory Usage',
|
|
523
|
-
type: 'gauge',
|
|
524
|
-
size: 'medium',
|
|
525
|
-
position: { x: 6, y: 0, width: 6, height: 3 },
|
|
526
|
-
dataSource: {
|
|
527
|
-
query: 'memory-usage',
|
|
528
|
-
metrics: ['memory-usage'],
|
|
529
|
-
aggregation: 'avg',
|
|
530
|
-
timeRange: '1h',
|
|
531
|
-
groupBy: [],
|
|
532
|
-
},
|
|
533
|
-
visualization: {
|
|
534
|
-
chartType: 'gauge',
|
|
535
|
-
options: { max: 100, unit: '%' },
|
|
536
|
-
thresholds: { warning: 80, critical: 95 },
|
|
537
|
-
},
|
|
538
|
-
alerts: { enabled: true, conditions: [] },
|
|
539
|
-
},
|
|
540
|
-
{
|
|
541
|
-
title: 'Response Time',
|
|
542
|
-
type: 'chart',
|
|
543
|
-
size: 'large',
|
|
544
|
-
position: { x: 0, y: 3, width: 12, height: 4 },
|
|
545
|
-
dataSource: {
|
|
546
|
-
query: 'response-time',
|
|
547
|
-
metrics: ['response-time'],
|
|
548
|
-
aggregation: 'avg',
|
|
549
|
-
timeRange: '24h',
|
|
550
|
-
groupBy: ['service'],
|
|
551
|
-
},
|
|
552
|
-
visualization: {
|
|
553
|
-
chartType: 'line',
|
|
554
|
-
options: { unit: 'ms' },
|
|
555
|
-
},
|
|
556
|
-
alerts: { enabled: false, conditions: [] },
|
|
557
|
-
},
|
|
558
|
-
],
|
|
559
|
-
},
|
|
560
|
-
{
|
|
561
|
-
name: 'Business KPIs',
|
|
562
|
-
description: 'Key business performance indicators',
|
|
563
|
-
type: 'executive',
|
|
564
|
-
widgets: [
|
|
565
|
-
{
|
|
566
|
-
title: 'Active Users',
|
|
567
|
-
type: 'metric',
|
|
568
|
-
size: 'small',
|
|
569
|
-
position: { x: 0, y: 0, width: 3, height: 2 },
|
|
570
|
-
dataSource: {
|
|
571
|
-
query: 'active-users',
|
|
572
|
-
metrics: ['active-users'],
|
|
573
|
-
aggregation: 'count',
|
|
574
|
-
timeRange: '24h',
|
|
575
|
-
groupBy: [],
|
|
576
|
-
},
|
|
577
|
-
visualization: {
|
|
578
|
-
options: { unit: 'users' },
|
|
579
|
-
},
|
|
580
|
-
alerts: { enabled: false, conditions: [] },
|
|
581
|
-
},
|
|
582
|
-
],
|
|
583
|
-
},
|
|
584
|
-
];
|
|
585
|
-
for (const dashboardData of defaultDashboards) {
|
|
586
|
-
if (!Array.from(this.dashboards.values()).some((d) => d.name === dashboardData.name)) {
|
|
587
|
-
await this.createDashboard(dashboardData);
|
|
588
|
-
}
|
|
589
|
-
}
|
|
590
|
-
}
|
|
591
|
-
async startMetricsCollection() {
|
|
592
|
-
// Start collecting system metrics
|
|
593
|
-
setInterval(async () => {
|
|
594
|
-
await this.collectSystemMetrics();
|
|
595
|
-
}, 60000); // Every minute
|
|
596
|
-
// Start collecting application metrics
|
|
597
|
-
setInterval(async () => {
|
|
598
|
-
await this.collectApplicationMetrics();
|
|
599
|
-
}, 30000); // Every 30 seconds
|
|
600
|
-
this.logger.info('Started automatic metrics collection');
|
|
601
|
-
}
|
|
602
|
-
async collectSystemMetrics() {
|
|
603
|
-
try {
|
|
604
|
-
// Mock system metrics collection
|
|
605
|
-
await this.recordMetric({
|
|
606
|
-
name: 'cpu-usage',
|
|
607
|
-
description: 'CPU usage percentage',
|
|
608
|
-
type: 'gauge',
|
|
609
|
-
category: 'performance',
|
|
610
|
-
unit: 'percent',
|
|
611
|
-
value: Math.random() * 100,
|
|
612
|
-
tags: { host: 'localhost', service: 'system' },
|
|
613
|
-
source: 'system-monitor',
|
|
614
|
-
metadata: {},
|
|
615
|
-
});
|
|
616
|
-
await this.recordMetric({
|
|
617
|
-
name: 'memory-usage',
|
|
618
|
-
description: 'Memory usage percentage',
|
|
619
|
-
type: 'gauge',
|
|
620
|
-
category: 'performance',
|
|
621
|
-
unit: 'percent',
|
|
622
|
-
value: Math.random() * 100,
|
|
623
|
-
tags: { host: 'localhost', service: 'system' },
|
|
624
|
-
source: 'system-monitor',
|
|
625
|
-
metadata: {},
|
|
626
|
-
});
|
|
627
|
-
await this.recordMetric({
|
|
628
|
-
name: 'disk-usage',
|
|
629
|
-
description: 'Disk usage percentage',
|
|
630
|
-
type: 'gauge',
|
|
631
|
-
category: 'performance',
|
|
632
|
-
unit: 'percent',
|
|
633
|
-
value: Math.random() * 100,
|
|
634
|
-
tags: { host: 'localhost', service: 'system' },
|
|
635
|
-
source: 'system-monitor',
|
|
636
|
-
metadata: {},
|
|
637
|
-
});
|
|
638
|
-
}
|
|
639
|
-
catch (error) {
|
|
640
|
-
this.logger.error('Failed to collect system metrics', { error });
|
|
641
|
-
}
|
|
642
|
-
}
|
|
643
|
-
async collectApplicationMetrics() {
|
|
644
|
-
try {
|
|
645
|
-
// Mock application metrics collection
|
|
646
|
-
await this.recordMetric({
|
|
647
|
-
name: 'response-time',
|
|
648
|
-
description: 'Average response time',
|
|
649
|
-
type: 'gauge',
|
|
650
|
-
category: 'performance',
|
|
651
|
-
unit: 'milliseconds',
|
|
652
|
-
value: Math.random() * 1000 + 100,
|
|
653
|
-
tags: { service: 'api', endpoint: '/users' },
|
|
654
|
-
source: 'application',
|
|
655
|
-
metadata: {},
|
|
656
|
-
});
|
|
657
|
-
await this.recordMetric({
|
|
658
|
-
name: 'request-rate',
|
|
659
|
-
description: 'Requests per second',
|
|
660
|
-
type: 'counter',
|
|
661
|
-
category: 'usage',
|
|
662
|
-
unit: 'requests/sec',
|
|
663
|
-
value: Math.random() * 100 + 10,
|
|
664
|
-
tags: { service: 'api' },
|
|
665
|
-
source: 'application',
|
|
666
|
-
metadata: {},
|
|
667
|
-
});
|
|
668
|
-
await this.recordMetric({
|
|
669
|
-
name: 'error-rate',
|
|
670
|
-
description: 'Error rate percentage',
|
|
671
|
-
type: 'gauge',
|
|
672
|
-
category: 'performance',
|
|
673
|
-
unit: 'percent',
|
|
674
|
-
value: Math.random() * 5,
|
|
675
|
-
tags: { service: 'api' },
|
|
676
|
-
source: 'application',
|
|
677
|
-
metadata: {},
|
|
678
|
-
});
|
|
679
|
-
}
|
|
680
|
-
catch (error) {
|
|
681
|
-
this.logger.error('Failed to collect application metrics', { error });
|
|
682
|
-
}
|
|
683
|
-
}
|
|
684
|
-
async persistMetric(metric) {
|
|
685
|
-
const date = metric.timestamp.toISOString().split('T')[0];
|
|
686
|
-
const filePath = join(this.analyticsPath, 'metrics', `${date}.json`);
|
|
687
|
-
try {
|
|
688
|
-
let existingData = [];
|
|
689
|
-
try {
|
|
690
|
-
const content = await readFile(filePath, 'utf-8');
|
|
691
|
-
existingData = JSON.parse(content);
|
|
692
|
-
}
|
|
693
|
-
catch {
|
|
694
|
-
// File doesn't exist yet
|
|
695
|
-
}
|
|
696
|
-
existingData.push(metric);
|
|
697
|
-
await writeFile(filePath, JSON.stringify(existingData, null, 2));
|
|
698
|
-
}
|
|
699
|
-
catch (error) {
|
|
700
|
-
this.logger.error('Failed to persist metric', { error, metric: metric.id });
|
|
701
|
-
}
|
|
702
|
-
}
|
|
703
|
-
async checkForAnomalies(metricKey, metric) {
|
|
704
|
-
const historical = this.metrics.get(metricKey) || [];
|
|
705
|
-
if (historical.length < 10)
|
|
706
|
-
return; // Need enough data for baseline
|
|
707
|
-
const recent = historical.slice(-10);
|
|
708
|
-
const average = recent.reduce((sum, m) => sum + m.value, 0) / recent.length;
|
|
709
|
-
const stdDev = Math.sqrt(recent.reduce((sum, m) => sum + Math.pow(m.value - average, 2), 0) / recent.length);
|
|
710
|
-
const threshold = 2; // 2 standard deviations
|
|
711
|
-
const deviation = Math.abs(metric.value - average) / stdDev;
|
|
712
|
-
if (deviation > threshold) {
|
|
713
|
-
const insight = {
|
|
714
|
-
id: `insight-${Date.now()}-${Math.random().toString(36).substr(2, 9)}`,
|
|
715
|
-
title: `Anomaly detected in ${metric.name}`,
|
|
716
|
-
description: `The metric ${metric.name} has deviated significantly from its normal pattern`,
|
|
717
|
-
type: 'anomaly',
|
|
718
|
-
category: metric.category,
|
|
719
|
-
confidence: Math.min(95, deviation * 20),
|
|
720
|
-
impact: deviation > 3 ? 'high' : 'medium',
|
|
721
|
-
priority: deviation > 3 ? 'high' : 'medium',
|
|
722
|
-
data: {
|
|
723
|
-
metrics: [metric.name],
|
|
724
|
-
timeRange: { start: recent[0].timestamp, end: metric.timestamp },
|
|
725
|
-
values: { current: metric.value, average, stdDev },
|
|
726
|
-
baseline: { average, stdDev },
|
|
727
|
-
deviation,
|
|
728
|
-
},
|
|
729
|
-
recommendations: [
|
|
730
|
-
{
|
|
731
|
-
action: 'Investigate the cause of the anomaly',
|
|
732
|
-
effort: 'medium',
|
|
733
|
-
impact: 'Identify potential issues before they become critical',
|
|
734
|
-
implementation: [
|
|
735
|
-
'Check recent deployments or configuration changes',
|
|
736
|
-
'Review system logs for errors or warnings',
|
|
737
|
-
'Monitor related metrics for correlation',
|
|
738
|
-
],
|
|
739
|
-
},
|
|
740
|
-
],
|
|
741
|
-
status: 'new',
|
|
742
|
-
createdAt: new Date(),
|
|
743
|
-
updatedAt: new Date(),
|
|
744
|
-
};
|
|
745
|
-
this.insights.set(insight.id, insight);
|
|
746
|
-
await this.saveInsight(insight);
|
|
747
|
-
this.emit('anomaly:detected', { metric, insight, deviation });
|
|
748
|
-
this.logger.warn(`Anomaly detected in ${metric.name}`, {
|
|
749
|
-
current: metric.value,
|
|
750
|
-
average,
|
|
751
|
-
deviation,
|
|
752
|
-
});
|
|
753
|
-
}
|
|
754
|
-
}
|
|
755
|
-
async detectAnomalies(timeRange, metrics) {
|
|
756
|
-
// Simplified anomaly detection
|
|
757
|
-
return [];
|
|
758
|
-
}
|
|
759
|
-
async analyzeTrends(timeRange, metrics) {
|
|
760
|
-
// Simplified trend analysis
|
|
761
|
-
return [];
|
|
762
|
-
}
|
|
763
|
-
async analyzePerformance(timeRange) {
|
|
764
|
-
const insights = [];
|
|
765
|
-
// Check response time trends
|
|
766
|
-
const responseTimeData = await this.queryMetrics({
|
|
767
|
-
metrics: ['response-time'],
|
|
768
|
-
timeRange,
|
|
769
|
-
aggregation: 'avg',
|
|
770
|
-
});
|
|
771
|
-
if (responseTimeData['response-time']?.length > 0) {
|
|
772
|
-
const values = responseTimeData['response-time'].map((d) => d.value);
|
|
773
|
-
const recent = values.slice(-5);
|
|
774
|
-
const earlier = values.slice(0, -5);
|
|
775
|
-
if (recent.length > 0 && earlier.length > 0) {
|
|
776
|
-
const recentAvg = recent.reduce((sum, v) => sum + v, 0) / recent.length;
|
|
777
|
-
const earlierAvg = earlier.reduce((sum, v) => sum + v, 0) / earlier.length;
|
|
778
|
-
const change = ((recentAvg - earlierAvg) / earlierAvg) * 100;
|
|
779
|
-
if (Math.abs(change) > 20) {
|
|
780
|
-
insights.push({
|
|
781
|
-
id: `perf-insight-${Date.now()}`,
|
|
782
|
-
title: `Response time ${change > 0 ? 'increased' : 'decreased'} by ${Math.abs(change).toFixed(1)}%`,
|
|
783
|
-
description: `Response time has changed significantly in the recent period`,
|
|
784
|
-
type: 'trend',
|
|
785
|
-
category: 'performance',
|
|
786
|
-
confidence: 80,
|
|
787
|
-
impact: Math.abs(change) > 50 ? 'high' : 'medium',
|
|
788
|
-
priority: Math.abs(change) > 50 ? 'high' : 'medium',
|
|
789
|
-
data: {
|
|
790
|
-
metrics: ['response-time'],
|
|
791
|
-
timeRange,
|
|
792
|
-
values: { recent: recentAvg, earlier: earlierAvg, change },
|
|
793
|
-
},
|
|
794
|
-
recommendations: change > 0
|
|
795
|
-
? [
|
|
796
|
-
{
|
|
797
|
-
action: 'Investigate performance degradation',
|
|
798
|
-
effort: 'medium',
|
|
799
|
-
impact: 'Restore optimal response times',
|
|
800
|
-
implementation: [
|
|
801
|
-
'Check for increased load or traffic',
|
|
802
|
-
'Review recent code deployments',
|
|
803
|
-
'Analyze database query performance',
|
|
804
|
-
'Monitor resource utilization',
|
|
805
|
-
],
|
|
806
|
-
},
|
|
807
|
-
]
|
|
808
|
-
: [
|
|
809
|
-
{
|
|
810
|
-
action: 'Document performance improvement',
|
|
811
|
-
effort: 'low',
|
|
812
|
-
impact: 'Understand what caused the improvement',
|
|
813
|
-
implementation: [
|
|
814
|
-
'Identify recent optimizations',
|
|
815
|
-
'Document best practices',
|
|
816
|
-
'Monitor sustainability',
|
|
817
|
-
],
|
|
818
|
-
},
|
|
819
|
-
],
|
|
820
|
-
status: 'new',
|
|
821
|
-
createdAt: new Date(),
|
|
822
|
-
updatedAt: new Date(),
|
|
823
|
-
});
|
|
824
|
-
}
|
|
825
|
-
}
|
|
826
|
-
}
|
|
827
|
-
return insights;
|
|
828
|
-
}
|
|
829
|
-
async analyzeUsage(timeRange) {
|
|
830
|
-
// Simplified usage analysis
|
|
831
|
-
return [];
|
|
832
|
-
}
|
|
833
|
-
async analyzeCostOptimization(timeRange) {
|
|
834
|
-
// Simplified cost optimization analysis
|
|
835
|
-
return [];
|
|
836
|
-
}
|
|
837
|
-
async collectTrainingData(model) {
|
|
838
|
-
// Collect historical data for training
|
|
839
|
-
const data = await this.queryMetrics({
|
|
840
|
-
metrics: model.features,
|
|
841
|
-
timeRange: model.trainingData.timeRange,
|
|
842
|
-
aggregation: 'avg',
|
|
843
|
-
});
|
|
844
|
-
// Transform data for ML training (simplified)
|
|
845
|
-
return Object.values(data).flat();
|
|
846
|
-
}
|
|
847
|
-
async executeModelTraining(model, data) {
|
|
848
|
-
// Simplified model training
|
|
849
|
-
return {
|
|
850
|
-
accuracy: 85 + Math.random() * 10,
|
|
851
|
-
confidence: 80 + Math.random() * 15,
|
|
852
|
-
performance: {
|
|
853
|
-
precision: 0.85,
|
|
854
|
-
recall: 0.82,
|
|
855
|
-
f1Score: 0.83,
|
|
856
|
-
},
|
|
857
|
-
trainingData: {
|
|
858
|
-
...model.trainingData,
|
|
859
|
-
samples: data.length,
|
|
860
|
-
},
|
|
861
|
-
};
|
|
862
|
-
}
|
|
863
|
-
async executePrediction(model, input) {
|
|
864
|
-
// Simplified prediction logic
|
|
865
|
-
const value = Math.random() * 100;
|
|
866
|
-
const confidence = 70 + Math.random() * 25;
|
|
867
|
-
return { value, confidence };
|
|
868
|
-
}
|
|
869
|
-
groupMetrics(metrics, groupBy) {
|
|
870
|
-
const groups = {};
|
|
871
|
-
for (const metric of metrics) {
|
|
872
|
-
const key = groupBy
|
|
873
|
-
.map((field) => {
|
|
874
|
-
if (field === 'tags') {
|
|
875
|
-
return Object.entries(metric.tags)
|
|
876
|
-
.map(([k, v]) => `${k}:${v}`)
|
|
877
|
-
.join(',');
|
|
878
|
-
}
|
|
879
|
-
return metric[field] || 'unknown';
|
|
880
|
-
})
|
|
881
|
-
.join('-');
|
|
882
|
-
if (!groups[key]) {
|
|
883
|
-
groups[key] = [];
|
|
884
|
-
}
|
|
885
|
-
groups[key].push(metric);
|
|
886
|
-
}
|
|
887
|
-
return groups;
|
|
888
|
-
}
|
|
889
|
-
aggregateMetrics(metrics, aggregation) {
|
|
890
|
-
if (metrics.length === 0)
|
|
891
|
-
return [];
|
|
892
|
-
// Group by time buckets for time series aggregation
|
|
893
|
-
const buckets = {};
|
|
894
|
-
for (const metric of metrics) {
|
|
895
|
-
const bucket = new Date(Math.floor(metric.timestamp.getTime() / 60000) * 60000).toISOString();
|
|
896
|
-
if (!buckets[bucket]) {
|
|
897
|
-
buckets[bucket] = [];
|
|
898
|
-
}
|
|
899
|
-
buckets[bucket].push(metric);
|
|
900
|
-
}
|
|
901
|
-
return Object.entries(buckets)
|
|
902
|
-
.map(([timestamp, bucketMetrics]) => {
|
|
903
|
-
const values = bucketMetrics.map((m) => m.value);
|
|
904
|
-
let aggregatedValue;
|
|
905
|
-
switch (aggregation) {
|
|
906
|
-
case 'sum':
|
|
907
|
-
aggregatedValue = values.reduce((sum, v) => sum + v, 0);
|
|
908
|
-
break;
|
|
909
|
-
case 'min':
|
|
910
|
-
aggregatedValue = Math.min(...values);
|
|
911
|
-
break;
|
|
912
|
-
case 'max':
|
|
913
|
-
aggregatedValue = Math.max(...values);
|
|
914
|
-
break;
|
|
915
|
-
case 'count':
|
|
916
|
-
aggregatedValue = values.length;
|
|
917
|
-
break;
|
|
918
|
-
case 'p95':
|
|
919
|
-
values.sort((a, b) => a - b);
|
|
920
|
-
aggregatedValue = values[Math.floor(values.length * 0.95)];
|
|
921
|
-
break;
|
|
922
|
-
case 'p99':
|
|
923
|
-
values.sort((a, b) => a - b);
|
|
924
|
-
aggregatedValue = values[Math.floor(values.length * 0.99)];
|
|
925
|
-
break;
|
|
926
|
-
case 'avg':
|
|
927
|
-
default:
|
|
928
|
-
aggregatedValue = values.reduce((sum, v) => sum + v, 0) / values.length;
|
|
929
|
-
}
|
|
930
|
-
return {
|
|
931
|
-
timestamp: new Date(timestamp),
|
|
932
|
-
value: aggregatedValue,
|
|
933
|
-
count: values.length,
|
|
934
|
-
};
|
|
935
|
-
})
|
|
936
|
-
.sort((a, b) => a.timestamp.getTime() - b.timestamp.getTime());
|
|
937
|
-
}
|
|
938
|
-
getLatestValue(dataPoints) {
|
|
939
|
-
if (!dataPoints || dataPoints.length === 0)
|
|
940
|
-
return 0;
|
|
941
|
-
return dataPoints[dataPoints.length - 1]?.value || 0;
|
|
942
|
-
}
|
|
943
|
-
async saveDashboard(dashboard) {
|
|
944
|
-
const filePath = join(this.analyticsPath, 'dashboards', `${dashboard.id}.json`);
|
|
945
|
-
await writeFile(filePath, JSON.stringify(dashboard, null, 2));
|
|
946
|
-
}
|
|
947
|
-
async saveInsight(insight) {
|
|
948
|
-
const filePath = join(this.analyticsPath, 'insights', `${insight.id}.json`);
|
|
949
|
-
await writeFile(filePath, JSON.stringify(insight, null, 2));
|
|
950
|
-
}
|
|
951
|
-
async saveModel(model) {
|
|
952
|
-
const filePath = join(this.analyticsPath, 'models', `${model.id}.json`);
|
|
953
|
-
await writeFile(filePath, JSON.stringify(model, null, 2));
|
|
954
|
-
}
|
|
955
|
-
}
|
|
956
|
-
//# sourceMappingURL=analytics-manager.js.map
|