claude-flow-novice 1.6.1 → 1.6.3
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/.claude/agents/cfn-loop/product-owner.md +54 -4
- package/.claude/commands/cfn-claude-sync.md +303 -0
- package/.claude/commands/cfn-loop-epic.md +290 -0
- package/.claude/commands/cfn-loop-single.md +168 -0
- package/.claude/commands/cfn-loop-sprints.md +384 -0
- package/.claude/commands/cfn-loop.md +180 -0
- package/.claude/commands/metrics-summary.md +58 -0
- package/.claude/commands/parse-epic.md +357 -0
- package/.claude/settings.json +5 -4
- package/.claude/settings.local.json +9 -2
- package/.claude-flow-novice/.claude/agents/cfn-loop/product-owner.md +792 -0
- package/.claude-flow-novice/dist/mcp/server.js +21 -2
- package/.claude-flow-novice/dist/src/api/auth-service.js +84 -38
- package/.claude-flow-novice/dist/src/api/auth-service.js.map +1 -1
- package/.claude-flow-novice/dist/src/api/claude-client.js +138 -3
- package/.claude-flow-novice/dist/src/api/claude-client.js.map +1 -1
- package/.claude-flow-novice/dist/src/cfn-loop/phase-orchestrator-example.js +1 -1
- package/.claude-flow-novice/dist/src/cfn-loop/scope-control.js +247 -0
- package/.claude-flow-novice/dist/src/cfn-loop/scope-control.js.map +1 -0
- package/.claude-flow-novice/dist/src/cli/commands/swarm.js +32 -15
- package/.claude-flow-novice/dist/src/cli/commands/swarm.js.map +1 -1
- package/.claude-flow-novice/dist/src/cli/commands/transparency.js +455 -0
- package/.claude-flow-novice/dist/src/cli/commands/transparency.js.map +1 -0
- package/.claude-flow-novice/dist/src/cli/simple-commands/init/templates/CLAUDE.md +129 -13
- package/.claude-flow-novice/dist/src/components/visualizations/index.js +9 -0
- package/.claude-flow-novice/dist/src/components/visualizations/index.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/adapters/v1-coordinator-adapter.js +462 -0
- package/.claude-flow-novice/dist/src/coordination/adapters/v1-coordinator-adapter.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/config-translator.js +248 -0
- package/.claude-flow-novice/dist/src/coordination/config-translator.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/coordination-toggle.js +287 -0
- package/.claude-flow-novice/dist/src/coordination/coordination-toggle.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/distributed-consensus.js +68 -9
- package/.claude-flow-novice/dist/src/coordination/distributed-consensus.js.map +1 -1
- package/.claude-flow-novice/dist/src/coordination/feature-flags.js +166 -0
- package/.claude-flow-novice/dist/src/coordination/feature-flags.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/queen-agent.js +18 -4
- package/.claude-flow-novice/dist/src/coordination/queen-agent.js.map +1 -1
- package/.claude-flow-novice/dist/src/coordination/role-assignment.js +6 -110
- package/.claude-flow-novice/dist/src/coordination/role-assignment.js.map +1 -1
- package/.claude-flow-novice/dist/src/coordination/v2/cache/artifact-cache-optimizer.js +632 -0
- package/.claude-flow-novice/dist/src/coordination/v2/cache/artifact-cache-optimizer.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/cache/index.js +11 -0
- package/.claude-flow-novice/dist/src/coordination/v2/cache/index.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/checkpoints/checkpoint-compressor.js +318 -0
- package/.claude-flow-novice/dist/src/coordination/v2/checkpoints/checkpoint-compressor.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/coordinators/cascading-shutdown.example.js +364 -0
- package/.claude-flow-novice/dist/src/coordination/v2/coordinators/cascading-shutdown.example.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/coordinators/cascading-shutdown.js +492 -0
- package/.claude-flow-novice/dist/src/coordination/v2/coordinators/cascading-shutdown.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/coordinators/hierarchical-coordinator.js +786 -0
- package/.claude-flow-novice/dist/src/coordination/v2/coordinators/hierarchical-coordinator.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/coordinators/index.js +16 -0
- package/.claude-flow-novice/dist/src/coordination/v2/coordinators/index.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/coordinators/parent-child-manager.js +342 -0
- package/.claude-flow-novice/dist/src/coordination/v2/coordinators/parent-child-manager.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/coordinators/swarm-coordinator-v2.js +601 -0
- package/.claude-flow-novice/dist/src/coordination/v2/coordinators/swarm-coordinator-v2.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/core/help-request-metrics.js +211 -0
- package/.claude-flow-novice/dist/src/coordination/v2/core/help-request-metrics.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/core/index.js +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/core/index.js.map +1 -1
- package/.claude-flow-novice/dist/src/coordination/v2/core/message-broker.js +365 -6
- package/.claude-flow-novice/dist/src/coordination/v2/core/message-broker.js.map +1 -1
- package/.claude-flow-novice/dist/src/coordination/v2/core/resource-manager-safe.js +478 -0
- package/.claude-flow-novice/dist/src/coordination/v2/core/resource-manager-safe.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/core/state-machine-config.js +5 -2
- package/.claude-flow-novice/dist/src/coordination/v2/core/state-machine-config.js.map +1 -1
- package/.claude-flow-novice/dist/src/coordination/v2/core/state-machine.js +189 -0
- package/.claude-flow-novice/dist/src/coordination/v2/core/state-machine.js.map +1 -1
- package/.claude-flow-novice/dist/src/coordination/v2/deadlock/deadlock-detector.js +424 -0
- package/.claude-flow-novice/dist/src/coordination/v2/deadlock/deadlock-detector.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/deadlock/index.js +9 -0
- package/.claude-flow-novice/dist/src/coordination/v2/deadlock/index.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/deadlock/resource-manager.js +669 -0
- package/.claude-flow-novice/dist/src/coordination/v2/deadlock/resource-manager.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/dependency/artifact-storage.js +451 -0
- package/.claude-flow-novice/dist/src/coordination/v2/dependency/artifact-storage.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/dependency/cycle-detector.js +271 -0
- package/.claude-flow-novice/dist/src/coordination/v2/dependency/cycle-detector.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/dependency/dependency-graph.js +335 -0
- package/.claude-flow-novice/dist/src/coordination/v2/dependency/dependency-graph.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/dependency/dependency-manager.js +439 -0
- package/.claude-flow-novice/dist/src/coordination/v2/dependency/dependency-manager.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/dependency/dependency-request.js +92 -0
- package/.claude-flow-novice/dist/src/coordination/v2/dependency/dependency-request.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/dependency/index.js +21 -0
- package/.claude-flow-novice/dist/src/coordination/v2/dependency/index.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/dependency/topological-sort.js +223 -0
- package/.claude-flow-novice/dist/src/coordination/v2/dependency/topological-sort.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-coordinator.js +436 -0
- package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-coordinator.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-matcher.js +278 -0
- package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-matcher.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-request-handler.js +317 -0
- package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-request-handler.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-request.js +273 -0
- package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-request.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/help-system/index.js +15 -0
- package/.claude-flow-novice/dist/src/coordination/v2/help-system/index.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/help-system/waiting-agent-pool.js +512 -0
- package/.claude-flow-novice/dist/src/coordination/v2/help-system/waiting-agent-pool.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/index.js +6 -0
- package/.claude-flow-novice/dist/src/coordination/v2/index.js.map +1 -1
- package/.claude-flow-novice/dist/src/coordination/v2/integration/help-deadlock-integration.js +557 -0
- package/.claude-flow-novice/dist/src/coordination/v2/integration/help-deadlock-integration.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/integration/index.js +14 -0
- package/.claude-flow-novice/dist/src/coordination/v2/integration/index.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/integration/message-bus-completion-integration.example.js +212 -0
- package/.claude-flow-novice/dist/src/coordination/v2/integration/message-bus-completion-integration.example.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/integration/message-bus-completion-integration.js +552 -0
- package/.claude-flow-novice/dist/src/coordination/v2/integration/message-bus-completion-integration.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/memory/dependency-storage.js +367 -0
- package/.claude-flow-novice/dist/src/coordination/v2/memory/dependency-storage.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/memory/index.js +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/memory/index.js.map +1 -1
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/channel.js +371 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/channel.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/dependency-channel.js +355 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/dependency-channel.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/help-channel.js +424 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/help-channel.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/index.js +16 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/index.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/state-channel.js +295 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/state-channel.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/task-channel.js +411 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/task-channel.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/index.js +14 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/index.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/message-bus.js +387 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/message-bus.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/message-persistence.js +589 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/message-persistence.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/message-router.js +444 -0
- package/.claude-flow-novice/dist/src/coordination/v2/messaging/message-router.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/checkpoint-manager.js +29 -8
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/checkpoint-manager.js.map +1 -1
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/help-coordinator.js +470 -0
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/help-coordinator.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/hierarchical-background-integration.js +450 -0
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/hierarchical-background-integration.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/index.js +5 -0
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/index.js.map +1 -1
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/multi-level-control.js +545 -0
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/multi-level-control.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/query-controller.js +44 -0
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/query-controller.js.map +1 -1
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/query-message-integration.js +415 -0
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/query-message-integration.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/session-pool-optimizer.js +615 -0
- package/.claude-flow-novice/dist/src/coordination/v2/sdk/session-pool-optimizer.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/security/payload-validator.js +259 -0
- package/.claude-flow-novice/dist/src/coordination/v2/security/payload-validator.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/transparency/index.js +17 -0
- package/.claude-flow-novice/dist/src/coordination/v2/transparency/index.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/transparency/transparency-integration.js +357 -0
- package/.claude-flow-novice/dist/src/coordination/v2/transparency/transparency-integration.js.map +1 -0
- package/.claude-flow-novice/dist/src/coordination/v2/transparency/transparency-system.js +679 -0
- package/.claude-flow-novice/dist/src/coordination/v2/transparency/transparency-system.js.map +1 -0
- package/.claude-flow-novice/dist/src/core/agent-manager.js +30 -0
- package/.claude-flow-novice/dist/src/core/agent-manager.js.map +1 -1
- package/.claude-flow-novice/dist/src/mcp/server.js +21 -2
- package/.claude-flow-novice/dist/src/mcp/server.js.map +1 -1
- package/.claude-flow-novice/dist/src/monitoring/apm/apm-integration.js +719 -0
- package/.claude-flow-novice/dist/src/monitoring/apm/apm-integration.js.map +1 -0
- package/.claude-flow-novice/dist/src/monitoring/apm/datadog-collector.js +363 -0
- package/.claude-flow-novice/dist/src/monitoring/apm/datadog-collector.js.map +1 -0
- package/.claude-flow-novice/dist/src/monitoring/apm/index.js +97 -0
- package/.claude-flow-novice/dist/src/monitoring/apm/index.js.map +1 -0
- package/.claude-flow-novice/dist/src/monitoring/apm/newrelic-collector.js +384 -0
- package/.claude-flow-novice/dist/src/monitoring/apm/newrelic-collector.js.map +1 -0
- package/.claude-flow-novice/dist/src/monitoring/apm/performance-optimizer.js +612 -0
- package/.claude-flow-novice/dist/src/monitoring/apm/performance-optimizer.js.map +1 -0
- package/.claude-flow-novice/dist/src/monitoring/metrics-collector.js +282 -0
- package/.claude-flow-novice/dist/src/monitoring/metrics-collector.js.map +1 -0
- package/.claude-flow-novice/dist/src/observability/metrics-counter.js +268 -0
- package/.claude-flow-novice/dist/src/observability/metrics-counter.js.map +1 -0
- package/.claude-flow-novice/dist/src/observability/metrics-storage.js +265 -0
- package/.claude-flow-novice/dist/src/observability/metrics-storage.js.map +1 -0
- package/.claude-flow-novice/dist/src/observability/telemetry.js +26 -0
- package/.claude-flow-novice/dist/src/observability/telemetry.js.map +1 -1
- package/.claude-flow-novice/dist/src/providers/tiered-router.js +64 -10
- package/.claude-flow-novice/dist/src/providers/tiered-router.js.map +1 -1
- package/.claude-flow-novice/dist/src/providers/zai-provider.js +196 -97
- package/.claude-flow-novice/dist/src/providers/zai-provider.js.map +1 -1
- package/.claude-flow-novice/dist/src/slash-commands/cfn-claude-sync.js +533 -0
- package/.claude-flow-novice/dist/src/slash-commands/index.js +5 -0
- package/.claude-flow-novice/dist/src/slash-commands/metrics-summary-class.js +74 -0
- package/.claude-flow-novice/dist/src/slash-commands/metrics-summary.js +335 -0
- package/.claude-flow-novice/dist/src/slash-commands/register-all-commands.js +12 -0
- package/.claude-flow-novice/dist/src/verification/checkpoint-compression-demo.js +96 -0
- package/.claude-flow-novice/dist/src/verification/checkpoint-compression-demo.js.map +1 -0
- package/.claude-flow-novice/dist/src/verification/checkpoint-compression.js +406 -0
- package/.claude-flow-novice/dist/src/verification/checkpoint-compression.js.map +1 -0
- package/.claude-flow-novice/dist/src/verification/checkpoint-manager.js +35 -5
- package/.claude-flow-novice/dist/src/verification/checkpoint-manager.js.map +1 -1
- package/.claude-flow-novice/dist/src/web/api/apm-routes.js +355 -0
- package/.claude-flow-novice/dist/src/web/api/apm-routes.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/api/config/api-config.js +186 -0
- package/.claude-flow-novice/dist/src/web/api/config/api-config.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/api/middleware/auth.js +205 -0
- package/.claude-flow-novice/dist/src/web/api/middleware/auth.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/api/middleware/cache.js +262 -0
- package/.claude-flow-novice/dist/src/web/api/middleware/cache.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/api/middleware/error-handler.js +250 -0
- package/.claude-flow-novice/dist/src/web/api/middleware/error-handler.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/api/middleware/request-logger.js +217 -0
- package/.claude-flow-novice/dist/src/web/api/middleware/request-logger.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/api/middleware/validation.js +325 -0
- package/.claude-flow-novice/dist/src/web/api/middleware/validation.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/api/routes/events.js +465 -0
- package/.claude-flow-novice/dist/src/web/api/routes/events.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/api/routes/hierarchy.js +302 -0
- package/.claude-flow-novice/dist/src/web/api/routes/hierarchy.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/api/routes/index.js +14 -0
- package/.claude-flow-novice/dist/src/web/api/routes/index.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/api/routes/metrics.js +561 -0
- package/.claude-flow-novice/dist/src/web/api/routes/metrics.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/api/routes/status.js +450 -0
- package/.claude-flow-novice/dist/src/web/api/routes/status.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/api/server.js +451 -0
- package/.claude-flow-novice/dist/src/web/api/server.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/dashboard/hooks/useWebSocket.js +385 -0
- package/.claude-flow-novice/dist/src/web/dashboard/hooks/useWebSocket.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/dashboard/index.js +87 -0
- package/.claude-flow-novice/dist/src/web/dashboard/index.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/dashboard/types.js +6 -0
- package/.claude-flow-novice/dist/src/web/dashboard/types.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/frontend/src/utils/security.js +425 -0
- package/.claude-flow-novice/dist/src/web/frontend/src/utils/security.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/security/security-middleware.js +379 -0
- package/.claude-flow-novice/dist/src/web/security/security-middleware.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/websocket/apm-websocket-handler.js +441 -0
- package/.claude-flow-novice/dist/src/web/websocket/apm-websocket-handler.js.map +1 -0
- package/.claude-flow-novice/dist/src/web/websocket/websocket-manager.js +255 -1
- package/.claude-flow-novice/dist/src/web/websocket/websocket-manager.js.map +1 -1
- package/.claude-flow-novice/metrics.db +0 -0
- package/.claude-flow-novice/metrics.db-shm +0 -0
- package/.claude-flow-novice/metrics.db-wal +0 -0
- package/AGENT_PERFORMANCE_GUIDELINES.md +88 -0
- package/CLAUDE.md +60 -3
- package/MEMORY_LEAK_ROOT_CAUSE.md +149 -0
- package/README.md +27 -0
- package/config/hooks/post-edit-pipeline.js +36 -2
- package/examples/metrics-counter-demo.ts +106 -0
- package/examples/persistent-metrics-demo.ts +83 -0
- package/examples/phase-5-multi-level-control.ts +282 -0
- package/examples/session-pool-optimizer-example.ts +311 -0
- package/package.json +18 -4
- package/scripts/check-routing-stats.cjs +122 -0
- package/scripts/monitor-loop.sh +65 -0
- package/scripts/monitor-memory.sh +47 -0
- package/scripts/monitor.py +43 -0
- package/scripts/pre-publish-validation.cjs +212 -0
- package/scripts/test-provider-routing.cjs +228 -0
- package/scripts/test-routing-telemetry.cjs +147 -0
- package/scripts/test-zai-10k.cjs +81 -0
- package/scripts/test-zai-api.cjs +191 -0
- package/scripts/test-zai-diagnostic.cjs +151 -0
- package/scripts/test-zai-final.cjs +128 -0
- package/scripts/test-zai-with-env.cjs +85 -0
- package/scripts/validate-coordination-cli.js +69 -0
- package/scripts/validate-coordination-toggle-integration.cjs +501 -0
- package/src/cli/simple-commands/init/templates/CLAUDE.md +29 -0
- package/src/observability/metrics-counter.ts +347 -0
- package/src/observability/metrics-storage.ts +356 -0
- package/src/observability/telemetry.ts +658 -0
- package/src/slash-commands/cfn-claude-sync.js +533 -0
- package/src/slash-commands/index.js +5 -0
- package/src/slash-commands/metrics-summary-class.js +74 -0
- package/src/slash-commands/metrics-summary.js +335 -0
- package/src/slash-commands/register-all-commands.js +12 -0
package/.claude-flow-novice/dist/src/coordination/v2/coordinators/cascading-shutdown.example.js
ADDED
|
@@ -0,0 +1,364 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Cascading Shutdown Coordinator - Usage Examples
|
|
3
|
+
*
|
|
4
|
+
* Demonstrates hierarchical shutdown coordination with top-down notification
|
|
5
|
+
* and bottom-up completion aggregation.
|
|
6
|
+
*/ import { CascadingShutdown } from './cascading-shutdown.js';
|
|
7
|
+
/**
|
|
8
|
+
* Example 1: Basic Hierarchical Shutdown
|
|
9
|
+
*
|
|
10
|
+
* Simple 3-level hierarchy with graceful shutdown from root.
|
|
11
|
+
*/ async function example1_BasicShutdown() {
|
|
12
|
+
const cascadingShutdown = new CascadingShutdown(undefined, {
|
|
13
|
+
maxShutdownTimeMs: 10000,
|
|
14
|
+
createShutdownCheckpoints: true,
|
|
15
|
+
enableResourceCleanup: true,
|
|
16
|
+
notificationTimeoutMs: 100,
|
|
17
|
+
completionTimeoutMs: 200,
|
|
18
|
+
agentGracePeriodMs: 500
|
|
19
|
+
});
|
|
20
|
+
// Register 3-level hierarchy
|
|
21
|
+
cascadingShutdown.registerHierarchy('swarm-1', 'coordinator-0', [
|
|
22
|
+
{
|
|
23
|
+
agentId: 'coordinator-0',
|
|
24
|
+
level: 0,
|
|
25
|
+
childIds: [
|
|
26
|
+
'agent-1',
|
|
27
|
+
'agent-2'
|
|
28
|
+
],
|
|
29
|
+
resources: [
|
|
30
|
+
{
|
|
31
|
+
type: 'connection',
|
|
32
|
+
id: 'db-conn-1',
|
|
33
|
+
cleaned: false
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
type: 'subscription',
|
|
37
|
+
id: 'event-sub-1',
|
|
38
|
+
cleaned: false
|
|
39
|
+
}
|
|
40
|
+
]
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
agentId: 'agent-1',
|
|
44
|
+
level: 1,
|
|
45
|
+
parentId: 'coordinator-0',
|
|
46
|
+
childIds: [
|
|
47
|
+
'agent-3',
|
|
48
|
+
'agent-4'
|
|
49
|
+
],
|
|
50
|
+
resources: [
|
|
51
|
+
{
|
|
52
|
+
type: 'file',
|
|
53
|
+
id: '/tmp/agent-1-cache.json',
|
|
54
|
+
cleaned: false
|
|
55
|
+
}
|
|
56
|
+
]
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
agentId: 'agent-2',
|
|
60
|
+
level: 1,
|
|
61
|
+
parentId: 'coordinator-0',
|
|
62
|
+
childIds: [
|
|
63
|
+
'agent-5'
|
|
64
|
+
],
|
|
65
|
+
resources: [
|
|
66
|
+
{
|
|
67
|
+
type: 'process',
|
|
68
|
+
id: 'worker-proc-123',
|
|
69
|
+
cleaned: false
|
|
70
|
+
}
|
|
71
|
+
]
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
agentId: 'agent-3',
|
|
75
|
+
level: 2,
|
|
76
|
+
parentId: 'agent-1',
|
|
77
|
+
resources: []
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
agentId: 'agent-4',
|
|
81
|
+
level: 2,
|
|
82
|
+
parentId: 'agent-1',
|
|
83
|
+
resources: []
|
|
84
|
+
},
|
|
85
|
+
{
|
|
86
|
+
agentId: 'agent-5',
|
|
87
|
+
level: 2,
|
|
88
|
+
parentId: 'agent-2',
|
|
89
|
+
resources: []
|
|
90
|
+
}
|
|
91
|
+
]);
|
|
92
|
+
// Register resource cleanup handlers
|
|
93
|
+
cascadingShutdown.registerResourceCleanup('connection', async (resource)=>{
|
|
94
|
+
console.log(`Closing database connection: ${resource.id}`);
|
|
95
|
+
// await db.close(resource.id);
|
|
96
|
+
});
|
|
97
|
+
cascadingShutdown.registerResourceCleanup('file', async (resource)=>{
|
|
98
|
+
console.log(`Deleting temporary file: ${resource.id}`);
|
|
99
|
+
// await fs.unlink(resource.id);
|
|
100
|
+
});
|
|
101
|
+
cascadingShutdown.registerResourceCleanup('process', async (resource)=>{
|
|
102
|
+
console.log(`Terminating worker process: ${resource.id}`);
|
|
103
|
+
// await killProcess(resource.id);
|
|
104
|
+
});
|
|
105
|
+
// Initiate shutdown from root
|
|
106
|
+
const result = await cascadingShutdown.initiateShutdown('coordinator-0', 'Task completed successfully');
|
|
107
|
+
console.log('Shutdown Results:', {
|
|
108
|
+
success: result.success,
|
|
109
|
+
totalAgents: result.totalAgents,
|
|
110
|
+
successfulShutdowns: result.successfulShutdowns,
|
|
111
|
+
totalLatencyMs: result.totalLatencyMs,
|
|
112
|
+
notificationLatencyMs: result.notificationLatencyMs,
|
|
113
|
+
aggregationLatencyMs: result.aggregationLatencyMs,
|
|
114
|
+
resourcesCleaned: result.totalResourcesCleaned
|
|
115
|
+
});
|
|
116
|
+
// Performance validation
|
|
117
|
+
if (result.totalLatencyMs < 1000 && result.totalAgents <= 20) {
|
|
118
|
+
console.log('✅ Performance target met: <1s for 6 agents');
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
/**
|
|
122
|
+
* Example 2: Emergency Shutdown
|
|
123
|
+
*
|
|
124
|
+
* Fast shutdown without checkpoints or resource cleanup (critical errors).
|
|
125
|
+
*/ async function example2_EmergencyShutdown() {
|
|
126
|
+
const cascadingShutdown = new CascadingShutdown(undefined, {
|
|
127
|
+
maxShutdownTimeMs: 5000,
|
|
128
|
+
createShutdownCheckpoints: false,
|
|
129
|
+
enableResourceCleanup: false,
|
|
130
|
+
enableEmergencyMode: true
|
|
131
|
+
});
|
|
132
|
+
cascadingShutdown.registerHierarchy('swarm-2', 'root-agent', [
|
|
133
|
+
{
|
|
134
|
+
agentId: 'root-agent',
|
|
135
|
+
level: 0,
|
|
136
|
+
childIds: [
|
|
137
|
+
'agent-a',
|
|
138
|
+
'agent-b'
|
|
139
|
+
]
|
|
140
|
+
},
|
|
141
|
+
{
|
|
142
|
+
agentId: 'agent-a',
|
|
143
|
+
level: 1,
|
|
144
|
+
parentId: 'root-agent'
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
agentId: 'agent-b',
|
|
148
|
+
level: 1,
|
|
149
|
+
parentId: 'root-agent'
|
|
150
|
+
}
|
|
151
|
+
]);
|
|
152
|
+
// Emergency shutdown (skips checkpoints and resource cleanup)
|
|
153
|
+
const result = await cascadingShutdown.emergencyShutdown('root-agent', 'Critical memory leak detected');
|
|
154
|
+
console.log('Emergency Shutdown:', {
|
|
155
|
+
success: result.success,
|
|
156
|
+
latencyMs: result.totalLatencyMs,
|
|
157
|
+
reason: result.reason
|
|
158
|
+
});
|
|
159
|
+
}
|
|
160
|
+
/**
|
|
161
|
+
* Example 3: Deep Hierarchy (10+ levels)
|
|
162
|
+
*
|
|
163
|
+
* Tests cascading shutdown with maximum nesting depth.
|
|
164
|
+
*/ async function example3_DeepHierarchy() {
|
|
165
|
+
const cascadingShutdown = new CascadingShutdown();
|
|
166
|
+
// Build 10-level hierarchy
|
|
167
|
+
const nodes = [];
|
|
168
|
+
for(let level = 0; level < 10; level++){
|
|
169
|
+
const agentId = `agent-L${level}`;
|
|
170
|
+
const parentId = level > 0 ? `agent-L${level - 1}` : undefined;
|
|
171
|
+
const childIds = level < 9 ? [
|
|
172
|
+
`agent-L${level + 1}`
|
|
173
|
+
] : [];
|
|
174
|
+
nodes.push({
|
|
175
|
+
agentId,
|
|
176
|
+
level,
|
|
177
|
+
parentId,
|
|
178
|
+
childIds
|
|
179
|
+
});
|
|
180
|
+
}
|
|
181
|
+
cascadingShutdown.registerHierarchy('deep-swarm', 'agent-L0', nodes);
|
|
182
|
+
// Shutdown from root (Level 0)
|
|
183
|
+
const result = await cascadingShutdown.initiateShutdown('agent-L0', 'Deep hierarchy test completion');
|
|
184
|
+
console.log('Deep Hierarchy Shutdown:', {
|
|
185
|
+
maxDepth: result.maxDepth,
|
|
186
|
+
totalAgents: result.totalAgents,
|
|
187
|
+
notificationLatency: result.notificationLatencyMs,
|
|
188
|
+
aggregationLatency: result.aggregationLatencyMs
|
|
189
|
+
});
|
|
190
|
+
// Verify bottom-up completion order
|
|
191
|
+
const levels = result.agentResults.map((r)=>r.level).sort((a, b)=>b - a);
|
|
192
|
+
console.log('Completion order (by level, desc):', levels);
|
|
193
|
+
// Expected: [9, 8, 7, 6, 5, 4, 3, 2, 1, 0] (leaves first, root last)
|
|
194
|
+
}
|
|
195
|
+
/**
|
|
196
|
+
* Example 4: Event Monitoring
|
|
197
|
+
*
|
|
198
|
+
* Listen to shutdown events for debugging and metrics.
|
|
199
|
+
*/ async function example4_EventMonitoring() {
|
|
200
|
+
const cascadingShutdown = new CascadingShutdown();
|
|
201
|
+
// Monitor shutdown events
|
|
202
|
+
cascadingShutdown.on('shutdown:started', (data)=>{
|
|
203
|
+
console.log('[Event] Shutdown started:', data);
|
|
204
|
+
});
|
|
205
|
+
cascadingShutdown.on('agent:notified', (data)=>{
|
|
206
|
+
console.log(`[Event] Agent ${data.agentId} notified at level ${data.level}`);
|
|
207
|
+
});
|
|
208
|
+
cascadingShutdown.on('agent:shutdown', (result)=>{
|
|
209
|
+
console.log(`[Event] Agent ${result.agentId} shutdown:`, {
|
|
210
|
+
success: result.success,
|
|
211
|
+
resourcesCleaned: result.resourcesCleaned,
|
|
212
|
+
latencyMs: result.completionLatencyMs
|
|
213
|
+
});
|
|
214
|
+
});
|
|
215
|
+
cascadingShutdown.on('resource:cleaned', (data)=>{
|
|
216
|
+
console.log(`[Event] Resource cleaned: ${data.resourceType} ${data.resourceId}`);
|
|
217
|
+
});
|
|
218
|
+
cascadingShutdown.on('shutdown:completed', (result)=>{
|
|
219
|
+
console.log('[Event] Shutdown completed:', {
|
|
220
|
+
success: result.success,
|
|
221
|
+
totalLatencyMs: result.totalLatencyMs
|
|
222
|
+
});
|
|
223
|
+
});
|
|
224
|
+
// Register and shutdown
|
|
225
|
+
cascadingShutdown.registerHierarchy('monitored-swarm', 'root', [
|
|
226
|
+
{
|
|
227
|
+
agentId: 'root',
|
|
228
|
+
level: 0,
|
|
229
|
+
childIds: [
|
|
230
|
+
'child-1',
|
|
231
|
+
'child-2'
|
|
232
|
+
]
|
|
233
|
+
},
|
|
234
|
+
{
|
|
235
|
+
agentId: 'child-1',
|
|
236
|
+
level: 1,
|
|
237
|
+
parentId: 'root'
|
|
238
|
+
},
|
|
239
|
+
{
|
|
240
|
+
agentId: 'child-2',
|
|
241
|
+
level: 1,
|
|
242
|
+
parentId: 'root'
|
|
243
|
+
}
|
|
244
|
+
]);
|
|
245
|
+
await cascadingShutdown.initiateShutdown('root', 'Event monitoring example');
|
|
246
|
+
}
|
|
247
|
+
/**
|
|
248
|
+
* Example 5: Integration with HierarchicalCompletionDetector
|
|
249
|
+
*
|
|
250
|
+
* Combine completion detection with cascading shutdown.
|
|
251
|
+
*/ async function example5_CompletionIntegration(hierarchicalDetector) {
|
|
252
|
+
const cascadingShutdown = new CascadingShutdown(hierarchicalDetector, {
|
|
253
|
+
createShutdownCheckpoints: true,
|
|
254
|
+
enableResourceCleanup: true
|
|
255
|
+
});
|
|
256
|
+
// Register hierarchy
|
|
257
|
+
cascadingShutdown.registerHierarchy('completion-swarm', 'pm-agent', [
|
|
258
|
+
{
|
|
259
|
+
agentId: 'pm-agent',
|
|
260
|
+
level: 0,
|
|
261
|
+
childIds: [
|
|
262
|
+
'worker-1',
|
|
263
|
+
'worker-2'
|
|
264
|
+
]
|
|
265
|
+
},
|
|
266
|
+
{
|
|
267
|
+
agentId: 'worker-1',
|
|
268
|
+
level: 1,
|
|
269
|
+
parentId: 'pm-agent'
|
|
270
|
+
},
|
|
271
|
+
{
|
|
272
|
+
agentId: 'worker-2',
|
|
273
|
+
level: 1,
|
|
274
|
+
parentId: 'pm-agent'
|
|
275
|
+
}
|
|
276
|
+
]);
|
|
277
|
+
// Wait for completion detection
|
|
278
|
+
const completionResult = await hierarchicalDetector.detectCompletion('completion-swarm');
|
|
279
|
+
if (completionResult.completed) {
|
|
280
|
+
console.log('All agents completed. Initiating shutdown...');
|
|
281
|
+
// Shutdown after completion
|
|
282
|
+
const shutdownResult = await cascadingShutdown.initiateShutdown('pm-agent', 'Task completed - graceful shutdown');
|
|
283
|
+
console.log('Shutdown after completion:', {
|
|
284
|
+
checkpointsCreated: shutdownResult.agentResults.filter((r)=>r.checkpointId).length,
|
|
285
|
+
totalLatencyMs: shutdownResult.totalLatencyMs
|
|
286
|
+
});
|
|
287
|
+
}
|
|
288
|
+
}
|
|
289
|
+
/**
|
|
290
|
+
* Example 6: 20-Agent Performance Benchmark
|
|
291
|
+
*
|
|
292
|
+
* Validates <1s shutdown target for 20-agent hierarchy.
|
|
293
|
+
*/ async function example6_PerformanceBenchmark() {
|
|
294
|
+
const cascadingShutdown = new CascadingShutdown();
|
|
295
|
+
// Create 20-agent hierarchy (4 levels, 5 agents per level)
|
|
296
|
+
const nodes = [
|
|
297
|
+
{
|
|
298
|
+
agentId: 'root',
|
|
299
|
+
level: 0,
|
|
300
|
+
childIds: [
|
|
301
|
+
'L1-A',
|
|
302
|
+
'L1-B',
|
|
303
|
+
'L1-C',
|
|
304
|
+
'L1-D',
|
|
305
|
+
'L1-E'
|
|
306
|
+
]
|
|
307
|
+
}
|
|
308
|
+
];
|
|
309
|
+
// Level 1
|
|
310
|
+
for(let i = 0; i < 5; i++){
|
|
311
|
+
const agentId = `L1-${String.fromCharCode(65 + i)}`;
|
|
312
|
+
nodes.push({
|
|
313
|
+
agentId,
|
|
314
|
+
level: 1,
|
|
315
|
+
parentId: 'root',
|
|
316
|
+
childIds: [
|
|
317
|
+
`L2-${String.fromCharCode(65 + i)}`
|
|
318
|
+
]
|
|
319
|
+
});
|
|
320
|
+
}
|
|
321
|
+
// Level 2
|
|
322
|
+
for(let i = 0; i < 5; i++){
|
|
323
|
+
const agentId = `L2-${String.fromCharCode(65 + i)}`;
|
|
324
|
+
nodes.push({
|
|
325
|
+
agentId,
|
|
326
|
+
level: 2,
|
|
327
|
+
parentId: `L1-${String.fromCharCode(65 + i)}`,
|
|
328
|
+
childIds: [
|
|
329
|
+
`L3-${String.fromCharCode(65 + i)}`
|
|
330
|
+
]
|
|
331
|
+
});
|
|
332
|
+
}
|
|
333
|
+
// Level 3 (leaf nodes)
|
|
334
|
+
for(let i = 0; i < 5; i++){
|
|
335
|
+
const agentId = `L3-${String.fromCharCode(65 + i)}`;
|
|
336
|
+
nodes.push({
|
|
337
|
+
agentId,
|
|
338
|
+
level: 3,
|
|
339
|
+
parentId: `L2-${String.fromCharCode(65 + i)}`
|
|
340
|
+
});
|
|
341
|
+
}
|
|
342
|
+
cascadingShutdown.registerHierarchy('benchmark-swarm', 'root', nodes);
|
|
343
|
+
console.log('Starting 20-agent shutdown benchmark...');
|
|
344
|
+
const startTime = Date.now();
|
|
345
|
+
const result = await cascadingShutdown.initiateShutdown('root', 'Performance benchmark');
|
|
346
|
+
const totalTime = Date.now() - startTime;
|
|
347
|
+
console.log('Benchmark Results:', {
|
|
348
|
+
totalAgents: result.totalAgents,
|
|
349
|
+
totalLatencyMs: totalTime,
|
|
350
|
+
targetMet: totalTime < 1000,
|
|
351
|
+
notificationLatencyMs: result.notificationLatencyMs,
|
|
352
|
+
aggregationLatencyMs: result.aggregationLatencyMs
|
|
353
|
+
});
|
|
354
|
+
// Assert performance target
|
|
355
|
+
if (totalTime < 1000) {
|
|
356
|
+
console.log('✅ Performance target achieved: <1s for 20 agents');
|
|
357
|
+
} else {
|
|
358
|
+
console.warn(`⚠️ Performance target missed: ${totalTime}ms > 1000ms`);
|
|
359
|
+
}
|
|
360
|
+
}
|
|
361
|
+
// Export examples
|
|
362
|
+
export { example1_BasicShutdown, example2_EmergencyShutdown, example3_DeepHierarchy, example4_EventMonitoring, example5_CompletionIntegration, example6_PerformanceBenchmark };
|
|
363
|
+
|
|
364
|
+
//# sourceMappingURL=cascading-shutdown.example.js.map
|
package/.claude-flow-novice/dist/src/coordination/v2/coordinators/cascading-shutdown.example.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../../src/coordination/v2/coordinators/cascading-shutdown.example.ts"],"names":["CascadingShutdown","example1_BasicShutdown","cascadingShutdown","undefined","maxShutdownTimeMs","createShutdownCheckpoints","enableResourceCleanup","notificationTimeoutMs","completionTimeoutMs","agentGracePeriodMs","registerHierarchy","agentId","level","childIds","resources","type","id","cleaned","parentId","registerResourceCleanup","resource","console","log","result","initiateShutdown","success","totalAgents","successfulShutdowns","totalLatencyMs","notificationLatencyMs","aggregationLatencyMs","resourcesCleaned","totalResourcesCleaned","example2_EmergencyShutdown","enableEmergencyMode","emergencyShutdown","latencyMs","reason","example3_DeepHierarchy","nodes","push","maxDepth","notificationLatency","aggregationLatency","levels","agentResults","map","r","sort","a","b","example4_EventMonitoring","on","data","completionLatencyMs","resourceType","resourceId","example5_CompletionIntegration","hierarchicalDetector","completionResult","detectCompletion","completed","shutdownResult","checkpointsCreated","filter","checkpointId","length","example6_PerformanceBenchmark","i","String","fromCharCode","startTime","Date","now","totalTime","targetMet","warn"],"mappings":"AAAA;;;;;CAKC,GAED,SAASA,iBAAiB,QAAQ,0BAA0B;AAG5D;;;;CAIC,GACD,eAAeC;IACb,MAAMC,oBAAoB,IAAIF,kBAAkBG,WAAW;QACzDC,mBAAmB;QACnBC,2BAA2B;QAC3BC,uBAAuB;QACvBC,uBAAuB;QACvBC,qBAAqB;QACrBC,oBAAoB;IACtB;IAEA,6BAA6B;IAC7BP,kBAAkBQ,iBAAiB,CAAC,WAAW,iBAAiB;QAC9D;YACEC,SAAS;YACTC,OAAO;YACPC,UAAU;gBAAC;gBAAW;aAAU;YAChCC,WAAW;gBACT;oBAAEC,MAAM;oBAAcC,IAAI;oBAAaC,SAAS;gBAAM;gBACtD;oBAAEF,MAAM;oBAAgBC,IAAI;oBAAeC,SAAS;gBAAM;aAC3D;QACH;QACA;YACEN,SAAS;YACTC,OAAO;YACPM,UAAU;YACVL,UAAU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