monomind 1.10.0 → 1.10.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/monomind.js +50 -0
- package/package.json +11 -71
- package/.claude/agents/academic/academic-anthropologist.md +0 -126
- package/.claude/agents/academic/academic-geographer.md +0 -128
- package/.claude/agents/academic/academic-historian.md +0 -124
- package/.claude/agents/academic/academic-narratologist.md +0 -119
- package/.claude/agents/academic/academic-psychologist.md +0 -119
- package/.claude/agents/analysis/analyze-code-quality.md +0 -58
- package/.claude/agents/analysis/code-analyzer.md +0 -189
- package/.claude/agents/analysis/code-review/analyze-code-quality.md +0 -58
- package/.claude/agents/architecture/system-design/arch-system-design.md +0 -54
- package/.claude/agents/consensus/crdt-synchronizer.md +0 -977
- package/.claude/agents/consensus/performance-benchmarker.md +0 -831
- package/.claude/agents/consensus/quorum-manager.md +0 -803
- package/.claude/agents/consensus/security-manager.md +0 -602
- package/.claude/agents/core/coder.md +0 -262
- package/.claude/agents/core/planner.md +0 -170
- package/.claude/agents/core/researcher.md +0 -192
- package/.claude/agents/core/reviewer.md +0 -327
- package/.claude/agents/core/tester.md +0 -318
- package/.claude/agents/data/ml/data-ml-model.md +0 -76
- package/.claude/agents/design/design-monodesign.md +0 -121
- package/.claude/agents/development/dev-backend-api.md +0 -178
- package/.claude/agents/devops/ci-cd/ops-cicd-github.md +0 -52
- package/.claude/agents/documentation/api-docs/docs-api-openapi.md +0 -63
- package/.claude/agents/engineering/engineering-ai-data-remediation-engineer.md +0 -212
- package/.claude/agents/engineering/engineering-ai-engineer.md +0 -165
- package/.claude/agents/engineering/engineering-autonomous-optimization-architect.md +0 -108
- package/.claude/agents/engineering/engineering-backend-architect.md +0 -254
- package/.claude/agents/engineering/engineering-code-reviewer.md +0 -95
- package/.claude/agents/engineering/engineering-data-engineer.md +0 -307
- package/.claude/agents/engineering/engineering-database-optimizer.md +0 -200
- package/.claude/agents/engineering/engineering-devops-automator.md +0 -430
- package/.claude/agents/engineering/engineering-embedded-firmware-engineer.md +0 -174
- package/.claude/agents/engineering/engineering-feishu-integration-developer.md +0 -607
- package/.claude/agents/engineering/engineering-frontend-developer.md +0 -249
- package/.claude/agents/engineering/engineering-git-workflow-master.md +0 -108
- package/.claude/agents/engineering/engineering-incident-response-commander.md +0 -482
- package/.claude/agents/engineering/engineering-mobile-app-builder.md +0 -499
- package/.claude/agents/engineering/engineering-rapid-prototyper.md +0 -463
- package/.claude/agents/engineering/engineering-security-engineer.md +0 -303
- package/.claude/agents/engineering/engineering-senior-developer.md +0 -195
- package/.claude/agents/engineering/engineering-software-architect.md +0 -100
- package/.claude/agents/engineering/engineering-solidity-smart-contract-engineer.md +0 -528
- package/.claude/agents/engineering/engineering-sre.md +0 -114
- package/.claude/agents/engineering/engineering-technical-writer.md +0 -412
- package/.claude/agents/engineering/engineering-threat-detection-engineer.md +0 -540
- package/.claude/agents/engineering/engineering-wechat-mini-program-developer.md +0 -351
- package/.claude/agents/game-development/blender/blender-addon-engineer.md +0 -235
- package/.claude/agents/game-development/game-audio-engineer.md +0 -265
- package/.claude/agents/game-development/game-designer.md +0 -168
- package/.claude/agents/game-development/godot/godot-gameplay-scripter.md +0 -335
- package/.claude/agents/game-development/godot/godot-multiplayer-engineer.md +0 -298
- package/.claude/agents/game-development/godot/godot-shader-developer.md +0 -267
- package/.claude/agents/game-development/level-designer.md +0 -209
- package/.claude/agents/game-development/narrative-designer.md +0 -244
- package/.claude/agents/game-development/roblox-studio/roblox-avatar-creator.md +0 -298
- package/.claude/agents/game-development/roblox-studio/roblox-experience-designer.md +0 -306
- package/.claude/agents/game-development/roblox-studio/roblox-systems-scripter.md +0 -326
- package/.claude/agents/game-development/technical-artist.md +0 -230
- package/.claude/agents/game-development/unity/unity-architect.md +0 -272
- package/.claude/agents/game-development/unity/unity-editor-tool-developer.md +0 -311
- package/.claude/agents/game-development/unity/unity-multiplayer-engineer.md +0 -322
- package/.claude/agents/game-development/unity/unity-shader-graph-artist.md +0 -270
- package/.claude/agents/game-development/unreal-engine/unreal-multiplayer-architect.md +0 -314
- package/.claude/agents/game-development/unreal-engine/unreal-systems-engineer.md +0 -311
- package/.claude/agents/game-development/unreal-engine/unreal-technical-artist.md +0 -257
- package/.claude/agents/game-development/unreal-engine/unreal-world-builder.md +0 -274
- package/.claude/agents/github/code-review-swarm.md +0 -557
- package/.claude/agents/github/github-modes.md +0 -154
- package/.claude/agents/github/issue-tracker.md +0 -299
- package/.claude/agents/github/multi-repo-swarm.md +0 -525
- package/.claude/agents/github/pr-manager.md +0 -163
- package/.claude/agents/github/project-board-sync.md +0 -478
- package/.claude/agents/github/release-manager.md +0 -296
- package/.claude/agents/github/release-swarm.md +0 -597
- package/.claude/agents/github/repo-architect.md +0 -359
- package/.claude/agents/github/swarm-issue.md +0 -548
- package/.claude/agents/github/swarm-pr.md +0 -427
- package/.claude/agents/github/sync-coordinator.md +0 -355
- package/.claude/agents/github/workflow-automation.md +0 -640
- package/.claude/agents/goal/agent.md +0 -804
- package/.claude/agents/goal/code-goal-planner.md +0 -445
- package/.claude/agents/goal/goal-planner.md +0 -168
- package/.claude/agents/hive-mind/collective-intelligence-coordinator.md +0 -129
- package/.claude/agents/hive-mind/queen-coordinator.md +0 -202
- package/.claude/agents/hive-mind/scout-explorer.md +0 -241
- package/.claude/agents/hive-mind/swarm-memory-manager.md +0 -192
- package/.claude/agents/hive-mind/worker-specialist.md +0 -216
- package/.claude/agents/marketing/marketing-ai-citation-strategist.md +0 -171
- package/.claude/agents/marketing/marketing-app-store-optimizer.md +0 -322
- package/.claude/agents/marketing/marketing-baidu-seo-specialist.md +0 -227
- package/.claude/agents/marketing/marketing-bilibili-content-strategist.md +0 -200
- package/.claude/agents/marketing/marketing-book-co-author.md +0 -111
- package/.claude/agents/marketing/marketing-carousel-growth-engine.md +0 -200
- package/.claude/agents/marketing/marketing-china-ecommerce-operator.md +0 -284
- package/.claude/agents/marketing/marketing-competitive-content.md +0 -155
- package/.claude/agents/marketing/marketing-content-creator.md +0 -67
- package/.claude/agents/marketing/marketing-cro-specialist.md +0 -147
- package/.claude/agents/marketing/marketing-cross-border-ecommerce.md +0 -260
- package/.claude/agents/marketing/marketing-douyin-strategist.md +0 -150
- package/.claude/agents/marketing/marketing-email-specialist.md +0 -90
- package/.claude/agents/marketing/marketing-growth-hacker.md +0 -54
- package/.claude/agents/marketing/marketing-instagram-curator.md +0 -114
- package/.claude/agents/marketing/marketing-kuaishou-strategist.md +0 -224
- package/.claude/agents/marketing/marketing-launch-strategist.md +0 -129
- package/.claude/agents/marketing/marketing-linkedin-content-creator.md +0 -215
- package/.claude/agents/marketing/marketing-livestream-commerce-coach.md +0 -306
- package/.claude/agents/marketing/marketing-podcast-strategist.md +0 -278
- package/.claude/agents/marketing/marketing-pricing-strategist.md +0 -127
- package/.claude/agents/marketing/marketing-private-domain-operator.md +0 -309
- package/.claude/agents/marketing/marketing-reddit-community-builder.md +0 -124
- package/.claude/agents/marketing/marketing-seo-specialist.md +0 -279
- package/.claude/agents/marketing/marketing-short-video-editing-coach.md +0 -413
- package/.claude/agents/marketing/marketing-social-media-strategist.md +0 -125
- package/.claude/agents/marketing/marketing-tiktok-strategist.md +0 -126
- package/.claude/agents/marketing/marketing-twitter-engager.md +0 -127
- package/.claude/agents/marketing/marketing-wechat-official-account.md +0 -146
- package/.claude/agents/marketing/marketing-weibo-strategist.md +0 -241
- package/.claude/agents/marketing/marketing-xiaohongshu-specialist.md +0 -139
- package/.claude/agents/marketing/marketing-zhihu-strategist.md +0 -163
- package/.claude/agents/neural/safla-neural.md +0 -74
- package/.claude/agents/optimization/benchmark-suite.md +0 -663
- package/.claude/agents/optimization/load-balancer.md +0 -429
- package/.claude/agents/optimization/performance-monitor.md +0 -670
- package/.claude/agents/optimization/resource-allocator.md +0 -672
- package/.claude/agents/optimization/topology-optimizer.md +0 -806
- package/.claude/agents/paid-media/paid-media-auditor.md +0 -71
- package/.claude/agents/paid-media/paid-media-creative-strategist.md +0 -71
- package/.claude/agents/paid-media/paid-media-paid-social-strategist.md +0 -71
- package/.claude/agents/paid-media/paid-media-ppc-strategist.md +0 -71
- package/.claude/agents/paid-media/paid-media-programmatic-buyer.md +0 -71
- package/.claude/agents/paid-media/paid-media-search-query-analyst.md +0 -71
- package/.claude/agents/paid-media/paid-media-tracking-specialist.md +0 -71
- package/.claude/agents/payments/agentic-payments.md +0 -126
- package/.claude/agents/product/product-behavioral-nudge-engine.md +0 -81
- package/.claude/agents/product/product-feedback-synthesizer.md +0 -119
- package/.claude/agents/product/product-manager.md +0 -469
- package/.claude/agents/product/product-sprint-prioritizer.md +0 -154
- package/.claude/agents/product/product-trend-researcher.md +0 -159
- package/.claude/agents/project-management/project-management-experiment-tracker.md +0 -199
- package/.claude/agents/project-management/project-management-jira-workflow-steward.md +0 -231
- package/.claude/agents/project-management/project-management-project-shepherd.md +0 -195
- package/.claude/agents/project-management/project-management-studio-operations.md +0 -201
- package/.claude/agents/project-management/project-management-studio-producer.md +0 -204
- package/.claude/agents/project-management/project-manager-senior.md +0 -136
- package/.claude/agents/reasoning/agent.md +0 -804
- package/.claude/agents/reasoning/goal-planner.md +0 -73
- package/.claude/agents/sales/sales-account-strategist.md +0 -228
- package/.claude/agents/sales/sales-coach.md +0 -272
- package/.claude/agents/sales/sales-deal-strategist.md +0 -181
- package/.claude/agents/sales/sales-discovery-coach.md +0 -226
- package/.claude/agents/sales/sales-engineer.md +0 -183
- package/.claude/agents/sales/sales-outbound-strategist.md +0 -202
- package/.claude/agents/sales/sales-pipeline-analyst.md +0 -268
- package/.claude/agents/sales/sales-proposal-strategist.md +0 -218
- package/.claude/agents/schemas/architecture-output.json +0 -43
- package/.claude/agents/schemas/code-review-output.json +0 -28
- package/.claude/agents/schemas/generic-task-input.json +0 -12
- package/.claude/agents/schemas/implementation-output.json +0 -18
- package/.claude/agents/schemas/research-output.json +0 -31
- package/.claude/agents/schemas/security-audit-output.json +0 -29
- package/.claude/agents/schemas/test-report-output.json +0 -29
- package/.claude/agents/sona/sona-learning-optimizer.md +0 -65
- package/.claude/agents/sparc/architecture.md +0 -453
- package/.claude/agents/sparc/pseudocode.md +0 -299
- package/.claude/agents/sparc/refinement.md +0 -504
- package/.claude/agents/sparc/specification.md +0 -258
- package/.claude/agents/spatial-computing/macos-spatial-metal-engineer.md +0 -338
- package/.claude/agents/spatial-computing/terminal-integration-specialist.md +0 -71
- package/.claude/agents/spatial-computing/visionos-spatial-engineer.md +0 -55
- package/.claude/agents/specialists/integration-architect.md +0 -94
- package/.claude/agents/specialists/memory-specialist.md +0 -298
- package/.claude/agents/specialists/performance-engineer.md +0 -387
- package/.claude/agents/specialists/queen-coordinator.md +0 -67
- package/.claude/agents/specialists/security-architect.md +0 -154
- package/.claude/agents/specialized/accounts-payable-agent.md +0 -186
- package/.claude/agents/specialized/agentic-identity-trust.md +0 -388
- package/.claude/agents/specialized/agents-orchestrator.md +0 -368
- package/.claude/agents/specialized/automation-governance-architect.md +0 -217
- package/.claude/agents/specialized/blockchain-security-auditor.md +0 -497
- package/.claude/agents/specialized/compliance-auditor.md +0 -159
- package/.claude/agents/specialized/corporate-training-designer.md +0 -193
- package/.claude/agents/specialized/data-consolidation-agent.md +0 -61
- package/.claude/agents/specialized/government-digital-presales-consultant.md +0 -364
- package/.claude/agents/specialized/healthcare-marketing-compliance.md +0 -396
- package/.claude/agents/specialized/identity-graph-operator.md +0 -261
- package/.claude/agents/specialized/lsp-index-engineer.md +0 -315
- package/.claude/agents/specialized/mobile/spec-mobile-react-native.md +0 -89
- package/.claude/agents/specialized/recruitment-specialist.md +0 -510
- package/.claude/agents/specialized/report-distribution-agent.md +0 -66
- package/.claude/agents/specialized/sales-data-extraction-agent.md +0 -68
- package/.claude/agents/specialized/specialized-cultural-intelligence-strategist.md +0 -89
- package/.claude/agents/specialized/specialized-developer-advocate.md +0 -318
- package/.claude/agents/specialized/specialized-document-generator.md +0 -56
- package/.claude/agents/specialized/specialized-french-consulting-market.md +0 -193
- package/.claude/agents/specialized/specialized-korean-business-navigator.md +0 -217
- package/.claude/agents/specialized/specialized-mcp-builder.md +0 -64
- package/.claude/agents/specialized/specialized-model-qa.md +0 -489
- package/.claude/agents/specialized/specialized-salesforce-architect.md +0 -181
- package/.claude/agents/specialized/specialized-workflow-architect.md +0 -598
- package/.claude/agents/specialized/study-abroad-advisor.md +0 -283
- package/.claude/agents/specialized/supply-chain-strategist.md +0 -583
- package/.claude/agents/specialized/zk-steward.md +0 -212
- package/.claude/agents/sublinear/consensus-coordinator.md +0 -333
- package/.claude/agents/sublinear/matrix-optimizer.md +0 -180
- package/.claude/agents/sublinear/pagerank-analyzer.md +0 -295
- package/.claude/agents/sublinear/performance-optimizer.md +0 -363
- package/.claude/agents/sublinear/trading-predictor.md +0 -242
- package/.claude/agents/support/support-analytics-reporter.md +0 -366
- package/.claude/agents/support/support-executive-summary-generator.md +0 -213
- package/.claude/agents/support/support-finance-tracker.md +0 -443
- package/.claude/agents/support/support-infrastructure-maintainer.md +0 -619
- package/.claude/agents/support/support-legal-compliance-checker.md +0 -589
- package/.claude/agents/support/support-support-responder.md +0 -586
- package/.claude/agents/swarm/adaptive-coordinator.md +0 -364
- package/.claude/agents/swarm/hierarchical-coordinator.md +0 -318
- package/.claude/agents/swarm/mesh-coordinator.md +0 -363
- package/.claude/agents/templates/automation-smart-agent.md +0 -185
- package/.claude/agents/templates/coordinator-swarm-init.md +0 -83
- package/.claude/agents/templates/github-pr-manager.md +0 -155
- package/.claude/agents/templates/implementer-sparc-coder.md +0 -231
- package/.claude/agents/templates/memory-coordinator.md +0 -163
- package/.claude/agents/templates/migration-plan.md +0 -724
- package/.claude/agents/templates/orchestrator-task.md +0 -120
- package/.claude/agents/templates/performance-analyzer.md +0 -179
- package/.claude/agents/templates/sparc-coordinator.md +0 -163
- package/.claude/agents/testing/production-validator.md +0 -374
- package/.claude/agents/testing/tdd-london-swarm.md +0 -241
- package/.claude/agents/testing/testing-accessibility-auditor.md +0 -322
- package/.claude/agents/testing/testing-api-tester.md +0 -307
- package/.claude/agents/testing/testing-evidence-collector.md +0 -211
- package/.claude/agents/testing/testing-performance-benchmarker.md +0 -269
- package/.claude/agents/testing/testing-reality-checker.md +0 -237
- package/.claude/agents/testing/testing-test-results-analyzer.md +0 -306
- package/.claude/agents/testing/testing-tool-evaluator.md +0 -395
- package/.claude/agents/testing/testing-workflow-optimizer.md +0 -451
- package/.claude/checkpoints/1767754460.json +0 -8
- package/.claude/commands/agents/README.md +0 -14
- package/.claude/commands/agents/agent-capabilities.md +0 -25
- package/.claude/commands/agents/agent-coordination.md +0 -32
- package/.claude/commands/agents/agent-spawning.md +0 -32
- package/.claude/commands/agents/agent-types.md +0 -30
- package/.claude/commands/analysis/README.md +0 -18
- package/.claude/commands/analysis/bottleneck-detect.md +0 -69
- package/.claude/commands/analysis/performance-bottlenecks.md +0 -59
- package/.claude/commands/analysis/performance-report.md +0 -52
- package/.claude/commands/analysis/token-efficiency.md +0 -42
- package/.claude/commands/analysis/token-usage.md +0 -47
- package/.claude/commands/automation/README.md +0 -19
- package/.claude/commands/automation/auto-agent.md +0 -86
- package/.claude/commands/automation/self-healing.md +0 -108
- package/.claude/commands/automation/session-memory.md +0 -89
- package/.claude/commands/automation/smart-agents.md +0 -81
- package/.claude/commands/automation/smart-spawn.md +0 -66
- package/.claude/commands/automation/workflow-select.md +0 -60
- package/.claude/commands/browse.md +0 -32
- package/.claude/commands/coordination/README.md +0 -13
- package/.claude/commands/coordination/agent-spawn.md +0 -69
- package/.claude/commands/coordination/swarm-init.md +0 -82
- package/.claude/commands/coordination/task-orchestrate.md +0 -79
- package/.claude/commands/github/README.md +0 -24
- package/.claude/commands/github/github-modes.md +0 -151
- package/.claude/commands/github/issue-tracker.md +0 -293
- package/.claude/commands/github/pr-manager.md +0 -173
- package/.claude/commands/github/release-manager.md +0 -343
- package/.claude/commands/github/repo-architect.md +0 -379
- package/.claude/commands/github/sync-coordinator.md +0 -297
- package/.claude/commands/hive-mind/README.md +0 -42
- package/.claude/commands/hive-mind/hive-mind-consensus.md +0 -72
- package/.claude/commands/hive-mind/hive-mind-init.md +0 -68
- package/.claude/commands/hive-mind/hive-mind-memory.md +0 -73
- package/.claude/commands/hive-mind/hive-mind-spawn.md +0 -82
- package/.claude/commands/hive-mind/hive-mind-status.md +0 -56
- package/.claude/commands/hive-mind/hive-mind-stop.md +0 -55
- package/.claude/commands/hive-mind/hive-mind.md +0 -87
- package/.claude/commands/hooks/README.md +0 -66
- package/.claude/commands/hooks/overview.md +0 -117
- package/.claude/commands/hooks/post-edit.md +0 -78
- package/.claude/commands/hooks/post-task.md +0 -62
- package/.claude/commands/hooks/pre-edit.md +0 -81
- package/.claude/commands/hooks/pre-task.md +0 -76
- package/.claude/commands/hooks/session-end.md +0 -82
- package/.claude/commands/hooks/setup.md +0 -132
- package/.claude/commands/mastermind/_repeat.md +0 -451
- package/.claude/commands/mastermind/architect.md +0 -55
- package/.claude/commands/mastermind/brain.md +0 -102
- package/.claude/commands/mastermind/build.md +0 -26
- package/.claude/commands/mastermind/content.md +0 -26
- package/.claude/commands/mastermind/createorg.md +0 -97
- package/.claude/commands/mastermind/finance.md +0 -26
- package/.claude/commands/mastermind/idea.md +0 -26
- package/.claude/commands/mastermind/marketing.md +0 -26
- package/.claude/commands/mastermind/master.md +0 -772
- package/.claude/commands/mastermind/ops.md +0 -26
- package/.claude/commands/mastermind/release.md +0 -26
- package/.claude/commands/mastermind/research.md +0 -26
- package/.claude/commands/mastermind/review.md +0 -26
- package/.claude/commands/mastermind/runorg.md +0 -109
- package/.claude/commands/mastermind/sales.md +0 -26
- package/.claude/commands/mastermind/techport.md +0 -26
- package/.claude/commands/mastermind.md +0 -121
- package/.claude/commands/memory/README.md +0 -79
- package/.claude/commands/memory/memory-search.md +0 -77
- package/.claude/commands/monitoring/README.md +0 -69
- package/.claude/commands/monitoring/agent-metrics.md +0 -65
- package/.claude/commands/monitoring/agents.md +0 -71
- package/.claude/commands/monitoring/status.md +0 -108
- package/.claude/commands/monograph/README.md +0 -102
- package/.claude/commands/monograph/monograph-build.md +0 -79
- package/.claude/commands/monograph/monograph-search.md +0 -96
- package/.claude/commands/monograph/monograph-stats.md +0 -53
- package/.claude/commands/monograph/monograph-watch.md +0 -63
- package/.claude/commands/monograph/monograph-wiki.md +0 -91
- package/.claude/commands/monomind/createtask.md +0 -277
- package/.claude/commands/monomind/do.md +0 -446
- package/.claude/commands/monomind/help.md +0 -118
- package/.claude/commands/monomind/idea.md +0 -273
- package/.claude/commands/monomind/improve.md +0 -350
- package/.claude/commands/monomind/memory.md +0 -230
- package/.claude/commands/monomind/repeat.md +0 -257
- package/.claude/commands/monomind/review.md +0 -317
- package/.claude/commands/monomind/specialagents.md +0 -125
- package/.claude/commands/monomind/swarm.md +0 -161
- package/.claude/commands/monomind/understand.md +0 -150
- package/.claude/commands/optimization/README.md +0 -73
- package/.claude/commands/optimization/auto-topology.md +0 -85
- package/.claude/commands/optimization/parallel-execution.md +0 -76
- package/.claude/commands/optimization/performance-optimize.md +0 -79
- package/.claude/commands/pair/README.md +0 -79
- package/.claude/commands/pair/examples.md +0 -156
- package/.claude/commands/pair/modes.md +0 -122
- package/.claude/commands/pair/session.md +0 -124
- package/.claude/commands/sparc/analyzer.md +0 -35
- package/.claude/commands/sparc/architect.md +0 -36
- package/.claude/commands/sparc/ask.md +0 -56
- package/.claude/commands/sparc/batch-executor.md +0 -37
- package/.claude/commands/sparc/code.md +0 -48
- package/.claude/commands/sparc/coder.md +0 -37
- package/.claude/commands/sparc/debug.md +0 -42
- package/.claude/commands/sparc/debugger.md +0 -37
- package/.claude/commands/sparc/designer.md +0 -36
- package/.claude/commands/sparc/devops.md +0 -68
- package/.claude/commands/sparc/docs-writer.md +0 -39
- package/.claude/commands/sparc/documenter.md +0 -37
- package/.claude/commands/sparc/innovator.md +0 -37
- package/.claude/commands/sparc/integration.md +0 -42
- package/.claude/commands/sparc/mcp.md +0 -76
- package/.claude/commands/sparc/memory-manager.md +0 -57
- package/.claude/commands/sparc/optimizer.md +0 -37
- package/.claude/commands/sparc/orchestrator.md +0 -70
- package/.claude/commands/sparc/post-deployment-monitoring-mode.md +0 -42
- package/.claude/commands/sparc/refinement-optimization-mode.md +0 -42
- package/.claude/commands/sparc/researcher.md +0 -37
- package/.claude/commands/sparc/reviewer.md +0 -37
- package/.claude/commands/sparc/security-review.md +0 -39
- package/.claude/commands/sparc/sparc-modes.md +0 -120
- package/.claude/commands/sparc/sparc.md +0 -71
- package/.claude/commands/sparc/spec-pseudocode.md +0 -39
- package/.claude/commands/sparc/supabase-admin.md +0 -301
- package/.claude/commands/sparc/swarm-coordinator.md +0 -50
- package/.claude/commands/sparc/tdd.md +0 -37
- package/.claude/commands/sparc/tester.md +0 -37
- package/.claude/commands/sparc/tutorial.md +0 -38
- package/.claude/commands/sparc/workflow-manager.md +0 -37
- package/.claude/commands/sparc.md +0 -112
- package/.claude/commands/stream-chain/pipeline.md +0 -116
- package/.claude/commands/stream-chain/run.md +0 -156
- package/.claude/commands/swarm/README.md +0 -40
- package/.claude/commands/swarm/analysis.md +0 -73
- package/.claude/commands/swarm/development.md +0 -72
- package/.claude/commands/swarm/examples.md +0 -103
- package/.claude/commands/swarm/maintenance.md +0 -75
- package/.claude/commands/swarm/optimization.md +0 -84
- package/.claude/commands/swarm/research.md +0 -76
- package/.claude/commands/swarm/swarm-analysis.md +0 -62
- package/.claude/commands/swarm/swarm-background.md +0 -65
- package/.claude/commands/swarm/swarm-modes.md +0 -67
- package/.claude/commands/swarm/swarm-monitor.md +0 -54
- package/.claude/commands/swarm/swarm-status.md +0 -44
- package/.claude/commands/swarm/swarm-strategies.md +0 -76
- package/.claude/commands/swarm/swarm.md +0 -79
- package/.claude/commands/swarm/testing.md +0 -80
- package/.claude/commands/tokens.md +0 -18
- package/.claude/commands/training/README.md +0 -39
- package/.claude/commands/training/model-update.md +0 -78
- package/.claude/commands/training/neural-patterns.md +0 -73
- package/.claude/commands/training/neural-train.md +0 -79
- package/.claude/commands/training/pattern-learn.md +0 -69
- package/.claude/commands/training/specialization.md +0 -92
- package/.claude/commands/truth/start.md +0 -121
- package/.claude/commands/ts.md +0 -14
- package/.claude/commands/verify/check.md +0 -106
- package/.claude/commands/verify/start.md +0 -105
- package/.claude/commands/workflows/README.md +0 -65
- package/.claude/commands/workflows/development.md +0 -86
- package/.claude/commands/workflows/research.md +0 -89
- package/.claude/commands/workflows/workflow-create.md +0 -84
- package/.claude/commands/workflows/workflow-execute.md +0 -103
- package/.claude/commands/workflows/workflow-export.md +0 -90
- package/.claude/config/v1-dependency-optimization.json +0 -266
- package/.claude/config/v1-performance-targets.json +0 -251
- package/.claude/helpers/README.md +0 -105
- package/.claude/helpers/auto-memory-hook.mjs +0 -369
- package/.claude/helpers/context-persistence-hook.mjs +0 -1988
- package/.claude/helpers/control-start.cjs +0 -91
- package/.claude/helpers/extras-registry.json +0 -5141
- package/.claude/helpers/graphify-freshen.cjs +0 -98
- package/.claude/helpers/hook-handler.cjs +0 -1718
- package/.claude/helpers/intelligence.cjs +0 -227
- package/.claude/helpers/learning-service.mjs +0 -1144
- package/.claude/helpers/loop-tracker.cjs +0 -107
- package/.claude/helpers/memory-palace.cjs +0 -401
- package/.claude/helpers/memory.cjs +0 -84
- package/.claude/helpers/metrics-db.mjs +0 -488
- package/.claude/helpers/router.cjs +0 -450
- package/.claude/helpers/session.cjs +0 -125
- package/.claude/helpers/skill-registry.json +0 -946
- package/.claude/helpers/statusline.cjs +0 -1331
- package/.claude/helpers/swarm-hooks.sh +0 -761
- package/.claude/helpers/toggle-statusline.cjs +0 -58
- package/.claude/helpers/token-tracker.cjs +0 -934
- package/.claude/mcp.json +0 -3
- package/.claude/scheduled_tasks.lock +0 -1
- package/.claude/settings.json +0 -318
- package/.claude/settings.local.json +0 -52
- package/.claude/skills/.monomind/data/ranked-context.json +0 -5
- package/.claude/skills/.monomind/sessions/current.json +0 -13
- package/.claude/skills/.monomind/sessions/session-1777829336455.json +0 -15
- package/.claude/skills/.monomind/sessions/session-1777831614725.json +0 -15
- package/.claude/skills/.monomind/sessions/session-1777832095857.json +0 -15
- package/.claude/skills/.monomind/sessions/session-1777839814183.json +0 -15
- package/.claude/skills/.monomind/sessions/session-1777841847131.json +0 -15
- package/.claude/skills/.monomind/sessions/session-1777843309463.json +0 -15
- package/.claude/skills/.monomind/sessions/session-1777880867159.json +0 -15
- package/.claude/skills/.monomind/sessions/session-1777881884593.json +0 -15
- package/.claude/skills/.monomind/sessions/session-1777884090471.json +0 -15
- package/.claude/skills/.monomind/sessions/session-1777884808221.json +0 -15
- package/.claude/skills/.monomind/sessions/session-1777885672155.json +0 -15
- package/.claude/skills/.monomind/sessions/session-1777886852818.json +0 -15
- package/.claude/skills/.monomind/sessions/session-1777896532690.json +0 -15
- package/.claude/skills/agent-browser-testing/SKILL.md +0 -312
- package/.claude/skills/agentdb-advanced/SKILL.md +0 -549
- package/.claude/skills/agentdb-learning/SKILL.md +0 -544
- package/.claude/skills/agentdb-memory-patterns/SKILL.md +0 -337
- package/.claude/skills/agentdb-optimization/SKILL.md +0 -508
- package/.claude/skills/agentdb-vector-search/SKILL.md +0 -335
- package/.claude/skills/agentic-integration/SKILL.md +0 -265
- package/.claude/skills/agentic-jujutsu/SKILL.md +0 -645
- package/.claude/skills/cli-modernization/SKILL.md +0 -950
- package/.claude/skills/core-implementation/SKILL.md +0 -892
- package/.claude/skills/ddd-architecture/SKILL.md +0 -444
- package/.claude/skills/github-code-review/SKILL.md +0 -1147
- package/.claude/skills/github-multi-repo/SKILL.md +0 -912
- package/.claude/skills/github-project-management/SKILL.md +0 -1245
- package/.claude/skills/github-release-management/SKILL.md +0 -1118
- package/.claude/skills/github-workflow-automation/SKILL.md +0 -1107
- package/.claude/skills/hive-mind-advanced/SKILL.md +0 -709
- package/.claude/skills/hooks-automation/SKILL.md +0 -1196
- package/.claude/skills/mastermind/_agent-select.md +0 -132
- package/.claude/skills/mastermind/_intake.md +0 -83
- package/.claude/skills/mastermind/_protocol.md +0 -380
- package/.claude/skills/mastermind/access.md +0 -236
- package/.claude/skills/mastermind/activity.md +0 -191
- package/.claude/skills/mastermind/adapter-manager.md +0 -259
- package/.claude/skills/mastermind/adapters.md +0 -204
- package/.claude/skills/mastermind/agent-detail.md +0 -242
- package/.claude/skills/mastermind/agents.md +0 -178
- package/.claude/skills/mastermind/approval-detail.md +0 -259
- package/.claude/skills/mastermind/approve.md +0 -181
- package/.claude/skills/mastermind/architect.md +0 -863
- package/.claude/skills/mastermind/backup.md +0 -197
- package/.claude/skills/mastermind/bootstrap.md +0 -190
- package/.claude/skills/mastermind/budgets.md +0 -237
- package/.claude/skills/mastermind/build.md +0 -170
- package/.claude/skills/mastermind/companies.md +0 -256
- package/.claude/skills/mastermind/content.md +0 -197
- package/.claude/skills/mastermind/costs.md +0 -151
- package/.claude/skills/mastermind/createorg.md +0 -344
- package/.claude/skills/mastermind/diagnose.md +0 -249
- package/.claude/skills/mastermind/env.md +0 -198
- package/.claude/skills/mastermind/environments.md +0 -250
- package/.claude/skills/mastermind/export.md +0 -324
- package/.claude/skills/mastermind/finance.md +0 -166
- package/.claude/skills/mastermind/goal-detail.md +0 -255
- package/.claude/skills/mastermind/goals.md +0 -149
- package/.claude/skills/mastermind/heartbeat.md +0 -164
- package/.claude/skills/mastermind/idea.md +0 -1120
- package/.claude/skills/mastermind/import.md +0 -281
- package/.claude/skills/mastermind/inbox.md +0 -214
- package/.claude/skills/mastermind/instance-settings.md +0 -315
- package/.claude/skills/mastermind/instance.md +0 -231
- package/.claude/skills/mastermind/invite-landing.md +0 -227
- package/.claude/skills/mastermind/invites.md +0 -254
- package/.claude/skills/mastermind/issue-detail.md +0 -291
- package/.claude/skills/mastermind/issues.md +0 -235
- package/.claude/skills/mastermind/join-queue.md +0 -170
- package/.claude/skills/mastermind/liveness.md +0 -392
- package/.claude/skills/mastermind/marketing.md +0 -228
- package/.claude/skills/mastermind/memory.md +0 -321
- package/.claude/skills/mastermind/monotask.md +0 -350
- package/.claude/skills/mastermind/my-issues.md +0 -146
- package/.claude/skills/mastermind/new-agent.md +0 -241
- package/.claude/skills/mastermind/ops.md +0 -168
- package/.claude/skills/mastermind/org-chart.md +0 -207
- package/.claude/skills/mastermind/org-settings.md +0 -217
- package/.claude/skills/mastermind/plan-to-tasks.md +0 -136
- package/.claude/skills/mastermind/plugin-manager.md +0 -241
- package/.claude/skills/mastermind/plugin-settings.md +0 -273
- package/.claude/skills/mastermind/plugins.md +0 -190
- package/.claude/skills/mastermind/profile.md +0 -187
- package/.claude/skills/mastermind/project-detail.md +0 -249
- package/.claude/skills/mastermind/project-workspace.md +0 -244
- package/.claude/skills/mastermind/projects.md +0 -164
- package/.claude/skills/mastermind/references/copywriting-frameworks.md +0 -181
- package/.claude/skills/mastermind/references/persuasion-psychology.md +0 -158
- package/.claude/skills/mastermind/release.md +0 -168
- package/.claude/skills/mastermind/research.md +0 -168
- package/.claude/skills/mastermind/review.md +0 -169
- package/.claude/skills/mastermind/routine-detail.md +0 -253
- package/.claude/skills/mastermind/routines.md +0 -202
- package/.claude/skills/mastermind/runorg.md +0 -373
- package/.claude/skills/mastermind/sales.md +0 -170
- package/.claude/skills/mastermind/search.md +0 -186
- package/.claude/skills/mastermind/secrets.md +0 -199
- package/.claude/skills/mastermind/skills.md +0 -156
- package/.claude/skills/mastermind/tasks.md +0 -149
- package/.claude/skills/mastermind/techport.md +0 -743
- package/.claude/skills/mastermind/threads.md +0 -259
- package/.claude/skills/mastermind/tree-control.md +0 -250
- package/.claude/skills/mastermind/wiki.md +0 -314
- package/.claude/skills/mastermind/workspace-detail.md +0 -317
- package/.claude/skills/mastermind/workspaces.md +0 -261
- package/.claude/skills/mastermind/worktree.md +0 -187
- package/.claude/skills/mcp-optimization/SKILL.md +0 -837
- package/.claude/skills/memory-unification/SKILL.md +0 -196
- package/.claude/skills/monodesign/SKILL.md +0 -302
- package/.claude/skills/monodesign/reference/adapt.md +0 -190
- package/.claude/skills/monodesign/reference/animate.md +0 -175
- package/.claude/skills/monodesign/reference/antipatterns-catalog.md +0 -187
- package/.claude/skills/monodesign/reference/audit.md +0 -133
- package/.claude/skills/monodesign/reference/bolder.md +0 -113
- package/.claude/skills/monodesign/reference/brand-workflow.md +0 -180
- package/.claude/skills/monodesign/reference/brand.md +0 -114
- package/.claude/skills/monodesign/reference/clarify.md +0 -174
- package/.claude/skills/monodesign/reference/cognitive-load.md +0 -106
- package/.claude/skills/monodesign/reference/color-and-contrast.md +0 -105
- package/.claude/skills/monodesign/reference/colorize.md +0 -154
- package/.claude/skills/monodesign/reference/component-specs.md +0 -260
- package/.claude/skills/monodesign/reference/component-states.md +0 -274
- package/.claude/skills/monodesign/reference/component-system.md +0 -358
- package/.claude/skills/monodesign/reference/copy-formulas.md +0 -160
- package/.claude/skills/monodesign/reference/craft.md +0 -193
- package/.claude/skills/monodesign/reference/critique.md +0 -213
- package/.claude/skills/monodesign/reference/delight.md +0 -302
- package/.claude/skills/monodesign/reference/design-principles.md +0 -246
- package/.claude/skills/monodesign/reference/distill.md +0 -111
- package/.claude/skills/monodesign/reference/document.md +0 -427
- package/.claude/skills/monodesign/reference/extract.md +0 -69
- package/.claude/skills/monodesign/reference/harden.md +0 -347
- package/.claude/skills/monodesign/reference/heuristics-scoring.md +0 -234
- package/.claude/skills/monodesign/reference/image-prompts.md +0 -118
- package/.claude/skills/monodesign/reference/interaction-design.md +0 -195
- package/.claude/skills/monodesign/reference/layout.md +0 -141
- package/.claude/skills/monodesign/reference/live.md +0 -622
- package/.claude/skills/monodesign/reference/motion-design.md +0 -109
- package/.claude/skills/monodesign/reference/onboard.md +0 -234
- package/.claude/skills/monodesign/reference/optimize.md +0 -258
- package/.claude/skills/monodesign/reference/overdrive.md +0 -130
- package/.claude/skills/monodesign/reference/personas.md +0 -179
- package/.claude/skills/monodesign/reference/polish.md +0 -233
- package/.claude/skills/monodesign/reference/pre-delivery-checklist.md +0 -108
- package/.claude/skills/monodesign/reference/product.md +0 -62
- package/.claude/skills/monodesign/reference/quieter.md +0 -99
- package/.claude/skills/monodesign/reference/responsive-design.md +0 -114
- package/.claude/skills/monodesign/reference/shape.md +0 -151
- package/.claude/skills/monodesign/reference/spatial-design.md +0 -100
- package/.claude/skills/monodesign/reference/teach.md +0 -156
- package/.claude/skills/monodesign/reference/token-architecture.md +0 -222
- package/.claude/skills/monodesign/reference/typeset.md +0 -124
- package/.claude/skills/monodesign/reference/typography.md +0 -159
- package/.claude/skills/monodesign/reference/ux-research.md +0 -143
- package/.claude/skills/monodesign/reference/ux-rules.md +0 -211
- package/.claude/skills/monodesign/reference/ux-writing.md +0 -107
- package/.claude/skills/monomotion/SKILL.md +0 -145
- package/.claude/skills/monomotion/rules/api-control.md +0 -139
- package/.claude/skills/monomotion/rules/effects.md +0 -109
- package/.claude/skills/monomotion/rules/integration.md +0 -140
- package/.claude/skills/monomotion/rules/scroll.md +0 -131
- package/.claude/skills/monomotion/rules/sequencing.md +0 -105
- package/.claude/skills/monomotion/rules/svg.md +0 -101
- package/.claude/skills/monomotion/rules/text.md +0 -119
- package/.claude/skills/pair-programming/SKILL.md +0 -1202
- package/.claude/skills/performance-analysis/SKILL.md +0 -560
- package/.claude/skills/performance-optimization/SKILL.md +0 -416
- package/.claude/skills/reasoningbank-agentdb/SKILL.md +0 -444
- package/.claude/skills/reasoningbank-intelligence/SKILL.md +0 -199
- package/.claude/skills/security-hardening/SKILL.md +0 -101
- package/.claude/skills/skill-builder/SKILL.md +0 -910
- package/.claude/skills/sparc-methodology/SKILL.md +0 -950
- package/.claude/skills/specialagent/SKILL.md +0 -208
- package/.claude/skills/stop-slop/SKILL.md +0 -67
- package/.claude/skills/stop-slop/references/examples.md +0 -61
- package/.claude/skills/stop-slop/references/phrases.md +0 -130
- package/.claude/skills/stop-slop/references/structures.md +0 -136
- package/.claude/skills/stream-chain/SKILL.md +0 -560
- package/.claude/skills/swarm-advanced/SKILL.md +0 -940
- package/.claude/skills/swarm-coordination/SKILL.md +0 -451
- package/.claude/skills/swarm-orchestration/SKILL.md +0 -179
- package/.claude/skills/verification-quality/SKILL.md +0 -674
- package/.claude/statusline-command.sh +0 -176
- package/.claude/statusline.mjs +0 -109
- package/.claude/statusline.sh +0 -431
- package/.claude/workflows/feature-dev.yaml +0 -18
- package/.claude/workflows/security-audit.yaml +0 -10
- package/.claude-plugin/README.md +0 -705
- package/.claude-plugin/docs/INSTALLATION.md +0 -258
- package/.claude-plugin/docs/PLUGIN_SUMMARY.md +0 -359
- package/.claude-plugin/docs/QUICKSTART.md +0 -360
- package/.claude-plugin/docs/STRUCTURE.md +0 -126
- package/.claude-plugin/hooks/hooks.json +0 -74
- package/.claude-plugin/marketplace.json +0 -98
- package/.claude-plugin/plugin.json +0 -70
- package/.claude-plugin/scripts/install.sh +0 -234
- package/.claude-plugin/scripts/uninstall.sh +0 -36
- package/.claude-plugin/scripts/verify.sh +0 -108
- package/LICENSE +0 -21
- package/README.md +0 -441
- package/bin/cli.js +0 -11
- package/bin/npx-safe-launch.js +0 -9
- package/packages/@monomind/cli/README.md +0 -441
- package/packages/@monomind/cli/bin/cli.js +0 -221
- package/packages/@monomind/cli/bin/mcp-server.js +0 -189
- package/packages/@monomind/cli/bin/preinstall.cjs +0 -2
- package/packages/@monomind/cli/bundled-graph/dist/tsconfig.tsbuildinfo +0 -1
- package/packages/@monomind/cli/bundled-graph/package.json +0 -57
- package/packages/@monomind/cli/package.json +0 -114
- package/packages/@monomind/guidance/README.md +0 -1192
- package/packages/@monomind/guidance/dist/adversarial.d.ts +0 -284
- package/packages/@monomind/guidance/dist/adversarial.js +0 -572
- package/packages/@monomind/guidance/dist/analyzer.d.ts +0 -530
- package/packages/@monomind/guidance/dist/analyzer.js +0 -2518
- package/packages/@monomind/guidance/dist/artifacts.d.ts +0 -283
- package/packages/@monomind/guidance/dist/artifacts.js +0 -356
- package/packages/@monomind/guidance/dist/authority.d.ts +0 -290
- package/packages/@monomind/guidance/dist/authority.js +0 -558
- package/packages/@monomind/guidance/dist/capabilities.d.ts +0 -209
- package/packages/@monomind/guidance/dist/capabilities.js +0 -485
- package/packages/@monomind/guidance/dist/coherence.d.ts +0 -233
- package/packages/@monomind/guidance/dist/coherence.js +0 -372
- package/packages/@monomind/guidance/dist/compiler.d.ts +0 -87
- package/packages/@monomind/guidance/dist/compiler.js +0 -419
- package/packages/@monomind/guidance/dist/conformance-kit.d.ts +0 -225
- package/packages/@monomind/guidance/dist/conformance-kit.js +0 -629
- package/packages/@monomind/guidance/dist/continue-gate.d.ts +0 -214
- package/packages/@monomind/guidance/dist/continue-gate.js +0 -353
- package/packages/@monomind/guidance/dist/crypto-utils.d.ts +0 -17
- package/packages/@monomind/guidance/dist/crypto-utils.js +0 -24
- package/packages/@monomind/guidance/dist/evolution.d.ts +0 -282
- package/packages/@monomind/guidance/dist/evolution.js +0 -500
- package/packages/@monomind/guidance/dist/gates.d.ts +0 -79
- package/packages/@monomind/guidance/dist/gates.js +0 -302
- package/packages/@monomind/guidance/dist/gateway.d.ts +0 -206
- package/packages/@monomind/guidance/dist/gateway.js +0 -452
- package/packages/@monomind/guidance/dist/generators.d.ts +0 -153
- package/packages/@monomind/guidance/dist/generators.js +0 -682
- package/packages/@monomind/guidance/dist/headless.d.ts +0 -177
- package/packages/@monomind/guidance/dist/headless.js +0 -342
- package/packages/@monomind/guidance/dist/hooks.d.ts +0 -109
- package/packages/@monomind/guidance/dist/hooks.js +0 -347
- package/packages/@monomind/guidance/dist/index.d.ts +0 -205
- package/packages/@monomind/guidance/dist/index.js +0 -321
- package/packages/@monomind/guidance/dist/ledger.d.ts +0 -162
- package/packages/@monomind/guidance/dist/ledger.js +0 -375
- package/packages/@monomind/guidance/dist/manifest-validator.d.ts +0 -289
- package/packages/@monomind/guidance/dist/manifest-validator.js +0 -838
- package/packages/@monomind/guidance/dist/memory-gate.d.ts +0 -222
- package/packages/@monomind/guidance/dist/memory-gate.js +0 -382
- package/packages/@monomind/guidance/dist/meta-governance.d.ts +0 -265
- package/packages/@monomind/guidance/dist/meta-governance.js +0 -348
- package/packages/@monomind/guidance/dist/optimizer.d.ts +0 -104
- package/packages/@monomind/guidance/dist/optimizer.js +0 -329
- package/packages/@monomind/guidance/dist/persistence.d.ts +0 -189
- package/packages/@monomind/guidance/dist/persistence.js +0 -464
- package/packages/@monomind/guidance/dist/proof.d.ts +0 -185
- package/packages/@monomind/guidance/dist/proof.js +0 -238
- package/packages/@monomind/guidance/dist/retriever.d.ts +0 -116
- package/packages/@monomind/guidance/dist/retriever.js +0 -394
- package/packages/@monomind/guidance/dist/ruvbot-integration.d.ts +0 -370
- package/packages/@monomind/guidance/dist/ruvbot-integration.js +0 -738
- package/packages/@monomind/guidance/dist/temporal.d.ts +0 -426
- package/packages/@monomind/guidance/dist/temporal.js +0 -658
- package/packages/@monomind/guidance/dist/trust.d.ts +0 -283
- package/packages/@monomind/guidance/dist/trust.js +0 -473
- package/packages/@monomind/guidance/dist/truth-anchors.d.ts +0 -276
- package/packages/@monomind/guidance/dist/truth-anchors.js +0 -488
- package/packages/@monomind/guidance/dist/types.d.ts +0 -378
- package/packages/@monomind/guidance/dist/types.js +0 -10
- package/packages/@monomind/guidance/dist/uncertainty.d.ts +0 -372
- package/packages/@monomind/guidance/dist/uncertainty.js +0 -619
- package/packages/@monomind/guidance/dist/wasm-kernel.d.ts +0 -48
- package/packages/@monomind/guidance/dist/wasm-kernel.js +0 -158
- package/packages/@monomind/guidance/package.json +0 -198
- package/packages/@monomind/shared/README.md +0 -322
- package/packages/@monomind/shared/dist/agent-contract.d.ts +0 -28
- package/packages/@monomind/shared/dist/agent-contract.js +0 -57
- package/packages/@monomind/shared/dist/agent-error-result.d.ts +0 -17
- package/packages/@monomind/shared/dist/agent-error-result.js +0 -23
- package/packages/@monomind/shared/dist/core/config/defaults.d.ts +0 -41
- package/packages/@monomind/shared/dist/core/config/defaults.js +0 -186
- package/packages/@monomind/shared/dist/core/config/index.d.ts +0 -8
- package/packages/@monomind/shared/dist/core/config/index.js +0 -12
- package/packages/@monomind/shared/dist/core/config/loader.d.ts +0 -45
- package/packages/@monomind/shared/dist/core/config/loader.js +0 -238
- package/packages/@monomind/shared/dist/core/config/schema.d.ts +0 -324
- package/packages/@monomind/shared/dist/core/config/schema.js +0 -160
- package/packages/@monomind/shared/dist/core/config/validator.d.ts +0 -92
- package/packages/@monomind/shared/dist/core/config/validator.js +0 -147
- package/packages/@monomind/shared/dist/core/event-bus.d.ts +0 -31
- package/packages/@monomind/shared/dist/core/event-bus.js +0 -197
- package/packages/@monomind/shared/dist/core/index.d.ts +0 -15
- package/packages/@monomind/shared/dist/core/index.js +0 -19
- package/packages/@monomind/shared/dist/core/interfaces/agent.interface.d.ts +0 -200
- package/packages/@monomind/shared/dist/core/interfaces/agent.interface.js +0 -6
- package/packages/@monomind/shared/dist/core/interfaces/coordinator.interface.d.ts +0 -310
- package/packages/@monomind/shared/dist/core/interfaces/coordinator.interface.js +0 -7
- package/packages/@monomind/shared/dist/core/interfaces/event.interface.d.ts +0 -224
- package/packages/@monomind/shared/dist/core/interfaces/event.interface.js +0 -46
- package/packages/@monomind/shared/dist/core/interfaces/index.d.ts +0 -10
- package/packages/@monomind/shared/dist/core/interfaces/index.js +0 -15
- package/packages/@monomind/shared/dist/core/interfaces/memory.interface.d.ts +0 -298
- package/packages/@monomind/shared/dist/core/interfaces/memory.interface.js +0 -7
- package/packages/@monomind/shared/dist/core/interfaces/task.interface.d.ts +0 -185
- package/packages/@monomind/shared/dist/core/interfaces/task.interface.js +0 -6
- package/packages/@monomind/shared/dist/core/orchestrator/event-coordinator.d.ts +0 -35
- package/packages/@monomind/shared/dist/core/orchestrator/event-coordinator.js +0 -101
- package/packages/@monomind/shared/dist/core/orchestrator/health-monitor.d.ts +0 -60
- package/packages/@monomind/shared/dist/core/orchestrator/health-monitor.js +0 -166
- package/packages/@monomind/shared/dist/core/orchestrator/index.d.ts +0 -46
- package/packages/@monomind/shared/dist/core/orchestrator/index.js +0 -64
- package/packages/@monomind/shared/dist/core/orchestrator/lifecycle-manager.d.ts +0 -56
- package/packages/@monomind/shared/dist/core/orchestrator/lifecycle-manager.js +0 -195
- package/packages/@monomind/shared/dist/core/orchestrator/session-manager.d.ts +0 -83
- package/packages/@monomind/shared/dist/core/orchestrator/session-manager.js +0 -193
- package/packages/@monomind/shared/dist/core/orchestrator/task-manager.d.ts +0 -49
- package/packages/@monomind/shared/dist/core/orchestrator/task-manager.js +0 -253
- package/packages/@monomind/shared/dist/events/domain-events.d.ts +0 -282
- package/packages/@monomind/shared/dist/events/domain-events.js +0 -165
- package/packages/@monomind/shared/dist/events/event-store.d.ts +0 -126
- package/packages/@monomind/shared/dist/events/event-store.js +0 -416
- package/packages/@monomind/shared/dist/events/event-store.test.d.ts +0 -8
- package/packages/@monomind/shared/dist/events/event-store.test.js +0 -293
- package/packages/@monomind/shared/dist/events/example-usage.d.ts +0 -10
- package/packages/@monomind/shared/dist/events/example-usage.js +0 -193
- package/packages/@monomind/shared/dist/events/index.d.ts +0 -21
- package/packages/@monomind/shared/dist/events/index.js +0 -22
- package/packages/@monomind/shared/dist/events/projections.d.ts +0 -177
- package/packages/@monomind/shared/dist/events/projections.js +0 -421
- package/packages/@monomind/shared/dist/events/rvf-event-log.d.ts +0 -82
- package/packages/@monomind/shared/dist/events/rvf-event-log.js +0 -340
- package/packages/@monomind/shared/dist/events/state-reconstructor.d.ts +0 -101
- package/packages/@monomind/shared/dist/events/state-reconstructor.js +0 -263
- package/packages/@monomind/shared/dist/events.d.ts +0 -80
- package/packages/@monomind/shared/dist/events.js +0 -249
- package/packages/@monomind/shared/dist/hooks/example-usage.d.ts +0 -42
- package/packages/@monomind/shared/dist/hooks/example-usage.js +0 -351
- package/packages/@monomind/shared/dist/hooks/executor.d.ts +0 -100
- package/packages/@monomind/shared/dist/hooks/executor.js +0 -264
- package/packages/@monomind/shared/dist/hooks/hooks.test.d.ts +0 -9
- package/packages/@monomind/shared/dist/hooks/hooks.test.js +0 -322
- package/packages/@monomind/shared/dist/hooks/index.d.ts +0 -52
- package/packages/@monomind/shared/dist/hooks/index.js +0 -51
- package/packages/@monomind/shared/dist/hooks/registry.d.ts +0 -133
- package/packages/@monomind/shared/dist/hooks/registry.js +0 -277
- package/packages/@monomind/shared/dist/hooks/safety/bash-safety.d.ts +0 -105
- package/packages/@monomind/shared/dist/hooks/safety/bash-safety.js +0 -481
- package/packages/@monomind/shared/dist/hooks/safety/file-organization.d.ts +0 -144
- package/packages/@monomind/shared/dist/hooks/safety/file-organization.js +0 -328
- package/packages/@monomind/shared/dist/hooks/safety/git-commit.d.ts +0 -158
- package/packages/@monomind/shared/dist/hooks/safety/git-commit.js +0 -450
- package/packages/@monomind/shared/dist/hooks/safety/index.d.ts +0 -17
- package/packages/@monomind/shared/dist/hooks/safety/index.js +0 -17
- package/packages/@monomind/shared/dist/hooks/session-hooks.d.ts +0 -234
- package/packages/@monomind/shared/dist/hooks/session-hooks.js +0 -334
- package/packages/@monomind/shared/dist/hooks/task-hooks.d.ts +0 -163
- package/packages/@monomind/shared/dist/hooks/task-hooks.js +0 -326
- package/packages/@monomind/shared/dist/hooks/types.d.ts +0 -267
- package/packages/@monomind/shared/dist/hooks/types.js +0 -62
- package/packages/@monomind/shared/dist/hooks/verify-exports.test.d.ts +0 -9
- package/packages/@monomind/shared/dist/hooks/verify-exports.test.js +0 -93
- package/packages/@monomind/shared/dist/index.d.ts +0 -46
- package/packages/@monomind/shared/dist/index.js +0 -77
- package/packages/@monomind/shared/dist/mcp/connection-pool.d.ts +0 -98
- package/packages/@monomind/shared/dist/mcp/connection-pool.js +0 -364
- package/packages/@monomind/shared/dist/mcp/index.d.ts +0 -69
- package/packages/@monomind/shared/dist/mcp/index.js +0 -84
- package/packages/@monomind/shared/dist/mcp/server.d.ts +0 -166
- package/packages/@monomind/shared/dist/mcp/server.js +0 -593
- package/packages/@monomind/shared/dist/mcp/session-manager.d.ts +0 -136
- package/packages/@monomind/shared/dist/mcp/session-manager.js +0 -335
- package/packages/@monomind/shared/dist/mcp/tool-registry.d.ts +0 -178
- package/packages/@monomind/shared/dist/mcp/tool-registry.js +0 -439
- package/packages/@monomind/shared/dist/mcp/transport/http.d.ts +0 -104
- package/packages/@monomind/shared/dist/mcp/transport/http.js +0 -476
- package/packages/@monomind/shared/dist/mcp/transport/index.d.ts +0 -102
- package/packages/@monomind/shared/dist/mcp/transport/index.js +0 -238
- package/packages/@monomind/shared/dist/mcp/transport/stdio.d.ts +0 -104
- package/packages/@monomind/shared/dist/mcp/transport/stdio.js +0 -263
- package/packages/@monomind/shared/dist/mcp/transport/websocket.d.ts +0 -133
- package/packages/@monomind/shared/dist/mcp/transport/websocket.js +0 -396
- package/packages/@monomind/shared/dist/mcp/types.d.ts +0 -438
- package/packages/@monomind/shared/dist/mcp/types.js +0 -54
- package/packages/@monomind/shared/dist/plugin-interface.d.ts +0 -544
- package/packages/@monomind/shared/dist/plugin-interface.js +0 -23
- package/packages/@monomind/shared/dist/plugin-loader.d.ts +0 -139
- package/packages/@monomind/shared/dist/plugin-loader.js +0 -434
- package/packages/@monomind/shared/dist/plugin-registry.d.ts +0 -183
- package/packages/@monomind/shared/dist/plugin-registry.js +0 -457
- package/packages/@monomind/shared/dist/plugins/index.d.ts +0 -10
- package/packages/@monomind/shared/dist/plugins/index.js +0 -10
- package/packages/@monomind/shared/dist/plugins/official/hive-mind-plugin.d.ts +0 -106
- package/packages/@monomind/shared/dist/plugins/official/hive-mind-plugin.js +0 -241
- package/packages/@monomind/shared/dist/plugins/official/index.d.ts +0 -10
- package/packages/@monomind/shared/dist/plugins/official/index.js +0 -10
- package/packages/@monomind/shared/dist/plugins/official/maestro-plugin.d.ts +0 -121
- package/packages/@monomind/shared/dist/plugins/official/maestro-plugin.js +0 -355
- package/packages/@monomind/shared/dist/plugins/types.d.ts +0 -93
- package/packages/@monomind/shared/dist/plugins/types.js +0 -9
- package/packages/@monomind/shared/dist/reducers.d.ts +0 -33
- package/packages/@monomind/shared/dist/reducers.js +0 -89
- package/packages/@monomind/shared/dist/resilience/bulkhead.d.ts +0 -105
- package/packages/@monomind/shared/dist/resilience/bulkhead.js +0 -206
- package/packages/@monomind/shared/dist/resilience/circuit-breaker.d.ts +0 -132
- package/packages/@monomind/shared/dist/resilience/circuit-breaker.js +0 -233
- package/packages/@monomind/shared/dist/resilience/index.d.ts +0 -19
- package/packages/@monomind/shared/dist/resilience/index.js +0 -19
- package/packages/@monomind/shared/dist/resilience/rate-limiter.d.ts +0 -168
- package/packages/@monomind/shared/dist/resilience/rate-limiter.js +0 -314
- package/packages/@monomind/shared/dist/resilience/retry.d.ts +0 -91
- package/packages/@monomind/shared/dist/resilience/retry.js +0 -159
- package/packages/@monomind/shared/dist/retry-policy.d.ts +0 -14
- package/packages/@monomind/shared/dist/retry-policy.js +0 -23
- package/packages/@monomind/shared/dist/retry-runner.d.ts +0 -21
- package/packages/@monomind/shared/dist/retry-runner.js +0 -57
- package/packages/@monomind/shared/dist/schema-validator.d.ts +0 -46
- package/packages/@monomind/shared/dist/schema-validator.js +0 -133
- package/packages/@monomind/shared/dist/scratchpad.d.ts +0 -23
- package/packages/@monomind/shared/dist/scratchpad.js +0 -32
- package/packages/@monomind/shared/dist/security/index.d.ts +0 -10
- package/packages/@monomind/shared/dist/security/index.js +0 -12
- package/packages/@monomind/shared/dist/security/input-validation.d.ts +0 -73
- package/packages/@monomind/shared/dist/security/input-validation.js +0 -201
- package/packages/@monomind/shared/dist/security/secure-random.d.ts +0 -92
- package/packages/@monomind/shared/dist/security/secure-random.js +0 -142
- package/packages/@monomind/shared/dist/services/index.d.ts +0 -7
- package/packages/@monomind/shared/dist/services/index.js +0 -7
- package/packages/@monomind/shared/dist/services/progress.service.d.ts +0 -124
- package/packages/@monomind/shared/dist/services/progress.service.js +0 -402
- package/packages/@monomind/shared/dist/state-manager.d.ts +0 -34
- package/packages/@monomind/shared/dist/state-manager.js +0 -73
- package/packages/@monomind/shared/dist/state-validator.d.ts +0 -20
- package/packages/@monomind/shared/dist/state-validator.js +0 -49
- package/packages/@monomind/shared/dist/swarm-state.d.ts +0 -52
- package/packages/@monomind/shared/dist/swarm-state.js +0 -18
- package/packages/@monomind/shared/dist/testing/fixture-builder.d.ts +0 -14
- package/packages/@monomind/shared/dist/testing/fixture-builder.js +0 -32
- package/packages/@monomind/shared/dist/testing/index.d.ts +0 -2
- package/packages/@monomind/shared/dist/testing/index.js +0 -2
- package/packages/@monomind/shared/dist/testing/test-model.d.ts +0 -29
- package/packages/@monomind/shared/dist/testing/test-model.js +0 -53
- package/packages/@monomind/shared/dist/types/agent-registry.d.ts +0 -62
- package/packages/@monomind/shared/dist/types/agent-registry.js +0 -8
- package/packages/@monomind/shared/dist/types/agent-version.d.ts +0 -49
- package/packages/@monomind/shared/dist/types/agent-version.js +0 -7
- package/packages/@monomind/shared/dist/types/agent.types.d.ts +0 -137
- package/packages/@monomind/shared/dist/types/agent.types.js +0 -6
- package/packages/@monomind/shared/dist/types/benchmark.d.ts +0 -39
- package/packages/@monomind/shared/dist/types/benchmark.js +0 -6
- package/packages/@monomind/shared/dist/types/communication-flow.d.ts +0 -25
- package/packages/@monomind/shared/dist/types/communication-flow.js +0 -7
- package/packages/@monomind/shared/dist/types/consensus-audit.d.ts +0 -40
- package/packages/@monomind/shared/dist/types/consensus-audit.js +0 -7
- package/packages/@monomind/shared/dist/types/dlq.d.ts +0 -40
- package/packages/@monomind/shared/dist/types/dlq.js +0 -7
- package/packages/@monomind/shared/dist/types/eval.d.ts +0 -59
- package/packages/@monomind/shared/dist/types/eval.js +0 -6
- package/packages/@monomind/shared/dist/types/index.d.ts +0 -19
- package/packages/@monomind/shared/dist/types/index.js +0 -33
- package/packages/@monomind/shared/dist/types/mcp.types.d.ts +0 -266
- package/packages/@monomind/shared/dist/types/mcp.types.js +0 -7
- package/packages/@monomind/shared/dist/types/memory.types.d.ts +0 -236
- package/packages/@monomind/shared/dist/types/memory.types.js +0 -7
- package/packages/@monomind/shared/dist/types/retry.d.ts +0 -72
- package/packages/@monomind/shared/dist/types/retry.js +0 -40
- package/packages/@monomind/shared/dist/types/specialization.d.ts +0 -27
- package/packages/@monomind/shared/dist/types/specialization.js +0 -8
- package/packages/@monomind/shared/dist/types/swarm.types.d.ts +0 -186
- package/packages/@monomind/shared/dist/types/swarm.types.js +0 -65
- package/packages/@monomind/shared/dist/types/task.types.d.ts +0 -178
- package/packages/@monomind/shared/dist/types/task.types.js +0 -32
- package/packages/@monomind/shared/dist/types/termination.d.ts +0 -29
- package/packages/@monomind/shared/dist/types/termination.js +0 -14
- package/packages/@monomind/shared/dist/types/tool-version.d.ts +0 -41
- package/packages/@monomind/shared/dist/types/tool-version.js +0 -8
- package/packages/@monomind/shared/dist/types/trigger.d.ts +0 -40
- package/packages/@monomind/shared/dist/types/trigger.js +0 -8
- package/packages/@monomind/shared/dist/types.d.ts +0 -197
- package/packages/@monomind/shared/dist/types.js +0 -21
- package/packages/@monomind/shared/dist/utils/secure-logger.d.ts +0 -69
- package/packages/@monomind/shared/dist/utils/secure-logger.js +0 -208
- package/packages/@monomind/shared/package.json +0 -42
- package/packages/README.md +0 -513
|
@@ -1,831 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: performance-benchmarker
|
|
3
|
-
description: Implements comprehensive performance benchmarking for distributed consensus protocols
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Performance Benchmarker
|
|
7
|
-
|
|
8
|
-
Implements comprehensive performance benchmarking and optimization analysis for distributed consensus protocols.
|
|
9
|
-
|
|
10
|
-
## Core Responsibilities
|
|
11
|
-
|
|
12
|
-
1. **Protocol Benchmarking**: Measure throughput, latency, and scalability across consensus algorithms
|
|
13
|
-
2. **Resource Monitoring**: Track CPU, memory, network, and storage utilization patterns
|
|
14
|
-
3. **Comparative Analysis**: Compare Byzantine, Raft, and Gossip protocol performance
|
|
15
|
-
4. **Adaptive Tuning**: Implement real-time parameter optimization and load balancing
|
|
16
|
-
5. **Performance Reporting**: Generate actionable insights and optimization recommendations
|
|
17
|
-
|
|
18
|
-
## Technical Implementation
|
|
19
|
-
|
|
20
|
-
### Core Benchmarking Framework
|
|
21
|
-
```javascript
|
|
22
|
-
class ConsensusPerformanceBenchmarker {
|
|
23
|
-
constructor() {
|
|
24
|
-
this.benchmarkSuites = new Map();
|
|
25
|
-
this.performanceMetrics = new Map();
|
|
26
|
-
this.historicalData = new TimeSeriesDatabase();
|
|
27
|
-
this.currentBenchmarks = new Set();
|
|
28
|
-
this.adaptiveOptimizer = new AdaptiveOptimizer();
|
|
29
|
-
this.alertSystem = new PerformanceAlertSystem();
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
// Register benchmark suite for specific consensus protocol
|
|
33
|
-
registerBenchmarkSuite(protocolName, benchmarkConfig) {
|
|
34
|
-
const suite = new BenchmarkSuite(protocolName, benchmarkConfig);
|
|
35
|
-
this.benchmarkSuites.set(protocolName, suite);
|
|
36
|
-
|
|
37
|
-
return suite;
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
// Execute comprehensive performance benchmarks
|
|
41
|
-
async runComprehensiveBenchmarks(protocols, scenarios) {
|
|
42
|
-
const results = new Map();
|
|
43
|
-
|
|
44
|
-
for (const protocol of protocols) {
|
|
45
|
-
const protocolResults = new Map();
|
|
46
|
-
|
|
47
|
-
for (const scenario of scenarios) {
|
|
48
|
-
console.log(`Running ${scenario.name} benchmark for ${protocol}`);
|
|
49
|
-
|
|
50
|
-
const benchmarkResult = await this.executeBenchmarkScenario(
|
|
51
|
-
protocol, scenario
|
|
52
|
-
);
|
|
53
|
-
|
|
54
|
-
protocolResults.set(scenario.name, benchmarkResult);
|
|
55
|
-
|
|
56
|
-
// Store in historical database
|
|
57
|
-
await this.historicalData.store({
|
|
58
|
-
protocol: protocol,
|
|
59
|
-
scenario: scenario.name,
|
|
60
|
-
timestamp: Date.now(),
|
|
61
|
-
metrics: benchmarkResult
|
|
62
|
-
});
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
results.set(protocol, protocolResults);
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
// Generate comparative analysis
|
|
69
|
-
const analysis = await this.generateComparativeAnalysis(results);
|
|
70
|
-
|
|
71
|
-
// Trigger adaptive optimizations
|
|
72
|
-
await this.adaptiveOptimizer.optimizeBasedOnResults(results);
|
|
73
|
-
|
|
74
|
-
return {
|
|
75
|
-
benchmarkResults: results,
|
|
76
|
-
comparativeAnalysis: analysis,
|
|
77
|
-
recommendations: await this.generateOptimizationRecommendations(results)
|
|
78
|
-
};
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
async executeBenchmarkScenario(protocol, scenario) {
|
|
82
|
-
const benchmark = this.benchmarkSuites.get(protocol);
|
|
83
|
-
if (!benchmark) {
|
|
84
|
-
throw new Error(`No benchmark suite found for protocol: ${protocol}`);
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
// Initialize benchmark environment
|
|
88
|
-
const environment = await this.setupBenchmarkEnvironment(scenario);
|
|
89
|
-
|
|
90
|
-
try {
|
|
91
|
-
// Pre-benchmark setup
|
|
92
|
-
await benchmark.setup(environment);
|
|
93
|
-
|
|
94
|
-
// Execute benchmark phases
|
|
95
|
-
const results = {
|
|
96
|
-
throughput: await this.measureThroughput(benchmark, scenario),
|
|
97
|
-
latency: await this.measureLatency(benchmark, scenario),
|
|
98
|
-
resourceUsage: await this.measureResourceUsage(benchmark, scenario),
|
|
99
|
-
scalability: await this.measureScalability(benchmark, scenario),
|
|
100
|
-
faultTolerance: await this.measureFaultTolerance(benchmark, scenario)
|
|
101
|
-
};
|
|
102
|
-
|
|
103
|
-
// Post-benchmark analysis
|
|
104
|
-
results.analysis = await this.analyzeBenchmarkResults(results);
|
|
105
|
-
|
|
106
|
-
return results;
|
|
107
|
-
|
|
108
|
-
} finally {
|
|
109
|
-
// Cleanup benchmark environment
|
|
110
|
-
await this.cleanupBenchmarkEnvironment(environment);
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
|
-
```
|
|
115
|
-
|
|
116
|
-
### Throughput Measurement System
|
|
117
|
-
```javascript
|
|
118
|
-
class ThroughputBenchmark {
|
|
119
|
-
constructor(protocol, configuration) {
|
|
120
|
-
this.protocol = protocol;
|
|
121
|
-
this.config = configuration;
|
|
122
|
-
this.metrics = new MetricsCollector();
|
|
123
|
-
this.loadGenerator = new LoadGenerator();
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
async measureThroughput(scenario) {
|
|
127
|
-
const measurements = [];
|
|
128
|
-
const duration = scenario.duration || 60000; // 1 minute default
|
|
129
|
-
const startTime = Date.now();
|
|
130
|
-
|
|
131
|
-
// Initialize load generator
|
|
132
|
-
await this.loadGenerator.initialize({
|
|
133
|
-
requestRate: scenario.initialRate || 10,
|
|
134
|
-
rampUp: scenario.rampUp || false,
|
|
135
|
-
pattern: scenario.pattern || 'constant'
|
|
136
|
-
});
|
|
137
|
-
|
|
138
|
-
// Start metrics collection
|
|
139
|
-
this.metrics.startCollection(['transactions_per_second', 'success_rate']);
|
|
140
|
-
|
|
141
|
-
let currentRate = scenario.initialRate || 10;
|
|
142
|
-
const rateIncrement = scenario.rateIncrement || 5;
|
|
143
|
-
const measurementInterval = 5000; // 5 seconds
|
|
144
|
-
|
|
145
|
-
while (Date.now() - startTime < duration) {
|
|
146
|
-
const intervalStart = Date.now();
|
|
147
|
-
|
|
148
|
-
// Generate load for this interval
|
|
149
|
-
const transactions = await this.generateTransactionLoad(
|
|
150
|
-
currentRate, measurementInterval
|
|
151
|
-
);
|
|
152
|
-
|
|
153
|
-
// Measure throughput for this interval
|
|
154
|
-
const intervalMetrics = await this.measureIntervalThroughput(
|
|
155
|
-
transactions, measurementInterval
|
|
156
|
-
);
|
|
157
|
-
|
|
158
|
-
measurements.push({
|
|
159
|
-
timestamp: intervalStart,
|
|
160
|
-
requestRate: currentRate,
|
|
161
|
-
actualThroughput: intervalMetrics.throughput,
|
|
162
|
-
successRate: intervalMetrics.successRate,
|
|
163
|
-
averageLatency: intervalMetrics.averageLatency,
|
|
164
|
-
p95Latency: intervalMetrics.p95Latency,
|
|
165
|
-
p99Latency: intervalMetrics.p99Latency
|
|
166
|
-
});
|
|
167
|
-
|
|
168
|
-
// Adaptive rate adjustment
|
|
169
|
-
if (scenario.rampUp && intervalMetrics.successRate > 0.95) {
|
|
170
|
-
currentRate += rateIncrement;
|
|
171
|
-
} else if (intervalMetrics.successRate < 0.8) {
|
|
172
|
-
currentRate = Math.max(1, currentRate - rateIncrement);
|
|
173
|
-
}
|
|
174
|
-
|
|
175
|
-
// Wait for next interval
|
|
176
|
-
const elapsed = Date.now() - intervalStart;
|
|
177
|
-
if (elapsed < measurementInterval) {
|
|
178
|
-
await this.sleep(measurementInterval - elapsed);
|
|
179
|
-
}
|
|
180
|
-
}
|
|
181
|
-
|
|
182
|
-
// Stop metrics collection
|
|
183
|
-
this.metrics.stopCollection();
|
|
184
|
-
|
|
185
|
-
// Analyze throughput results
|
|
186
|
-
return this.analyzeThroughputMeasurements(measurements);
|
|
187
|
-
}
|
|
188
|
-
|
|
189
|
-
async generateTransactionLoad(rate, duration) {
|
|
190
|
-
const transactions = [];
|
|
191
|
-
const interval = 1000 / rate; // Interval between transactions in ms
|
|
192
|
-
const endTime = Date.now() + duration;
|
|
193
|
-
|
|
194
|
-
while (Date.now() < endTime) {
|
|
195
|
-
const transactionStart = Date.now();
|
|
196
|
-
|
|
197
|
-
const transaction = {
|
|
198
|
-
id: `tx_${Date.now()}_${Math.random()}`,
|
|
199
|
-
type: this.getRandomTransactionType(),
|
|
200
|
-
data: this.generateTransactionData(),
|
|
201
|
-
timestamp: transactionStart
|
|
202
|
-
};
|
|
203
|
-
|
|
204
|
-
// Submit transaction to consensus protocol
|
|
205
|
-
const promise = this.protocol.submitTransaction(transaction)
|
|
206
|
-
.then(result => ({
|
|
207
|
-
...transaction,
|
|
208
|
-
result: result,
|
|
209
|
-
latency: Date.now() - transactionStart,
|
|
210
|
-
success: result.committed === true
|
|
211
|
-
}))
|
|
212
|
-
.catch(error => ({
|
|
213
|
-
...transaction,
|
|
214
|
-
error: error,
|
|
215
|
-
latency: Date.now() - transactionStart,
|
|
216
|
-
success: false
|
|
217
|
-
}));
|
|
218
|
-
|
|
219
|
-
transactions.push(promise);
|
|
220
|
-
|
|
221
|
-
// Wait for next transaction interval
|
|
222
|
-
await this.sleep(interval);
|
|
223
|
-
}
|
|
224
|
-
|
|
225
|
-
// Wait for all transactions to complete
|
|
226
|
-
return await Promise.all(transactions);
|
|
227
|
-
}
|
|
228
|
-
|
|
229
|
-
analyzeThroughputMeasurements(measurements) {
|
|
230
|
-
const totalMeasurements = measurements.length;
|
|
231
|
-
const avgThroughput = measurements.reduce((sum, m) => sum + m.actualThroughput, 0) / totalMeasurements;
|
|
232
|
-
const maxThroughput = Math.max(...measurements.map(m => m.actualThroughput));
|
|
233
|
-
const avgSuccessRate = measurements.reduce((sum, m) => sum + m.successRate, 0) / totalMeasurements;
|
|
234
|
-
|
|
235
|
-
// Find optimal operating point (highest throughput with >95% success rate)
|
|
236
|
-
const optimalPoints = measurements.filter(m => m.successRate >= 0.95);
|
|
237
|
-
const optimalThroughput = optimalPoints.length > 0 ?
|
|
238
|
-
Math.max(...optimalPoints.map(m => m.actualThroughput)) : 0;
|
|
239
|
-
|
|
240
|
-
return {
|
|
241
|
-
averageThroughput: avgThroughput,
|
|
242
|
-
maxThroughput: maxThroughput,
|
|
243
|
-
optimalThroughput: optimalThroughput,
|
|
244
|
-
averageSuccessRate: avgSuccessRate,
|
|
245
|
-
measurements: measurements,
|
|
246
|
-
sustainableThroughput: this.calculateSustainableThroughput(measurements),
|
|
247
|
-
throughputVariability: this.calculateThroughputVariability(measurements)
|
|
248
|
-
};
|
|
249
|
-
}
|
|
250
|
-
|
|
251
|
-
calculateSustainableThroughput(measurements) {
|
|
252
|
-
// Find the highest throughput that can be sustained for >80% of the time
|
|
253
|
-
const sortedThroughputs = measurements.map(m => m.actualThroughput).sort((a, b) => b - a);
|
|
254
|
-
const p80Index = Math.floor(sortedThroughputs.length * 0.2);
|
|
255
|
-
return sortedThroughputs[p80Index];
|
|
256
|
-
}
|
|
257
|
-
}
|
|
258
|
-
```
|
|
259
|
-
|
|
260
|
-
### Latency Analysis System
|
|
261
|
-
```javascript
|
|
262
|
-
class LatencyBenchmark {
|
|
263
|
-
constructor(protocol, configuration) {
|
|
264
|
-
this.protocol = protocol;
|
|
265
|
-
this.config = configuration;
|
|
266
|
-
this.latencyHistogram = new LatencyHistogram();
|
|
267
|
-
this.percentileCalculator = new PercentileCalculator();
|
|
268
|
-
}
|
|
269
|
-
|
|
270
|
-
async measureLatency(scenario) {
|
|
271
|
-
const measurements = [];
|
|
272
|
-
const sampleSize = scenario.sampleSize || 10000;
|
|
273
|
-
const warmupSize = scenario.warmupSize || 1000;
|
|
274
|
-
|
|
275
|
-
console.log(`Measuring latency with ${sampleSize} samples (${warmupSize} warmup)`);
|
|
276
|
-
|
|
277
|
-
// Warmup phase
|
|
278
|
-
await this.performWarmup(warmupSize);
|
|
279
|
-
|
|
280
|
-
// Measurement phase
|
|
281
|
-
for (let i = 0; i < sampleSize; i++) {
|
|
282
|
-
const latencyMeasurement = await this.measureSingleTransactionLatency();
|
|
283
|
-
measurements.push(latencyMeasurement);
|
|
284
|
-
|
|
285
|
-
// Progress reporting
|
|
286
|
-
if (i % 1000 === 0) {
|
|
287
|
-
console.log(`Completed ${i}/${sampleSize} latency measurements`);
|
|
288
|
-
}
|
|
289
|
-
}
|
|
290
|
-
|
|
291
|
-
// Analyze latency distribution
|
|
292
|
-
return this.analyzeLatencyDistribution(measurements);
|
|
293
|
-
}
|
|
294
|
-
|
|
295
|
-
async measureSingleTransactionLatency() {
|
|
296
|
-
const transaction = {
|
|
297
|
-
id: `latency_tx_${Date.now()}_${Math.random()}`,
|
|
298
|
-
type: 'benchmark',
|
|
299
|
-
data: { value: Math.random() },
|
|
300
|
-
phases: {}
|
|
301
|
-
};
|
|
302
|
-
|
|
303
|
-
// Phase 1: Submission
|
|
304
|
-
const submissionStart = performance.now();
|
|
305
|
-
const submissionPromise = this.protocol.submitTransaction(transaction);
|
|
306
|
-
transaction.phases.submission = performance.now() - submissionStart;
|
|
307
|
-
|
|
308
|
-
// Phase 2: Consensus
|
|
309
|
-
const consensusStart = performance.now();
|
|
310
|
-
const result = await submissionPromise;
|
|
311
|
-
transaction.phases.consensus = performance.now() - consensusStart;
|
|
312
|
-
|
|
313
|
-
// Phase 3: Application (if applicable)
|
|
314
|
-
let applicationLatency = 0;
|
|
315
|
-
if (result.applicationTime) {
|
|
316
|
-
applicationLatency = result.applicationTime;
|
|
317
|
-
}
|
|
318
|
-
transaction.phases.application = applicationLatency;
|
|
319
|
-
|
|
320
|
-
// Total end-to-end latency
|
|
321
|
-
const totalLatency = transaction.phases.submission +
|
|
322
|
-
transaction.phases.consensus +
|
|
323
|
-
transaction.phases.application;
|
|
324
|
-
|
|
325
|
-
return {
|
|
326
|
-
transactionId: transaction.id,
|
|
327
|
-
totalLatency: totalLatency,
|
|
328
|
-
phases: transaction.phases,
|
|
329
|
-
success: result.committed === true,
|
|
330
|
-
timestamp: Date.now()
|
|
331
|
-
};
|
|
332
|
-
}
|
|
333
|
-
|
|
334
|
-
analyzeLatencyDistribution(measurements) {
|
|
335
|
-
const successfulMeasurements = measurements.filter(m => m.success);
|
|
336
|
-
const latencies = successfulMeasurements.map(m => m.totalLatency);
|
|
337
|
-
|
|
338
|
-
if (latencies.length === 0) {
|
|
339
|
-
throw new Error('No successful latency measurements');
|
|
340
|
-
}
|
|
341
|
-
|
|
342
|
-
// Calculate percentiles
|
|
343
|
-
const percentiles = this.percentileCalculator.calculate(latencies, [
|
|
344
|
-
50, 75, 90, 95, 99, 99.9, 99.99
|
|
345
|
-
]);
|
|
346
|
-
|
|
347
|
-
// Phase-specific analysis
|
|
348
|
-
const phaseAnalysis = this.analyzePhaseLatencies(successfulMeasurements);
|
|
349
|
-
|
|
350
|
-
// Latency distribution analysis
|
|
351
|
-
const distribution = this.analyzeLatencyHistogram(latencies);
|
|
352
|
-
|
|
353
|
-
return {
|
|
354
|
-
sampleSize: successfulMeasurements.length,
|
|
355
|
-
mean: latencies.reduce((sum, l) => sum + l, 0) / latencies.length,
|
|
356
|
-
median: percentiles[50],
|
|
357
|
-
standardDeviation: this.calculateStandardDeviation(latencies),
|
|
358
|
-
percentiles: percentiles,
|
|
359
|
-
phaseAnalysis: phaseAnalysis,
|
|
360
|
-
distribution: distribution,
|
|
361
|
-
outliers: this.identifyLatencyOutliers(latencies)
|
|
362
|
-
};
|
|
363
|
-
}
|
|
364
|
-
|
|
365
|
-
analyzePhaseLatencies(measurements) {
|
|
366
|
-
const phases = ['submission', 'consensus', 'application'];
|
|
367
|
-
const phaseAnalysis = {};
|
|
368
|
-
|
|
369
|
-
for (const phase of phases) {
|
|
370
|
-
const phaseLatencies = measurements.map(m => m.phases[phase]);
|
|
371
|
-
const validLatencies = phaseLatencies.filter(l => l > 0);
|
|
372
|
-
|
|
373
|
-
if (validLatencies.length > 0) {
|
|
374
|
-
phaseAnalysis[phase] = {
|
|
375
|
-
mean: validLatencies.reduce((sum, l) => sum + l, 0) / validLatencies.length,
|
|
376
|
-
p50: this.percentileCalculator.calculate(validLatencies, [50])[50],
|
|
377
|
-
p95: this.percentileCalculator.calculate(validLatencies, [95])[95],
|
|
378
|
-
p99: this.percentileCalculator.calculate(validLatencies, [99])[99],
|
|
379
|
-
max: Math.max(...validLatencies),
|
|
380
|
-
contributionPercent: (validLatencies.reduce((sum, l) => sum + l, 0) /
|
|
381
|
-
measurements.reduce((sum, m) => sum + m.totalLatency, 0)) * 100
|
|
382
|
-
};
|
|
383
|
-
}
|
|
384
|
-
}
|
|
385
|
-
|
|
386
|
-
return phaseAnalysis;
|
|
387
|
-
}
|
|
388
|
-
}
|
|
389
|
-
```
|
|
390
|
-
|
|
391
|
-
### Resource Usage Monitor
|
|
392
|
-
```javascript
|
|
393
|
-
class ResourceUsageMonitor {
|
|
394
|
-
constructor() {
|
|
395
|
-
this.monitoringActive = false;
|
|
396
|
-
this.samplingInterval = 1000; // 1 second
|
|
397
|
-
this.measurements = [];
|
|
398
|
-
this.systemMonitor = new SystemMonitor();
|
|
399
|
-
}
|
|
400
|
-
|
|
401
|
-
async measureResourceUsage(protocol, scenario) {
|
|
402
|
-
console.log('Starting resource usage monitoring');
|
|
403
|
-
|
|
404
|
-
this.monitoringActive = true;
|
|
405
|
-
this.measurements = [];
|
|
406
|
-
|
|
407
|
-
// Start monitoring in background
|
|
408
|
-
const monitoringPromise = this.startContinuousMonitoring();
|
|
409
|
-
|
|
410
|
-
try {
|
|
411
|
-
// Execute the benchmark scenario
|
|
412
|
-
const benchmarkResult = await this.executeBenchmarkWithMonitoring(
|
|
413
|
-
protocol, scenario
|
|
414
|
-
);
|
|
415
|
-
|
|
416
|
-
// Stop monitoring
|
|
417
|
-
this.monitoringActive = false;
|
|
418
|
-
await monitoringPromise;
|
|
419
|
-
|
|
420
|
-
// Analyze resource usage
|
|
421
|
-
const resourceAnalysis = this.analyzeResourceUsage();
|
|
422
|
-
|
|
423
|
-
return {
|
|
424
|
-
benchmarkResult: benchmarkResult,
|
|
425
|
-
resourceUsage: resourceAnalysis
|
|
426
|
-
};
|
|
427
|
-
|
|
428
|
-
} catch (error) {
|
|
429
|
-
this.monitoringActive = false;
|
|
430
|
-
throw error;
|
|
431
|
-
}
|
|
432
|
-
}
|
|
433
|
-
|
|
434
|
-
async startContinuousMonitoring() {
|
|
435
|
-
while (this.monitoringActive) {
|
|
436
|
-
const measurement = await this.collectResourceMeasurement();
|
|
437
|
-
this.measurements.push(measurement);
|
|
438
|
-
|
|
439
|
-
await this.sleep(this.samplingInterval);
|
|
440
|
-
}
|
|
441
|
-
}
|
|
442
|
-
|
|
443
|
-
async collectResourceMeasurement() {
|
|
444
|
-
const timestamp = Date.now();
|
|
445
|
-
|
|
446
|
-
// CPU usage
|
|
447
|
-
const cpuUsage = await this.systemMonitor.getCPUUsage();
|
|
448
|
-
|
|
449
|
-
// Memory usage
|
|
450
|
-
const memoryUsage = await this.systemMonitor.getMemoryUsage();
|
|
451
|
-
|
|
452
|
-
// Network I/O
|
|
453
|
-
const networkIO = await this.systemMonitor.getNetworkIO();
|
|
454
|
-
|
|
455
|
-
// Disk I/O
|
|
456
|
-
const diskIO = await this.systemMonitor.getDiskIO();
|
|
457
|
-
|
|
458
|
-
// Process-specific metrics
|
|
459
|
-
const processMetrics = await this.systemMonitor.getProcessMetrics();
|
|
460
|
-
|
|
461
|
-
return {
|
|
462
|
-
timestamp: timestamp,
|
|
463
|
-
cpu: {
|
|
464
|
-
totalUsage: cpuUsage.total,
|
|
465
|
-
consensusUsage: cpuUsage.process,
|
|
466
|
-
loadAverage: cpuUsage.loadAverage,
|
|
467
|
-
coreUsage: cpuUsage.cores
|
|
468
|
-
},
|
|
469
|
-
memory: {
|
|
470
|
-
totalUsed: memoryUsage.used,
|
|
471
|
-
totalAvailable: memoryUsage.available,
|
|
472
|
-
processRSS: memoryUsage.processRSS,
|
|
473
|
-
processHeap: memoryUsage.processHeap,
|
|
474
|
-
gcStats: memoryUsage.gcStats
|
|
475
|
-
},
|
|
476
|
-
network: {
|
|
477
|
-
bytesIn: networkIO.bytesIn,
|
|
478
|
-
bytesOut: networkIO.bytesOut,
|
|
479
|
-
packetsIn: networkIO.packetsIn,
|
|
480
|
-
packetsOut: networkIO.packetsOut,
|
|
481
|
-
connectionsActive: networkIO.connectionsActive
|
|
482
|
-
},
|
|
483
|
-
disk: {
|
|
484
|
-
bytesRead: diskIO.bytesRead,
|
|
485
|
-
bytesWritten: diskIO.bytesWritten,
|
|
486
|
-
operationsRead: diskIO.operationsRead,
|
|
487
|
-
operationsWrite: diskIO.operationsWrite,
|
|
488
|
-
queueLength: diskIO.queueLength
|
|
489
|
-
},
|
|
490
|
-
process: {
|
|
491
|
-
consensusThreads: processMetrics.consensusThreads,
|
|
492
|
-
fileDescriptors: processMetrics.fileDescriptors,
|
|
493
|
-
uptime: processMetrics.uptime
|
|
494
|
-
}
|
|
495
|
-
};
|
|
496
|
-
}
|
|
497
|
-
|
|
498
|
-
analyzeResourceUsage() {
|
|
499
|
-
if (this.measurements.length === 0) {
|
|
500
|
-
return null;
|
|
501
|
-
}
|
|
502
|
-
|
|
503
|
-
const cpuAnalysis = this.analyzeCPUUsage();
|
|
504
|
-
const memoryAnalysis = this.analyzeMemoryUsage();
|
|
505
|
-
const networkAnalysis = this.analyzeNetworkUsage();
|
|
506
|
-
const diskAnalysis = this.analyzeDiskUsage();
|
|
507
|
-
|
|
508
|
-
return {
|
|
509
|
-
duration: this.measurements[this.measurements.length - 1].timestamp -
|
|
510
|
-
this.measurements[0].timestamp,
|
|
511
|
-
sampleCount: this.measurements.length,
|
|
512
|
-
cpu: cpuAnalysis,
|
|
513
|
-
memory: memoryAnalysis,
|
|
514
|
-
network: networkAnalysis,
|
|
515
|
-
disk: diskAnalysis,
|
|
516
|
-
efficiency: this.calculateResourceEfficiency(),
|
|
517
|
-
bottlenecks: this.identifyResourceBottlenecks()
|
|
518
|
-
};
|
|
519
|
-
}
|
|
520
|
-
|
|
521
|
-
analyzeCPUUsage() {
|
|
522
|
-
const cpuUsages = this.measurements.map(m => m.cpu.consensusUsage);
|
|
523
|
-
|
|
524
|
-
return {
|
|
525
|
-
average: cpuUsages.reduce((sum, usage) => sum + usage, 0) / cpuUsages.length,
|
|
526
|
-
peak: Math.max(...cpuUsages),
|
|
527
|
-
p95: this.calculatePercentile(cpuUsages, 95),
|
|
528
|
-
variability: this.calculateStandardDeviation(cpuUsages),
|
|
529
|
-
coreUtilization: this.analyzeCoreUtilization(),
|
|
530
|
-
trends: this.analyzeCPUTrends()
|
|
531
|
-
};
|
|
532
|
-
}
|
|
533
|
-
|
|
534
|
-
analyzeMemoryUsage() {
|
|
535
|
-
const memoryUsages = this.measurements.map(m => m.memory.processRSS);
|
|
536
|
-
const heapUsages = this.measurements.map(m => m.memory.processHeap);
|
|
537
|
-
|
|
538
|
-
return {
|
|
539
|
-
averageRSS: memoryUsages.reduce((sum, usage) => sum + usage, 0) / memoryUsages.length,
|
|
540
|
-
peakRSS: Math.max(...memoryUsages),
|
|
541
|
-
averageHeap: heapUsages.reduce((sum, usage) => sum + usage, 0) / heapUsages.length,
|
|
542
|
-
peakHeap: Math.max(...heapUsages),
|
|
543
|
-
memoryLeaks: this.detectMemoryLeaks(),
|
|
544
|
-
gcImpact: this.analyzeGCImpact(),
|
|
545
|
-
growth: this.calculateMemoryGrowth()
|
|
546
|
-
};
|
|
547
|
-
}
|
|
548
|
-
|
|
549
|
-
identifyResourceBottlenecks() {
|
|
550
|
-
const bottlenecks = [];
|
|
551
|
-
|
|
552
|
-
// CPU bottleneck detection
|
|
553
|
-
const avgCPU = this.measurements.reduce((sum, m) => sum + m.cpu.consensusUsage, 0) /
|
|
554
|
-
this.measurements.length;
|
|
555
|
-
if (avgCPU > 80) {
|
|
556
|
-
bottlenecks.push({
|
|
557
|
-
type: 'CPU',
|
|
558
|
-
severity: 'HIGH',
|
|
559
|
-
description: `High CPU usage (${avgCPU.toFixed(1)}%)`
|
|
560
|
-
});
|
|
561
|
-
}
|
|
562
|
-
|
|
563
|
-
// Memory bottleneck detection
|
|
564
|
-
const memoryGrowth = this.calculateMemoryGrowth();
|
|
565
|
-
if (memoryGrowth.rate > 1024 * 1024) { // 1MB/s growth
|
|
566
|
-
bottlenecks.push({
|
|
567
|
-
type: 'MEMORY',
|
|
568
|
-
severity: 'MEDIUM',
|
|
569
|
-
description: `High memory growth rate (${(memoryGrowth.rate / 1024 / 1024).toFixed(2)} MB/s)`
|
|
570
|
-
});
|
|
571
|
-
}
|
|
572
|
-
|
|
573
|
-
// Network bottleneck detection
|
|
574
|
-
const avgNetworkOut = this.measurements.reduce((sum, m) => sum + m.network.bytesOut, 0) /
|
|
575
|
-
this.measurements.length;
|
|
576
|
-
if (avgNetworkOut > 100 * 1024 * 1024) { // 100 MB/s
|
|
577
|
-
bottlenecks.push({
|
|
578
|
-
type: 'NETWORK',
|
|
579
|
-
severity: 'MEDIUM',
|
|
580
|
-
description: `High network output (${(avgNetworkOut / 1024 / 1024).toFixed(2)} MB/s)`
|
|
581
|
-
});
|
|
582
|
-
}
|
|
583
|
-
|
|
584
|
-
return bottlenecks;
|
|
585
|
-
}
|
|
586
|
-
}
|
|
587
|
-
```
|
|
588
|
-
|
|
589
|
-
### Adaptive Performance Optimizer
|
|
590
|
-
```javascript
|
|
591
|
-
class AdaptiveOptimizer {
|
|
592
|
-
constructor() {
|
|
593
|
-
this.optimizationHistory = new Map();
|
|
594
|
-
this.performanceModel = new PerformanceModel();
|
|
595
|
-
this.parameterTuner = new ParameterTuner();
|
|
596
|
-
this.currentOptimizations = new Map();
|
|
597
|
-
}
|
|
598
|
-
|
|
599
|
-
async optimizeBasedOnResults(benchmarkResults) {
|
|
600
|
-
const optimizations = [];
|
|
601
|
-
|
|
602
|
-
for (const [protocol, results] of benchmarkResults) {
|
|
603
|
-
const protocolOptimizations = await this.optimizeProtocol(protocol, results);
|
|
604
|
-
optimizations.push(...protocolOptimizations);
|
|
605
|
-
}
|
|
606
|
-
|
|
607
|
-
// Apply optimizations gradually
|
|
608
|
-
await this.applyOptimizations(optimizations);
|
|
609
|
-
|
|
610
|
-
return optimizations;
|
|
611
|
-
}
|
|
612
|
-
|
|
613
|
-
async optimizeProtocol(protocol, results) {
|
|
614
|
-
const optimizations = [];
|
|
615
|
-
|
|
616
|
-
// Analyze performance bottlenecks
|
|
617
|
-
const bottlenecks = this.identifyPerformanceBottlenecks(results);
|
|
618
|
-
|
|
619
|
-
for (const bottleneck of bottlenecks) {
|
|
620
|
-
const optimization = await this.generateOptimization(protocol, bottleneck);
|
|
621
|
-
if (optimization) {
|
|
622
|
-
optimizations.push(optimization);
|
|
623
|
-
}
|
|
624
|
-
}
|
|
625
|
-
|
|
626
|
-
// Parameter tuning based on performance characteristics
|
|
627
|
-
const parameterOptimizations = await this.tuneParameters(protocol, results);
|
|
628
|
-
optimizations.push(...parameterOptimizations);
|
|
629
|
-
|
|
630
|
-
return optimizations;
|
|
631
|
-
}
|
|
632
|
-
|
|
633
|
-
identifyPerformanceBottlenecks(results) {
|
|
634
|
-
const bottlenecks = [];
|
|
635
|
-
|
|
636
|
-
// Throughput bottlenecks
|
|
637
|
-
for (const [scenario, result] of results) {
|
|
638
|
-
if (result.throughput && result.throughput.optimalThroughput < result.throughput.maxThroughput * 0.8) {
|
|
639
|
-
bottlenecks.push({
|
|
640
|
-
type: 'THROUGHPUT_DEGRADATION',
|
|
641
|
-
scenario: scenario,
|
|
642
|
-
severity: 'HIGH',
|
|
643
|
-
impact: (result.throughput.maxThroughput - result.throughput.optimalThroughput) /
|
|
644
|
-
result.throughput.maxThroughput,
|
|
645
|
-
details: result.throughput
|
|
646
|
-
});
|
|
647
|
-
}
|
|
648
|
-
|
|
649
|
-
// Latency bottlenecks
|
|
650
|
-
if (result.latency && result.latency.p99 > result.latency.p50 * 10) {
|
|
651
|
-
bottlenecks.push({
|
|
652
|
-
type: 'LATENCY_TAIL',
|
|
653
|
-
scenario: scenario,
|
|
654
|
-
severity: 'MEDIUM',
|
|
655
|
-
impact: result.latency.p99 / result.latency.p50,
|
|
656
|
-
details: result.latency
|
|
657
|
-
});
|
|
658
|
-
}
|
|
659
|
-
|
|
660
|
-
// Resource bottlenecks
|
|
661
|
-
if (result.resourceUsage && result.resourceUsage.bottlenecks.length > 0) {
|
|
662
|
-
bottlenecks.push({
|
|
663
|
-
type: 'RESOURCE_CONSTRAINT',
|
|
664
|
-
scenario: scenario,
|
|
665
|
-
severity: 'HIGH',
|
|
666
|
-
details: result.resourceUsage.bottlenecks
|
|
667
|
-
});
|
|
668
|
-
}
|
|
669
|
-
}
|
|
670
|
-
|
|
671
|
-
return bottlenecks;
|
|
672
|
-
}
|
|
673
|
-
|
|
674
|
-
async generateOptimization(protocol, bottleneck) {
|
|
675
|
-
switch (bottleneck.type) {
|
|
676
|
-
case 'THROUGHPUT_DEGRADATION':
|
|
677
|
-
return await this.optimizeThroughput(protocol, bottleneck);
|
|
678
|
-
case 'LATENCY_TAIL':
|
|
679
|
-
return await this.optimizeLatency(protocol, bottleneck);
|
|
680
|
-
case 'RESOURCE_CONSTRAINT':
|
|
681
|
-
return await this.optimizeResourceUsage(protocol, bottleneck);
|
|
682
|
-
default:
|
|
683
|
-
return null;
|
|
684
|
-
}
|
|
685
|
-
}
|
|
686
|
-
|
|
687
|
-
async optimizeThroughput(protocol, bottleneck) {
|
|
688
|
-
const optimizations = [];
|
|
689
|
-
|
|
690
|
-
// Batch size optimization
|
|
691
|
-
if (protocol === 'raft') {
|
|
692
|
-
optimizations.push({
|
|
693
|
-
type: 'PARAMETER_ADJUSTMENT',
|
|
694
|
-
parameter: 'max_batch_size',
|
|
695
|
-
currentValue: await this.getCurrentParameter(protocol, 'max_batch_size'),
|
|
696
|
-
recommendedValue: this.calculateOptimalBatchSize(bottleneck.details),
|
|
697
|
-
expectedImprovement: '15-25% throughput increase',
|
|
698
|
-
confidence: 0.8
|
|
699
|
-
});
|
|
700
|
-
}
|
|
701
|
-
|
|
702
|
-
// Pipelining optimization
|
|
703
|
-
if (protocol === 'byzantine') {
|
|
704
|
-
optimizations.push({
|
|
705
|
-
type: 'FEATURE_ENABLE',
|
|
706
|
-
feature: 'request_pipelining',
|
|
707
|
-
description: 'Enable request pipelining to improve throughput',
|
|
708
|
-
expectedImprovement: '20-30% throughput increase',
|
|
709
|
-
confidence: 0.7
|
|
710
|
-
});
|
|
711
|
-
}
|
|
712
|
-
|
|
713
|
-
return optimizations.length > 0 ? optimizations[0] : null;
|
|
714
|
-
}
|
|
715
|
-
|
|
716
|
-
async tuneParameters(protocol, results) {
|
|
717
|
-
const optimizations = [];
|
|
718
|
-
|
|
719
|
-
// Use machine learning model to suggest parameter values
|
|
720
|
-
const parameterSuggestions = await this.performanceModel.suggestParameters(
|
|
721
|
-
protocol, results
|
|
722
|
-
);
|
|
723
|
-
|
|
724
|
-
for (const suggestion of parameterSuggestions) {
|
|
725
|
-
if (suggestion.confidence > 0.6) {
|
|
726
|
-
optimizations.push({
|
|
727
|
-
type: 'PARAMETER_TUNING',
|
|
728
|
-
parameter: suggestion.parameter,
|
|
729
|
-
currentValue: suggestion.currentValue,
|
|
730
|
-
recommendedValue: suggestion.recommendedValue,
|
|
731
|
-
expectedImprovement: suggestion.expectedImprovement,
|
|
732
|
-
confidence: suggestion.confidence,
|
|
733
|
-
rationale: suggestion.rationale
|
|
734
|
-
});
|
|
735
|
-
}
|
|
736
|
-
}
|
|
737
|
-
|
|
738
|
-
return optimizations;
|
|
739
|
-
}
|
|
740
|
-
|
|
741
|
-
async applyOptimizations(optimizations) {
|
|
742
|
-
// Sort by confidence and expected impact
|
|
743
|
-
const sortedOptimizations = optimizations.sort((a, b) =>
|
|
744
|
-
(b.confidence * parseFloat(b.expectedImprovement)) -
|
|
745
|
-
(a.confidence * parseFloat(a.expectedImprovement))
|
|
746
|
-
);
|
|
747
|
-
|
|
748
|
-
// Apply optimizations gradually
|
|
749
|
-
for (const optimization of sortedOptimizations) {
|
|
750
|
-
try {
|
|
751
|
-
await this.applyOptimization(optimization);
|
|
752
|
-
|
|
753
|
-
// Wait and measure impact
|
|
754
|
-
await this.sleep(30000); // 30 seconds
|
|
755
|
-
const impact = await this.measureOptimizationImpact(optimization);
|
|
756
|
-
|
|
757
|
-
if (impact.improvement < 0.05) {
|
|
758
|
-
// Revert if improvement is less than 5%
|
|
759
|
-
await this.revertOptimization(optimization);
|
|
760
|
-
} else {
|
|
761
|
-
// Keep optimization and record success
|
|
762
|
-
this.recordOptimizationSuccess(optimization, impact);
|
|
763
|
-
}
|
|
764
|
-
|
|
765
|
-
} catch (error) {
|
|
766
|
-
console.error(`Failed to apply optimization:`, error);
|
|
767
|
-
await this.revertOptimization(optimization);
|
|
768
|
-
}
|
|
769
|
-
}
|
|
770
|
-
}
|
|
771
|
-
}
|
|
772
|
-
```
|
|
773
|
-
|
|
774
|
-
## MCP Integration Hooks
|
|
775
|
-
|
|
776
|
-
### Performance Metrics Storage
|
|
777
|
-
```javascript
|
|
778
|
-
// Store comprehensive benchmark results
|
|
779
|
-
await this.mcpTools.memory_usage({
|
|
780
|
-
action: 'store',
|
|
781
|
-
key: `benchmark_results_${protocol}_${Date.now()}`,
|
|
782
|
-
value: JSON.stringify({
|
|
783
|
-
protocol: protocol,
|
|
784
|
-
timestamp: Date.now(),
|
|
785
|
-
throughput: throughputResults,
|
|
786
|
-
latency: latencyResults,
|
|
787
|
-
resourceUsage: resourceResults,
|
|
788
|
-
optimizations: appliedOptimizations
|
|
789
|
-
}),
|
|
790
|
-
namespace: 'performance_benchmarks',
|
|
791
|
-
ttl: 604800000 // 7 days
|
|
792
|
-
});
|
|
793
|
-
|
|
794
|
-
// Real-time performance monitoring
|
|
795
|
-
await this.mcpTools.metrics_collect({
|
|
796
|
-
components: [
|
|
797
|
-
'consensus_throughput',
|
|
798
|
-
'consensus_latency_p99',
|
|
799
|
-
'cpu_utilization',
|
|
800
|
-
'memory_usage',
|
|
801
|
-
'network_io_rate'
|
|
802
|
-
]
|
|
803
|
-
});
|
|
804
|
-
```
|
|
805
|
-
|
|
806
|
-
### Neural Performance Learning
|
|
807
|
-
```javascript
|
|
808
|
-
// Learn performance optimization patterns
|
|
809
|
-
await this.mcpTools.neural_patterns({
|
|
810
|
-
action: 'learn',
|
|
811
|
-
operation: 'performance_optimization',
|
|
812
|
-
outcome: JSON.stringify({
|
|
813
|
-
optimizationType: optimization.type,
|
|
814
|
-
performanceGain: measurementResults.improvement,
|
|
815
|
-
resourceImpact: measurementResults.resourceDelta,
|
|
816
|
-
networkConditions: currentNetworkState
|
|
817
|
-
})
|
|
818
|
-
});
|
|
819
|
-
|
|
820
|
-
// Predict optimal configurations
|
|
821
|
-
const configPrediction = await this.mcpTools.neural_predict({
|
|
822
|
-
modelId: 'consensus_performance_model',
|
|
823
|
-
input: JSON.stringify({
|
|
824
|
-
workloadPattern: currentWorkload,
|
|
825
|
-
networkTopology: networkState,
|
|
826
|
-
resourceConstraints: systemResources
|
|
827
|
-
})
|
|
828
|
-
});
|
|
829
|
-
```
|
|
830
|
-
|
|
831
|
-
This Performance Benchmarker provides comprehensive performance analysis, optimization recommendations, and adaptive tuning capabilities for distributed consensus protocols.
|